From 395a604489e4474c013779643153fcea7a17b6e0 Mon Sep 17 00:00:00 2001 From: Wonju Jeon Date: Fri, 21 Feb 2020 12:48:19 +0900 Subject: [PATCH] chore(types): Fix wrong type definition - Add missing y ticks show option - Fix on wrong type definition: .load(), tooltip.position Close #1247 --- AUTHORS.txt | 1 + types/axis.d.ts | 5 +++++ types/chart.d.ts | 2 +- types/options.d.ts | 4 ++-- 4 files changed, 9 insertions(+), 3 deletions(-) diff --git a/AUTHORS.txt b/AUTHORS.txt index 0b48225e6..d4a6efa71 100644 --- a/AUTHORS.txt +++ b/AUTHORS.txt @@ -37,3 +37,4 @@ Christophe Coevoet Jung Hoon Park Kamil Michalski Zhongde Liu +Wonju Jeon diff --git a/types/axis.d.ts b/types/axis.d.ts index a486d203a..f26f3eb24 100644 --- a/types/axis.d.ts +++ b/types/axis.d.ts @@ -314,6 +314,11 @@ export interface YTickConfiguration { */ stepSize?: number; + /** + * Show or hide axis tick line. + */ + show?: boolean; + text?: { /** * Set the x Axis tick text's position relatively its original position diff --git a/types/chart.d.ts b/types/chart.d.ts index 438b466f7..9003df944 100644 --- a/types/chart.d.ts +++ b/types/chart.d.ts @@ -335,7 +335,7 @@ export interface Chart { type?: string; types?: { [key: string]: string }; unload?: boolean | ArrayOrString; - done?(): () => any; + done?: () => any; }): void; /** diff --git a/types/options.d.ts b/types/options.d.ts index 1edb9ab56..3f17a3bc7 100644 --- a/types/options.d.ts +++ b/types/options.d.ts @@ -867,12 +867,12 @@ export interface TooltipOptions { * Or set tooltip's position unit. * This option can't be used along with `tooltip.position` custom function. If want to specify unit in custom function, return value with desired unit. */ - position?( + position?: (( data: any, width: number, height: number, element: any - ): { top: number; left: number } | { unit: string; }; + ) => { top: number; left: number }) | { unit: string; }; /** * Set custom HTML for the tooltip.