to(a: any): Morphable;\r
}\r
\r
+ type ListEachCallback<T> = (el: T, index: number, list: T[]) => T\r
+\r
// List.js\r
- interface List<T> extends BuiltInArray<T> {\r
+ class List<T> extends BuiltInArray<T> {\r
// I have no clue how to deal with this\r
// [key: string]: (...arg0: any[]) => List<T>\r
// [key: string]: () => List<any>\r
- each(fn: Function): void\r
- each(...args: any[]): void\r
+ each(fn: ListEachCallback<T>): T[]\r
+ each(...args: any[]): T[]\r
toArray(): T[]\r
}\r
\r
clip(): ClipPath;\r
ellipse(width?: number, height?: number): Ellipse;\r
flatten(parent: Dom, depth?: number): this;\r
+ foreignObject(width: number, height: number) : ForeignObject\r
gradient(type: string, block?: (stop: Gradient) => void): Gradient;\r
group(): G;\r
\r
target(): string;\r
}\r
\r
+\r
+ // ForeignObject.js\r
+ class ForeignObject extends Element {\r
+ constructor(node: HTMLElement, attrs?: any)\r
+ add(element: Dom) : ForeignObject\r
+ }\r
+\r
// image.js\r
class Image extends Shape {\r
constructor(node?: SVGImageElement);\r