liusuyi
2023-04-24 4737f1e038743ced243c9e52423404d9034d6107
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
export declare type CSSSelectorVNode = Record<string, string>;
export declare type CSSAnimationVNode = Record<string, Record<string, string>>;
export declare const SVGNS = "http://www.w3.org/2000/svg";
export declare const XLINKNS = "http://www.w3.org/1999/xlink";
export declare const XMLNS = "http://www.w3.org/2000/xmlns/";
export declare const XML_NAMESPACE = "http://www.w3.org/XML/1998/namespace";
export declare function createElement(name: string): SVGElement;
export declare type SVGVNodeAttrs = Record<string, string | number | undefined | boolean>;
export interface SVGVNode {
    tag: string;
    attrs: SVGVNodeAttrs;
    children?: SVGVNode[];
    text?: string;
    elm?: Node;
    key: string;
}
export declare function createVNode(tag: string, key: string, attrs?: SVGVNodeAttrs, children?: SVGVNode[], text?: string): SVGVNode;
export declare function vNodeToString(el: SVGVNode, opts?: {
    newline?: boolean;
}): string;
export declare function getCssString(selectorNodes: Record<string, CSSSelectorVNode>, animationNodes: Record<string, CSSAnimationVNode>, opts?: {
    newline?: boolean;
}): string;
export interface BrushScope {
    zrId: string;
    shadowCache: Record<string, string>;
    gradientCache: Record<string, string>;
    patternCache: Record<string, string>;
    clipPathCache: Record<string, string>;
    defs: Record<string, SVGVNode>;
    cssNodes: Record<string, CSSSelectorVNode>;
    cssAnims: Record<string, Record<string, Record<string, string>>>;
    cssClassIdx: number;
    cssAnimIdx: number;
    shadowIdx: number;
    gradientIdx: number;
    patternIdx: number;
    clipPathIdx: number;
    animation?: boolean;
    willUpdate?: boolean;
    compress?: boolean;
}
export declare function createBrushScope(zrId: string): BrushScope;
export declare function createSVGVNode(width: number | string, height: number | string, children?: SVGVNode[], useViewBox?: boolean): SVGVNode;