@zyzgroup/core-web 0.1.84 → 0.1.86
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/dist/animate_ce.css +0 -18
- package/dist/zyzgroup_core_web.iife.js +27 -24
- package/dist/zyzgroup_core_web.iife.js.map +1 -1
- package/dist/zyzgroup_core_web.js +8644 -7989
- package/dist/zyzgroup_core_web.js.map +1 -1
- package/dist/zyzgroup_core_web.umd.cjs +27 -24
- package/dist/zyzgroup_core_web.umd.cjs.map +1 -1
- package/package.json +1 -1
- package/types/Context.d.ts +4 -3
- package/types/Context.d.ts.map +1 -1
- package/types/WebSocketClient.d.ts +3 -3
- package/types/WebSocketClient.d.ts.map +1 -1
- package/types/ajax.d.ts.map +1 -1
- package/types/axios.d.ts +2 -0
- package/types/axios.d.ts.map +1 -1
- package/types/env.d.ts +0 -6
- package/types/env.d.ts.map +1 -1
- package/types/hooks/index.d.ts +0 -1
- package/types/hooks/index.d.ts.map +1 -1
- package/types/hooks/useAttribute.d.ts +1 -1
- package/types/hooks/useAttribute.d.ts.map +1 -1
- package/types/hooks/useDraw/DrawContext.d.ts +3 -1
- package/types/hooks/useDraw/DrawContext.d.ts.map +1 -1
- package/types/hooks/useDraw/Shape.d.ts +134 -105
- package/types/hooks/useDraw/Shape.d.ts.map +1 -1
- package/types/hooks/useDraw/canvas/YZCanvasContext.d.ts +2 -1
- package/types/hooks/useDraw/canvas/YZCanvasContext.d.ts.map +1 -1
- package/types/hooks/useDraw/line/Arc.d.ts.map +1 -1
- package/types/hooks/useDraw/line/CubicBezier.d.ts +6 -6
- package/types/hooks/useDraw/line/CubicBezier.d.ts.map +1 -1
- package/types/hooks/useDraw/line/L.d.ts +1 -1
- package/types/hooks/useDraw/line/L.d.ts.map +1 -1
- package/types/hooks/useDraw/line/PathD.d.ts +23 -15
- package/types/hooks/useDraw/line/PathD.d.ts.map +1 -1
- package/types/hooks/useDraw/line/QuadraticBezier.d.ts +1 -1
- package/types/hooks/useDraw/line/QuadraticBezier.d.ts.map +1 -1
- package/types/hooks/useDraw/shapes/BallShape.d.ts +3 -11
- package/types/hooks/useDraw/shapes/BallShape.d.ts.map +1 -1
- package/types/hooks/useDraw/shapes/ConfettiShapeCombo.d.ts +27 -0
- package/types/hooks/useDraw/shapes/ConfettiShapeCombo.d.ts.map +1 -0
- package/types/hooks/useDraw/shapes/CrossShape.d.ts.map +1 -1
- package/types/hooks/useDraw/shapes/CurveShape.d.ts +24 -0
- package/types/hooks/useDraw/shapes/CurveShape.d.ts.map +1 -0
- package/types/hooks/useDraw/shapes/EllipseShape.d.ts +1 -0
- package/types/hooks/useDraw/shapes/EllipseShape.d.ts.map +1 -1
- package/types/hooks/useDraw/shapes/LineShape.d.ts +11 -9
- package/types/hooks/useDraw/shapes/LineShape.d.ts.map +1 -1
- package/types/hooks/useDraw/shapes/PointsShape.d.ts +35 -0
- package/types/hooks/useDraw/shapes/PointsShape.d.ts.map +1 -0
- package/types/hooks/useDraw/shapes/RectShape.d.ts +15 -12
- package/types/hooks/useDraw/shapes/RectShape.d.ts.map +1 -1
- package/types/hooks/useDraw/shapes/RingIndicatorShapeCombo.d.ts +2 -2
- package/types/hooks/useDraw/shapes/RingIndicatorShapeCombo.d.ts.map +1 -1
- package/types/hooks/useDraw/shapes/SegmentShapeCombo.d.ts +2 -2
- package/types/hooks/useDraw/shapes/SegmentShapeCombo.d.ts.map +1 -1
- package/types/hooks/useDraw/shapes/ShipShapeCombo.d.ts +6 -4
- package/types/hooks/useDraw/shapes/ShipShapeCombo.d.ts.map +1 -1
- package/types/hooks/useDraw/shapes/SliderShapeCombo.d.ts +3 -2
- package/types/hooks/useDraw/shapes/SliderShapeCombo.d.ts.map +1 -1
- package/types/hooks/useDraw/shapes/TextShape.d.ts +23 -0
- package/types/hooks/useDraw/shapes/TextShape.d.ts.map +1 -0
- package/types/hooks/useDraw/shapes/TreeShapeCombo.d.ts +3 -2
- package/types/hooks/useDraw/shapes/TreeShapeCombo.d.ts.map +1 -1
- package/types/hooks/useDraw/shapes/index.d.ts +4 -0
- package/types/hooks/useDraw/shapes/index.d.ts.map +1 -1
- package/types/hooks/useDraw/svg/SVGUtil.d.ts +3 -2
- package/types/hooks/useDraw/svg/SVGUtil.d.ts.map +1 -1
- package/types/hooks/useElement.d.ts +2 -2
- package/types/hooks/useElement.d.ts.map +1 -1
- package/types/hooks/useEventListener.d.ts +2 -0
- package/types/hooks/useEventListener.d.ts.map +1 -1
- package/types/hooks/useLocalStorage.d.ts +1 -1
- package/types/hooks/useLocalStorage.d.ts.map +1 -1
- package/types/hooks/useMutation.d.ts +1 -0
- package/types/hooks/useMutation.d.ts.map +1 -1
- package/types/hooks/useSafeArea.d.ts.map +1 -1
- package/types/hooks/useSessionStorage.d.ts +1 -1
- package/types/hooks/useSessionStorage.d.ts.map +1 -1
- package/types/hooks/useStyle.d.ts +1 -1
- package/types/hooks/useStyle.d.ts.map +1 -1
- package/types/hooks/useTheme.d.ts.map +1 -1
- package/types/hooks/useVnode.d.ts +5 -5
- package/types/hooks/useVnode.d.ts.map +1 -1
- package/types/index.d.ts +0 -3
- package/types/index.d.ts.map +1 -1
- package/types/math/Matrix.d.ts +3 -3
- package/types/math/Matrix.d.ts.map +1 -1
- package/types/math/ShapeGroup.d.ts +0 -34
- package/types/math/ShapeGroup.d.ts.map +1 -1
- package/types/math/shapes/Sector.d.ts +0 -65
- package/types/math/shapes/Sector.d.ts.map +1 -1
- package/types/math/shapes/Tip.d.ts +0 -21
- package/types/math/shapes/Tip.d.ts.map +1 -1
- package/types/rem.d.ts +1 -1
- package/types/rem.d.ts.map +1 -1
- package/types/signature.d.ts +29 -2
- package/types/signature.d.ts.map +1 -1
- package/types/vnode.d.ts.map +1 -1
- package/types/YZMessageChannel.d.ts +0 -21
- package/types/YZMessageChannel.d.ts.map +0 -1
- package/types/YZWorker.d.ts +0 -16
- package/types/YZWorker.d.ts.map +0 -1
- package/types/canvas/YZCanvas.d.ts +0 -1
- package/types/canvas/YZCanvas.d.ts.map +0 -1
- package/types/hooks/useTimestampValue.d.ts +0 -11
- package/types/hooks/useTimestampValue.d.ts.map +0 -1
- package/types/math/ShapeCombo.d.ts +0 -38
- package/types/math/ShapeCombo.d.ts.map +0 -1
- package/types/math/math/cameras/Camera.d.ts +0 -1
- package/types/math/math/cameras/Camera.d.ts.map +0 -1
- package/types/math/math/controls/Controls.d.ts +0 -1
- package/types/math/math/controls/Controls.d.ts.map +0 -1
- package/types/math/math/controls/OrbitControls.d.ts +0 -1
- package/types/math/math/controls/OrbitControls.d.ts.map +0 -1
- package/types/math/math/core/BufferGeometry.d.ts +0 -1
- package/types/math/math/core/BufferGeometry.d.ts.map +0 -1
- package/types/math/math/core/GLBufferAttribute.d.ts +0 -1
- package/types/math/math/core/GLBufferAttribute.d.ts.map +0 -1
- package/types/math/math/interpolants/Interpolant.d.ts +0 -14
- package/types/math/math/interpolants/Interpolant.d.ts.map +0 -1
- package/types/math/shapes/Arrow.d.ts +0 -10
- package/types/math/shapes/Arrow.d.ts.map +0 -1
- package/types/math/shapes/Confetti.d.ts +0 -27
- package/types/math/shapes/Confetti.d.ts.map +0 -1
- package/types/math/shapes/Cross.d.ts +0 -6
- package/types/math/shapes/Cross.d.ts.map +0 -1
- package/types/math/shapes/Ellipse.d.ts +0 -22
- package/types/math/shapes/Ellipse.d.ts.map +0 -1
- package/types/math/shapes/Fox.d.ts +0 -10
- package/types/math/shapes/Fox.d.ts.map +0 -1
- package/types/math/shapes/HalfRing.d.ts +0 -27
- package/types/math/shapes/HalfRing.d.ts.map +0 -1
- package/types/math/shapes/HalfRingIndicator.d.ts +0 -34
- package/types/math/shapes/HalfRingIndicator.d.ts.map +0 -1
- package/types/math/shapes/Heart.d.ts +0 -13
- package/types/math/shapes/Heart.d.ts.map +0 -1
- package/types/math/shapes/HeartVariant.d.ts +0 -13
- package/types/math/shapes/HeartVariant.d.ts.map +0 -1
- package/types/math/shapes/Line.d.ts +0 -19
- package/types/math/shapes/Line.d.ts.map +0 -1
- package/types/math/shapes/LinePicture.d.ts +0 -15
- package/types/math/shapes/LinePicture.d.ts.map +0 -1
- package/types/math/shapes/LineQuadraticBezier.d.ts +0 -21
- package/types/math/shapes/LineQuadraticBezier.d.ts.map +0 -1
- package/types/math/shapes/Point.d.ts +0 -85
- package/types/math/shapes/Point.d.ts.map +0 -1
- package/types/math/shapes/Points.d.ts +0 -28
- package/types/math/shapes/Points.d.ts.map +0 -1
- package/types/math/shapes/Rabbit.d.ts +0 -8
- package/types/math/shapes/Rabbit.d.ts.map +0 -1
- package/types/math/shapes/Rect.d.ts +0 -33
- package/types/math/shapes/Rect.d.ts.map +0 -1
- package/types/math/shapes/Ring.d.ts +0 -24
- package/types/math/shapes/Ring.d.ts.map +0 -1
- package/types/math/shapes/RingIndicator.d.ts +0 -28
- package/types/math/shapes/RingIndicator.d.ts.map +0 -1
- package/types/math/shapes/Segment.d.ts +0 -22
- package/types/math/shapes/Segment.d.ts.map +0 -1
- package/types/math/shapes/Ship.d.ts +0 -13
- package/types/math/shapes/Ship.d.ts.map +0 -1
- package/types/math/shapes/Slider.d.ts +0 -23
- package/types/math/shapes/Slider.d.ts.map +0 -1
- package/types/math/shapes/Star.d.ts +0 -11
- package/types/math/shapes/Star.d.ts.map +0 -1
- package/types/math/shapes/Text.d.ts +0 -21
- package/types/math/shapes/Text.d.ts.map +0 -1
- package/types/math/shapes/Tree.d.ts +0 -7
- package/types/math/shapes/Tree.d.ts.map +0 -1
- package/types/math/shapes/index.d.ts +0 -29
- package/types/math/shapes/index.d.ts.map +0 -1
- package/types/svg/YZSVG.d.ts +0 -1
- package/types/svg/YZSVG.d.ts.map +0 -1
- package/types/url.d.ts +0 -21
- package/types/url.d.ts.map +0 -1
package/package.json
CHANGED
package/types/Context.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type CreateStoreEnhancer, type EventBusListeners, type Reducer, type State, type Store, EventBus } from "@zyzgroup/core-common";
|
|
1
|
+
import { type CreateStoreEnhancer, type EventBusListeners, type Reducer, type State, type Store, EventBus, DialogSchedule } from "@zyzgroup/core-common";
|
|
2
2
|
import { type AxiosRequestConfig, type AxiosResponse, type AxiosError, FetchWithAxios } from "./axios";
|
|
3
3
|
export type ContextConfig<E> = {
|
|
4
4
|
store?: {
|
|
@@ -12,7 +12,7 @@ export type ContextConfig<E> = {
|
|
|
12
12
|
headers?: {
|
|
13
13
|
[key: string]: string;
|
|
14
14
|
};
|
|
15
|
-
responseType?: "arraybuffer" | "blob" | "document" | "json" | "text" | "stream"
|
|
15
|
+
responseType?: "arraybuffer" | "blob" | "document" | "json" | "text" | "stream";
|
|
16
16
|
responseEncoding?: "ascii" | "ASCII" | "ansi" | "ANSI" | "binary" | "BINARY" | "base64" | "BASE64" | "base64url" | "BASE64URL" | "hex" | "HEX" | "latin1" | "LATIN1" | "ucs-2" | "UCS-2" | "ucs2" | "UCS2" | "utf-8" | "UTF-8" | "utf8" | "UTF8" | "utf16le" | "UTF16LE";
|
|
17
17
|
interceptor?: {
|
|
18
18
|
request?: (config: AxiosRequestConfig) => void;
|
|
@@ -26,10 +26,11 @@ export type ContextConfig<E> = {
|
|
|
26
26
|
static?: Record<string, string | number>;
|
|
27
27
|
};
|
|
28
28
|
export declare class Context<E extends EventBusListeners = EventBusListeners> {
|
|
29
|
-
|
|
29
|
+
static: Record<string, string | number>;
|
|
30
30
|
store: Store;
|
|
31
31
|
eb: EventBus<E>;
|
|
32
32
|
axios: FetchWithAxios;
|
|
33
|
+
ds: DialogSchedule;
|
|
33
34
|
constructor(config?: ContextConfig<E>);
|
|
34
35
|
}
|
|
35
36
|
//# sourceMappingURL=Context.d.ts.map
|
package/types/Context.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Context.d.ts","sourceRoot":"","sources":["../src/Context.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,OAAO,EACZ,KAAK,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EAAE,CAAC,KAAK,EAAE,UAAU,KAAK,IAAI,CAAC;YAC3C,QAAQ,CAAC,EAAE,CAAC,QAAQ,EAAE,aAAa,KAAK,IAAI,CAAC;YAC7C,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,UAAU,KAAK,IAAI,CAAC;SAC7C,CAAC;QAEF,KAAK,CAAC,EAAE,MAAM,CAAC;QAEf,KAAK,CAAC,EAAE,MAAM,CAAC;KAChB,CAAC;IAGF,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC,CAAC;CAC1C,CAAC;AAEF,qBAAa,OAAO,CAAC,CAAC,SAAS,iBAAiB,GAAG,iBAAiB;IAC3D,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC,CAAC;IACxC,KAAK,EAAE,KAAK,CAAC;IACb,EAAE,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC;IAChB,KAAK,EAAE,cAAc,CAAC;IACtB,EAAE,EAAE,cAAc,CAAC;gBAEd,MAAM,GAAE,aAAa,CAAC,CAAC,CAAM;CAyB1C"}
|
|
@@ -28,7 +28,7 @@ export declare class WebSocketClient {
|
|
|
28
28
|
onerror?: (e: any) => void;
|
|
29
29
|
requestid: number;
|
|
30
30
|
waitings: Record<number, WebSocketClientRequest>;
|
|
31
|
-
listeners: Record<string, ((err: any, message?:
|
|
31
|
+
listeners: Record<string, ((err: any, message?: any) => void)[]>;
|
|
32
32
|
constructor(url?: string, options?: {
|
|
33
33
|
socketCreatorProtocols?: string | string[];
|
|
34
34
|
socketCreatorOptions?: Record<string, any>;
|
|
@@ -46,8 +46,8 @@ export declare class WebSocketClient {
|
|
|
46
46
|
private onunhandled;
|
|
47
47
|
private _send;
|
|
48
48
|
ping(): void;
|
|
49
|
-
register(address: string, listener: (err: any, message?:
|
|
50
|
-
unregister(address: string, listener: (err: any, message?:
|
|
49
|
+
register(address: string, listener: (err: any, message?: any) => void, headers?: Record<string, string>): void;
|
|
50
|
+
unregister(address: string, listener: (err: any, message?: any) => void, headers?: Record<string, string>): void;
|
|
51
51
|
publish(address: string, body: Record<string, any>, headers?: Record<string, string>): void;
|
|
52
52
|
send(address: string, body: Record<string, any>, headers?: Record<string, string>, timeout?: number): Promise<string>;
|
|
53
53
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WebSocketClient.d.ts","sourceRoot":"","sources":["../src/WebSocketClient.ts"],"names":[],"mappings":"AAWA,KAAK,sBAAsB,GAAG;IAC5B,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,GAAG,KAAK,IAAI,CAAC;CAChC,CAAC;AAEF,KAAK,aAAa,GAAG,CACnB,GAAG,EAAE,MAAM,EACX,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,EAC7B,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,KAC1B,SAAS,CAAC;AAEf,wBAAgB,eAAe,CAC7B,GAAG,EAAE,MAAM,EACX,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,EAC7B,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAC5B,SAAS,CAEX;AA2DD,wBAAgB,uBAAuB,CAAC,OAAO,EAAE,MAAM,UAItD;AAED,qBAAa,eAAe;IAC1B,MAAM,CAAC,UAAU,IAAwB;IACzC,MAAM,CAAC,IAAI,IAAkB;IAC7B,MAAM,CAAC,OAAO,IAAqB;IACnC,MAAM,CAAC,MAAM,IAAoB;IAEjC,GAAG,EAAE,MAAM,CAAC;IACZ,sBAAsB,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAC3C,oBAAoB,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC1C,aAAa,EAAE,aAAa,CAAC;IAE7B,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB,KAAK,EACD,OAAO,eA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M,CAAC,MAAM,EAAE,MAAM,CAAM;IAWzB,IAAI,CACf,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EACzB,OAAO,GAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAM,EACpC,OAAO,SAAQ,GACd,OAAO,CAAC,MAAM,CAAC;CA2BnB"}
|
package/types/ajax.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ajax.d.ts","sourceRoot":"","sources":["../src/ajax.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ajax.d.ts","sourceRoot":"","sources":["../src/ajax.ts"],"names":[],"mappings":"AAqDA,wBAAgB,oBAAoB,QAwBnC;AAED,wBAAgB,IAAI,CAClB,GAAG,EAAE,MAAM,EACX,OAAO,CAAC,EAAE;IACR,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,QAAQ,CAAC;IACzC,uBAAuB,CAAC,EAAE,MAAM,CAAC;IACjC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACjC,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,YAAY,CAAC,EAAE,EAAE,GAAG,MAAM,GAAG,aAAa,GAAG,MAAM,GAAG,UAAU,GAAG,MAAM,CAAC;IAC1E,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,CAAC,CAAC,EAAE,GAAG,EAAE,GAAG,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,KAAK,IAAI,CAAC;IACrE,IAAI,CAAC,EAAE,CAAC,CAAC,EAAE,GAAG,EAAE,GAAG,EAAE,cAAc,KAAK,IAAI,CAAC;IAC7C,SAAS,CAAC,EAAE,CAAC,CAAC,EAAE,GAAG,EAAE,GAAG,EAAE,cAAc,KAAK,IAAI,CAAC;IAClD,OAAO,CAAC,EAAE,CAAC,CAAC,EAAE,GAAG,EAAE,GAAG,EAAE,cAAc,KAAK,IAAI,CAAC;IAChD,KAAK,CAAC,EAAE,CAAC,CAAC,EAAE,GAAG,EAAE,GAAG,EAAE,cAAc,KAAK,IAAI,CAAC;IAC9C,KAAK,CAAC,EAAE,CAAC,CAAC,EAAE,GAAG,EAAE,GAAG,EAAE,cAAc,KAAK,IAAI,CAAC;CAC/C,oBA+IF;AAED,wBAAsB,iBAAiB,CAAC,WAAW,EAAE,eAAe;;UAGpD,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;;;;GAsFrC"}
|
package/types/axios.d.ts
CHANGED
|
@@ -2,6 +2,8 @@ import { type AxiosRequestConfig, type AxiosResponse, type AxiosError } from "ax
|
|
|
2
2
|
export { type AxiosRequestConfig, type AxiosResponse, type AxiosError } from "axios";
|
|
3
3
|
export interface FetchWithAxiosRequestConfig extends AxiosRequestConfig {
|
|
4
4
|
interceptor?: {
|
|
5
|
+
start?: () => void;
|
|
6
|
+
end?: () => void;
|
|
5
7
|
request?: (config: AxiosRequestConfig) => void;
|
|
6
8
|
requestError?: (error: AxiosError) => void;
|
|
7
9
|
response?: (response: AxiosResponse) => void;
|
package/types/axios.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"axios.d.ts","sourceRoot":"","sources":["../src/axios.ts"],"names":[],"mappings":"AAAA,OAAc,EACZ,KAAK,kBAAkB,EACvB,KAAK,aAAa,EAClB,KAAK,UAAU,EAEhB,MAAM,OAAO,CAAC;AACf,OAAO,EACL,KAAK,kBAAkB,EACvB,KAAK,aAAa,EAClB,KAAK,UAAU,EAChB,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"axios.d.ts","sourceRoot":"","sources":["../src/axios.ts"],"names":[],"mappings":"AAAA,OAAc,EACZ,KAAK,kBAAkB,EACvB,KAAK,aAAa,EAClB,KAAK,UAAU,EAEh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,GAAG,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,2BAA2B;IAI/D,OAAO,CAAC,CAAC,GAAG,GAAG,EAAE,GAAG,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,2BAA2B;IAIlE,IAAI,CAAC,CAAC,GAAG,GAAG,EACjB,GAAG,EAAE,MAAM,EACX,IAAI,CAAC,EAAE,GAAG,EACV,MAAM,CAAC,EAAE,2BAA2B;IAK/B,QAAQ,CAAC,CAAC,GAAG,GAAG,EACrB,GAAG,EAAE,MAAM,EACX,IAAI,EAAE,QAAQ,EACd,MAAM,CAAC,EAAE,2BAA2B;IAc/B,QAAQ,CAAC,CAAC,GAAG,GAAG,EACrB,GAAG,EAAE,MAAM,EACX,MAAM,EAAE,eAAe,EACvB,MAAM,CAAC,EAAE,2BAA2B;IAY/B,GAAG,CAAC,CAAC,GAAG,GAAG,EAChB,GAAG,EAAE,MAAM,EACX,IAAI,CAAC,EAAE,GAAG,EACV,MAAM,CAAC,EAAE,2BAA2B;IAK/B,KAAK,CAAC,CAAC,GAAG,GAAG,EAClB,GAAG,EAAE,MAAM,EACX,IAAI,CAAC,EAAE,GAAG,EACV,MAAM,CAAC,EAAE,2BAA2B;IAK/B,MAAM,CAAC,MAAM,CAAC,EAAE,2BAA2B,GAAG,MAAM;CAG5D"}
|
package/types/env.d.ts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
export function getOperatingSystemVersion(ua?: string): string;
|
|
2
|
-
export function compareVersion(v1: any, v2: any): 0 | 1 | -1;
|
|
3
2
|
export function getBrowserClient(): string;
|
|
4
3
|
export function getBrowserLanguage(): any;
|
|
5
4
|
export function getTimeZone(): string;
|
|
@@ -20,16 +19,11 @@ export const isIE: boolean;
|
|
|
20
19
|
export const isIE9: boolean;
|
|
21
20
|
export const isIE10: boolean;
|
|
22
21
|
export const isIE11: boolean;
|
|
23
|
-
export const hasDocument: boolean;
|
|
24
|
-
export const hasWindow: boolean;
|
|
25
|
-
export const hasHistory: boolean;
|
|
26
22
|
export const isBrowserSupportFileAPI: false | {
|
|
27
23
|
new (blobParts?: BlobPart[], options?: BlobPropertyBag): Blob;
|
|
28
24
|
prototype: Blob;
|
|
29
25
|
};
|
|
30
|
-
export const canUseWorker: boolean;
|
|
31
26
|
export const canUsePaths: boolean;
|
|
32
|
-
export const canDrawBitmap: boolean;
|
|
33
27
|
export function isElement(obj: any): any;
|
|
34
28
|
export const prefixes: string[];
|
|
35
29
|
//# sourceMappingURL=env.d.ts.map
|
package/types/env.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"env.d.ts","sourceRoot":"","sources":["../src/env.js"],"names":[],"mappings":"AAyBA,+DAwBC;AAED,
|
|
1
|
+
{"version":3,"file":"env.d.ts","sourceRoot":"","sources":["../src/env.js"],"names":[],"mappings":"AAyBA,+DAwBC;AAED,2CAyBC;AAkCD,0CAEC;AAED,sCAEC;AAED,iCAEC;AAED,mCAEC;AAED,wCAEC;AAED,qCAEC;AAED,oCAEC;AAED,qDAoBC;AAiBD,uCAEC;AAED,wCAEC;AAGD,8DAKC;AAGD,oEAEC;AA6BD,0CAMC;AAjOM,6CAmBN;AAuDM,kDA8BN;AAoDD,2BAAwD;AAKxD,4BAEU;AACV,6BAEU;AACV,6BAEU;AAuBV;;;EAKc;AAEd,kCACkE;AAQ5D,yCAOC;AAEP,gCAAqD"}
|
package/types/hooks/index.d.ts
CHANGED
|
@@ -15,7 +15,6 @@ export * from "./useDataset";
|
|
|
15
15
|
export * from "./useAttribute";
|
|
16
16
|
export * from "./useStyle";
|
|
17
17
|
export * from "./useTheme";
|
|
18
|
-
export * from "./useTimestampValue";
|
|
19
18
|
export * from "./useLocalStorage";
|
|
20
19
|
export * from "./useSessionStorage";
|
|
21
20
|
export * from "./useCookie";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/hooks/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC;AAErC,cAAc,cAAc,CAAC;AAC7B,cAAc,oBAAoB,CAAC;AACnC,cAAc,WAAW,CAAC;AAE1B,cAAc,oBAAoB,CAAC;AACnC,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,aAAa,CAAC;AAE5B,cAAc,iBAAiB,CAAC;AAChC,cAAc,oBAAoB,CAAC;AAEnC,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAE3B,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/hooks/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC;AAErC,cAAc,cAAc,CAAC;AAC7B,cAAc,oBAAoB,CAAC;AACnC,cAAc,WAAW,CAAC;AAE1B,cAAc,oBAAoB,CAAC;AACnC,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,aAAa,CAAC;AAE5B,cAAc,iBAAiB,CAAC;AAChC,cAAc,oBAAoB,CAAC;AAEnC,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAE3B,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAE7B,cAAc,YAAY,CAAC;AAE3B,cAAc,YAAY,CAAC;AAE3B,cAAc,uBAAuB,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type AnyElement } from "@zyzgroup/core-common";
|
|
2
2
|
import { YZCanvasContext } from "./useDraw/canvas";
|
|
3
|
-
export declare function useAttribute(el: AnyElement, prop?: string | Record<string,
|
|
3
|
+
export declare function useAttribute(el: AnyElement, prop?: string | Record<string, any>, value?: string): string | Record<string, string | Record<string, string>> | null | undefined;
|
|
4
4
|
export declare const domPrefixes: string[];
|
|
5
5
|
export declare function atomReadAttributes(el: AnyElement): Record<string, string | Record<string, string>>;
|
|
6
6
|
export declare function atomReadAttribute(el: AnyElement, prop: string): string | Record<string, string> | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useAttribute.d.ts","sourceRoot":"","sources":["../../src/hooks/useAttribute.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,UAAU,EAAW,MAAM,uBAAuB,CAAC;AAIjE,OAAO,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAKnD,wBAAgB,YAAY,CAC1B,EAAE,EAAE,UAAU,EACd,IAAI,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC,MAAM,EAAE,
|
|
1
|
+
{"version":3,"file":"useAttribute.d.ts","sourceRoot":"","sources":["../../src/hooks/useAttribute.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,UAAU,EAAW,MAAM,uBAAuB,CAAC;AAIjE,OAAO,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAKnD,wBAAgB,YAAY,CAC1B,EAAE,EAAE,UAAU,EACd,IAAI,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EACnC,KAAK,CAAC,EAAE,MAAM,+EAyCf;AAED,eAAO,MAAM,WAAW,UAA2C,CAAC;AAEpE,wBAAgB,kBAAkB,CAAC,EAAE,EAAE,UAAU,mDAahD;AAED,wBAAgB,iBAAiB,CAAC,EAAE,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,0CAM7D;AAED,wBAAgB,kBAAkB,CAChC,EAAE,EAAE,UAAU,EACd,IAAI,EAAE,MAAM,EACZ,KAAK,EAAE,MAAM,QAGd;AAED,wBAAgB,mBAAmB,CAAC,EAAE,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,QAOhE;AAGD,wBAAgB,qBAAqB,CACnC,GAAG,EAAE,eAAe,EACpB,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,cAAc,CAAC,QAsH/C"}
|
|
@@ -33,14 +33,16 @@ export declare class DrawContext {
|
|
|
33
33
|
};
|
|
34
34
|
private mouseSubscription;
|
|
35
35
|
shapes: Shape[];
|
|
36
|
+
shapeTap$: BehaviorSubject<Shape | null>;
|
|
37
|
+
private tapSubscription;
|
|
36
38
|
private lastMouseInShapeId;
|
|
37
39
|
private draggingShapeId;
|
|
38
40
|
private prevCursor;
|
|
39
41
|
constructor(PARENT_EL?: HTMLEventObservable, type?: DrawType, enableCustomContext?: boolean);
|
|
40
42
|
destroy(): void;
|
|
41
43
|
private setCursor;
|
|
42
|
-
private animateShape;
|
|
43
44
|
draw(...ss: DrawShape[]): void;
|
|
45
|
+
clear(): void;
|
|
44
46
|
drawMouseMoveLine(options?: {
|
|
45
47
|
brushSize?: number;
|
|
46
48
|
brushColor?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DrawContext.d.ts","sourceRoot":"","sources":["../../../src/hooks/useDraw/DrawContext.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"DrawContext.d.ts","sourceRoot":"","sources":["../../../src/hooks/useDraw/DrawContext.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAa1D,OAAO,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAO5C,OAAO,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAG3C,OAAO,EAAE,eAAe,EAAE,MAAM,MAAM,CAAC;AAQvC,MAAM,MAAM,SAAS,GAAG,KAAK,GAAG,UA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";
|
|
5
|
+
import { Matrix } from "../../math";
|
|
5
6
|
import { TweenRawOptions } from "../../animate/Timeline";
|
|
7
|
+
import { MousePointGroup } from "../useElementEvents";
|
|
6
8
|
export type ShapeBaseOptions = {
|
|
7
|
-
|
|
9
|
+
initD?: string | SVGParsedPathData[] | PathD;
|
|
10
|
+
};
|
|
11
|
+
export type ShapeAttributeOptions = {
|
|
8
12
|
attrs?: Record<string, string | CanvasGradient>;
|
|
13
|
+
style?: Record<string, string>;
|
|
9
14
|
};
|
|
10
15
|
export type ShapeTransformOptions = {
|
|
11
16
|
centerX?: number;
|
|
@@ -23,38 +28,57 @@ export type ShapeAnimateOptions = {
|
|
|
23
28
|
ax?: number;
|
|
24
29
|
ay?: number;
|
|
25
30
|
mass?: number;
|
|
31
|
+
};
|
|
32
|
+
export type ShapeAnimateConstantOptions = {
|
|
26
33
|
gravity?: number;
|
|
34
|
+
enableGravityBetweenObjects?: boolean;
|
|
27
35
|
friction?: number;
|
|
28
36
|
easing?: number;
|
|
29
37
|
spring?: number;
|
|
30
38
|
springLength?: number;
|
|
39
|
+
wall?: {
|
|
40
|
+
x: number;
|
|
41
|
+
y: number;
|
|
42
|
+
width: number;
|
|
43
|
+
height: number;
|
|
44
|
+
cycle?: boolean;
|
|
45
|
+
bounce?: number;
|
|
46
|
+
};
|
|
47
|
+
enableCollision?: boolean;
|
|
48
|
+
enableSpringMassAlpha?: boolean;
|
|
31
49
|
};
|
|
32
50
|
export type ShapeDrawOptions = {
|
|
33
|
-
|
|
34
|
-
followMouse?: boolean;
|
|
51
|
+
interactive?: boolean;
|
|
35
52
|
drag?: {
|
|
36
53
|
enable?: boolean;
|
|
37
54
|
followSibling?: boolean;
|
|
38
55
|
alongPath?: PathD;
|
|
39
|
-
targetToAfterDrop?: {
|
|
40
|
-
x: number;
|
|
41
|
-
y: number;
|
|
42
|
-
};
|
|
43
|
-
easing?: number;
|
|
44
56
|
};
|
|
45
57
|
};
|
|
46
|
-
export type ShapeOptions = ShapeBaseOptions & ShapeTransformOptions & ShapeAnimateOptions & ShapeDrawOptions;
|
|
58
|
+
export type ShapeOptions = ShapeBaseOptions & ShapeAttributeOptions & ShapeTransformOptions & ShapeAnimateOptions & ShapeDrawOptions;
|
|
47
59
|
export declare class Shape {
|
|
60
|
+
[index: string | number | symbol]: any;
|
|
61
|
+
shouldUpdatePathD: boolean;
|
|
62
|
+
shouldUpdateTransformPathD: boolean;
|
|
63
|
+
shouldUpdateSVGElInDraw: boolean;
|
|
64
|
+
shouldUpdateMInDraw: boolean;
|
|
65
|
+
shouldUpdateAttrsInDraw: boolean;
|
|
66
|
+
shouldUpdateStyleInDraw: boolean;
|
|
48
67
|
id: string;
|
|
49
|
-
|
|
68
|
+
initD?: string | SVGParsedPathData[] | PathD;
|
|
69
|
+
d?: PathD;
|
|
50
70
|
parent?: {
|
|
51
71
|
combo: ShapeCombo;
|
|
52
|
-
|
|
53
|
-
|
|
72
|
+
dX: number;
|
|
73
|
+
dY: number;
|
|
74
|
+
dDegree: number;
|
|
75
|
+
dScaleX: number;
|
|
76
|
+
dScaleY: number;
|
|
54
77
|
};
|
|
55
78
|
attrs: Record<string, string | CanvasGradient>;
|
|
56
|
-
|
|
57
|
-
private
|
|
79
|
+
style: Record<string, string>;
|
|
80
|
+
private initCenterX?;
|
|
81
|
+
private initCenterY?;
|
|
58
82
|
private _x;
|
|
59
83
|
private _y;
|
|
60
84
|
private _degree;
|
|
@@ -65,15 +89,19 @@ export declare class Shape {
|
|
|
65
89
|
ax: number;
|
|
66
90
|
ay: number;
|
|
67
91
|
mass: number;
|
|
68
|
-
|
|
69
|
-
followMouse: boolean;
|
|
92
|
+
interactive: boolean;
|
|
70
93
|
drag?: ShapeDrawOptions["drag"];
|
|
71
94
|
transform$: Subject<{
|
|
72
|
-
|
|
73
|
-
|
|
95
|
+
dX?: number;
|
|
96
|
+
dY?: number;
|
|
97
|
+
dDegree?: number;
|
|
98
|
+
dScaleX?: number;
|
|
99
|
+
dScaleY?: number;
|
|
74
100
|
}>;
|
|
101
|
+
private transformSubscription;
|
|
75
102
|
isMouseIn: boolean;
|
|
76
103
|
isDragging: boolean;
|
|
104
|
+
m?: Matrix | DOMMatrix;
|
|
77
105
|
el?: HTMLElement | SVGElement;
|
|
78
106
|
constructor(options?: ShapeOptions);
|
|
79
107
|
destroy(): void;
|
|
@@ -97,11 +125,17 @@ export declare class Shape {
|
|
|
97
125
|
set scaleX(v: number);
|
|
98
126
|
get scaleY(): number;
|
|
99
127
|
set scaleY(v: number);
|
|
100
|
-
pathD(): PathD;
|
|
101
|
-
|
|
128
|
+
pathD(force?: PathD): PathD;
|
|
129
|
+
protected cachedTransformedPathD?: PathD;
|
|
130
|
+
transformPathD(): PathD;
|
|
102
131
|
getBaseOptions(): {
|
|
103
|
-
|
|
104
|
-
attrs:
|
|
132
|
+
initD: string | SVGParsedPathData[] | PathD | undefined;
|
|
133
|
+
attrs: {
|
|
134
|
+
[x: string]: string | CanvasGradient;
|
|
135
|
+
};
|
|
136
|
+
style: {
|
|
137
|
+
[x: string]: string;
|
|
138
|
+
};
|
|
105
139
|
centerX: number | undefined;
|
|
106
140
|
centerY: number | undefined;
|
|
107
141
|
x: number;
|
|
@@ -114,20 +148,17 @@ export declare class Shape {
|
|
|
114
148
|
ax: number;
|
|
115
149
|
ay: number;
|
|
116
150
|
mass: number;
|
|
117
|
-
|
|
151
|
+
interactive: boolean;
|
|
118
152
|
drag: {
|
|
119
153
|
enable?: boolean;
|
|
120
154
|
followSibling?: boolean;
|
|
121
155
|
alongPath?: PathD;
|
|
122
|
-
|
|
123
|
-
x: number;
|
|
124
|
-
y: number;
|
|
125
|
-
};
|
|
126
|
-
easing?: number;
|
|
127
|
-
} | undefined;
|
|
156
|
+
};
|
|
128
157
|
};
|
|
129
158
|
clone(): Shape;
|
|
130
159
|
protected cloneShape(): Shape;
|
|
160
|
+
update(options?: Partial<ShapeOptions>): void;
|
|
161
|
+
toSVGEl(): SVGElement | null;
|
|
131
162
|
toSVGPathData(): SVGParsedPathData[];
|
|
132
163
|
toSVGPathD(): string;
|
|
133
164
|
toCanvasContext(ctx: YZCanvasContext): void;
|
|
@@ -136,57 +167,46 @@ export declare class Shape {
|
|
|
136
167
|
y: number;
|
|
137
168
|
width: number;
|
|
138
169
|
height: number;
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
y: number;
|
|
142
|
-
};
|
|
143
|
-
} | {
|
|
170
|
+
};
|
|
171
|
+
getRealBoundingClientRect(dot?: number): {
|
|
144
172
|
x: number;
|
|
145
173
|
y: number;
|
|
146
174
|
width: number;
|
|
147
175
|
height: number;
|
|
148
|
-
center?: undefined;
|
|
149
176
|
};
|
|
150
177
|
getBoundingClientRectCenter(dot?: number): {
|
|
151
178
|
x: number;
|
|
152
179
|
y: number;
|
|
153
180
|
};
|
|
181
|
+
getRealBoundingClientRectCenter(dot?: number): {
|
|
182
|
+
x: number;
|
|
183
|
+
y: number;
|
|
184
|
+
};
|
|
154
185
|
transformOrigin(forceSelf?: boolean, dot?: number): {
|
|
155
186
|
x: number;
|
|
156
187
|
y: number;
|
|
157
188
|
};
|
|
158
189
|
isPointInPath(ctx: YZCanvasContext | SVGElement, x: number, y: number): boolean;
|
|
159
190
|
isPointInStroke(ctx: YZCanvasContext | SVGElement, x: number, y: number): boolean;
|
|
191
|
+
setStyle(obj: Record<string, string>): void;
|
|
160
192
|
setAttr(obj: Record<string, string | CanvasGradient>): void;
|
|
161
193
|
setAttr(name: string, value: string | CanvasGradient): void;
|
|
162
194
|
getAttr(name: string, defaultValue: string | CanvasGradient): string | CanvasGradient;
|
|
163
195
|
getAttr(name: string): string | CanvasGradient | undefined;
|
|
164
196
|
hasAttr(name: string): boolean;
|
|
165
|
-
|
|
166
|
-
animate(options?: ShapeAnimateOptions): void;
|
|
197
|
+
animate(options?: Pick<ShapeAnimateConstantOptions, "gravity" | "friction">): void;
|
|
167
198
|
animateEaseTo(target: {
|
|
168
199
|
x: number;
|
|
169
200
|
y: number;
|
|
170
|
-
}, options?:
|
|
201
|
+
}, options?: Pick<ShapeAnimateConstantOptions, "easing" | "gravity" | "friction">): void;
|
|
171
202
|
animateSpringTo(target: {
|
|
172
203
|
x: number;
|
|
173
204
|
y: number;
|
|
174
205
|
} | {
|
|
175
206
|
x: number;
|
|
176
207
|
y: number;
|
|
177
|
-
}[], options?:
|
|
178
|
-
|
|
179
|
-
springLength?: number;
|
|
180
|
-
spring?: number;
|
|
181
|
-
}): number;
|
|
182
|
-
distance(target: {
|
|
183
|
-
x: number;
|
|
184
|
-
y: number;
|
|
185
|
-
}): number;
|
|
186
|
-
rotateToTarget(target: {
|
|
187
|
-
x: number;
|
|
188
|
-
y: number;
|
|
189
|
-
}): void;
|
|
208
|
+
}[], options?: Pick<ShapeAnimateConstantOptions, "spring" | "gravity" | "friction">): void;
|
|
209
|
+
getSpringMassAlphaTo(target: Shape, options?: Pick<ShapeAnimateConstantOptions, "spring" | "springLength" | "gravity" | "friction">): number;
|
|
190
210
|
followTo(target: {
|
|
191
211
|
x: number;
|
|
192
212
|
y: number;
|
|
@@ -197,26 +217,18 @@ export declare class Shape {
|
|
|
197
217
|
}, length?: number): void;
|
|
198
218
|
gravitateTo(target: Shape): void;
|
|
199
219
|
checkCollision(target: Shape): void;
|
|
200
|
-
checkWall(options:
|
|
201
|
-
wall: {
|
|
202
|
-
x: number;
|
|
203
|
-
y: number;
|
|
204
|
-
width: number;
|
|
205
|
-
height: number;
|
|
206
|
-
};
|
|
207
|
-
bounce?: number;
|
|
208
|
-
}): void;
|
|
220
|
+
checkWall(options?: ShapeAnimateConstantOptions): void;
|
|
209
221
|
getTotalLength(): number;
|
|
210
|
-
|
|
222
|
+
getPointAtLength(length: number): {
|
|
211
223
|
x: number;
|
|
212
224
|
y: number;
|
|
225
|
+
alpha: number;
|
|
213
226
|
};
|
|
214
|
-
|
|
227
|
+
interpolate(t: number): {
|
|
215
228
|
x: number;
|
|
216
229
|
y: number;
|
|
217
|
-
alpha: number;
|
|
218
230
|
};
|
|
219
|
-
trailPath(
|
|
231
|
+
trailPath(st?: number, et?: number): {
|
|
220
232
|
subPathD: PathD;
|
|
221
233
|
point: {
|
|
222
234
|
x: number;
|
|
@@ -225,28 +237,66 @@ export declare class Shape {
|
|
|
225
237
|
};
|
|
226
238
|
};
|
|
227
239
|
strokeDashTween(frameDuration?: number, options?: TweenRawOptions): void;
|
|
240
|
+
static generateRosetta(x: number, y: number, rx: number, ry: number, n: number): Shape;
|
|
228
241
|
}
|
|
229
242
|
export type ShapeComboOptions = {
|
|
230
243
|
svg?: string;
|
|
231
244
|
forceWidth?: number;
|
|
232
|
-
};
|
|
245
|
+
} & ShapeAttributeOptions & ShapeTransformOptions & ShapeDrawOptions;
|
|
233
246
|
export declare class ShapeCombo {
|
|
234
|
-
protected options?: ShapeComboOptions;
|
|
235
|
-
protected commonChildShapeOptions?: ShapeOptions;
|
|
236
247
|
shapes: Shape[];
|
|
248
|
+
svg?: string;
|
|
249
|
+
forceWidth?: number;
|
|
250
|
+
attrs: Record<string, string | CanvasGradient>;
|
|
251
|
+
style: Record<string, string>;
|
|
252
|
+
initCenterX?: number;
|
|
253
|
+
initCenterY?: number;
|
|
237
254
|
x: number;
|
|
238
255
|
y: number;
|
|
239
256
|
degree: number;
|
|
240
257
|
scaleX: number;
|
|
241
258
|
scaleY: number;
|
|
242
|
-
|
|
259
|
+
interactive: boolean;
|
|
260
|
+
drag?: ShapeDrawOptions["drag"];
|
|
261
|
+
constructor(options?: ShapeComboOptions);
|
|
243
262
|
destroy(): void;
|
|
263
|
+
getBaseOptions(): {
|
|
264
|
+
svg: string | undefined;
|
|
265
|
+
forceWidth: number | undefined;
|
|
266
|
+
attrs: {
|
|
267
|
+
[x: string]: string | CanvasGradient;
|
|
268
|
+
};
|
|
269
|
+
style: {
|
|
270
|
+
[x: string]: string;
|
|
271
|
+
};
|
|
272
|
+
centerX: number | undefined;
|
|
273
|
+
centerY: number | undefined;
|
|
274
|
+
x: number;
|
|
275
|
+
y: number;
|
|
276
|
+
degree: number;
|
|
277
|
+
scaleX: number;
|
|
278
|
+
scaleY: number;
|
|
279
|
+
interactive: boolean;
|
|
280
|
+
drag: {
|
|
281
|
+
enable?: boolean;
|
|
282
|
+
followSibling?: boolean;
|
|
283
|
+
alongPath?: PathD;
|
|
284
|
+
};
|
|
285
|
+
};
|
|
244
286
|
clone(): ShapeCombo;
|
|
245
287
|
protected cloneShapeCombo(): ShapeCombo;
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
288
|
+
update(options?: Partial<ShapeComboOptions>): void;
|
|
289
|
+
addShape(shape: Shape, options?: {
|
|
290
|
+
dX?: number;
|
|
291
|
+
dY?: number;
|
|
292
|
+
dDegree?: number;
|
|
293
|
+
dScaleX?: number;
|
|
294
|
+
dScaleY?: number;
|
|
295
|
+
notCopyFromCombo?: boolean;
|
|
296
|
+
}): void;
|
|
297
|
+
comboMove(dx: number, dy: number, justChild?: boolean): void;
|
|
298
|
+
comboRotate(degree: number, justChild?: boolean): void;
|
|
299
|
+
comboScale(scaleX: number, scaleY?: number, justChild?: boolean): void;
|
|
250
300
|
comboTransform(options?: {
|
|
251
301
|
x?: number;
|
|
252
302
|
y?: number;
|
|
@@ -254,29 +304,23 @@ export declare class ShapeCombo {
|
|
|
254
304
|
scale?: number;
|
|
255
305
|
scaleX?: number;
|
|
256
306
|
scaleY?: number;
|
|
257
|
-
}): void;
|
|
307
|
+
}, justChild?: boolean): void;
|
|
258
308
|
getBoundingClientRect(dot?: number): {
|
|
259
309
|
x: number;
|
|
260
310
|
y: number;
|
|
261
311
|
width: number;
|
|
262
312
|
height: number;
|
|
263
|
-
center: {
|
|
264
|
-
x: number;
|
|
265
|
-
y: number;
|
|
266
|
-
};
|
|
267
|
-
} | {
|
|
268
|
-
x: number;
|
|
269
|
-
y: number;
|
|
270
|
-
width: number;
|
|
271
|
-
height: number;
|
|
272
|
-
center?: undefined;
|
|
273
313
|
};
|
|
274
314
|
getBoundingClientRectCenter(dot?: number): {
|
|
275
315
|
x: number;
|
|
276
316
|
y: number;
|
|
277
317
|
};
|
|
318
|
+
setStyle(obj: Record<string, string>): void;
|
|
278
319
|
setAttr(obj: Record<string, string | CanvasGradient>): void;
|
|
279
320
|
setAttr(name: string, value: string | CanvasGradient): void;
|
|
321
|
+
getAttr(name: string, defaultValue: string | CanvasGradient): string | CanvasGradient;
|
|
322
|
+
getAttr(name: string): string | CanvasGradient | undefined;
|
|
323
|
+
hasAttr(name: string): boolean;
|
|
280
324
|
sort(): void;
|
|
281
325
|
expendTo(larger: ShapeCombo): void;
|
|
282
326
|
strokeDashTween(frameDuration?: number, options?: Omit<TweenRawOptions, "onStart" | "onUpdate" | "onComplete"> & {
|
|
@@ -286,28 +330,13 @@ export declare class ShapeCombo {
|
|
|
286
330
|
onGroupComplete?: () => void;
|
|
287
331
|
}): void;
|
|
288
332
|
}
|
|
289
|
-
export declare function
|
|
290
|
-
|
|
291
|
-
x: number;
|
|
292
|
-
y: number;
|
|
293
|
-
width: number;
|
|
294
|
-
height: number;
|
|
295
|
-
};
|
|
296
|
-
bounce?: number;
|
|
297
|
-
}): void;
|
|
298
|
-
export declare function gravitateShapes(shapes: Shape[]): void;
|
|
299
|
-
export declare function animateSpringChainShapes(shapes: Shape[], options?: ShapeAnimateOptions): void;
|
|
300
|
-
export declare function animateSpringConnectShapes(shapes: Shape[], options?: ShapeAnimateOptions): void;
|
|
301
|
-
export declare function animateSpringMassShapes(shapes: Shape[], wall: {
|
|
333
|
+
export declare function followMouseShape(shape: Shape, mpg: MousePointGroup, margin?: number): void;
|
|
334
|
+
export declare function targetToAfterDropShape(shape: Shape, target: {
|
|
302
335
|
x: number;
|
|
303
336
|
y: number;
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
export declare function polymorphShapesTween(shapes: (Shape | ShapeCombo)[], frameDuration?: number, options?: TweenRawOptions & {
|
|
310
|
-
shape?: (shape: Shape) => void;
|
|
311
|
-
}): void;
|
|
312
|
-
export declare function generateRosettaShape(x: number, y: number, rx: number, ry: number, n: number): Shape;
|
|
337
|
+
}, options?: ShapeAnimateConstantOptions): void;
|
|
338
|
+
export declare function animateShapes(shapes: Shape[], options?: ShapeAnimateConstantOptions): number[][];
|
|
339
|
+
export declare function polymorphTween(shapes: (Shape | ShapeCombo)[], frameDuration?: number, options?: TweenRawOptions & {
|
|
340
|
+
shapeOrCombo?: (s: Shape | ShapeCombo, offset: number) => void;
|
|
341
|
+
}): Shape | ShapeCombo;
|
|
313
342
|
//# sourceMappingURL=Shape.d.ts.map
|