mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-04-01 12:42:58 +08:00
Add type definition for Focus (#10884)
This commit is contained in:
committed by
Masahiro Wakame
parent
4862bdef24
commit
46ca501630
37
nvd3/nvd3.d.ts
vendored
37
nvd3/nvd3.d.ts
vendored
@@ -126,6 +126,41 @@ declare namespace nv {
|
||||
width(value: number): this;
|
||||
}
|
||||
|
||||
interface Focus extends Nvd3Element {
|
||||
color(value: string[]): this;
|
||||
color(func: (d: any, i: number) => string): this;
|
||||
width(): number;
|
||||
width(value: number): this;
|
||||
height(): number;
|
||||
height(value: number): this;
|
||||
margin(): Margin;
|
||||
margin(value: Margin): this;
|
||||
x(): (d: any) => any;
|
||||
x(func: (d: any) => any): this;
|
||||
y(): (d: any) => number;
|
||||
y(func: (d: any) => number): this;
|
||||
showXAxis(): boolean;
|
||||
showXAxis(value: boolean): this;
|
||||
showYAxis(): boolean;
|
||||
showYAxis(value: boolean): this;
|
||||
brushExtent(): [number, number] | [[number, number], [number, number]];
|
||||
brushExtent(value: [number, number] | [[number, number], [number, number]]) : this;
|
||||
duration(): number;
|
||||
duration(value: number): this;
|
||||
xTickFormat(): (d: any) => string;
|
||||
xTickFormat(format: (t: any) => string): this;
|
||||
xTickFormat(format: string): this;
|
||||
xTickFormat(format: (d: any, i: any) => string): this;
|
||||
yTickFormat(): (d: any) => string;
|
||||
yTickFormat(format: (t: any) => string): this;
|
||||
yTickFormat(format: string): this;
|
||||
yTickFormat(format: (d: any, i: any) => string): this;
|
||||
interpolate(): string;
|
||||
interpolate(value: string): this;
|
||||
rightAlignYAxis(): boolean;
|
||||
rightAlignYAxis(value: boolean): this;
|
||||
}
|
||||
|
||||
interface Nvd3Axis extends d3.svg.Axis {
|
||||
axisLabel(): string;
|
||||
axisLabel(value: string): this;
|
||||
@@ -1805,6 +1840,7 @@ id(value: number|string): this;
|
||||
yAxis: Nvd3Axis;
|
||||
legend: Legend;
|
||||
tooltip: Tooltip;
|
||||
focus: Focus;
|
||||
|
||||
clearHighlights(): this;
|
||||
/*If true, masks lines within the X and Y scales using a clip-path*/
|
||||
@@ -3238,6 +3274,7 @@ id(value: number|string): this;
|
||||
yAxis: Nvd3Axis;
|
||||
y2Axis: Nvd3Axis;
|
||||
tooltip: Tooltip;
|
||||
focus: Focus;
|
||||
|
||||
controlLabels(): any;
|
||||
/*Object that defines the labels for control items in the graph. For instance, in the stackedAreaChart, there are controls for making it stacked, expanded, or stream. For stacked bar charts, there is stacked and grouped.*/
|
||||
|
||||
Reference in New Issue
Block a user