diff --git a/drop/drop-tests.ts b/drop/drop-tests.ts index cc19621fbd..0da04e9445 100644 --- a/drop/drop-tests.ts +++ b/drop/drop-tests.ts @@ -36,3 +36,11 @@ var e = new Drop({ content: () => greenBox }); +var Tooltip = Drop.createContext({ + classPrefix: 'tooltip' +}); + +var t = new Tooltip({ + target: yellowBox, + content: () => greenBox +}); diff --git a/drop/drop.d.ts b/drop/drop.d.ts index 63f9c8621e..87ae4425b9 100644 --- a/drop/drop.d.ts +++ b/drop/drop.d.ts @@ -27,7 +27,7 @@ declare class Drop { public once(event: string, handler: Function, context?: any): void; public off(event: string, handler?: Function): void; - public static createContext(options: Drop.IDropContextOptions): Drop; + public static createContext(options: Drop.IDropContextOptions): typeof Drop; } declare namespace Drop { @@ -59,4 +59,3 @@ declare namespace Drop { declare module "drop" { export = Drop; } -