VERSION 1.14 @ 2019-04-04 08:32:01.655131

x axis retains previous scale after restoring layout #3828
getVisiblePriceRange() not working in 1.14 (unstable) #3774
uppercase_instrument_names doesn't work for compare/overlay #3746
API method to trigger the Zoom Out #3739
Provide event that study properties was changed #3736
Fixed security issue in master #3699
widget.save have old data #3623
JS error on switching chart types #3602
Add a way to prevent scrolling beyond the beginning of bars #3597
Chart customization - overrides #3572
Theme override colors from saved_data #3557
Error while applying Pivot Points Indicator #3521
Month timeframe combining months #3510
initialSettings from settings adapter does not work #3479
Add Indexed to 100 mode for price scale #3391
RTL #3335
Add warning about incorrect usage disable_resolution_rebuild and has_empty_bars #3329
Unable to load DOME and Bottom Widget when open_account_manager disabled #3312
Randomly clickable area on chart that redirects user to tradingview.com #3299
Apply to all #3298
Save container element while charting library's life #3297
Gap appearing in chart layout #3246
User's colors not working when theme is enabled #3232
Chart is outside of visible range when in auto scale and load study template or load chart #3229
Please make getVisibleRange return the range in UTC #3173
Remove TradingView.onready from API #3162
Add API to export data from the chart #3152
Market status is not updated properly #3122
Placeholders disappear in "Compare or Add Symbol" popup when the cursor is set into the fields #2966
getVisibleRange to return 0, any way of getting the last bar in active chart ? #2757
"onListAdded" event is not fired when user click on "Save Watchlist As" #2654
Error report : Parabolic SAR #2205
TERMINAL: make a flag to disable support of stop orders #2181
Add Change % in the OHLC label Charting Library #2120
Request more bars for indicators #1362
Drawing tool does not work on Samsung Edge and  Note 5 #984
This commit is contained in:
Jenkins
2019-04-04 11:32:07 +03:00
parent e38d004695
commit 9d8b63e068
142 changed files with 38224 additions and 2420 deletions

View File

@@ -1,12 +1,35 @@
export declare type CustomTimezones = 'America/New_York' | 'America/Los_Angeles' | 'America/Chicago' | 'America/Phoenix' | 'America/Toronto' | 'America/Vancouver' | 'America/Argentina/Buenos_Aires' | 'America/El_Salvador' | 'America/Sao_Paulo' | 'America/Bogota' | 'America/Caracas' | 'Europe/Moscow' | 'Europe/Athens' | 'Europe/Belgrade' | 'Europe/Berlin' | 'Europe/London' | 'Europe/Luxembourg' | 'Europe/Madrid' | 'Europe/Paris' | 'Europe/Rome' | 'Europe/Warsaw' | 'Europe/Istanbul' | 'Europe/Zurich' | 'Australia/Sydney' | 'Australia/Brisbane' | 'Australia/Adelaide' | 'Australia/ACT' | 'Asia/Almaty' | 'Asia/Ashkhabad' | 'Asia/Tokyo' | 'Asia/Taipei' | 'Asia/Singapore' | 'Asia/Shanghai' | 'Asia/Seoul' | 'Asia/Tehran' | 'Asia/Dubai' | 'Asia/Kolkata' | 'Asia/Hong_Kong' | 'Asia/Bangkok' | 'Asia/Chongqing' | 'Asia/Jerusalem' | 'Asia/Kuwait' | 'Asia/Muscat' | 'Asia/Qatar' | 'Asia/Riyadh' | 'Pacific/Auckland' | 'Pacific/Chatham' | 'Pacific/Fakaofo' | 'Pacific/Honolulu' | 'America/Mexico_City' | 'Africa/Cairo' | 'Africa/Johannesburg' | 'Asia/Kathmandu' | 'US/Mountain' | 'Europe/Helsinki' | 'Europe/Stockholm' | 'Europe/Copenhagen' | 'Atlantic/Reykjavik' | 'Europe/Tallinn' | 'Europe/Riga' | 'Europe/Vilnius' | 'America/Lima' | 'America/Santiago' | 'Asia/Bahrain' | 'Asia/Jakarta' | 'Africa/Lagos' | 'Pacific/Norfolk' | 'America/Juneau' | 'Asia/Ho_Chi_Minh' | 'Australia/Perth' | 'Europe/Oslo';
export declare type DomeCallback = (data: DOMData) => void;
export declare type ErrorCallback = (reason: string) => void;
export declare type GetMarksCallback<T> = (marks: T[]) => void;
export declare type HistoryCallback = (bars: Bar[], meta: HistoryMetadata) => void;
export declare type MarkConstColors = 'red' | 'green' | 'blue' | 'yellow';
export declare type OnReadyCallback = (configuration: DatafeedConfiguration) => void;
export declare type QuoteData = QuoteOkData | QuoteErrorData;
export declare type QuotesCallback = (data: QuoteData[]) => void;
export declare type ResolutionBackValues = 'D' | 'M';
export declare type ResolutionString = string;
export interface Exchange {
value: string;
name: string;
desc: string;
export declare type ResolveCallback = (symbolInfo: LibrarySymbolInfo) => void;
export declare type SearchSymbolsCallback = (items: SearchSymbolResultItem[]) => void;
export declare type ServerTimeCallback = (serverTime: number) => void;
export declare type SubscribeBarsCallback = (bar: Bar) => void;
export declare type Timezone = 'Etc/UTC' | CustomTimezones;
export interface Bar {
time: number;
open: number;
high: number;
low: number;
close: number;
volume?: number;
}
export interface DatafeedSymbolType {
name: string;
value: string;
export interface DOMData {
snapshot: boolean;
asks: DOMLevel[];
bids: DOMLevel[];
}
export interface DOMLevel {
price: number;
volume: number;
}
export interface DatafeedConfiguration {
exchanges?: Exchange[];
@@ -16,10 +39,6 @@ export interface DatafeedConfiguration {
supports_timescale_marks?: boolean;
symbols_types?: DatafeedSymbolType[];
}
export declare type OnReadyCallback = (configuration: DatafeedConfiguration) => void;
export interface IExternalDatafeed {
onReady(callback: OnReadyCallback): void;
}
export interface DatafeedQuoteValues {
ch?: number;
chp?: number;
@@ -38,25 +57,49 @@ export interface DatafeedQuoteValues {
original_name?: string;
[valueName: string]: string | number | undefined;
}
export interface QuoteOkData {
s: 'ok';
n: string;
v: DatafeedQuoteValues;
export interface DatafeedSymbolType {
name: string;
value: string;
}
export interface QuoteErrorData {
s: 'error';
n: string;
v: object;
export interface Exchange {
value: string;
name: string;
desc: string;
}
export interface HistoryDepth {
resolutionBack: ResolutionBackValues;
intervalBack: number;
}
export interface HistoryMetadata {
noData: boolean;
nextTime?: number | null;
}
export interface IDatafeedChartApi {
calculateHistoryDepth?(resolution: ResolutionString, resolutionBack: ResolutionBackValues, intervalBack: number): HistoryDepth | undefined;
getMarks?(symbolInfo: LibrarySymbolInfo, from: number, to: number, onDataCallback: GetMarksCallback<Mark>, resolution: ResolutionString): void;
getTimescaleMarks?(symbolInfo: LibrarySymbolInfo, from: number, to: number, onDataCallback: GetMarksCallback<TimescaleMark>, resolution: ResolutionString): void;
/**
* This function is called if configuration flag supports_time is set to true when chart needs to know the server time.
* The charting library expects callback to be called once.
* The time is provided without milliseconds. Example: 1445324591. It is used to display Countdown on the price scale.
*/
getServerTime?(callback: ServerTimeCallback): void;
searchSymbols(userInput: string, exchange: string, symbolType: string, onResult: SearchSymbolsCallback): void;
resolveSymbol(symbolName: string, onResolve: ResolveCallback, onError: ErrorCallback): void;
getBars(symbolInfo: LibrarySymbolInfo, resolution: ResolutionString, rangeStartDate: number, rangeEndDate: number, onResult: HistoryCallback, onError: ErrorCallback, isFirstCall: boolean): void;
subscribeBars(symbolInfo: LibrarySymbolInfo, resolution: ResolutionString, onTick: SubscribeBarsCallback, listenerGuid: string, onResetCacheNeededCallback: () => void): void;
unsubscribeBars(listenerGuid: string): void;
subscribeDepth?(symbolInfo: LibrarySymbolInfo, callback: DomeCallback): string;
unsubscribeDepth?(subscriberUID: string): void;
}
export declare type QuoteData = QuoteOkData | QuoteErrorData;
export declare type QuotesCallback = (data: QuoteData[]) => void;
export interface IDatafeedQuotesApi {
getQuotes(symbols: string[], onDataCallback: QuotesCallback, onErrorCallback: (msg: string) => void): void;
subscribeQuotes(symbols: string[], fastSymbols: string[], onRealtimeCallback: QuotesCallback, listenerGUID: string): void;
unsubscribeQuotes(listenerGUID: string): void;
}
export declare type CustomTimezones = 'America/New_York' | 'America/Los_Angeles' | 'America/Chicago' | 'America/Phoenix' | 'America/Toronto' | 'America/Vancouver' | 'America/Argentina/Buenos_Aires' | 'America/El_Salvador' | 'America/Sao_Paulo' | 'America/Bogota' | 'America/Caracas' | 'Europe/Moscow' | 'Europe/Athens' | 'Europe/Belgrade' | 'Europe/Berlin' | 'Europe/London' | 'Europe/Luxembourg' | 'Europe/Madrid' | 'Europe/Paris' | 'Europe/Rome' | 'Europe/Warsaw' | 'Europe/Istanbul' | 'Europe/Zurich' | 'Australia/Sydney' | 'Australia/Brisbane' | 'Australia/Adelaide' | 'Australia/ACT' | 'Asia/Almaty' | 'Asia/Ashkhabad' | 'Asia/Tokyo' | 'Asia/Taipei' | 'Asia/Singapore' | 'Asia/Shanghai' | 'Asia/Seoul' | 'Asia/Tehran' | 'Asia/Dubai' | 'Asia/Kolkata' | 'Asia/Hong_Kong' | 'Asia/Bangkok' | 'Asia/Chongqing' | 'Asia/Jerusalem' | 'Asia/Kuwait' | 'Asia/Muscat' | 'Asia/Qatar' | 'Asia/Riyadh' | 'Pacific/Auckland' | 'Pacific/Chatham' | 'Pacific/Fakaofo' | 'Pacific/Honolulu' | 'America/Mexico_City' | 'Africa/Cairo' | 'Africa/Johannesburg' | 'Asia/Kathmandu' | 'US/Mountain';
export declare type Timezone = 'Etc/UTC' | CustomTimezones;
export interface IExternalDatafeed {
onReady(callback: OnReadyCallback): void;
}
export interface LibrarySymbolInfo {
/**
* Symbol Name
@@ -135,40 +178,6 @@ export interface LibrarySymbolInfo {
industry?: string;
currency_code?: string;
}
export interface DOMLevel {
price: number;
volume: number;
}
export interface DOMData {
snapshot: boolean;
asks: DOMLevel[];
bids: DOMLevel[];
}
export interface Bar {
time: number;
open: number;
high: number;
low: number;
close: number;
volume?: number;
}
export interface SearchSymbolResultItem {
symbol: string;
full_name: string;
description: string;
exchange: string;
ticker: string;
type: string;
}
export interface HistoryMetadata {
noData: boolean;
nextTime?: number | null;
}
export interface MarkCustomColor {
color: string;
background: string;
}
export declare type MarkConstColors = 'red' | 'green' | 'blue' | 'yellow';
export interface Mark {
id: string | number;
time: number;
@@ -178,6 +187,28 @@ export interface Mark {
labelFontColor: string;
minSize: number;
}
export interface MarkCustomColor {
color: string;
background: string;
}
export interface QuoteErrorData {
s: 'error';
n: string;
v: object;
}
export interface QuoteOkData {
s: 'ok';
n: string;
v: DatafeedQuoteValues;
}
export interface SearchSymbolResultItem {
symbol: string;
full_name: string;
description: string;
exchange: string;
ticker: string;
type: string;
}
export interface TimescaleMark {
id: string | number;
time: number;
@@ -185,36 +216,5 @@ export interface TimescaleMark {
label: string;
tooltip: string[];
}
export declare type ResolutionBackValues = 'D' | 'M';
export interface HistoryDepth {
resolutionBack: ResolutionBackValues;
intervalBack: number;
}
export declare type SearchSymbolsCallback = (items: SearchSymbolResultItem[]) => void;
export declare type ResolveCallback = (symbolInfo: LibrarySymbolInfo) => void;
export declare type HistoryCallback = (bars: Bar[], meta: HistoryMetadata) => void;
export declare type SubscribeBarsCallback = (bar: Bar) => void;
export declare type GetMarksCallback<T> = (marks: T[]) => void;
export declare type ServerTimeCallback = (serverTime: number) => void;
export declare type DomeCallback = (data: DOMData) => void;
export declare type ErrorCallback = (reason: string) => void;
export interface IDatafeedChartApi {
calculateHistoryDepth?(resolution: ResolutionString, resolutionBack: ResolutionBackValues, intervalBack: number): HistoryDepth | undefined;
getMarks?(symbolInfo: LibrarySymbolInfo, from: number, to: number, onDataCallback: GetMarksCallback<Mark>, resolution: ResolutionString): void;
getTimescaleMarks?(symbolInfo: LibrarySymbolInfo, from: number, to: number, onDataCallback: GetMarksCallback<TimescaleMark>, resolution: ResolutionString): void;
/**
* This function is called if configuration flag supports_time is set to true when chart needs to know the server time.
* The charting library expects callback to be called once.
* The time is provided without milliseconds. Example: 1445324591. It is used to display Countdown on the price scale.
*/
getServerTime?(callback: ServerTimeCallback): void;
searchSymbols(userInput: string, exchange: string, symbolType: string, onResult: SearchSymbolsCallback): void;
resolveSymbol(symbolName: string, onResolve: ResolveCallback, onError: ErrorCallback): void;
getBars(symbolInfo: LibrarySymbolInfo, resolution: ResolutionString, rangeStartDate: number, rangeEndDate: number, onResult: HistoryCallback, onError: ErrorCallback, isFirstCall: boolean): void;
subscribeBars(symbolInfo: LibrarySymbolInfo, resolution: ResolutionString, onTick: SubscribeBarsCallback, listenerGuid: string, onResetCacheNeededCallback: () => void): void;
unsubscribeBars(listenerGuid: string): void;
subscribeDepth?(symbolInfo: LibrarySymbolInfo, callback: DomeCallback): string;
unsubscribeDepth?(subscriberUID: string): void;
}
export as namespace TradingView;