diff --git a/charting_library/charting_library.min.d.ts b/charting_library/charting_library.min.d.ts index a41372e1..40a21561 100644 --- a/charting_library/charting_library.min.d.ts +++ b/charting_library/charting_library.min.d.ts @@ -1,17 +1,5 @@ /// -export declare type LanguageCode = 'ar' | 'zh' | 'cs' | 'da_DK' | 'nl_NL' | 'en' | 'et_EE' | 'fr' | 'de' | 'el' | 'he_IL' | 'hu_HU' | 'id_ID' | 'it' | 'ja' | 'ko' | 'fa' | 'pl' | 'pt' | 'ro' | 'ru' | 'sk_SK' | 'es' | 'sv' | 'th' | 'tr' | 'vi'; -export interface ISubscription { - subscribe(obj: object | null, member: TFunc, singleshot?: boolean): void; - unsubscribe(obj: object | null, member: TFunc): void; - unsubscribeAll(obj: object | null): void; -} -export interface IDelegate extends ISubscription { - fire: TFunc; -} -export interface IDestroyable { - destroy(): void; -} /** * This is the generic type useful for declaring a nominal type, * which does not structurally matches with the base type and @@ -28,65 +16,15 @@ export interface IDestroyable { export declare type Nominal = T & { [Symbol.species]: Name; }; -export interface FormatterParseResult { - res: boolean; -} -export interface ErrorFormatterParseResult extends FormatterParseResult { - error?: string; - res: false; -} -export interface SuccessFormatterParseResult extends FormatterParseResult { - res: true; - suggest?: string; -} -export interface IFormatter { - format(value: any): string; - parse?(value: string): ErrorFormatterParseResult | SuccessFormatterParseResult; -} -export declare type StudyInputValueType = string | number | boolean; -export declare type StudyOverrideValueType = string | number | boolean; -export interface StudyOverrides { - [key: string]: StudyOverrideValueType; -} -export interface WatchedValueSubscribeOptions { - once?: boolean; - callWithLast?: boolean; -} -export interface IWatchedValueReadonly { - value(): T; - subscribe(callback: (value: T) => void, options?: WatchedValueSubscribeOptions): void; - unsubscribe(callback?: ((value: T) => void) | null): void; - spawn(): IWatchedValueReadonlySpawn; -} -export interface IWatchedValueReadonlySpawn extends IWatchedValueReadonly, IDestroyable { -} -export declare type WatchedValueCallback = (value: T) => void; -export interface IWatchedValue extends IWatchedValueReadonly { - value(): T; - setValue(value: T, forceUpdate?: boolean): void; - subscribe(callback: WatchedValueCallback, options?: WatchedValueSubscribeOptions): void; - unsubscribe(callback?: WatchedValueCallback | null): void; - readonly(): IWatchedValueReadonly; - spawn(): IWatchedValueSpawn; -} -export interface IWatchedValueSpawn extends IWatchedValueReadonlySpawn, IWatchedValue { - spawn(): IWatchedValueSpawn; -} export declare const enum ConnectionStatus { Connected = 1, Connecting = 2, Disconnected = 3, - Error = 4, + Error = 4 } -export declare const enum OrderType { - Limit = 1, - Market = 2, - Stop = 3, - StopLimit = 4, -} -export declare const enum Side { - Buy = 1, - Sell = -1, +export declare const enum NotificationType { + Error = 0, + Success = 1 } export declare const enum OrderStatus { Canceled = 1, @@ -94,119 +32,110 @@ export declare const enum OrderStatus { Inactive = 3, Placing = 4, Rejected = 5, - Working = 6, + Working = 6 } -export declare const enum ParentType { - Order = 1, - Position = 2, - Trade = 3, +export declare const enum OrderStatusFilter { + All = 0, + Canceled = 1, + Filled = 2, + Inactive = 3, + Rejected = 5, + Working = 6 } export declare const enum OrderTicketFocusControl { StopLoss = 1, StopPrice = 2, - TakeProfit = 3, + TakeProfit = 3 } -export declare const enum NotificationType { - Error = 0, - Success = 1, +export declare const enum OrderType { + Limit = 1, + Market = 2, + Stop = 3, + StopLimit = 4 } -export interface TableRow { - priceFormatter?: IFormatter; - [name: string]: any; +export declare const enum ParentType { + Order = 1, + Position = 2, + Trade = 3 } -export interface TableFormatterInputs { - value: number | string | Side | OrderType | OrderStatus; - prevValue?: number | undefined; - row: TableRow; - $container: JQuery; - priceFormatter?: IFormatter; +export declare const enum PriceScaleMode { + Normal = 0, + Log = 1, + Percentage = 2, + IndexedTo100 = 3 } -export declare type TableElementFormatFunction = (inputs: TableFormatterInputs) => string | JQuery; -export interface TableElementFormatter { - name: string; - format: TableElementFormatFunction; +export declare const enum SeriesStyle { + Bars = 0, + Candles = 1, + Line = 2, + Area = 3, + HeikenAshi = 8, + HollowCandles = 9, + Renko = 4, + Kagi = 5, + PointAndFigure = 6, + LineBreak = 7 } -export declare type StandardFormatterName = 'date' | 'default' | 'fixed' | 'formatPrice' | 'formatPriceForexSup' | 'integerSeparated' | 'localDate' | 'percentage' | 'pips' | 'profit' | 'side' | 'status' | 'symbol' | 'type'; -export interface DOMLevel { - price: number; - volume: number; -} -export interface DOMData { - snapshot: boolean; - asks: DOMLevel[]; - bids: DOMLevel[]; -} -export interface QuantityMetainfo { - min: number; - max: number; - step: number; - default?: number; -} -export interface InstrumentInfo { - qty: QuantityMetainfo; - pipValue: number; - pipSize: number; - minTick: number; - description: string; - domVolumePrecision?: number; -} -export interface CustomFields { - [key: string]: any; -} -export interface PreOrder { - symbol: string; - brokerSymbol?: string; - type?: OrderType; - side?: Side; - qty: number; - status?: OrderStatus; - stopPrice?: number; - limitPrice?: number; - stopLoss?: number; - takeProfit?: number; - duration?: OrderDuration; -} -export interface PlacedOrder extends PreOrder, CustomFields { - id: string; - filledQty?: number; - avgPrice?: number; - updateTime?: number; - takeProfit?: number; - stopLoss?: number; - type: OrderType; - side: Side; - status: OrderStatus; -} -export interface OrderWithParent extends PlacedOrder { - parentId: string; - parentType: ParentType; +export declare const enum Side { + Buy = 1, + Sell = -1 } +export declare const widget: ChartingLibraryWidgetConstructor; +export declare function version(): string; +export declare type ActionMetaInfo = ActionDescriptionWithCallback | MenuSeparator; +export declare type AvailableSaveloadVersions = '1.0' | '1.1'; +export declare type ChartActionId = 'chartProperties' | 'compareOrAdd' | 'scalesProperties' | 'tmzProperties' | 'paneObjectTree' | 'insertIndicator' | 'symbolSearch' | 'changeInterval' | 'timeScaleReset' | 'chartReset' | 'seriesHide' | 'studyHide' | 'lineToggleLock' | 'lineHide' | 'showLeftAxis' | 'showRightAxis' | 'scaleSeriesOnly' | 'drawingToolbarAction' | 'magnetAction' | 'stayInDrawingModeAction' | 'hideAllMarks' | 'showCountdown' | 'showSeriesLastValue' | 'showSymbolLabelsAction' | 'showStudyLastValue' | 'showStudyPlotNamesAction' | 'undo' | 'redo' | 'paneRemoveAllStudiesDrawingTools'; +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 Direction = 'buy' | 'sell'; +export declare type DomeCallback = (data: DOMData) => void; +export declare type EditObjectDialogObjectType = 'mainSeries' | 'drawing' | 'study' | 'other'; +export declare type EmptyCallback = () => void; +export declare type EntityId = Nominal; +export declare type ErrorCallback = (reason: string) => void; +export declare type FieldDescriptor = TimeFieldDescriptor | SeriesFieldDescriptor | StudyFieldDescriptor; +export declare type GetMarksCallback = (marks: T[]) => void; +export declare type HistoryCallback = (bars: Bar[], meta: HistoryMetadata) => void; +export declare type IBasicDataFeed = IDatafeedChartApi & IExternalDatafeed; +export declare type InputFieldValidator = (value: any) => InputFieldValidatorResult; +export declare type InputFieldValidatorResult = PositiveBaseInputFieldValidatorResult | NegativeBaseInputFieldValidatorResult; +export declare type LanguageCode = 'ar' | 'zh' | 'cs' | 'da_DK' | 'nl_NL' | 'en' | 'et_EE' | 'fr' | 'de' | 'el' | 'he_IL' | 'hu_HU' | 'id_ID' | 'it' | 'ja' | 'ko' | 'fa' | 'pl' | 'pt' | 'ro' | 'ru' | 'sk_SK' | 'es' | 'sv' | 'th' | 'tr' | 'vi'; +export declare type LayoutType = SingleChartLayoutType | MultipleChartsLayoutType; +export declare type MarkConstColors = 'red' | 'green' | 'blue' | 'yellow'; +export declare type MultipleChartsLayoutType = '2h' | '2-1' | '2v' | '3h' | '3v' | '3s' | '4' | '6' | '8'; +export declare type OnReadyCallback = (configuration: DatafeedConfiguration) => void; export declare type Order = OrderWithParent | PlacedOrder; -export interface Position { - id: string; - symbol: string; - brokerSymbol?: string; - qty: number; - side: Side; - avgPrice: number; - [key: string]: any; +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 declare type ResolveCallback = (symbolInfo: LibrarySymbolInfo) => void; +export declare type RssNewsFeedItem = RssNewsFeedInfo | RssNewsFeedInfo[]; +export declare type SearchSymbolsCallback = (items: SearchSymbolResultItem[]) => void; +export declare type ServerTimeCallback = (serverTime: number) => void; +export declare type ShapePoint = StickedPoint | PricedPoint | TimePoint; +export declare type SingleChartLayoutType = 's'; +export declare type StandardFormatterName = 'date' | 'default' | 'fixed' | 'formatQuantity' | 'formatPrice' | 'formatPriceForexSup' | 'integerSeparated' | 'localDate' | 'percentage' | 'pips' | 'profit' | 'side' | 'status' | 'symbol' | 'type' | 'unixTimeAgo'; +export declare type StudyInputId = Nominal; +export declare type StudyInputValue = string | number | boolean; +export declare type StudyOverrideValueType = string | number | boolean; +export declare type StudyPriceScale = 'left' | 'right' | 'no-scale' | 'as-series'; +export declare type SubscribeBarsCallback = (bar: Bar) => void; +export declare type SupportedLineTools = 'text' | 'anchored_text' | 'note' | 'anchored_note' | 'double_curve' | 'arc' | 'icon' | 'arrow_up' | 'arrow_down' | 'arrow_left' | 'arrow_right' | 'price_label' | 'flag' | 'vertical_line' | 'horizontal_line' | 'cross_line' | 'horizontal_ray' | 'trend_line' | 'info_line' | 'trend_angle' | 'arrow' | 'ray' | 'extended' | 'parallel_channel' | 'disjoint_angle' | 'flat_bottom' | 'pitchfork' | 'schiff_pitchfork_modified' | 'schiff_pitchfork' | 'balloon' | 'inside_pitchfork' | 'pitchfan' | 'gannbox' | 'gannbox_square' | 'gannbox_fixed' | 'gannbox_fan' | 'fib_retracement' | 'fib_trend_ext' | 'fib_speed_resist_fan' | 'fib_timezone' | 'fib_trend_time' | 'fib_circles' | 'fib_spiral' | 'fib_speed_resist_arcs' | 'fib_channel' | 'xabcd_pattern' | 'cypher_pattern' | 'abcd_pattern' | 'callout' | 'triangle_pattern' | '3divers_pattern' | 'head_and_shoulders' | 'fib_wedge' | 'elliott_impulse_wave' | 'elliott_triangle_wave' | 'elliott_triple_combo' | 'elliott_correction' | 'elliott_double_combo' | 'cyclic_lines' | 'time_cycles' | 'sine_line' | 'long_position' | 'short_position' | 'forecast' | 'date_range' | 'price_range' | 'date_and_price_range' | 'bars_pattern' | 'ghost_feed' | 'projection' | 'rectangle' | 'rotated_rectangle' | 'ellipse' | 'triangle' | 'polyline' | 'curve' | 'cursor' | 'dot' | 'arrow_cursor' | 'eraser' | 'measure' | 'zoom' | 'brush'; +export declare type TableElementFormatFunction = (inputs: TableFormatterInputs) => string | JQuery; +export declare type TextInputFieldValidator = (value: string) => InputFieldValidatorResult; +export declare type ThemeName = 'Light' | 'Dark'; +export declare type Timezone = 'Etc/UTC' | CustomTimezones; +export declare type WatchListSymbolListAddedCallback = (listId: string, symbols: string[]) => void; +export declare type WatchListSymbolListRemovedCallback = (listId: string) => void; +export declare type WatchListSymbolListRenamedCallback = (listId: string, oldName: string, newName: string) => void; +export declare type WatchedValueCallback = (value: T) => void; +export interface AccessList { + type: 'black' | 'white'; + tools: AccessListItem[]; } -export interface Trade extends CustomFields { - id: string; - date: number; - symbol: string; - brokerSymbol?: string; - qty: number; - side: Side; - price: number; -} -export interface Execution extends CustomFields { - symbol: string; - brokerSymbol?: string; - price: number; - qty: number; - side: Side; - time: number; +export interface AccessListItem { + name: string; + grayed?: boolean; } export interface AccountInfo { id: string; @@ -229,9 +158,31 @@ export interface AccountManagerColumn { notHideable?: boolean; hideByDefault?: boolean; } -export interface SortingParameters { - columnId: string; - asc?: boolean; +export interface AccountManagerInfo { + accountTitle: string; + accountsList?: AccountInfo[]; + account?: IWatchedValue; + summary: AccountManagerSummaryField[]; + customFormatters?: TableElementFormatter[]; + orderColumns: OrderTableColumn[]; + orderColumnsSorting?: SortingParameters; + historyColumns?: AccountManagerColumn[]; + historyColumnsSorting?: SortingParameters; + positionColumns?: AccountManagerColumn[]; + tradeColumns?: AccountManagerColumn[]; + pages: AccountManagerPage[]; + possibleOrderStatuses?: OrderStatus[]; + contextMenuActions?(contextMenuEvent: JQueryEventObject, activePageActions: ActionMetaInfo[]): Promise; +} +export interface AccountManagerPage { + id: string; + title: string; + tables: AccountManagerTable[]; +} +export interface AccountManagerSummaryField { + text: string; + wValue: IWatchedValueReadonly; + formatter?: string; } export interface AccountManagerTable { id: string; @@ -239,35 +190,11 @@ export interface AccountManagerTable { columns: AccountManagerColumn[]; initialSorting?: SortingParameters; changeDelegate: ISubscription<(data: {}) => void>; - getData(): Promise<{}[]>; + flags?: AccountManagerTableFlags; + getData(paginationLastId?: string | number): Promise<{}[]>; } -export interface AccountManagerPage { - id: string; - title: string; - tables: AccountManagerTable[]; -} -export interface AccountManagerInfo { - accountTitle: string; - accountsList?: AccountInfo[]; - account?: IWatchedValue; - summary: AccountManagerSummaryField[]; - customFormatters?: TableElementFormatter[]; - orderColumns: AccountManagerColumn[]; - historyColumns?: AccountManagerColumn[]; - positionColumns: AccountManagerColumn[]; - tradeColumns?: AccountManagerColumn[]; - pages: AccountManagerPage[]; - possibleOrderStatuses?: OrderStatus[]; - contextMenuActions?(contextMenuEvent: JQueryEventObject, activePageActions: ActionMetaInfo[]): Promise; -} -export interface TradingQuotes { - trade?: number; - size?: number; - bid?: number; - bid_size?: number; - ask?: number; - ask_size?: number; - spread?: number; +export interface AccountManagerTableFlags { + supportPagination?: boolean; } export interface ActionDescription { text?: '-' | string; @@ -279,34 +206,28 @@ export interface ActionDescription { enabled?: boolean; externalLink?: boolean; } -export interface MenuSeparator extends ActionDescription { - separator: boolean; -} export interface ActionDescriptionWithCallback extends ActionDescription { action: (a: ActionDescription) => void; } -export declare type ActionMetaInfo = ActionDescriptionWithCallback | MenuSeparator; -export interface AccountManagerSummaryField { - text: string; - wValue: IWatchedValueReadonly; - formatter?: string; +export interface Bar { + time: number; + open: number; + high: number; + low: number; + close: number; + volume?: number; } -export interface OrderDurationMetaInfo { - hasDatePicker?: boolean; - hasTimePicker?: boolean; - name: string; - value: string; +export interface BaseInputFieldValidatorResult { + valid: boolean; } -export interface OrderDuration { - /** - * type is OrderDurationMetaInfo.value - */ - type: string; - datetime?: number; +export interface Brackets { + stopLoss?: number; + takeProfit?: number; } export interface BrokerConfigFlags { showQuantityInsteadOfAmount?: boolean; supportOrderBrackets?: boolean; + supportPositions?: boolean; supportPositionBrackets?: boolean; supportTradeBrackets?: boolean; supportTrades?: boolean; @@ -314,10 +235,14 @@ export interface BrokerConfigFlags { supportCloseTrade?: boolean; supportEditAmount?: boolean; supportLevel2Data?: boolean; + supportDOM?: boolean; supportMultiposition?: boolean; supportPLUpdate?: boolean; supportReducePosition?: boolean; supportReversePosition?: boolean; + supportMarketOrders?: boolean; + supportLimitOrders?: boolean; + supportStopOrders?: boolean; supportStopLimitOrders?: boolean; supportDemoLiveSwitcher?: boolean; supportCustomPlaceOrderTradableCheck?: boolean; @@ -333,14 +258,159 @@ export interface BrokerConfigFlags { */ supportBrackets?: boolean; } -export interface SingleBrokerMetaInfo { - configFlags: BrokerConfigFlags; - customNotificationFields?: string[]; - durations?: OrderDurationMetaInfo[]; +export interface ChartData { + id: string; + name: string; + symbol: string; + resolution: ResolutionString; + content: string; } -export interface Brackets { - stopLoss?: number; - takeProfit?: number; +export interface ChartMetaInfo { + id: string; + name: string; + symbol: string; + resolution: ResolutionString; + timestamp: number; +} +export interface ChartingLibraryWidgetConstructor { + new (options: ChartingLibraryWidgetOptions | TradingTerminalWidgetOptions): IChartingLibraryWidget; +} +export interface ChartingLibraryWidgetOptions { + container_id: string; + datafeed: IBasicDataFeed | (IBasicDataFeed & IDatafeedQuotesApi); + interval: ResolutionString; + symbol: string; + auto_save_delay?: number; + autosize?: boolean; + debug?: boolean; + disabled_features?: string[]; + drawings_access?: AccessList; + enabled_features?: string[]; + fullscreen?: boolean; + height?: number; + library_path?: string; + locale: LanguageCode; + numeric_formatting?: NumericFormattingParams; + saved_data?: object; + studies_access?: AccessList; + study_count_limit?: number; + symbol_search_request_delay?: number; + timeframe?: string; + timezone?: 'exchange' | Timezone; + toolbar_bg?: string; + width?: number; + charts_storage_url?: string; + charts_storage_api_version?: AvailableSaveloadVersions; + client_id?: string; + user_id?: string; + load_last_chart?: boolean; + studies_overrides?: StudyOverrides; + customFormatters?: CustomFormatters; + overrides?: Overrides; + snapshot_url?: string; + indicators_file_name?: string; + preset?: 'mobile'; + time_frames?: TimeFrameItem[]; + custom_css_url?: string; + favorites?: Favorites; + save_load_adapter?: IExternalSaveLoadAdapter; + loading_screen?: LoadingScreenOptions; + settings_adapter?: ISettingsAdapter; + theme?: ThemeName; +} +export interface ContextMenuItem { + position: 'top' | 'bottom'; + text: string; + click: EmptyCallback; +} +export interface CreateButtonOptions { + align: 'right' | 'left'; +} +export interface CreateShapeOptions { + shape?: 'arrow_up' | 'arrow_down' | 'flag' | 'vertical_line' | 'horizontal_line'; + text?: string; + lock?: boolean; + disableSelection?: boolean; + disableSave?: boolean; + disableUndo?: boolean; + overrides?: TOverrides; + zOrder?: 'top' | 'bottom'; + showInObjectsTree?: boolean; +} +export interface CreateStudyOptions { + checkLimit?: boolean; + priceScale?: StudyPriceScale; +} +export interface CreateStudyTemplateOptions { + saveInterval?: boolean; +} +export interface CreateTradingPrimitiveOptions { + disableUndo?: boolean; +} +export interface CrossHairMovedEventParams { + time: number; + price: number; +} +export interface CustomFields { + [key: string]: any; +} +export interface CustomFormatter { + format(date: Date): string; + formatLocal(date: Date): string; +} +export interface CustomFormatters { + timeFormatter: CustomFormatter; + dateFormatter: CustomFormatter; +} +export interface CustomInputFieldMetaInfo { + id: string; + title: string; + placeHolder: string; + value: any; + validator?: InputFieldValidator; + customInfo?: any; +} +export interface CustomInputFieldsValues { + [fieldId: string]: TextWithCheckboxValue | any; +} +export interface DOMData { + snapshot: boolean; + asks: DOMLevel[]; + bids: DOMLevel[]; +} +export interface DOMLevel { + price: number; + volume: number; +} +export interface DatafeedConfiguration { + exchanges?: Exchange[]; + supported_resolutions?: ResolutionString[]; + supports_marks?: boolean; + supports_time?: boolean; + supports_timescale_marks?: boolean; + symbols_types?: DatafeedSymbolType[]; +} +export interface DatafeedQuoteValues { + ch?: number; + chp?: number; + short_name?: string; + exchange?: string; + description?: string; + lp?: number; + ask?: number; + bid?: number; + spread?: number; + open_price?: number; + high_price?: number; + low_price?: number; + prev_close_price?: number; + volume?: number; + original_name?: string; + [valueName: string]: string | number | undefined; +} +export interface DatafeedSymbolType { + name: string; + value: string; } export interface DefaultContextMenuActionsParams { } @@ -352,62 +422,65 @@ export interface DefaultDropdownActionsParams { disconnect?: boolean; showHowToUse?: boolean; } -export interface ITradeContext { - symbol: string; - displaySymbol: string; - value: number | null; - formattedValue: string; - last: number; -} -export interface QuotesBase { - change: number; - change_percent: number; - last_price: number; - fractional: number; - minmov: number; - minmove2: number; - pricescale: number; - description: string; -} -export interface OrderDialogOptions { - customFields?: (TextWithCheckboxFieldMetaInfo | CustomInputFieldMetaInfo)[]; -} -export interface BaseInputFieldValidatorResult { - valid: boolean; -} -export interface PositiveBaseInputFieldValidatorResult extends BaseInputFieldValidatorResult { - valid: true; -} -export interface NegativeBaseInputFieldValidatorResult extends BaseInputFieldValidatorResult { - valid: false; - errorMessage: string; -} -export declare type InputFieldValidatorResult = PositiveBaseInputFieldValidatorResult | NegativeBaseInputFieldValidatorResult; -export declare type InputFieldValidator = (value: any) => InputFieldValidatorResult; -export interface CustomInputFieldMetaInfo { - id: string; +export interface DialogParams { title: string; - placeHolder: string; - value: any; - validator?: InputFieldValidator; - customInfo?: any; + body: string; + callback: CallbackType; } -export interface TextWithCheckboxValue { - text: string; - checked: boolean; +export interface EditObjectDialogEventParams { + objectType: EditObjectDialogObjectType; + scriptTitle: string; } -export interface TextWithCheckboxFieldCustomInfo { - checkboxTitle: string; - asterix?: boolean; +export interface EntityInfo { + id: EntityId; + name: string; } -export declare type TextInputFieldValidator = (value: string) => InputFieldValidatorResult; -export interface TextWithCheckboxFieldMetaInfo extends CustomInputFieldMetaInfo { - value: TextWithCheckboxValue; - customInfo: TextWithCheckboxFieldCustomInfo; - validator?: TextInputFieldValidator; +export interface ErrorFormatterParseResult extends FormatterParseResult { + error?: string; + res: false; } -export interface CustomInputFieldsValues { - [fieldId: string]: TextWithCheckboxValue | any; +export interface Exchange { + value: string; + name: string; + desc: string; +} +export interface Execution extends CustomFields { + symbol: string; + brokerSymbol?: string; + price: number; + qty: number; + side: Side; + time: number; +} +export interface ExportDataOptions { + from?: number; + to?: number; + includeTime?: boolean; + includeSeries?: boolean; + includedStudies: ReadonlyArray | 'all'; +} +export interface ExportedData { + schema: FieldDescriptor[]; + data: Float64Array[]; +} +export interface Favorites { + intervals: ResolutionString[]; + chartTypes: string[]; +} +export interface FormatterParseResult { + res: boolean; +} +export interface GrayedObject { + type: 'drawing' | 'study'; + name: string; +} +export interface HistoryDepth { + resolutionBack: ResolutionBackValues; + intervalBack: number; +} +export interface HistoryMetadata { + noData: boolean; + nextTime?: number | null; } export interface IBrokerCommon { chartContextMenuActions(context: ITradeContext, options?: DefaultContextMenuActionsParams): Promise; @@ -416,7 +489,7 @@ export interface IBrokerCommon { placeOrder(order: PreOrder, silently?: boolean): Promise; modifyOrder(order: Order, silently?: boolean, focus?: OrderTicketFocusControl): Promise; orders(): Promise; - positions(): Promise; + positions?(): Promise; trades?(): Promise; executions(symbol: string): Promise; symbolInfo(symbol: string): Promise; @@ -426,21 +499,19 @@ export interface IBrokerCommon { accountManagerInfo(): AccountManagerInfo; formatter?(symbol: string): Promise; spreadFormatter?(symbol: string): Promise; -} -export interface SuggestedQuantity { - changed: IDelegate<(symbol: string) => void>; - value(symbol: string): Promise; - setValue(symbol: string, value: number): void; + quantityFormatter?(symbol: string): Promise; } export interface IBrokerConnectionAdapterFactory { createDelegate(): IDelegate; createWatchedValue(value?: T): IWatchedValue; + createPriceFormatter(priceScale: number, minMove: number, fractional: boolean, minMove2: number): IFormatter; } export interface IBrokerConnectionAdapterHost { factory: IBrokerConnectionAdapterFactory; connectionStatusUpdate(status: ConnectionStatus, message?: string): void; defaultFormatter(symbol: string): Promise; numericFormatter(decimalPlaces: number): Promise; + quantityFormatter(decimalPlaces?: number): Promise; defaultContextMenuActions(context: ITradeContext, params?: DefaultContextMenuActionsParams): Promise; defaultDropdownMenuActions(options?: Partial): ActionMetaInfo[]; floatingTradingPanelVisibility(): IWatchedValue; @@ -462,19 +533,24 @@ export interface IBrokerConnectionAdapterHost { equityUpdate(equity: number): void; domeUpdate(symbol: string, equity: DOMData): void; showOrderDialog(order: T, handler: (order: T, customFieldsResult?: CustomInputFieldsValues) => Promise, focus?: OrderTicketFocusControl, options?: OrderDialogOptions): Promise; - showCancelOrderDialog(orderId: string, handler: () => void): Promise; - showCancelMultipleOrdersDialog(symbol: string, side: Side | undefined, qty: number, handler: () => void): Promise; - showCancelBracketsDialog(orderId: string, handler: () => void): Promise; - showCancelMultipleBracketsDialog(orderId: string, handler: () => void): Promise; - showClosePositionDialog(positionId: string, handler: () => void): Promise; - showReversePositionDialog(position: Position, handler: () => void): Promise; - showPositionBracketsDialog(position: Position | Trade, brackets: Brackets, focus: OrderTicketFocusControl | null, handler: (brackets: Brackets) => void): Promise; + showCancelOrderDialog(orderId: string, handler: () => Promise): Promise; + showCancelMultipleOrdersDialog(symbol: string, side: Side | undefined, qty: number, handler: () => Promise): Promise; + showCancelBracketsDialog(orderId: string, handler: () => Promise): Promise; + showCancelMultipleBracketsDialog(orderId: string, handler: () => Promise): Promise; + showClosePositionDialog(positionId: string, handler: () => Promise): Promise; + showReversePositionDialog(position: Position, handler: () => Promise): Promise; + showPositionBracketsDialog(position: Position | Trade, brackets: Brackets, focus: OrderTicketFocusControl | null, handler: (brackets: Brackets) => Promise): Promise; showNotification(title: string, text: string, notificationType?: NotificationType): void; setButtonDropdownActions(descriptions: ActionMetaInfo[]): void; activateBottomWidget(): Promise; showTradingProperties(): void; suggestedQty(): SuggestedQuantity; symbolSnapshot(symbol: string): Promise; + showMessageDialog(caption: string, message: string): void; +} +export interface IBrokerTerminal extends IBrokerWithoutRealtime { + subscribeRealtime(symbol: string): void; + unsubscribeRealtime(symbol: string): void; } export interface IBrokerWithoutRealtime extends IBrokerCommon { subscribeDOME?(symbol: string): void; @@ -482,7 +558,7 @@ export interface IBrokerWithoutRealtime extends IBrokerCommon { cancelOrder(orderId: string, silently: boolean): Promise; cancelOrders(symbol: string, side: Side | undefined, ordersIds: string[], silently: boolean): Promise; reversePosition?(positionId: string, silently?: boolean): Promise; - closePosition(positionId: string, silently: boolean): Promise; + closePosition?(positionId: string, silently: boolean): Promise; closeTrade?(tradeId: string, silently: boolean): Promise; /** * @deprecated Brokers should always send PL and equity updates @@ -495,69 +571,356 @@ export interface IBrokerWithoutRealtime extends IBrokerCommon { unsubscribePL?(positionId: string): void; unsubscribeEquity?(): void; } -export interface IBrokerTerminal extends IBrokerWithoutRealtime { - subscribeRealtime(symbol: string): void; - unsubscribeRealtime(symbol: string): void; +export interface IChartWidgetApi { + onDataLoaded(): ISubscription<() => void>; + onSymbolChanged(): ISubscription<() => void>; + onIntervalChanged(): ISubscription<(interval: ResolutionString, timeFrameParameters: { + timeframe?: string; + }) => void>; + onVisibleRangeChanged(): ISubscription<() => void>; + dataReady(callback: () => void): boolean; + crossHairMoved(callback: (params: CrossHairMovedEventParams) => void): void; + setVisibleRange(range: VisibleTimeRange, callback: () => void): void; + setSymbol(symbol: string, callback: () => void): void; + setResolution(resolution: ResolutionString, callback: () => void): void; + resetData(): void; + executeActionById(actionId: ChartActionId): void; + getCheckableActionState(actionId: ChartActionId): boolean; + refreshMarks(): void; + clearMarks(): void; + setChartType(type: SeriesStyle): void; + getAllShapes(): EntityInfo[]; + getAllStudies(): EntityInfo[]; + /** + * @deprecated Use shape/study API instead ([getStudyById] / [getShapeById]) + */ + setEntityVisibility(entityId: EntityId, isVisible: boolean): void; + createStudy(name: string, forceOverlay: boolean, lock?: boolean, inputs?: TStudyInputValue[], callback?: (entityId: EntityId) => void, overrides?: TOverrides, options?: CreateStudyOptions): EntityId | null; + getStudyById(entityId: EntityId): IStudyApi; + createShape(point: ShapePoint, options: CreateShapeOptions): EntityId | null; + createMultipointShape(points: ShapePoint[], options: CreateShapeOptions): EntityId | null; + getShapeById(entityId: EntityId): ILineDataSourceApi; + removeEntity(entityId: EntityId): void; + removeAllShapes(): void; + removeAllStudies(): void; + createStudyTemplate(options: CreateStudyTemplateOptions): object; + applyStudyTemplate(template: object): void; + createOrderLine(options: CreateTradingPrimitiveOptions): IOrderLineAdapter; + createPositionLine(options: CreateTradingPrimitiveOptions): IPositionLineAdapter; + createExecutionShape(options: CreateTradingPrimitiveOptions): IExecutionLineAdapter; + symbol(): string; + symbolExt(): SymbolExt; + resolution(): ResolutionString; + getVisibleRange(): VisibleTimeRange; + getVisiblePriceRange(): VisiblePriceRange; + priceFormatter(): IFormatter; + chartType(): SeriesStyle; + setTimezone(timezone: 'exchange' | Timezone): void; + getPanes(): IPaneApi[]; + exportData(options?: ExportDataOptions): Promise; + canZoomOut(): boolean; + zoomOut(): void; } -export declare type ResolutionString = string; -export interface Exchange { - value: string; - name: string; - desc: string; +export interface IChartingLibraryWidget { + headerReady(): Promise; + onChartReady(callback: EmptyCallback): void; + onGrayedObjectClicked(callback: (obj: GrayedObject) => void): void; + onShortcut(shortCut: string, callback: EmptyCallback): void; + subscribe(event: EventName, callback: SubscribeEventsMap[EventName]): void; + unsubscribe(event: EventName, callback: SubscribeEventsMap[EventName]): void; + chart(index?: number): IChartWidgetApi; + setLanguage(lang: LanguageCode): void; + setSymbol(symbol: string, interval: ResolutionString, callback: EmptyCallback): void; + remove(): void; + closePopupsAndDialogs(): void; + selectLineTool(linetool: SupportedLineTools): void; + selectedLineTool(): SupportedLineTools; + save(callback: (state: object) => void): void; + load(state: object): void; + getSavedCharts(callback: (chartRecords: SaveLoadChartRecord[]) => void): void; + loadChartFromServer(chartRecord: SaveLoadChartRecord): void; + saveChartToServer(onComplete?: EmptyCallback, onFail?: EmptyCallback, saveAsSnapshot?: false, options?: SaveChartToServerOptions): void; + removeChartFromServer(chartId: string, onCompleteCallback: EmptyCallback): void; + onContextMenu(callback: (unixTime: number, price: number) => ContextMenuItem[]): void; + createButton(options?: CreateButtonOptions): HTMLElement; + showNoticeDialog(params: DialogParams<() => void>): void; + showConfirmDialog(params: DialogParams<(confirmed: boolean) => void>): void; + showLoadChartDialog(): void; + showSaveAsChartDialog(): void; + symbolInterval(): SymbolIntervalResult; + mainSeriesPriceFormatter(): IFormatter; + getIntervals(): string[]; + getStudiesList(): string[]; + addCustomCSSFile(url: string): void; + applyOverrides(overrides: TOverrides): void; + applyStudiesOverrides(overrides: object): void; + watchList(): WatchListApi; + activeChart(): IChartWidgetApi; + chartsCount(): number; + layout(): LayoutType; + setLayout(layout: LayoutType): void; + layoutName(): string; + changeTheme(themeName: ThemeName): void; + takeScreenshot(): void; + lockAllDrawingTools(): IWatchedValue; + hideAllDrawingTools(): IWatchedValue; + undoRedoState(): UndoRedoState; } -export interface DatafeedSymbolType { - name: string; - value: string; +export interface IDatafeedChartApi { + calculateHistoryDepth?(resolution: ResolutionString, resolutionBack: ResolutionBackValues, intervalBack: number): HistoryDepth | undefined; + getMarks?(symbolInfo: LibrarySymbolInfo, from: number, to: number, onDataCallback: GetMarksCallback, resolution: ResolutionString): void; + getTimescaleMarks?(symbolInfo: LibrarySymbolInfo, from: number, to: number, onDataCallback: GetMarksCallback, 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 interface DatafeedConfiguration { - exchanges?: Exchange[]; - supported_resolutions?: ResolutionString[]; - supports_marks?: boolean; - supports_time?: boolean; - 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; - short_name?: string; - exchange?: string; - description?: string; - lp?: number; - ask?: number; - bid?: number; - spread?: number; - open_price?: number; - high_price?: number; - low_price?: number; - prev_close_price?: number; - volume?: number; - original_name?: string; - [valueName: string]: string | number | undefined; -} -export interface QuoteOkData { - s: 'ok'; - n: string; - v: DatafeedQuoteValues; -} -export interface QuoteErrorData { - s: 'error'; - n: string; - v: object; -} -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 IDelegate extends ISubscription { + fire: TFunc; +} +export interface IExecutionLineAdapter { + remove(): void; + getPrice(): number; + setPrice(value: number): this; + getTime(): number; + setTime(value: number): this; + getDirection(): Direction; + setDirection(value: Direction): this; + getText(): string; + setText(value: string): this; + getTooltip(): string; + setTooltip(value: string): this; + getArrowHeight(): number; + setArrowHeight(value: number): this; + getArrowSpacing(): number; + setArrowSpacing(value: number): this; + getFont(): string; + setFont(value: string): this; + getTextColor(): string; + setTextColor(value: string): this; + getArrowColor(): string; + setArrowColor(value: string): this; +} +export interface IExternalDatafeed { + onReady(callback: OnReadyCallback): void; +} +export interface IExternalSaveLoadAdapter { + getAllCharts(): Promise; + removeChart(chartId: string): Promise; + saveChart(chartData: ChartData): Promise; + getChartContent(chartId: string): Promise; + getAllStudyTemplates(): Promise; + removeStudyTemplate(studyTemplateInfo: StudyTemplateMetaInfo): Promise; + saveStudyTemplate(studyTemplateData: StudyTemplateData): Promise; + getStudyTemplateContent(studyTemplateInfo: StudyTemplateMetaInfo): Promise; +} +export interface IFormatter { + format(value: any): string; + parse?(value: string): ErrorFormatterParseResult | SuccessFormatterParseResult; +} +export interface ILineDataSourceApi { + isSelectionEnabled(): boolean; + setSelectionEnabled(enable: boolean): void; + isSavingEnabled(): boolean; + setSavingEnabled(enable: boolean): void; + isShowInObjectsTreeEnabled(): boolean; + setShowInObjectsTreeEnabled(enabled: boolean): void; + isUserEditEnabled(): boolean; + setUserEditEnabled(enabled: boolean): void; + bringToFront(): void; + sendToBack(): void; + getProperties(): object; + setProperties(newProperties: object): void; + getPoints(): PricedPoint[]; + setPoints(points: ShapePoint[]): void; +} +export interface IOrderLineAdapter { + remove(): void; + onModify(callback: () => void): this; + onModify(data: T, callback: (data: T) => void): this; + onMove(callback: () => void): this; + onMove(data: T, callback: (data: T) => void): this; + onCancel(callback: () => void): this; + onCancel(data: T, callback: (data: T) => void): this; + getPrice(): number; + setPrice(value: number): this; + getText(): string; + setText(value: string): this; + getTooltip(): string; + setTooltip(value: string): this; + getQuantity(): string; + setQuantity(value: string): this; + getEditable(): boolean; + setEditable(value: boolean): this; + getExtendLeft(): boolean; + setExtendLeft(value: boolean): this; + getLineLength(): number; + setLineLength(value: number): this; + getLineStyle(): number; + setLineStyle(value: number): this; + getLineWidth(): number; + setLineWidth(value: number): this; + getBodyFont(): string; + setBodyFont(value: string): this; + getQuantityFont(): string; + setQuantityFont(value: string): this; + getLineColor(): string; + setLineColor(value: string): this; + getBodyBorderColor(): string; + setBodyBorderColor(value: string): this; + getBodyBackgroundColor(): string; + setBodyBackgroundColor(value: string): this; + getBodyTextColor(): string; + setBodyTextColor(value: string): this; + getQuantityBorderColor(): string; + setQuantityBorderColor(value: string): this; + getQuantityBackgroundColor(): string; + setQuantityBackgroundColor(value: string): this; + getQuantityTextColor(): string; + setQuantityTextColor(value: string): this; + getCancelButtonBorderColor(): string; + setCancelButtonBorderColor(value: string): this; + getCancelButtonBackgroundColor(): string; + setCancelButtonBackgroundColor(value: string): this; + getCancelButtonIconColor(): string; + setCancelButtonIconColor(value: string): this; +} +export interface IPaneApi { + hasMainSeries(): boolean; + getLeftPriceScale(): IPriceScaleApi; + getRightPriceScale(): IPriceScaleApi; + getMainSourcePriceScale(): IPriceScaleApi | null; +} +export interface IPositionLineAdapter { + remove(): void; + onClose(callback: () => void): this; + onClose(data: T, callback: (data: T) => void): this; + onModify(callback: () => void): this; + onModify(data: T, callback: (data: T) => void): this; + onReverse(callback: () => void): this; + onReverse(data: T, callback: (data: T) => void): this; + getPrice(): number; + setPrice(value: number): this; + getText(): string; + setText(value: string): this; + getTooltip(): string; + setTooltip(value: string): this; + getQuantity(): string; + setQuantity(value: string): this; + getExtendLeft(): boolean; + setExtendLeft(value: boolean): this; + getLineLength(): number; + setLineLength(value: number): this; + getLineStyle(): number; + setLineStyle(value: number): this; + getLineWidth(): number; + setLineWidth(value: number): this; + getBodyFont(): string; + setBodyFont(value: string): this; + getQuantityFont(): string; + setQuantityFont(value: string): this; + getLineColor(): string; + setLineColor(value: string): this; + getBodyBorderColor(): string; + setBodyBorderColor(value: string): this; + getBodyBackgroundColor(): string; + setBodyBackgroundColor(value: string): this; + getBodyTextColor(): string; + setBodyTextColor(value: string): this; + getQuantityBorderColor(): string; + setQuantityBorderColor(value: string): this; + getQuantityBackgroundColor(): string; + setQuantityBackgroundColor(value: string): this; + getQuantityTextColor(): string; + setQuantityTextColor(value: string): this; + getReverseButtonBorderColor(): string; + setReverseButtonBorderColor(value: string): this; + getReverseButtonBackgroundColor(): string; + setReverseButtonBackgroundColor(value: string): this; + getReverseButtonIconColor(): string; + setReverseButtonIconColor(value: string): this; + getCloseButtonBorderColor(): string; + setCloseButtonBorderColor(value: string): this; + getCloseButtonBackgroundColor(): string; + setCloseButtonBackgroundColor(value: string): this; + getCloseButtonIconColor(): string; + setCloseButtonIconColor(value: string): this; +} +export interface IPriceScaleApi { + getMode(): PriceScaleMode; + setMode(newMode: PriceScaleMode): void; +} +export interface ISettingsAdapter { + initialSettings?: InitialSettingsMap; + setValue(key: string, value: string): void; + removeValue(key: string): void; +} +export interface IStudyApi { + isUserEditEnabled(): boolean; + setUserEditEnabled(enabled: boolean): void; + getInputsInfo(): StudyInputInfo[]; + getInputValues(): StudyInputValueItem[]; + setInputValues(values: StudyInputValueItem[]): void; + mergeUp(): void; + mergeDown(): void; + unmergeUp(): void; + unmergeDown(): void; + changePriceScale(newPriceScale: StudyPriceScale): void; + isVisible(): boolean; + setVisible(visible: boolean): void; + bringToFront(): void; + sendToBack(): void; + applyOverrides(overrides: TOverrides): void; +} +export interface ISubscription { + subscribe(obj: object | null, member: TFunc, singleshot?: boolean): void; + unsubscribe(obj: object | null, member: TFunc): void; + unsubscribeAll(obj: object | null): void; +} +export interface ITradeContext { + symbol: string; + displaySymbol: string; + value: number | null; + formattedValue: string; + last: number; +} +export interface IWatchedValue extends IWatchedValueReadonly { + value(): T; + setValue(value: T, forceUpdate?: boolean): void; + subscribe(callback: WatchedValueCallback, options?: WatchedValueSubscribeOptions): void; + unsubscribe(callback?: WatchedValueCallback | null): void; +} +export interface IWatchedValueReadonly { + value(): T; + subscribe(callback: (value: T) => void, options?: WatchedValueSubscribeOptions): void; + unsubscribe(callback?: ((value: T) => void) | null): void; +} +export interface InitialSettingsMap { + [key: string]: string; +} +export interface InstrumentInfo { + qty: QuantityMetainfo; + pipValue: number; + pipSize: number; + minTick: number; + lotSize?: number; + description: string; + domVolumePrecision?: number; +} export interface LibrarySymbolInfo { /** * Symbol Name @@ -636,31 +999,10 @@ export interface LibrarySymbolInfo { industry?: string; currency_code?: string; } -export interface Bar { - time: number; - open: number; - high: number; - low: number; - close: number; - volume?: number; +export interface LoadingScreenOptions { + foregroundColor?: string; + backgroundColor?: string; } -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; @@ -670,529 +1012,12 @@ export interface Mark { labelFontColor: string; minSize: number; } -export interface TimescaleMark { - id: string | number; - time: number; - color: MarkConstColors | string; - label: string; - tooltip: string[]; +export interface MarkCustomColor { + color: string; + background: 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 = (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, resolution: ResolutionString): void; - getTimescaleMarks?(symbolInfo: LibrarySymbolInfo, from: number, to: number, onDataCallback: GetMarksCallback, 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 interface ChartMetaInfo { - id: string; - name: string; - symbol: string; - resolution: ResolutionString; - timestamp: number; -} -export interface ChartData { - id: string; - name: string; - symbol: string; - resolution: ResolutionString; - content: string; -} -export interface StudyTemplateMetaInfo { - name: string; -} -export interface StudyTemplateData { - name: string; - content: string; -} -export interface IExternalSaveLoadAdapter { - getAllCharts(): Promise; - removeChart(chartId: string): Promise; - saveChart(chartData: ChartData): Promise; - getChartContent(chartId: string): Promise; - getAllStudyTemplates(): Promise; - removeStudyTemplate(studyTemplateInfo: StudyTemplateMetaInfo): Promise; - saveStudyTemplate(studyTemplateData: StudyTemplateData): Promise; - getStudyTemplateContent(studyTemplateInfo: StudyTemplateMetaInfo): Promise; -} -export interface RestBrokerMetaInfo { - url: string; - access_token: string; -} -export interface AccessListItem { - name: string; - grayed?: boolean; -} -export interface AccessList { - type: 'black' | 'white'; - tools: AccessListItem[]; -} -export interface NumericFormattingParams { - decimal_sign: string; -} -export declare type AvailableSaveloadVersions = '1.0' | '1.1'; -export interface Overrides { - [key: string]: string | number | boolean; -} -export interface WidgetBarParams { - details?: boolean; - watchlist?: boolean; - news?: boolean; - watchlist_settings?: { - default_symbols: string[]; - readonly?: boolean; - }; -} -export interface RssNewsFeedInfo { - url: string; - name: string; -} -export declare type RssNewsFeedItem = RssNewsFeedInfo | RssNewsFeedInfo[]; -export interface RssNewsFeedParams { - default: RssNewsFeedItem; - [symbolType: string]: RssNewsFeedItem; -} -export interface NewsProvider { - is_news_generic?: boolean; - get_news(symbol: string, callback: (items: NewsItem[]) => void): void; -} -export interface CustomFormatter { - format(date: Date): string; - formatLocal(date: Date): string; -} -export interface CustomFormatters { - timeFormatter: CustomFormatter; - dateFormatter: CustomFormatter; -} -export interface TimeFrameItem { - text: string; - resolution: ResolutionString; - description?: string; - title?: string; -} -export interface Favorites { - intervals: ResolutionString[]; - chartTypes: string[]; -} -export interface NewsItem { - fullDescription: string; - link?: string; - published: number; - shortDescription?: string; - source: string; - title: string; -} -export interface LoadingScreenOptions { - foregroundColor?: string; - backgroundColor?: string; -} -export interface InitialSettingsMap { - [key: string]: string; -} -export interface ISettingsAdapter { - initialSettings?: InitialSettingsMap; - setValue(key: string, value: string): void; - removeValue(key: string): void; -} -export declare type IBasicDataFeed = IDatafeedChartApi & IExternalDatafeed; -export declare type ThemeName = 'Light' | 'Dark'; -export interface ChartingLibraryWidgetOptions { - container_id: string; - datafeed: IBasicDataFeed | (IBasicDataFeed & IDatafeedQuotesApi); - interval: ResolutionString; - symbol: string; - auto_save_delay?: number; - autosize?: boolean; - debug?: boolean; - disabled_features?: string[]; - drawings_access?: AccessList; - enabled_features?: string[]; - fullscreen?: boolean; - height?: number; - library_path?: string; - locale: LanguageCode; - numeric_formatting?: NumericFormattingParams; - saved_data?: object; - studies_access?: AccessList; - study_count_limit?: number; - symbol_search_request_delay?: number; - timeframe?: string; - timezone?: 'exchange' | Timezone; - toolbar_bg?: string; - width?: number; - charts_storage_url?: string; - charts_storage_api_version?: AvailableSaveloadVersions; - client_id?: string; - user_id?: string; - load_last_chart?: boolean; - studies_overrides?: StudyOverrides; - customFormatters?: CustomFormatters; - overrides?: Overrides; - snapshot_url?: string; - indicators_file_name?: string; - preset?: 'mobile'; - time_frames?: TimeFrameItem[]; - custom_css_url?: string; - favorites?: Favorites; - save_load_adapter?: IExternalSaveLoadAdapter; - loading_screen?: LoadingScreenOptions; - settings_adapter?: ISettingsAdapter; - theme?: ThemeName; -} -export interface TradingTerminalWidgetOptions extends ChartingLibraryWidgetOptions { - brokerConfig?: SingleBrokerMetaInfo; - restConfig?: RestBrokerMetaInfo; - widgetbar?: WidgetBarParams; - rss_news_feed?: RssNewsFeedParams; - news_provider?: NewsProvider; - brokerFactory?(host: IBrokerConnectionAdapterHost): IBrokerWithoutRealtime | IBrokerTerminal; -} -export declare type LayoutType = 's' | '2h' | '2-1' | '2v' | '3h' | '3v' | '3s' | '4' | '6' | '8'; -export declare type SupportedLineTools = 'text' | 'anchored_text' | 'note' | 'anchored_note' | 'double_curve' | 'arc' | 'icon' | 'arrow_up' | 'arrow_down' | 'arrow_left' | 'arrow_right' | 'price_label' | 'flag' | 'vertical_line' | 'horizontal_line' | 'horizontal_ray' | 'trend_line' | 'trend_angle' | 'arrow' | 'ray' | 'extended' | 'parallel_channel' | 'disjoint_angle' | 'flat_bottom' | 'pitchfork' | 'schiff_pitchfork_modified' | 'schiff_pitchfork' | 'balloon' | 'inside_pitchfork' | 'pitchfan' | 'gannbox' | 'gannbox_square' | 'gannbox_fixed' | 'gannbox_fan' | 'fib_retracement' | 'fib_trend_ext' | 'fib_speed_resist_fan' | 'fib_timezone' | 'fib_trend_time' | 'fib_circles' | 'fib_spiral' | 'fib_speed_resist_arcs' | 'fib_channel' | 'xabcd_pattern' | 'cypher_pattern' | 'abcd_pattern' | 'callout' | 'triangle_pattern' | '3divers_pattern' | 'head_and_shoulders' | 'fib_wedge' | 'elliott_impulse_wave' | 'elliott_triangle_wave' | 'elliott_triple_combo' | 'elliott_correction' | 'elliott_double_combo' | 'cyclic_lines' | 'time_cycles' | 'sine_line' | 'long_position' | 'short_position' | 'forecast' | 'date_range' | 'price_range' | 'date_and_price_range' | 'bars_pattern' | 'ghost_feed' | 'projection' | 'rectangle' | 'rotated_rectangle' | 'ellipse' | 'triangle' | 'polyline' | 'curve' | 'regression_trend' | 'cursor' | 'dot' | 'arrow_cursor' | 'eraser' | 'measure' | 'zoom' | 'brush'; -export interface IOrderLineAdapter { - remove(): void; - onModify(callback: () => void): this; - onModify(data: T, callback: (data: T) => void): this; - onMove(callback: () => void): this; - onMove(data: T, callback: (data: T) => void): this; - getPrice(): number; - setPrice(value: number): this; - getText(): string; - setText(value: string): this; - getTooltip(): string; - setTooltip(value: string): this; - getQuantity(): string; - setQuantity(value: string): this; - getEditable(): boolean; - setEditable(value: boolean): this; - getExtendLeft(): boolean; - setExtendLeft(value: boolean): this; - getLineLength(): number; - setLineLength(value: number): this; - getLineStyle(): number; - setLineStyle(value: number): this; - getLineWidth(): number; - setLineWidth(value: number): this; - getBodyFont(): string; - setBodyFont(value: string): this; - getQuantityFont(): string; - setQuantityFont(value: string): this; - getLineColor(): string; - setLineColor(value: string): this; - getBodyBorderColor(): string; - setBodyBorderColor(value: string): this; - getBodyBackgroundColor(): string; - setBodyBackgroundColor(value: string): this; - getBodyTextColor(): string; - setBodyTextColor(value: string): this; - getQuantityBorderColor(): string; - setQuantityBorderColor(value: string): this; - getQuantityBackgroundColor(): string; - setQuantityBackgroundColor(value: string): this; - getQuantityTextColor(): string; - setQuantityTextColor(value: string): this; - getCancelButtonBorderColor(): string; - setCancelButtonBorderColor(value: string): this; - getCancelButtonBackgroundColor(): string; - setCancelButtonBackgroundColor(value: string): this; - getCancelButtonIconColor(): string; - setCancelButtonIconColor(value: string): this; -} -export interface IPositionLineAdapter { - remove(): void; - onClose(callback: () => void): this; - onClose(data: T, callback: (data: T) => void): this; - onModify(callback: () => void): this; - onModify(data: T, callback: (data: T) => void): this; - onReverse(callback: () => void): this; - onReverse(data: T, callback: (data: T) => void): this; - getPrice(): number; - setPrice(value: number): this; - getText(): string; - setText(value: string): this; - getTooltip(): string; - setTooltip(value: string): this; - getQuantity(): string; - setQuantity(value: string): this; - getExtendLeft(): boolean; - setExtendLeft(value: boolean): this; - getLineLength(): number; - setLineLength(value: number): this; - getLineStyle(): number; - setLineStyle(value: number): this; - getLineWidth(): number; - setLineWidth(value: number): this; - getBodyFont(): string; - setBodyFont(value: string): this; - getQuantityFont(): string; - setQuantityFont(value: string): this; - getLineColor(): string; - setLineColor(value: string): this; - getBodyBorderColor(): string; - setBodyBorderColor(value: string): this; - getBodyBackgroundColor(): string; - setBodyBackgroundColor(value: string): this; - getBodyTextColor(): string; - setBodyTextColor(value: string): this; - getQuantityBorderColor(): string; - setQuantityBorderColor(value: string): this; - getQuantityBackgroundColor(): string; - setQuantityBackgroundColor(value: string): this; - getQuantityTextColor(): string; - setQuantityTextColor(value: string): this; - getReverseButtonBorderColor(): string; - setReverseButtonBorderColor(value: string): this; - getReverseButtonBackgroundColor(): string; - setReverseButtonBackgroundColor(value: string): this; - getReverseButtonIconColor(): string; - setReverseButtonIconColor(value: string): this; - getCloseButtonBorderColor(): string; - setCloseButtonBorderColor(value: string): this; - getCloseButtonBackgroundColor(): string; - setCloseButtonBackgroundColor(value: string): this; - getCloseButtonIconColor(): string; - setCloseButtonIconColor(value: string): this; -} -export declare type Direction = 'buy' | 'sell'; -export interface IExecutionLineAdapter { - remove(): void; - getPrice(): number; - setPrice(value: number): this; - getTime(): number; - setTime(value: number): this; - getDirection(): Direction; - setDirection(value: Direction): this; - getText(): string; - setText(value: string): this; - getTooltip(): string; - setTooltip(value: string): this; - getArrowHeight(): number; - setArrowHeight(value: number): this; - getArrowSpacing(): number; - setArrowSpacing(value: number): this; - getFont(): string; - setFont(value: string): this; - getTextColor(): string; - setTextColor(value: string): this; - getArrowColor(): string; - setArrowColor(value: string): this; -} -export declare type StudyInputId = Nominal; -export interface StudyInputInfo { - id: StudyInputId; - name: string; - type: string; - localizedName: string; -} -export interface StudyInputValueItem { - id: StudyInputId; - value: StudyInputValueType; -} -export declare type StudyPriceScale = 'left' | 'right' | 'no-scale' | 'as-series'; -export interface IStudyApi { - isUserEditEnabled(): boolean; - setUserEditEnabled(enabled: boolean): void; - getInputsInfo(): StudyInputInfo[]; - getInputValues(): StudyInputValueItem[]; - setInputValues(values: StudyInputValueItem[]): void; - mergeUp(): void; - mergeDown(): void; - unmergeUp(): void; - unmergeDown(): void; - changePriceScale(newPriceScale: StudyPriceScale): void; - isVisible(): boolean; - setVisible(visible: boolean): void; - bringToFront(): void; - sendToBack(): void; - applyOverrides(overrides: TOverrides): void; -} -export interface TimePoint { - time: number; -} -export interface StickedPoint extends TimePoint { - channel: 'open' | 'high' | 'low' | 'close'; -} -export interface PricedPoint extends TimePoint { - price: number; -} -export declare type ShapePoint = StickedPoint | PricedPoint | TimePoint; -export interface ILineDataSourceApi { - isSelectionEnabled(): boolean; - setSelectionEnabled(enable: boolean): void; - isSavingEnabled(): boolean; - setSavingEnabled(enable: boolean): void; - isShowInObjectsTreeEnabled(): boolean; - setShowInObjectsTreeEnabled(enabled: boolean): void; - isUserEditEnabled(): boolean; - setUserEditEnabled(enabled: boolean): void; - bringToFront(): void; - sendToBack(): void; - getProperties(): object; - setProperties(newProperties: object): void; - getPoints(): PricedPoint[]; - setPoints(points: ShapePoint[]): void; -} -export declare const enum PriceScaleMode { - Normal = 0, - Log = 1, - Percentage = 2, -} -export interface IPriceScaleApi { - getMode(): PriceScaleMode; - setMode(newMode: PriceScaleMode): void; -} -export interface IPaneApi { - hasMainSeries(): boolean; - getLeftPriceScale(): IPriceScaleApi; - getRightPriceScale(): IPriceScaleApi; - getMainSourcePriceScale(): IPriceScaleApi | null; -} -export interface CrossHairMovedEventParams { - time: number; - price: number; -} -export interface VisibleTimeRange { - from: number; - to: number; -} -export interface VisiblePriceRange { - from: number; - to: number; -} -export declare type ChartActionId = 'chartProperties' | 'compareOrAdd' | 'scalesProperties' | 'tmzProperties' | 'paneObjectTree' | 'insertIndicator' | 'symbolSearch' | 'changeInterval' | 'timeScaleReset' | 'chartReset' | 'seriesHide' | 'studyHide' | 'lineToggleLock' | 'lineHide' | 'showLeftAxis' | 'showRightAxis' | 'scaleSeriesOnly' | 'drawingToolbarAction' | 'magnetAction' | 'stayInDrawingModeAction' | 'hideAllDrawingsAction' | 'hideAllMarks' | 'showCountdown' | 'showSeriesLastValue' | 'showSymbolLabelsAction' | 'showStudyLastValue' | 'showStudyPlotNamesAction' | 'undo' | 'redo' | 'paneRemoveAllStudiesDrawingTools'; -export declare const enum SeriesStyle { - Bars = 0, - Candles = 1, - Line = 2, - Area = 3, - HeikenAshi = 8, - HollowCandles = 9, - Renko = 4, - Kagi = 5, - PointAndFigure = 6, - LineBreak = 7, -} -export declare type EntityId = Nominal; -export interface EntityInfo { - id: EntityId; - name: string; -} -export interface CreateStudyOptions { - checkLimit?: boolean; - priceScale?: StudyPriceScale; -} -export interface CreateShapeOptions { - shape?: 'arrow_up' | 'arrow_down' | 'flag' | 'vertical_line' | 'horizontal_line'; - text?: string; - lock?: boolean; - disableSelection?: boolean; - disableSave?: boolean; - disableUndo?: boolean; - overrides?: TOverrides; - zOrder?: 'top' | 'bottom'; - showInObjectsTree?: boolean; -} -export interface CreateStudyTemplateOptions { - saveInterval?: boolean; -} -export interface SymbolExt { - symbol: string; - full_name: string; - exchange: string; - description: string; - type: string; -} -export interface CreateTradingPrimitiveOptions { - disableUndo?: boolean; -} -export interface IChartWidgetApi { - onDataLoaded(): ISubscription<() => void>; - onSymbolChanged(): ISubscription<() => void>; - onIntervalChanged(): ISubscription<(interval: ResolutionString, timeFrameParameters: { - timeframe?: string; - }) => void>; - onVisibleRangeChanged(): ISubscription<() => void>; - dataReady(callback: () => void): boolean; - crossHairMoved(callback: (params: CrossHairMovedEventParams) => void): void; - setVisibleRange(range: VisibleTimeRange, callback: () => void): void; - setSymbol(symbol: string, callback: () => void): void; - setResolution(resolution: ResolutionString, callback: () => void): void; - resetData(): void; - executeActionById(actionId: ChartActionId): void; - getCheckableActionState(actionId: ChartActionId): boolean; - refreshMarks(): void; - clearMarks(): void; - setChartType(type: SeriesStyle): void; - getAllShapes(): EntityInfo[]; - getAllStudies(): EntityInfo[]; - /** - * @deprecated Use shape/study API instead ([getStudyById] / [getShapeById]) - */ - setEntityVisibility(entityId: EntityId, isVisible: boolean): void; - createStudy(name: string, forceOverlay: boolean, lock?: boolean, inputs?: TStudyInputs[], callback?: (entityId: EntityId) => void, overrides?: TOverrides, options?: CreateStudyOptions): EntityId | null; - getStudyById(entityId: EntityId): IStudyApi; - createShape(point: ShapePoint, options: CreateShapeOptions): EntityId | null; - createMultipointShape(points: ShapePoint[], options: CreateShapeOptions): EntityId | null; - getShapeById(entityId: EntityId): ILineDataSourceApi; - removeEntity(entityId: EntityId): void; - removeAllShapes(): void; - removeAllStudies(): void; - createStudyTemplate(options: CreateStudyTemplateOptions): object; - applyStudyTemplate(template: object): void; - createOrderLine(options: CreateTradingPrimitiveOptions): IOrderLineAdapter; - createPositionLine(options: CreateTradingPrimitiveOptions): IPositionLineAdapter; - createExecutionShape(options: CreateTradingPrimitiveOptions): IExecutionLineAdapter; - symbol(): string; - symbolExt(): SymbolExt; - resolution(): ResolutionString; - getVisibleRange(): VisibleTimeRange; - getVisiblePriceRange(): VisiblePriceRange; - priceFormatter(): IFormatter; - chartType(): SeriesStyle; - setTimezone(timezone: 'exchange' | Timezone): void; - getPanes(): IPaneApi[]; -} -export interface WatchListSymbolList extends WatchListSymbolListData { - id: string; -} -export interface WatchListSymbolListData { - symbols: string[]; - title: string; -} -export interface WatchListSymbolListMap { - [listId: string]: WatchListSymbolList; -} -export declare type WatchListSymbolListAddedCallback = (listId: string, symbols: string[]) => void; -export declare type WatchListSymbolListRemovedCallback = (listId: string) => void; -export declare type WatchListSymbolListRenamedCallback = (listId: string, oldName: string, newName: string) => void; -export declare type EditObjectDialogObjectType = 'mainSeries' | 'drawing' | 'study' | 'other'; -export interface EditObjectDialogEventParams { - objectType: EditObjectDialogObjectType; - scriptTitle: string; +export interface MenuSeparator extends ActionDescription { + separator: boolean; } export interface MouseEventParams { clientX: number; @@ -1202,10 +1027,195 @@ export interface MouseEventParams { screenX: number; screenY: number; } +export interface NegativeBaseInputFieldValidatorResult extends BaseInputFieldValidatorResult { + valid: false; + errorMessage: string; +} +export interface NewsItem { + fullDescription: string; + link?: string; + published: number; + shortDescription?: string; + source: string; + title: string; +} +export interface NewsProvider { + is_news_generic?: boolean; + get_news(symbol: string, callback: (items: NewsItem[]) => void): void; +} +export interface NumericFormattingParams { + decimal_sign: string; +} +export interface OrderDialogOptions { + customFields?: (TextWithCheckboxFieldMetaInfo | CustomInputFieldMetaInfo)[]; +} +export interface OrderDuration { + /** + * type is OrderDurationMetaInfo.value + */ + type: string; + datetime?: number; +} +export interface OrderDurationMetaInfo { + hasDatePicker?: boolean; + hasTimePicker?: boolean; + name: string; + value: string; +} +export interface OrderTableColumn extends AccountManagerColumn { + supportedStatusFilters?: OrderStatusFilter[]; +} +export interface OrderWithParent extends PlacedOrder { + parentId: string; + parentType: ParentType; +} +export interface Overrides { + [key: string]: string | number | boolean; +} +export interface PlacedOrder extends PreOrder, CustomFields { + id: string; + filledQty?: number; + avgPrice?: number; + updateTime?: number; /** unix timestamp in milliseconds */ + takeProfit?: number; + stopLoss?: number; + type: OrderType; + side: Side; + status: OrderStatus; +} +export interface Position { + id: string; + symbol: string; + brokerSymbol?: string; + qty: number; + side: Side; + avgPrice: number; + [key: string]: any; +} +export interface PositiveBaseInputFieldValidatorResult extends BaseInputFieldValidatorResult { + valid: true; +} +export interface PreOrder { + symbol: string; + brokerSymbol?: string; + type?: OrderType; + side?: Side; + qty: number; + status?: OrderStatus; + stopPrice?: number; + limitPrice?: number; + stopLoss?: number; + takeProfit?: number; + duration?: OrderDuration; +} +export interface PricedPoint extends TimePoint { + price: number; +} +export interface QuantityMetainfo { + min: number; + max: number; + step: number; + default?: number; +} +export interface QuoteErrorData { + s: 'error'; + n: string; + v: object; +} +export interface QuoteOkData { + s: 'ok'; + n: string; + v: DatafeedQuoteValues; +} +export interface QuotesBase { + change: number; + change_percent: number; + last_price: number; + fractional: number; + minmov: number; + minmove2: number; + pricescale: number; + description: string; +} +export interface RestBrokerMetaInfo { + url: string; + access_token: string; +} +export interface RssNewsFeedInfo { + url: string; + name: string; +} +export interface RssNewsFeedParams { + default: RssNewsFeedItem; + [symbolType: string]: RssNewsFeedItem; +} +export interface SaveChartToServerOptions { + chartName?: string; + defaultChartName?: string; +} +export interface SaveLoadChartRecord { + id: string; + name: string; + image_url: string; + modified_iso: number; + short_symbol: string; + interval: ResolutionString; +} +export interface SearchSymbolResultItem { + symbol: string; + full_name: string; + description: string; + exchange: string; + ticker: string; + type: string; +} +export interface SeriesFieldDescriptor { + type: 'value'; + sourceType: 'series'; + plotTitle: string; +} +export interface SingleBrokerMetaInfo { + configFlags: BrokerConfigFlags; + customNotificationFields?: string[]; + durations?: OrderDurationMetaInfo[]; +} +export interface SortingParameters { + columnId: string; + asc?: boolean; +} +export interface StickedPoint extends TimePoint { + channel: 'open' | 'high' | 'low' | 'close'; +} +export interface StudyFieldDescriptor { + type: 'value'; + sourceType: 'study'; + sourceId: string; + sourceTitle: string; + plotTitle: string; +} +export interface StudyInputInfo { + id: StudyInputId; + name: string; + type: string; + localizedName: string; +} +export interface StudyInputValueItem { + id: StudyInputId; + value: StudyInputValue; +} export interface StudyOrDrawingAddedToChartEventParams { value: string; } -export declare type EmptyCallback = () => void; +export interface StudyOverrides { + [key: string]: StudyOverrideValueType; +} +export interface StudyTemplateData { + name: string; + content: string; +} +export interface StudyTemplateMetaInfo { + name: string; +} export interface SubscribeEventsMap { toggle_sidebar: (isHidden: boolean) => void; indicators_dialog: EmptyCallback; @@ -1219,6 +1229,7 @@ export interface SubscribeEventsMap { study: (params: StudyOrDrawingAddedToChartEventParams) => void; undo: EmptyCallback; redo: EmptyCallback; + undoRedoStackChanged: (state: UndoRedoState) => void; reset_scales: EmptyCallback; compare_add: EmptyCallback; add_compare: EmptyCallback; @@ -1233,9 +1244,112 @@ export interface SubscribeEventsMap { layout_changed: EmptyCallback; activeChartChanged: (chartIndex: number) => void; } -export interface SaveChartToServerOptions { - chartName?: string; - defaultChartName?: string; +export interface SuccessFormatterParseResult extends FormatterParseResult { + res: true; + suggest?: string; +} +export interface SuggestedQuantity { + changed: IDelegate<(symbol: string) => void>; + value(symbol: string): Promise; + setValue(symbol: string, value: number): void; +} +export interface SymbolExt { + symbol: string; + full_name: string; + exchange: string; + description: string; + type: string; +} +export interface SymbolIntervalResult { + symbol: string; + interval: ResolutionString; +} +export interface TableElementFormatter { + name: string; + format: TableElementFormatFunction; +} +export interface TableFormatterInputs { + value: number | string | Side | OrderType | OrderStatus; + prevValue?: number | undefined; + row: TableRow; + $container: JQuery; + priceFormatter?: IFormatter; +} +export interface TableRow { + priceFormatter?: IFormatter; + [name: string]: any; +} +export interface TextWithCheckboxFieldCustomInfo { + checkboxTitle: string; + asterix?: boolean; +} +export interface TextWithCheckboxFieldMetaInfo extends CustomInputFieldMetaInfo { + value: TextWithCheckboxValue; + customInfo: TextWithCheckboxFieldCustomInfo; + validator?: TextInputFieldValidator; +} +export interface TextWithCheckboxValue { + text: string; + checked: boolean; +} +export interface TimeFieldDescriptor { + type: 'time'; +} +export interface TimeFrameItem { + text: string; + resolution: ResolutionString; + description?: string; + title?: string; +} +export interface TimePoint { + time: number; +} +export interface TimescaleMark { + id: string | number; + time: number; + color: MarkConstColors | string; + label: string; + tooltip: string[]; +} +export interface Trade extends CustomFields { + id: string; + date: number; + symbol: string; + brokerSymbol?: string; + qty: number; + side: Side; + price: number; +} +export interface TradingQuotes { + trade?: number; + size?: number; + bid?: number; + bid_size?: number; + ask?: number; + ask_size?: number; + spread?: number; +} +export interface TradingTerminalWidgetOptions extends ChartingLibraryWidgetOptions { + brokerConfig?: SingleBrokerMetaInfo; + restConfig?: RestBrokerMetaInfo; + widgetbar?: WidgetBarParams; + rss_news_feed?: RssNewsFeedParams; + news_provider?: NewsProvider; + brokerFactory?(host: IBrokerConnectionAdapterHost): IBrokerWithoutRealtime | IBrokerTerminal; +} +export interface UndoRedoState { + enableUndo: boolean; + undoText: string | undefined; + enableRedo: boolean; + redoText: string | undefined; +} +export interface VisiblePriceRange { + from: number; + to: number; +} +export interface VisibleTimeRange { + from: number; + to: number; } export interface WatchListApi { defaultList(): string[]; @@ -1254,81 +1368,28 @@ export interface WatchListApi { onListRemoved(): ISubscription; onListRenamed(): ISubscription; } -export interface GrayedObject { - type: 'drawing' | 'study'; - name: string; -} -export interface ContextMenuItem { - position: 'top' | 'bottom'; - text: string; - click: EmptyCallback; -} -export interface DialogParams { - title: string; - body: string; - callback: CallbackType; -} -export interface SymbolIntervalResult { - symbol: string; - interval: ResolutionString; -} -export interface SaveLoadChartRecord { +export interface WatchListSymbolList extends WatchListSymbolListData { id: string; - name: string; - image_url: string; - modified_iso: number; - short_symbol: string; - interval: ResolutionString; } -export interface CreateButtonOptions { - align: 'right' | 'left'; +export interface WatchListSymbolListData { + symbols: string[]; + title: string; } -export interface IChartingLibraryWidget { - onChartReady(callback: EmptyCallback): void; - onGrayedObjectClicked(callback: (obj: GrayedObject) => void): void; - onShortcut(shortCut: string, callback: EmptyCallback): void; - subscribe(event: EventName, callback: SubscribeEventsMap[EventName]): void; - unsubscribe(event: EventName, callback: SubscribeEventsMap[EventName]): void; - chart(index?: number): IChartWidgetApi; - setLanguage(lang: LanguageCode): void; - setSymbol(symbol: string, interval: ResolutionString, callback: EmptyCallback): void; - remove(): void; - closePopupsAndDialogs(): void; - selectLineTool(linetool: SupportedLineTools): void; - selectedLineTool(): SupportedLineTools; - save(callback: (state: object) => void): void; - load(state: object): void; - getSavedCharts(callback: (chartRecords: SaveLoadChartRecord[]) => void): void; - loadChartFromServer(chartRecord: SaveLoadChartRecord): void; - saveChartToServer(onComplete?: EmptyCallback, onFail?: EmptyCallback, saveAsSnapshot?: false, options?: SaveChartToServerOptions): void; - removeChartFromServer(chartId: string, onCompleteCallback: EmptyCallback): void; - onContextMenu(callback: (unixTime: number, price: number) => ContextMenuItem[]): void; - createButton(options?: CreateButtonOptions): JQuery; - showNoticeDialog(params: DialogParams<() => void>): void; - showConfirmDialog(params: DialogParams<(confirmed: boolean) => void>): void; - showLoadChartDialog(): void; - showSaveAsChartDialog(): void; - symbolInterval(): SymbolIntervalResult; - mainSeriesPriceFormatter(): IFormatter; - getIntervals(): string[]; - getStudiesList(): string[]; - addCustomCSSFile(url: string): void; - applyOverrides(overrides: TOverrides): void; - applyStudiesOverrides(overrides: object): void; - watchList(): WatchListApi; - activeChart(): IChartWidgetApi; - chartsCount(): number; - layout(): LayoutType; - setLayout(layout: LayoutType): void; - changeTheme(themeName: ThemeName): void; - takeScreenshot(): void; - lockAllDrawingTools(): IWatchedValue; +export interface WatchListSymbolListMap { + [listId: string]: WatchListSymbolList; } -export interface ChartingLibraryWidgetConstructor { - new (options: ChartingLibraryWidgetOptions | TradingTerminalWidgetOptions): IChartingLibraryWidget; +export interface WatchedValueSubscribeOptions { + once?: boolean; + callWithLast?: boolean; +} +export interface WidgetBarParams { + details?: boolean; + watchlist?: boolean; + news?: boolean; + watchlist_settings?: { + default_symbols: string[]; + readonly?: boolean; + }; } -export declare function version(): string; -export declare function onready(callback: () => void): void; -export declare const widget: ChartingLibraryWidgetConstructor; export as namespace TradingView; diff --git a/charting_library/charting_library.min.js b/charting_library/charting_library.min.js index 9b381537..a40eb2a2 100644 --- a/charting_library/charting_library.min.js +++ b/charting_library/charting_library.min.js @@ -1 +1 @@ -!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e(t.TradingView=t.TradingView||{})}(this,function(t){"use strict";function e(t,o){var i=n({},t);for(var s in o)"object"!=typeof t[s]||null===t[s]||Array.isArray(t[s])?void 0!==o[s]&&(i[s]=o[s]):i[s]=e(t[s],o[s]);return i}function o(){return"1.13 (internal id b235e44c @ 2019-03-20 03:56:17.207031)"}function i(t){window.addEventListener("DOMContentLoaded",t,!1)}var n=Object.assign||function(t){for(var e,o=arguments,i=1,n=arguments.length;i'},t}(),d=a;window.TradingView=window.TradingView||{},window.TradingView.version=o,t.version=o,t.onready=i,t.widget=d,Object.defineProperty(t,"__esModule",{value:!0})}); +!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e(t.TradingView={})}(this,function(t){"use strict";var e=Object.assign||function(t){for(var e,o=arguments,i=1,n=arguments.length;i'},t}();window.TradingView=window.TradingView||{},window.TradingView.version=s,t.version=s,t.widget=r,Object.defineProperty(t,"__esModule",{value:!0})}); diff --git a/charting_library/datafeed-api.d.ts b/charting_library/datafeed-api.d.ts index 072cc76f..1abd4bcb 100644 --- a/charting_library/datafeed-api.d.ts +++ b/charting_library/datafeed-api.d.ts @@ -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 = (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, resolution: ResolutionString): void; + getTimescaleMarks?(symbolInfo: LibrarySymbolInfo, from: number, to: number, onDataCallback: GetMarksCallback, 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 = (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, resolution: ResolutionString): void; - getTimescaleMarks?(symbolInfo: LibrarySymbolInfo, from: number, to: number, onDataCallback: GetMarksCallback, 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; diff --git a/charting_library/static/ar-tv-chart.aaac22e21df68f2f7bad.html b/charting_library/static/ar-tv-chart.aaac22e21df68f2f7bad.html new file mode 100644 index 00000000..4d02eb1c --- /dev/null +++ b/charting_library/static/ar-tv-chart.aaac22e21df68f2f7bad.html @@ -0,0 +1 @@ +
\ No newline at end of file diff --git a/charting_library/static/ar-tv-chart.b235e44cb167872e5a6e.html b/charting_library/static/ar-tv-chart.b235e44cb167872e5a6e.html deleted file mode 100644 index a6764b13..00000000 --- a/charting_library/static/ar-tv-chart.b235e44cb167872e5a6e.html +++ /dev/null @@ -1 +0,0 @@ -
\ No newline at end of file diff --git a/charting_library/static/bundles/10.0b4b80ce7284d28083f7.js b/charting_library/static/bundles/10.0b4b80ce7284d28083f7.js deleted file mode 100644 index 3e3ad3b4..00000000 --- a/charting_library/static/bundles/10.0b4b80ce7284d28083f7.js +++ /dev/null @@ -1 +0,0 @@ -webpackJsonp([10],{1194:function(t,e,i){"use strict";function r(){return n.enabled("saveload_requires_authentication")&&!window.is_authenticated?Promise.resolve([]):new Promise(function(t){c.getCharts(function(e){t(e)})})}var n,o,a,c,s,u,h,l;Object.defineProperty(e,"__esModule",{value:!0}),n=i(5),o=i(1321),a=i(398),c=i(92),s=i(399),u=i(93),h=i(24),l=function(){function t(t){var e=this;this._favoriteChartsService=new o.FavoriteChartsService(u.TVXWindowEvents,h),this._dialog=new a,this._getChartEntry=function(t){return{id:t.id,url:t.url,title:t.name,symbol:t.short_symbol,interval:t.interval,toolsCount:0,modified:t.modified_iso,active:function(){return e._isActiveChart(t.id)},openAction:function(){return c.loadChart(t)},deleteAction:function(i,r){s.deleteChart(r,t.image_url,function(){e._deleteChart(t.id),i.resolve()},i.reject.bind(i))},favoriteAction:e._updateFavorites}},this._updateFavorites=function(t){return e._favoriteChartsService.set(t)},this._isActiveChart=function(t){return t===e._chartWidgetCollection.metaInfo.id.value()},this._deleteChart=function(t){e._isActiveChart(t)&&(n.enabled("saveload_storage_customization")?e._chartWidgetCollection.clearChartMetaInfo():location.href="/chart/")},this._chartWidgetCollection=t}return t.prototype.showLoadDialog=function(){var t=this;r().then(function(e){return e.map(t._getChartEntry)}).then(function(e){t._dialog.show(e,t._favoriteChartsService.get())})},t}(),e.LoadChartService=l},1321:function(t,e,i){"use strict";var r,n,o;Object.defineProperty(e,"__esModule",{value:!0}),r=i(0),n=i(174),o=function(t){function e(e,i){return t.call(this,e,i,"FAVORITE_CHARTS_CHANGED","loadChartDialog.favorites",{})||this}return r.__extends(e,t),e}(n.CommonJsonStoreService),e.FavoriteChartsService=o}}); \ No newline at end of file diff --git a/charting_library/static/bundles/13.87c51bb601702992e1dd.js b/charting_library/static/bundles/13.87c51bb601702992e1dd.js deleted file mode 100644 index 56d4e9fa..00000000 --- a/charting_library/static/bundles/13.87c51bb601702992e1dd.js +++ /dev/null @@ -1,2 +0,0 @@ -webpackJsonp([13],{1195:function(t,e,n){"use strict";function r(t,e,n,r){return l.__awaiter(this,void 0,void 0,function(){var a;return l.__generator(this,function(o){return a=new s.SaveRenameDialog({fields:[new h.InputField({name:w,label:t+":",error:e,maxLength:64})],title:n}),void 0!==r&&a.setField(w,r),[2,a.show().then(function(t){return t[w]})]})})}function a(t){return l.__awaiter(this,void 0,void 0,function(){return l.__generator(this,function(e){return[2,r(f.labelRename,f.error,f.titleRename,t)]})})}function o(t){return l.__awaiter(this,void 0,void 0,function(){return l.__generator(this,function(e){return[2,r(f.labelRename,f.error,f.titleCopy,f.valueCopy.format(t))]})})}function i(t){return l.__awaiter(this,void 0,void 0,function(){return l.__generator(this,function(e){return[2,r(f.labelRename,f.error,f.titleNew,t)]})})}function u(t){"/chart/"===location.pathname&&(location.href="/chart/"+t)}function c(){return l.__awaiter(this,void 0,void 0,function(){return l.__generator(this,function(t){return[2,new Promise(function(t){v.enabled("saved_charts_count_restriction")&&!window.user.is_pro?_.getCharts(function(e){t(e.length<5)}):t(!0)})]})})}var l,s,h,_,v,d,f,w,m;Object.defineProperty(e,"__esModule",{value:!0}),l=n(0),s=n(397),h=n(396),_=n(92),v=n(5),d=n(40),f={labelName:window.t("Chart layout name"),labelRename:window.t("Enter a new chart layout name"),error:window.t("Please enter chart layout name"),titleNew:window.t("Save New Chart Layout"),titleRename:window.t("Rename Chart Layout"),titleCopy:window.t("Copy Chart Layout"),valueCopy:window.t("{0} copy",{context:"ex: AAPL chart copy"})},w="chart-title",m=function(){function t(t,e){this._chartWidgetCollection=t,this._chartSaver=e}return t.prototype.tryCloneChart=function(){var t=this;!function(){l.__awaiter(t,void 0,void 0,function(){var t,e,n;return l.__generator(this,function(r){switch(r.label){case 0:return t=this._chartWidgetCollection,[4,c()];case 1:return e=r.sent(),e?[4,o(t.metaInfo.name.value())]:[3,3];case 2:return n=r.sent(),this._saveCurrentChartAsNewWithTitle(n),[3,3];case 3:return[2]}})})}()},t.prototype.tryRenameChart=function(){var t=this;!function(){l.__awaiter(t,void 0,void 0,function(){var t,e,n;return l.__generator(this,function(r){switch(r.label){case 0:return t=this._chartWidgetCollection,e=t.metaInfo.name.value(),[4,a(e)];case 1:return n=r.sent(),t.metaInfo.name.setValue(n),this._doSave(),[2]}})})}()},t.prototype.trySaveNewChart=function(){var t=this;!function(){l.__awaiter(t,void 0,void 0,function(){var t,e,n,r;return l.__generator(this,function(a){switch(a.label){case 0:return t=this._chartWidgetCollection,e=t.metaInfo.name.value(),[4,c()];case 1:return n=a.sent(),n?[4,i(e)]:[3,3];case 2:return r=a.sent(),t.metaInfo.name.setValue(r),this._doSave(),[3,3];case 3:return[2]}})})}()},t.prototype.trySaveExistentChart=function(){this._doSave()},t.prototype._saveCurrentChartAsNewWithTitle=function(t){var e=this._chartWidgetCollection;v.enabled("saveload_storage_customization")?(e.metaInfo.uid.deleteValue(),e.metaInfo.id.deleteValue(), -e.metaInfo.name.setValue(t),this._doSave()):window.open("/chart/?clone="+e.metaInfo.uid.value()+"&name="+encodeURIComponent(t),"_blank")},t.prototype._doSave=function(){var t=this._chartWidgetCollection;this._chartSaver.saveChartSilently(function(){d.trackEvent("GUI","Save Chart Layout"),u(t.metaInfo.uid.value())})},t}(),e.SaveAsService=m}}); \ No newline at end of file diff --git a/charting_library/static/bundles/15.909301c18dc6575a8a10.js b/charting_library/static/bundles/15.909301c18dc6575a8a10.js deleted file mode 100644 index 44d970cd..00000000 --- a/charting_library/static/bundles/15.909301c18dc6575a8a10.js +++ /dev/null @@ -1,4 +0,0 @@ -webpackJsonp([15],{1249:function(t,e,n){var o,i,r;!function(a,c){i=[t,n(1314),n(1316),n(1317)],o=c,void 0!==(r="function"==typeof o?o.apply(e,i):o)&&(t.exports=r)}(0,function(t,e,n,o){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function a(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function c(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function u(t,e){var n="data-clipboard-"+t;if(e.hasAttribute(n))return e.getAttribute(n)}var l=i(e),s=i(n),f=i(o),h="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},d=function(){function t(t,e){var n,o;for(n=0;n0&&void 0!==arguments[0]?arguments[0]:{};this.action="function"==typeof t.action?t.action:this.defaultAction,this.target="function"==typeof t.target?t.target:this.defaultTarget,this.text="function"==typeof t.text?t.text:this.defaultText,this.container="object"===h(t.container)?t.container:document.body}},{key:"listenClick",value:function(t){var e=this;this.listener=(0,f.default)(t,"click",function(t){return e.onClick(t)})}},{key:"onClick",value:function(t){var e=t.delegateTarget||t.currentTarget;this.clipboardAction&&(this.clipboardAction=null),this.clipboardAction=new l.default({action:this.action(e),target:this.target(e),text:this.text(e),container:this.container,trigger:e,emitter:this})}},{key:"defaultAction",value:function(t){return u("action",t)}},{key:"defaultTarget",value:function(t){var e=u("target",t);if(e)return document.querySelector(e)}},{key:"defaultText",value:function(t){return u("text",t)}},{key:"destroy",value:function(){this.listener.destroy(),this.clipboardAction&&(this.clipboardAction.destroy(),this.clipboardAction=null)}}],[{key:"isSupported",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:["copy","cut"],e="string"==typeof t?[t]:t,n=!!document.queryCommandSupported;return e.forEach(function(t){n=n&&!!document.queryCommandSupported(t)}),n}}]),e}(s.default);t.exports=p})},1314:function(t,e,n){var o,i,r;!function(a,c){i=[t,n(1315)],o=c, -void 0!==(r="function"==typeof o?o.apply(e,i):o)&&(t.exports=r)}(0,function(t,e){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var i=n(e),r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},a=function(){function t(t,e){var n,o;for(n=0;n0&&void 0!==arguments[0]?arguments[0]:{};this.action=t.action,this.container=t.container,this.emitter=t.emitter,this.target=t.target,this.text=t.text,this.trigger=t.trigger,this.selectedText=""}},{key:"initSelection",value:function(){this.text?this.selectFake():this.target&&this.selectTarget()}},{key:"selectFake",value:function(){var t,e=this,n="rtl"==document.documentElement.getAttribute("dir");this.removeFake(),this.fakeHandlerCallback=function(){return e.removeFake()},this.fakeHandler=this.container.addEventListener("click",this.fakeHandlerCallback)||!0,this.fakeElem=document.createElement("textarea"),this.fakeElem.style.fontSize="12pt",this.fakeElem.style.border="0",this.fakeElem.style.padding="0",this.fakeElem.style.margin="0",this.fakeElem.style.position="absolute",this.fakeElem.style[n?"right":"left"]="-9999px",t=window.pageYOffset||document.documentElement.scrollTop,this.fakeElem.style.top=t+"px",this.fakeElem.setAttribute("readonly",""),this.fakeElem.value=this.text,this.container.appendChild(this.fakeElem),this.selectedText=(0,i.default)(this.fakeElem),this.copyText()}},{key:"removeFake",value:function(){this.fakeHandler&&(this.container.removeEventListener("click",this.fakeHandlerCallback),this.fakeHandler=null,this.fakeHandlerCallback=null),this.fakeElem&&(this.container.removeChild(this.fakeElem),this.fakeElem=null)}},{key:"selectTarget",value:function(){this.selectedText=(0,i.default)(this.target),this.copyText()}},{key:"copyText",value:function(){var t=void 0;try{t=document.execCommand(this.action)}catch(e){t=!1}this.handleResult(t)}},{key:"handleResult",value:function(t){this.emitter.emit(t?"success":"error",{action:this.action,text:this.selectedText,trigger:this.trigger,clearSelection:this.clearSelection.bind(this)})}},{key:"clearSelection",value:function(){this.trigger&&this.trigger.focus(),window.getSelection().removeAllRanges()}},{key:"destroy",value:function(){this.removeFake()}},{key:"action",set:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"copy";if(this._action=t,"copy"!==this._action&&"cut"!==this._action)throw Error('Invalid "action" value, use either "copy" or "cut"')},get:function(){return this._action}},{key:"target", -set:function(t){if(void 0!==t){if(!t||"object"!==(void 0===t?"undefined":r(t))||1!==t.nodeType)throw Error('Invalid "target" value, use a valid Element');if("copy"===this.action&&t.hasAttribute("disabled"))throw Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if("cut"===this.action&&(t.hasAttribute("readonly")||t.hasAttribute("disabled")))throw Error('Invalid "target" attribute. You can\'t cut text from elements with "readonly" or "disabled" attributes');this._target=t}},get:function(){return this._target}}]),t}();t.exports=c})},1315:function(t,e){function n(t){var e,n,o,i;return"SELECT"===t.nodeName?(t.focus(),e=t.value):"INPUT"===t.nodeName||"TEXTAREA"===t.nodeName?(n=t.hasAttribute("readonly"),n||t.setAttribute("readonly",""),t.select(),t.setSelectionRange(0,t.value.length),n||t.removeAttribute("readonly"),e=t.value):(t.hasAttribute("contenteditable")&&t.focus(),o=window.getSelection(),i=document.createRange(),i.selectNodeContents(t),o.removeAllRanges(),o.addRange(i),e=""+o),e}t.exports=n},1316:function(t,e){function n(){}n.prototype={on:function(t,e,n){var o=this.e||(this.e={});return(o[t]||(o[t]=[])).push({fn:e,ctx:n}),this},once:function(t,e,n){function o(){i.off(t,o),e.apply(n,arguments)}var i=this;return o._=e,this.on(t,o,n)},emit:function(t){var e=[].slice.call(arguments,1),n=((this.e||(this.e={}))[t]||[]).slice(),o=0,i=n.length;for(o;o0&&void 0!==arguments[0]?arguments[0]:{};this.action=t.action,this.container=t.container,this.emitter=t.emitter,this.target=t.target,this.text=t.text,this.trigger=t.trigger,this.selectedText=""}},{key:"initSelection",value:function(){this.text?this.selectFake():this.target&&this.selectTarget()}},{key:"selectFake",value:function(){var t,e=this,n="rtl"==document.documentElement.getAttribute("dir");this.removeFake(),this.fakeHandlerCallback=function(){return e.removeFake()},this.fakeHandler=this.container.addEventListener("click",this.fakeHandlerCallback)||!0,this.fakeElem=document.createElement("textarea"),this.fakeElem.style.fontSize="12pt",this.fakeElem.style.border="0",this.fakeElem.style.padding="0",this.fakeElem.style.margin="0",this.fakeElem.style.position="absolute",this.fakeElem.style[n?"right":"left"]="-9999px",t=window.pageYOffset||document.documentElement.scrollTop,this.fakeElem.style.top=t+"px",this.fakeElem.setAttribute("readonly",""),this.fakeElem.value=this.text,this.container.appendChild(this.fakeElem),this.selectedText=(0,i.default)(this.fakeElem),this.copyText()}},{key:"removeFake",value:function(){this.fakeHandler&&(this.container.removeEventListener("click",this.fakeHandlerCallback),this.fakeHandler=null,this.fakeHandlerCallback=null),this.fakeElem&&(this.container.removeChild(this.fakeElem),this.fakeElem=null)}},{key:"selectTarget",value:function(){this.selectedText=(0,i.default)(this.target),this.copyText()}},{key:"copyText",value:function(){var t=void 0;try{t=document.execCommand(this.action)}catch(e){t=!1}this.handleResult(t)}},{key:"handleResult",value:function(t){this.emitter.emit(t?"success":"error",{action:this.action,text:this.selectedText,trigger:this.trigger,clearSelection:this.clearSelection.bind(this)})}},{key:"clearSelection",value:function(){this.trigger&&this.trigger.focus(),window.getSelection().removeAllRanges()}},{key:"destroy",value:function(){this.removeFake()}},{key:"action",set:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"copy";if(this._action=t, +"copy"!==this._action&&"cut"!==this._action)throw Error('Invalid "action" value, use either "copy" or "cut"')},get:function(){return this._action}},{key:"target",set:function(t){if(void 0!==t){if(!t||"object"!==(void 0===t?"undefined":r(t))||1!==t.nodeType)throw Error('Invalid "target" value, use a valid Element');if("copy"===this.action&&t.hasAttribute("disabled"))throw Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if("cut"===this.action&&(t.hasAttribute("readonly")||t.hasAttribute("disabled")))throw Error('Invalid "target" attribute. You can\'t cut text from elements with "readonly" or "disabled" attributes');this._target=t}},get:function(){return this._target}}]),t}();t.exports=c})},1210:function(t,e){function n(t){var e,n,o,i;return"SELECT"===t.nodeName?(t.focus(),e=t.value):"INPUT"===t.nodeName||"TEXTAREA"===t.nodeName?(n=t.hasAttribute("readonly"),n||t.setAttribute("readonly",""),t.select(),t.setSelectionRange(0,t.value.length),n||t.removeAttribute("readonly"),e=t.value):(t.hasAttribute("contenteditable")&&t.focus(),o=window.getSelection(),i=document.createRange(),i.selectNodeContents(t),o.removeAllRanges(),o.addRange(i),e=""+o),e}t.exports=n},1211:function(t,e){function n(){}n.prototype={on:function(t,e,n){var o=this.e||(this.e={});return(o[t]||(o[t]=[])).push({fn:e,ctx:n}),this},once:function(t,e,n){function o(){i.off(t,o),e.apply(n,arguments)}var i=this;return o._=e,this.on(t,o,n)},emit:function(t){var e=[].slice.call(arguments,1),n=((this.e||(this.e={}))[t]||[]).slice(),o=0,i=n.length;for(o;o0&&void 0!==arguments[0]?arguments[0]:{};this.action="function"==typeof t.action?t.action:this.defaultAction,this.target="function"==typeof t.target?t.target:this.defaultTarget,this.text="function"==typeof t.text?t.text:this.defaultText,this.container="object"===h(t.container)?t.container:document.body}},{key:"listenClick",value:function(t){var e=this;this.listener=(0,f.default)(t,"click",function(t){return e.onClick(t)})}},{key:"onClick",value:function(t){var e=t.delegateTarget||t.currentTarget;this.clipboardAction&&(this.clipboardAction=null), +this.clipboardAction=new l.default({action:this.action(e),target:this.target(e),text:this.text(e),container:this.container,trigger:e,emitter:this})}},{key:"defaultAction",value:function(t){return u("action",t)}},{key:"defaultTarget",value:function(t){var e=u("target",t);if(e)return document.querySelector(e)}},{key:"defaultText",value:function(t){return u("text",t)}},{key:"destroy",value:function(){this.listener.destroy(),this.clipboardAction&&(this.clipboardAction.destroy(),this.clipboardAction=null)}}],[{key:"isSupported",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:["copy","cut"],e="string"==typeof t?[t]:t,n=!!document.queryCommandSupported;return e.forEach(function(t){n=n&&!!document.queryCommandSupported(t)}),n}}]),e}(s.default);t.exports=p})}}); \ No newline at end of file diff --git a/charting_library/static/bundles/9.0f95ea8c401ed7b42af8.js b/charting_library/static/bundles/9.0f95ea8c401ed7b42af8.js deleted file mode 100644 index be8faa45..00000000 --- a/charting_library/static/bundles/9.0f95ea8c401ed7b42af8.js +++ /dev/null @@ -1,2 +0,0 @@ -webpackJsonp([9],{1082:function(t,o){t.exports='{\n\t"content": {\n\t\t"chartProperties": {\n\t\t\t"scalesProperties": {\n\t\t\t\t"textColor": "#D9D9D9",\n\t\t\t\t"lineColor": "#787878",\n\t\t\t\t"backgroundColor": "#ffffff"\n\t\t\t},\n\t\t\t"paneProperties": {\n\t\t\t\t"gridProperties": {\n\t\t\t\t\t"color": "#363c4e"\n\t\t\t\t},\n\t\t\t\t"background": "#131722"\n\t\t\t}\n\t\t},\n\t\t"mainSourceProperties": {\n\t\t\t"candleStyle": {\n\t\t\t\t"borderColor": "#378658",\n\t\t\t\t"upColor": "#53b987",\n\t\t\t\t"wickColor": "#B5B5B8",\n\t\t\t\t"wickUpColor": "#336854",\n\t\t\t\t"wickDownColor": "#7f323f",\n\t\t\t\t"downColor": "#eb4d5c",\n\t\t\t\t"borderUpColor": "#53b987",\n\t\t\t\t"borderDownColor": "#eb4d5c"\n\t\t\t},\n\t\t\t"haStyle": {\n\t\t\t\t"borderColor": "#378658",\n\t\t\t\t"upColor": "#53b987",\n\t\t\t\t"wickColor": "#B5B5B8",\n\t\t\t\t"wickUpColor": "#53b987",\n\t\t\t\t"wickDownColor": "#eb4d5c",\n\t\t\t\t"downColor": "#eb4d5c",\n\t\t\t\t"borderUpColor": "#53b987",\n\t\t\t\t"borderDownColor": "#eb4d5c"\n\t\t\t},\n\t\t\t"barStyle": {\n\t\t\t\t"downColor": "#eb4d5c",\n\t\t\t\t"upColor": "#53b987"\n\t\t\t},\n\t\t\t"pnfStyle": {\n\t\t\t\t"downColor": "#eb4d5c",\n\t\t\t\t"upColor": "#53b987",\n\t\t\t\t"upColorProjection": "#336854",\n\t\t\t\t"downColorProjection": "#7f323f"\n\t\t\t},\n\t\t\t"areaStyle": {\n\t\t\t\t"transparency": 50,\n\t\t\t\t"color1": "#606090",\n\t\t\t\t"color2": "#01F6F5",\n\t\t\t\t"linecolor": "#0094FF",\n\t\t\t\t"linewidth": 1,\n\t\t\t\t"linestyle": 0\n\t\t\t},\n\t\t\t"renkoStyle": {\n\t\t\t\t"upColor": "#53b987",\n\t\t\t\t"downColor": "#eb4d5c",\n\t\t\t\t"borderUpColor": "#53b987",\n\t\t\t\t"borderDownColor": "#eb4d5c",\n\t\t\t\t"upColorProjection": "#336854",\n\t\t\t\t"downColorProjection": "#7f323f",\n\t\t\t\t"borderUpColorProjection": "#336854",\n\t\t\t\t"borderDownColorProjection": "#7f323f",\n\t\t\t\t"wickUpColor": "#336854",\n\t\t\t\t"wickDownColor": "#7f323f"\n\t\t\t},\n\t\t\t"lineStyle": {\n\t\t\t\t"color": "#6FB8F7",\n\t\t\t\t"linewidth": 1,\n\t\t\t\t"linestyle": 0\n\t\t\t},\n\t\t\t"kagiStyle": {\n\t\t\t\t"downColor": "#eb4d5c",\n\t\t\t\t"upColor": "#53b987",\n\t\t\t\t"upColorProjection": "#336854",\n\t\t\t\t"downColorProjection": "#7f323f"\n\t\t\t},\n\t\t\t"pbStyle": {\n\t\t\t\t"upColor": "#53b987",\n\t\t\t\t"downColor": "#eb4d5c",\n\t\t\t\t"borderUpColor": "#53b987",\n\t\t\t\t"borderDownColor": "#eb4d5c",\n\t\t\t\t"upColorProjection": "#336854",\n\t\t\t\t"downColorProjection": "#7f323f",\n\t\t\t\t"borderUpColorProjection": "#336854",\n\t\t\t\t"borderDownColorProjection": "#7f323f"\n\t\t\t}\n\t\t}\n\t}\n}\n'},1083:function(t,o){ -t.exports='{\n\t"content": {\n\t\t"chartProperties": {\n\t\t\t"scalesProperties": {\n\t\t\t\t"textColor": "#555",\n\t\t\t\t"lineColor": "#555",\n\t\t\t\t"backgroundColor": "#ffffff"\n\t\t\t},\n\t\t\t"paneProperties": {\n\t\t\t\t"gridProperties": {\n\t\t\t\t\t"color": "#e1ecf2"\n\t\t\t\t},\n\t\t\t\t"background": "#ffffff"\n\t\t\t}\n\t\t},\n\t\t"mainSourceProperties": {\n\t\t\t"candleStyle": {\n\t\t\t\t"borderColor": "#378658",\n\t\t\t\t"upColor": "#53b987",\n\t\t\t\t"wickColor": "#737375",\n\t\t\t\t"wickUpColor": "#a9dcc3",\n\t\t\t\t"wickDownColor": "#f5a6ae",\n\t\t\t\t"downColor": "#eb4d5c",\n\t\t\t\t"borderUpColor": "#53b987",\n\t\t\t\t"borderDownColor": "#eb4d5c"\n\t\t\t},\n\t\t\t"haStyle": {\n\t\t\t\t"borderColor": "#378658",\n\t\t\t\t"upColor": "#53b987",\n\t\t\t\t"wickColor": "#737375",\n\t\t\t\t"wickUpColor": "#53b987",\n\t\t\t\t"wickDownColor": "#eb4d5c",\n\t\t\t\t"downColor": "#eb4d5c",\n\t\t\t\t"borderUpColor": "#53b987",\n\t\t\t\t"borderDownColor": "#eb4d5c"\n\t\t\t},\n\t\t\t"barStyle": {\n\t\t\t\t"downColor": "#eb4d5c",\n\t\t\t\t"upColor": "#53b987"\n\t\t\t},\n\t\t\t"pnfStyle": {\n\t\t\t\t"downColor": "#eb4d5c",\n\t\t\t\t"upColor": "#53b987",\n\t\t\t\t"upColorProjection": "#a9dcc3",\n\t\t\t\t"downColorProjection": "#f5a6ae"\n\t\t\t},\n\t\t\t"areaStyle": {\n\t\t\t\t"transparency": 50,\n\t\t\t\t"color1": "#606090",\n\t\t\t\t"color2": "#01F6F5",\n\t\t\t\t"linecolor": "#0094FF",\n\t\t\t\t"linewidth": 1,\n\t\t\t\t"linestyle": 0\n\t\t\t},\n\t\t\t"renkoStyle": {\n\t\t\t\t"upColor": "#53b987",\n\t\t\t\t"downColor": "#eb4d5c",\n\t\t\t\t"borderUpColor": "#53b987",\n\t\t\t\t"borderDownColor": "#eb4d5c",\n\t\t\t\t"upColorProjection": "#a9dcc3",\n\t\t\t\t"downColorProjection": "#f5a6ae",\n\t\t\t\t"borderUpColorProjection": "#a9dcc3",\n\t\t\t\t"borderDownColorProjection": "#f5a6ae",\n\t\t\t\t"wickUpColor": "#a9dcc3",\n\t\t\t\t"wickDownColor": "#f5a6ae"\n\t\t\t},\n\t\t\t"lineStyle": {\n\t\t\t\t"color": "#0303F7",\n\t\t\t\t"linewidth": 1,\n\t\t\t\t"linestyle": 0\n\t\t\t},\n\t\t\t"kagiStyle": {\n\t\t\t\t"downColor": "#eb4d5c",\n\t\t\t\t"upColor": "#53b987",\n\t\t\t\t"upColorProjection": "#a9dcc3",\n\t\t\t\t"downColorProjection": "#f5a6ae"\n\t\t\t},\n\t\t\t"pbStyle": {\n\t\t\t\t"upColor": "#53b987",\n\t\t\t\t"downColor": "#eb4d5c",\n\t\t\t\t"borderUpColor": "#53b987",\n\t\t\t\t"borderDownColor": "#eb4d5c",\n\t\t\t\t"upColorProjection": "#a9dcc3",\n\t\t\t\t"downColorProjection": "#f5a6ae",\n\t\t\t\t"borderUpColorProjection": "#a9dcc3",\n\t\t\t\t"borderDownColorProjection": "#f5a6ae"\n\t\t\t}\n\t\t}\n\t}\n}\n'}}); \ No newline at end of file diff --git a/charting_library/static/bundles/add-compare-dialog.99e6e22e5d6b137269e9.js b/charting_library/static/bundles/add-compare-dialog.99e6e22e5d6b137269e9.js new file mode 100644 index 00000000..2d762f03 --- /dev/null +++ b/charting_library/static/bundles/add-compare-dialog.99e6e22e5d6b137269e9.js @@ -0,0 +1,21 @@ +webpackJsonp([14,2],{1013:function(t,e,o){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function s(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function r(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}var a,l;Object.defineProperty(e,"__esModule",{value:!0}),e.AddSymbolCheckbox=void 0,a=o(308),l=i(a),e.AddSymbolCheckbox=function(t){function e(t){n(this,e),t.checked=TVSettings.getBool("showAddSymbolDialog.checkboxState",!0);var o=s(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return o.$checkbox.change(function(){setTimeout(function(){TVSettings.setValue("showAddSymbolDialog.checkboxState",o.checked)})}),o}return r(e,t),e}(l.default)},1024:function(t,e,o){"use strict";(function(t){function i(e){var o,i,c,d,h,u,p,f,_,g,b;if(e=$.extend({},l,e),o=$(t.render(r,{tabs:e.tabs,customControls:e.customControls,customControlsAddClass:e.customControlsContainerAddClass},{additionalHeaderContent:e.additionalHeaderContent})),i=$(a),c=i,e.contentAddClass&&i.addClass(e.contentAddClass),!1!==e.withScroll&&(i=$('
').append(c.addClass("tv-dialog__scroll-wrap-inner"))),d=$('
').append(o).append(i),e.customControls&&o.find(".js-custom-controls").append(e.customControls),!0!==e.doNotCreatePages)for(h=0;h').append(e.tabs[h].page));return u=e.tabStateSaveKey,p=e.activeTab,f=e.tabsScrollBoxAddClass,_=e.tabAddClass,delete e.tabs,delete e.activeTab,delete e.customControls,delete e.tabStateSaveKey,delete e.customControlsContainerAddClass,delete e.tabsScrollBoxAddClass,delete e.tabAddClass,e.closeButtonAddClass="tv-tabbed-dialog__close",e.contentWrapTemplate=d,g=(0,s.createDialog)(e),b=new n.Tabs(o.find(".tv-tabs").get(0),c.get(0),{addLeftArrowsClass:"tv-tabbed-dialog__tabs-arrow-left",addRightArrowsClass:"tv-tabbed-dialog__tabs-arrow-right",addScrollBoxClass:f,tabClass:_,saveTab:u,activeTab:p}),g.on("afterOpen",function(){b.setActivePage(b.index(),!0,!0)}),{dialog:g,tabs:b}}var n,s,r,a,l;Object.defineProperty(e,"__esModule",{value:!0}),e.createTabbedDialog=i,n=o(1025),s=o(188),o(1027), +r='
{{#tabs}}
{{name}}
{{/tabs}}
{{#customControls}}
{{/customControls}}
{{>additionalHeaderContent}}',a='
',l={tabs:[]}}).call(e,o(126))},1025:function(t,e,o){"use strict";function i(t){var e,o=[];for(e=1;e'+b.leftArrow+"
"),this._elArrowRight=this._findOrCreateElement(this._options.rArrowClass||"",this._elTabs,"append",'
'+b.rightArrow+"
"),this._options.noSlider||(this._elSlider=this._findOrCreateElement(this._options.sliderClass||"",this._elScrollBox,"append")),this._addClass(this._elArrowLeft,this._options.addLeftArrowsClass),this._addClass(this._elArrowRight,this._options.addRightArrowsClass),this._addClass(this._elScrollBox,this._options.addScrollBoxClass), +this._addClass(this._elSlider,this._options.addSliderClass),this._addClass(this._elTabs,this._options.tabsContainerClass),this._addClass(this.getTabsArray(),this._options.tabClass),this._addClass(this._elTabs,this._options.loadedClass),this.checkScrollArrows(!0),this._initActivePage(),this._bindEvents()}return t.prototype.getTabsArray=function(){var t,e,o,i=this._elScrollBox.children;if(!this._options.sliderClass)return Array.prototype.slice.call(i);for(t=[],e=0;e=s?e(this._elArrowLeft):(i<=s||this._elScrollWrap.scrollWidth<=n)&&o(this._elArrowLeft,_.Left),a-i>1?e(this._elArrowRight):(i>=a||this._elScrollWrap.scrollWidth<=n)&&o(this._elArrowRight,_.Right)},t.prototype.index=function(){var t=this.getElActiveTab();return t?this.getTabsArray().indexOf(t):-1},t.prototype.getElActiveTab=function(){return this._getActiveElement(this.getTabsArray(),this._options.activeTabClass||"",this._options.inactiveTabClass)},t.prototype.getElActivePage=function(){return this._getActiveElement(this.getPagesArray(),this._options.activePageClass||"",this._options.inactivePageClass)},t.prototype.setActivePage=function(t,e,o){function i(e,o,i){e.forEach(function(e,n){var s=t===n,r=e.classList;o&&r.toggle(o,s),i&&r.toggle(i,!s)})}if(-1!==t&&(t!==this.index()||o)){var n=this.index();i(this.getTabsArray(),this._options.activeTabClass,this._options.inactiveTabClass),i(this.getPagesArray(),this._options.activePageClass,this._options.inactivePageClass),this._options.noSlider||this.updateSlider(n,t,e),this._options.saveTab&&p.setValue(this._options.saveTab,t),this.tabChanged.fire(t)}},t.prototype.updateSlider=function(t,e,o){var i,n,s,a,c,d,h=this;this._options.noSlider||(i=this.getTabsArray()[e],0===i.clientWidth||0===i.clientHeight||"none"===window.getComputedStyle(i).getPropertyValue("display")||(n=window.getComputedStyle(i),s=i.offsetLeft+parseInt(n.getPropertyValue("padding-left")),a=this._getElWidth(i),c=i.querySelector(".js-tabs__slider-pos"),c&&(d=window.getComputedStyle(c),s+=parseInt(d.getPropertyValue("padding-left"))+c.offsetLeft,a-=a-this._getElWidth(c)), +o=o||-1===t||document.all&&!window.atob,o?(this._elSlider.style.left=s+"px",this._elSlider.style.width=a+"px"):(this._animating=!0,Object(r.lazyVelocity)().then(function(){$.Velocity.animate(h._elSlider,{left:s},{duration:l.dur,easing:"easeOutCubic",queue:!1}),$.Velocity.animate(h._elSlider,{width:a},{complete:function(){h._animating=!1},duration:l.dur,easing:"easeOutCubic",queue:!1})}))))},t.prototype.onTabClick=function(t){var e=t.currentTarget||t.target,o=this.getTabsArray().indexOf(e);-1===o||this._isTabDisabled(e)||this.setActivePage(o),document.activeElement.blur(),t.preventDefault()},t.prototype.resizeSlider=function(){var t,e;this._options.noSlider||(t=this._elTabs.offsetWidth)!==this._prevWidth&&(this._prevWidth=t,e=this.index(),this.updateSlider(e,e,!0))},t.prototype.count=function(){return this.getTabsArray().length},t.prototype.add=function(t,e){this._elScrollBox.appendChild(t),this._elPages&&e&&this._elPages.appendChild(e),this._bindTabEvents(t),this.checkScrollArrows(!0)},t.prototype.remove=function(t){function e(t){t.parentElement&&t.parentElement.removeChild(t)}var o,i,n=this.tabAt(t);n&&(this._unbindTabEvents(n),e(n)),o=this.pageAt(t),o&&e(o),i=t-1>=0?t-1:0,this.setActivePage(i),this.checkScrollArrows(!0)},t.prototype.indexOfTab=function(t){return this.getTabsArray().indexOf(t)},t.prototype.indexOfPage=function(t){return this.getPagesArray().indexOf(t)},t.prototype.pageAt=function(t){return this.getPagesArray()[t]||null},t.prototype.tabAt=function(t){return this.getTabsArray()[t]||null},t.prototype.deselect=function(t){var e,o=this.getElActiveTab();return this._options.activeTabClass&&o&&o.classList.remove(this._options.activeTabClass),e=this.getElActivePage(),this._options.activePageClass&&e&&e.classList.remove(this._options.activePageClass),this._elSlider&&(this._elSlider.style.left="",this._elSlider.style.width=""),this},t.prototype.stop=function(){this._unbindEvents({})},t.prototype._getElWidth=function(t){if(0===t.offsetWidth)return 0;var e=window.getComputedStyle(t);return t.offsetWidth-parseFloat(e.getPropertyValue("padding-left"))-parseFloat(e.getPropertyValue("padding-right"))-parseFloat(e.getPropertyValue("border-left-width"))-parseFloat(e.getPropertyValue("border-right-width"))},t.prototype._findOrCreateElement=function(t,e,o,i){var n,s,r,a=e.querySelector("."+t);if(!a)if(n=document.createElement("div"),n.innerHTML=i||'
',a=n.firstElementChild,"append"===o)e.appendChild(a);else{if("wrapInner"!==o)throw Error("Unknown insertMethod");for(s=Array.prototype.slice.call(e.childNodes),r=0;rs?n=!0:i=e}}),Object(r.lazyVelocity)().then(function(){$.Velocity.animate(e._elScrollWrap,"scroll",{axis:"x",container:$(e._elScrollWrap),duration:l.dur/2,easing:"easeInOutCubic",offset:Math.floor(i-s-e._getElWidth(e._elArrowLeft)),queue:!1})})},target:this._elArrowLeft}),this._bindOneEvent({eventName:"click",listener:function(t){var o=e.getTabsArray(),i=0,n=f.IS_RTL?0:e._elScrollWrap.scrollLeft+e._getElWidth(e._elScrollWrap);f.IS_RTL&&o.reverse(),o.forEach(function(t){if(0===i){var e=t.offsetLeft+t.offsetWidth;e>n&&(i=e)}}),Object(r.lazyVelocity)().then(function(){$.Velocity.animate(e._elScrollWrap,"scroll",{axis:"x",container:$(e._elScrollWrap),duration:l.dur/2,easing:"easeInOutCubic",offset:Math.ceil(i-n+e._getElWidth(e._elArrowRight)),queue:!1})})},target:this._elArrowRight}),t=Array.prototype.slice.call(this._elTabs.querySelectorAll(".js-tabs__slider-hover")||[]),t.length&&t.forEach(function(t){return e._bindOneEvent({eventName:"mouseenter",listener:function(t){if(!e._animating){var o=t.currentTarget;o&&e._options.activeTabClass&&o.classList&&o.classList.contains(e._options.activeTabClass)&&e._hoverSlider(o)}},target:t})}),this._bindOneEvent({eventName:"resize",listener:function(){e.checkScrollArrows(!0),e._options.noSlider||e.resizeSlider()},target:window})},t.prototype._bindTabEvents=function(t){var e=this;this._bindOneEvent({eventName:"click",listener:function(t){"function"==typeof e._options.onTabClick?e._options.onTabClick(t):e.onTabClick(t)},target:t})},t.prototype._unbindTabEvents=function(t){this._unbindEvents({target:t})},t.prototype._bindOneEvent=function(t){t.target.addEventListener(t.eventName,t.listener),this._bindings.push(t)},t.prototype._unbindEvents=function(t){var e=function(e){return!(void 0!==e.eventName&&e.eventName!==t.eventName||void 0!==e.target&&e.target!==t.target||void 0!==e.listener&&e.listener!==t.listener)};this._bindings.filter(e).forEach(function(t){return t.target.removeEventListener(t.eventName,t.listener)}),this._bindings=this._bindings.filter(function(t){return!e(t)})},t.prototype._getActiveElement=function(t,e,o){var i=function(t,i,n){return e?t.classList.contains(e):!!o&&!t.classList.contains(o)};return t.filter(i)[0]||null},t.prototype._isTabDisabled=function(t){return t.classList.contains("i-disabled")||this._options.tabDisabledClass&&t.classList.contains(this._options.tabDisabledClass)||t.hasAttribute("disabled")},t.prototype._hoverSlider=function(t){var e,o=this,i=this._getElWidth(t),n=window.getComputedStyle(t),s=t.offsetLeft+parseInt(n.getPropertyValue("padding-left"))+parseInt(n.getPropertyValue("margin-left")),a={duration:l.dur/4, +easing:"easeOutCubic",queue:!1};Object(r.lazyVelocity)().then(function(){$.Velocity.animate(o._elSlider,{left:s},a),$.Velocity.animate(o._elSlider,{width:i},a)}),e=function(){o.getElActiveTab()===t&&o._unhoverSlider(t),t.removeEventListener("mousleave",e)},t.addEventListener("mouseleave",e)},t.prototype._unhoverSlider=function(t){var e=this,o=window.getComputedStyle(t),i=t.querySelector(".js-tabs__slider-pos"),n=window.getComputedStyle(i),s=t.offsetLeft+parseInt(o.getPropertyValue("padding-left"))+parseInt(o.getPropertyValue("margin-left"))+parseInt(n.getPropertyValue("padding-left"))+i.offsetLeft,a=this._getElWidth(t),c=a-(a-this._getElWidth(i)),d={duration:l.dur/2,easing:"easeInSine",queue:!1};Object(r.lazyVelocity)().then(function(){$.Velocity.animate(e._elSlider,{left:s},d),$.Velocity.animate(e._elSlider,{width:c},d)})},t}()},1026:function(t,e){},1027:function(t,e){},1043:function(t,e){},1216:function(t,e,o){"use strict";(function(t,i){function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var s,r,a,l,c,d;Object.defineProperty(e,"__esModule",{value:!0}),e.CompareTab=void 0,s=function(){function t(t,e){var o,i;for(o=0;o\n\t\t\n\t
',c='
',d='\n\t
\n\t\t\n\t
',e.CompareTab=function(){function e(t,o){n(this,e),this._chartWidgetCollection=t,this._dialog=o,this._$popup=null,this._predefines={},this._symbolAlias={},this.init()}return s(e,[{key:"addCompareSymbol",value:function(t,e,o){var i,n,s,r,l,c,d=this._chartWidgetCollection.activeChartWidget.value();if(d&&(i=d.model())){for(n=i.mainSeries().interval(),s=i.studiesMetaData(),r=void 0,l=0;l\n\t\t\n\t\t
\n\t',e.AddSymbolTab=function(){function t(e,o){i(this,t),this._chartWidgetCollection=e,this._dialog=o,this._$popup=null,this.init()}return n(t,[{key:"init",value:function(){var t=this;this.$tab=$(a),this._$input=this.$tab.find(".js-add-symbol-tab-input"),this._checkbox=new r.AddSymbolCheckbox({labelRight:$.t("Overlay the main chart"),labelAddClass:"tv-add-symbol-tab__checkbox-label",boxAddClass:"tv-add-symbol-tab__checkbox-box"}), +this.$tab.find(".js-add-symbol-tab-checkbox").append(this._checkbox.$el),(0,s.bindToInput)(this._$input,{callback:function(e){var o=t._chartWidgetCollection.activeChartWidget.value();o&&o.addSymbol(e,t._checkbox.checked)},onPopupOpen:function(e){e.css("z-index",t._dialog.getZIndex()),t._$popup=e},onPopupClose:function(){t._$popup=null},keepFocus:!0,clearAfterAccept:!0})}},{key:"focus",value:function(){Modernizr.touch||this._$input.focus()}},{key:"isClickOnTab",value:function(t){return!!this._$popup&&!(this._$popup[0]!==t.target&&!this._$popup[0].contains(t.target))}}]),t}()},1219:function(t,e){},1220:function(t,e){},188:function(t,e,o){"use strict";function i(t){var e=t.type||"popup";return delete t.type,"modal"===e?new n.TVModal(t):new s.TVPopup(t)}var n,s;Object.defineProperty(e,"__esModule",{value:!0}),n=o(837),s=o(843),e.createDialog=i},690:function(t,e,o){"use strict";var i;Object.defineProperty(e,"__esModule",{value:!0}),i=o(839),o.n(i),o.o(i,"TVDialogAbstract")&&o.d(e,"TVDialogAbstract",function(){return i.TVDialogAbstract}),o.o(i,"closeAllDialogs")&&o.d(e,"closeAllDialogs",function(){return i.closeAllDialogs})},820:function(t,e,o){"use strict";function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var n,s,r,a,l;Object.defineProperty(e,"__esModule",{value:!0}),e.AddCompareDialog=void 0,n=function(){function t(t,e){var o,i;for(o=0;ot.height()},breakpoints:l.breakpoints,widgetbarBreakpoint:1064,setFixedBodyState:function(t){var e,o;t&&1==++h?("hidden"!==$(document.body).css("overflow").toLowerCase()&&document.body.scrollHeight>document.body.offsetHeight&&($(".widgetbar-wrap").css("right",u.getScrollbarWidth()),c.css("padding-right",parseInt(c.css("padding-right").replace("px",""))+u.getScrollbarWidth()+"px").data("wasScroll",!0)),c.addClass("i-no-scroll")):!t&&h>0&&0==--h&&(c.removeClass("i-no-scroll"),c.data("wasScroll")&&(e=c.get(0),$(".widgetbar-wrap").css("right",0),o=$(".widgetbar-wrap").width()||0,e.scrollHeight<=e.clientHeight&&(o-=u.getScrollbarWidth()),c.css("padding-right",(o<0?0:o)+"px").data("wasScroll",void 0)))}},p=Object.keys(u.breakpoints).sort(function(t,e){return u.breakpoints[t]-u.breakpoints[e]}),i.extend(u,a.default.prototype),s(),$(s),d.on("resize",s),e.default=u,t.exports=e.default}).call(e,o(187))},833:function(t,e,o){"use strict";(function(t){function i(e,o,i){var n,s,r,a,l,c,d=this;if(this._options=$.extend({},this._defaultOptions,i||{}),this._$wrapper=e, +this._$content=o,this._scroll_speed=40,this._shadow_offset=10,this._header_height=this._options.headerHeight,this._scroll_margin_top=this._options.scrollMarginTop,this.scrolled=new t,this.scrolltoend=new t,this.scrolltostart=new t,this.visibilityCallbacks=[],n=navigator.platform.toLowerCase(),s=navigator.userAgent.toLowerCase(),r=s.indexOf("firefox")>-1,a=n.indexOf("android")>-1||s.indexOf("android")>-1,this._touch=Modernizr.touch||navigator.msMaxTouchPoints||r&&a,this._touch)return this._$content.css("position","relative"),void this._$wrapper.css({"overflow-y":"auto","-webkit-overflow-scrolling":"touch","-ms-overflow-style":"-ms-autohiding-scrollbar"}).scroll(this._onScroll.bind(this));this._$wrapper.css("overflow","hidden"),this._$wrapper.on("mouseenter.sidebar-scroll",function(){d._bottomFixed||d._dragging||(d._options.alwaysVisible||d._$scrollBar.addClass("active"),d._onScroll())}).on("mouseleave.sidebar-scroll",function(){d._bottomFixed||d._dragging||(d._options.alwaysVisible||d._$scrollBar.removeClass("active"),d._onScroll())}).on("mousewheel.sidebar-scroll",function(t,e){if(!t.isDefaultPrevented())return d.scroll(e,"MozMousePixelScroll"===t.originalEvent.type?2:null)}),!1!==this._options.showTopShadow&&(this._$shadowTop=$('
').appendTo(this._$wrapper)),!1!==this._options.showBottomShadow&&(this._$shadowBottom=$('
').appendTo(this._$wrapper)),this._$shadowTop&&this._header_height&&this._$shadowTop.css("top",this._header_height-this._shadow_offset),l=this._options.additionalClass?" "+this._options.additionalClass:"",c=this._options.alwaysVisible?" active-always":"",this._$scrollBarWrapper=$('
').appendTo(this._$wrapper),this._$scrollBar=$('
').appendTo(this._$scrollBarWrapper),this._onScroll()}var n=o(827).lazyJqueryUI;i.prototype.isTouch=function(){return this._touch},i.prototype.getScrollBar=function(){return this._$scrollBar},i.prototype._defaultOptions={headerHeight:0,additionalClass:"",alwaysVisible:!1,showBottomShadow:!0,scrollMarginTop:1,bubbleScrollEvent:!1},i.prototype.initDraggable=function(){if(this._dragInitialized)return this;var t=this;return n(this._$scrollBar).draggable({axis:"y",containment:this._$scrollBarWrapper,start:function(){t._dragging=!0},stop:function(){t._dragging=!1},drag:function(e,o){t.updateScroll()}}),this._dragInitialized=!0,this},i.prototype.updateScroll=function(){var t,e,o,i,n;return this._touch?this:(t=1,e=Math.ceil(this._$scrollBar.position().top-this._scroll_margin_top-this._header_height),o=this.getContainerHeightWithoutHeader(),i=this._$content.outerHeight(),n=i-o-t,o<=0?this:(this._scroll_target_top=n<=0?this._header_height:Math.min(-e*i/o+this._header_height,this._header_height),e+this._$scrollBar.height()+2>=o?this.scrollToEnd():(this._$content.css("top",this._scroll_target_top+"px"),this._onScroll()),this))},i.prototype.getContainerHeightWithoutHeader=function(){ +return this._$wrapper[0].getBoundingClientRect().height-this._header_height},i.prototype.getContainerHeight=function(){return this._$wrapper[0].getBoundingClientRect().height},i.prototype.getContentHeight=function(){return this._$content[0].getBoundingClientRect().height},i.prototype.updateScrollBar=function(){var t,e,o,i,n,s,r,a,l;return this._touch?this:(t=1,e=this._$content.position().top,o=this.getContentHeight(),i=this.getContainerHeight(),n=this.getContainerHeightWithoutHeader(),s=t+this._header_height,r=n-2*t,a=(Math.abs(e)-this._header_height)*r/o,l=i*i/o,this.isContentShort()?(this._$scrollBar.addClass("js-hidden"),this._$wrapper.removeClass("sb-scroll-active")):(this._$scrollBar.removeClass("js-hidden").height(l).css("top",s+a),this._$wrapper.addClass("sb-scroll-active"),this.initDraggable()),this)},i.prototype.scroll=function(t,e){var o,i,n,s,r;return this._touch?this:(o=this._$content.position().top,i=this._$content.outerHeight(),n=this.getContainerHeightWithoutHeader(),s=i-n-1,r=e||this._scroll_speed,s<=0||(this._scroll_target_top=Math.max(-s+this._header_height,Math.min(this._header_height,o+t*r)),this.setContentTop(this._scroll_target_top),this._onScroll()))},i.prototype.animateTo=function(t){var e,o,i;return this._touch?this:(e=this._$content.outerHeight(),o=this.getContainerHeightWithoutHeader(),(i=e-o-1)<=0||(this._scroll_target_top=Math.max(-i+this._header_height,Math.min(this._header_height,-t)),void this._$content.animate({top:this._scroll_target_top},500,function(){this._onScroll()}.bind(this))))},i.prototype.resize=function(){var t,e;if(!this._bottomFixed){if(t=this._$content.outerHeight(),e=this._$wrapper.outerHeight(),!this._options.vAlignBottom&&ts&&t+e.areaHeightr?r-t-e.areaHeight:s-t}else"top"===e.position&&(a=s-t);return this.scroll(a,1),this._onScroll(),!1},i.prototype.scrollToEnd=function(){var t=this._$content.position().top,e=this._$content.outerHeight(),o=this._$wrapper.outerHeight(),i=e+t;return this.setContentTop(t+(o-i)+1),this._onScroll(),this},i.prototype.scrollToStart=function(){return this.setContentTop(this._header_height),this._onScroll(),this},i.prototype.currentPosition=function(){return Math.round(this._$content.position().top)}, +i.prototype.atStart=function(){return Math.round(this._$content.position().top)>=this._header_height},i.prototype.atEnd=function(t){var e,o,i,n;return"number"==typeof t&&isFinite(t)||(t=0),e=1,o=Math.round(this._$content.position().top),i=this._$content.outerHeight(),n=this._$wrapper.outerHeight(),i-Math.abs(o)-e<=n+t},i.prototype._onScroll=function(t){var e,o;return this._touch||this._$content.css("bottom","auto"),this.scrolled.fire(),this._dragging&&!0!==t||this.updateScrollBar(),e=this.atStart(),o=this.atEnd(),this._$shadowTop&&this._$shadowTop.toggleClass("i-invisible",!!e),this._$shadowBottom&&this._$shadowBottom.toggleClass("i-invisible",!!o),this._onContentVisible(),!this._atStart&&e?(this._atStart=!0,this.scrolltostart.fire()):this._atStart&&!e&&delete this._atStart,!this._atEnd&&o?(this._atEnd=!0,this.scrolltoend.fire()):this._atEnd&&!o&&delete this._atEnd,this._options.vAlignBottom&&(this._stickyBottom=this._$content.outerHeight()-Math.abs(this._$content.position().top)-this._$wrapper.outerHeight()),!(!this._atStart&&!this._atEnd||("function"==typeof this._options.bubbleScrollEvent?!this._options.bubbleScrollEvent():!this._options.bubbleScrollEvent))},i.prototype.checkContentVisibility=function(){this._onContentVisible()},i.prototype.subscribeToContentVisible=function(t,e,o){this.visibilityCallbacks.push({id:t,$el:e,callback:o})},i.prototype.triggerVisibilityCallbacks=function(t){this._onContentVisible(t)},i.prototype._contentIsVisible=function(t){return t.$el.position().top>-1*this.currentPosition()},i.prototype._onContentVisible=function(t){var e,o,i;this.visibilityCallbacks.length&&(e=t||this._contentIsVisible.bind(this),o=[],i=this.visibilityCallbacks.filter(function(t,i){if(!$.contains(this._$content,t.$el[0]))return!1;var n=e(t);return n&&o.push(i),!n},this),o.forEach(function(e){this.visibilityCallbacks[e].callback(!!t)},this),delete this.visibilityCallbacks,this.visibilityCallbacks=i)},i.prototype.save=function(){return this._saved={top:this._$content.position().top,height:this._$content.outerHeight()},this},i.prototype.restore=function(){if(this._saved){if(this._saved.top===this._$content.position().top&&this._saved.height===this._$content.outerHeight())return delete this._saved,this;this._options.vAlignBottom&&(this._saved.top-=this._$content.outerHeight()-this._saved.height,this._saved.top>this._header_height&&(this._saved.top=this._header_height)),this.setContentTop(this._saved.top),delete this._saved,this._onScroll(!0)}return this},i.prototype.fixBottom=function(){var t,e;return this._bottomFixed?this:(this._touch?(t=this._$content.outerHeight(),e=this._$wrapper.scrollTop(),this._tempIntervalID=setInterval(function(){this._$wrapper.scrollTop(e+(this._$content.outerHeight()-t))}.bind(this),0)):this._$content.css({top:"auto",bottom:this._$wrapper.outerHeight()-this._$content.position().top-this._$content.outerHeight()}),this._bottomFixed=!0,this)},i.prototype.releaseBottom=function(){return this._bottomFixed?(this._touch?clearInterval(this._tempIntervalID):this._$content.css({ +top:this._$content.position().top,bottom:"auto"}),delete this._bottomFixed,this._onScroll(),this):this},i.prototype.setContentTop=function(t){return this._touch?this._options.vAlignBottom&&this._$content.outerHeight()
',containerTemplate:'
',ajaxErrorTemplate:'
'+$.t("Error")+"
"},e.TVModal=function(e){function o(){var t,e,i,n,a=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return s(this,o),t=r(this,(o.__proto__||Object.getPrototypeOf(o)).call(this,c({},w,a))),t.$overlay=$(t.options.overlayTemplate),t.$modalWrap=$(t.options.containerTemplate), +t.$body=t.$modalWrap.find(".tv-dialog__modal-body").append(t.$el),t.options.closeOnOutsideClick&&t.$overlay.add(t.$modalWrap).click(function(e){t.isEventOut(e)&&t.close()}),t.on("change:zIndex",function(){t.$overlay.css("z-index",t.zIndex),t.$modalWrap.css("z-index",t.zIndex)}),t.on("destroy",function(){var e=function(){t.$overlay.remove(),t.$modalWrap.remove()};t.opened?(t.close(),setTimeout(e,t.options.closingDuration)):e()}),t.on("beforeOpen",function(){C.push(t)}),t.options.ajax.url&&(e=t.options.ajax.beforeSend||$.noop,i=t.options.ajax.success||!1,n=t.options.ajax.error||$.noop,$.extend(t.options.ajax,{beforeSend:function(){t.trigger("beforeLoading",[t]),t.startSpinner(),e(t)},success:function(e){t.trigger("afterLoading",[t]),t.renderContent(i?i(t,e):e).showContent(),t.trigger("afterLoadingShow",[t])},error:function(){t.renderContent(t.options.ajaxErrorTemplate),n(t),t.trigger("errorLoading",[t])}})),t.on("error",function(e,o){t.$modalWrap[0].getBoundingClientRect().height0&&C[C.length-1].focus(),e.options.destroyOnClose&&e.destroy()},this.options.closingDuration),this}},{key:"showContent",value:function(){var t=this;return this.$modalWrap.removeClass("i-hidden"),setTimeout(function(){t.$modalWrap.removeClass("i-closed")},20),setTimeout(function(){t.trigger("afterOpen",[t]),t.spinner&&t.stopSpinner()},.75*u.dur+20),this}},{key:"hideContent",value:function(){if(this.$el)return this.$modalWrap.addClass("i-closed"),this.unfocus(),this}},{key:"startSpinner",value:function(){return this.spinner=new g.Spinner("large"),this.spinner.spin(this.$overlay[0]),this}},{key:"stopSpinner",value:function(){if(this.spinner)return this.spinner.stop(),delete this.spinner,this} +}]),o}(_.TVDialogAbstract)}).call(e,o(187))},838:function(t,e,o){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),o.d(e,"breakpoints",function(){return i});var i={desktop:1/0,desktopHd:1919,phone:767,"phone-vertical":479,tablet:1019}},839:function(t,e,o){"use strict";(function(t,i){function n(t){return t&&t.__esModule?t:{default:t}}function s(t){var e,o;if(t&&t.__esModule)return t;if(e={},null!=t)for(o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e.default=t,e}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function a(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function c(){y.forEach(function(t){return t.close()})}var d,h,u,p,f,_,g,b,v,y,m,C,w,k,T,S,x;Object.defineProperty(e,"__esModule",{value:!0}),e.TVDialogAbstract=void 0,d=Object.assign||function(t){var e,o,i;for(e=1;e',errorTemplate:'
{{{ error }}}
',titleTemplate:'
{{{ title }}}
',contentWrapTemplate:'
',actionsWrapTemplate:'
',closeButtonTemplate:'
'+o(828)+"
",helpButtonTemplate:'',helpActionsMod:"tv-dialog__section--actions_with-help"},T={default:"tv-button tv-button--default",primary:"tv-button tv-button--primary",success:"tv-button tv-button--success",danger:"tv-button tv-button--danger",warning:"tv-button tv-button--warning",link:"tv-button tv-button--link",checkbox:"tv-control-checkbox tv-control-checkbox--in-actions","default-ghost":"tv-button tv-button--default_ghost", +"primary-ghost":"tv-button tv-button--primary_ghost","success-ghost":"tv-button tv-button--success_ghost","danger-ghost":"tv-button tv-button--danger_ghost","warning-ghost":"tv-button tv-button--warning_ghost"},S={_default:'
{{ text }}
',"submit-success":''},$(function(){k.$wrap=$(document.all&&!document.querySelector?"html":"body")}),x=function(e){function o(){var e,i,n,s,l,c=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};for(r(this,o),e=a(this,(o.__proto__||Object.getPrototypeOf(o)).call(this)),e._id=v++,e.loadingActions=[],e.disabledActions=[],e.firstFocusControl=null,e.options=d({},k,c),e.$el=$(t.render(e.options.template,{title:e.options.title,closeButton:e.options.closeButton})),e.$el.addClass("js-dialog"),e.el=e.$el[0],e.options.addClass&&e.$el.addClass(e.options.addClass),e.options.width&&e.$el.css({width:"100%","max-width":e.options.width}),e.options.title&&(e.$title=$(t.render(e.options.titleTemplate,{title:e.options.title})).appendTo(e.$el)),e.$content=$(e.options.contentWrapTemplate).appendTo(e.$el),e.$contentIn=e.$content;e.$contentIn.length;)e.$contentIn=e.$contentIn.children();if(e.$contentIn=e.$contentIn.end(),e.options.content&&e.renderContent(e.options.content),(e.options.actions||e.options.help)&&(e.$content.hasClass("tv-dialog__section")&&e.$content.addClass("tv-dialog__section--no-padding_bottom"),e.$actions=$(e.options.actionsWrapTemplate).appendTo(e.$el)),e.options.actions)for(e.actions={},e.$el.on("click touchend",".js-dialog__action-click",function(t){t.preventDefault(),e.actionDispatcher($(t.currentTarget).data("name"))}),i=function(o){var i,n,s,r,a,l,c=e.options.actions[o];c.type||(c.type="default"),c.class||(c.class=T[c.type]?T[c.type]:T.default),"checkbox"===c.type?(i=new _.default({labelRight:c.text,name:c.name,checked:c.checked}),e.actions[c.name]=i.$el.appendTo(e.$actions),e.actions[c.name].on("change",function(){setTimeout(function(){return e.actionDispatcher(c.name,i.checked)})})):e.actions[c.name]=$(t.render(c.template?c.template:S[c.type]||S._default,c,c)).appendTo(e.$actions),c.method&&"function"==typeof e[c.method]&&e.on("action:"+c.name,e[c.method].bind(e)),c.addClass&&e.actions[c.name].addClass(c.addClass),c.key&&(n=void 0,"string"==typeof c.key&&c.key.split("+").length>1?(s=[],r=c.key.split("+"),n=function(t){s=[]},a=function(t){var o=""+t.keyCode;-1!==r.indexOf(o)&&s.indexOf(o)&&s.push(o),e._focused&&s.length===r.length&&(s=[],e.actionDispatcher(c.name))},e.on("afterOpen",function(){w.on("keydown",a),w.on("keyup",n)}),e.on("beforeClose",function(){w.off("keydown",a),w.off("keyup",n)})):(l=$.isArray(c.key)?c.key:[c.key],n=function(t){!t.isDefaultPrevented()&&e._focused&&-1!==l.indexOf(t.keyCode)&&e.actionDispatcher(c.name)},e.on("afterOpen",function(){return w.on("keyup",n)}),e.on("beforeClose",function(){return w.off("keyup",n)})))},n=e.options.actions.length-1;n>=0;n--)i(n) +;return e.options.help&&$(t.render(e.options.helpButtonTemplate,e.options.help)).prependTo(e.$actions.addClass(e.options.helpActionsMod)),e.options.closeButton&&(s=$(e.options.closeButtonTemplate),s.addClass(e.options.closeButtonAddClass||""),l=e.$el,1===e.$el.find(".js-close-button-place").length&&(l=e.$el.find(".js-close-button-place")),s.appendTo(l)),e.setZIndex(C+y.length),c.errorMod&&(e.errorMod=c.errorMod),e.on("afterOpen",function(){e.options.focusFirstControl&&!Modernizr.touch&&(e.firstFocusControl||e.$el.find('input:not([type="hidden"]), textarea').first()).focus()}),e.$el.on("click touchend",".js-dialog__close",e.close.bind(e)),e.$el.on("mousedown touchstart",e.focus.bind(e)),y.push(e),e}return l(o,e),h(o,[{key:"renderContent",value:function(t){return this.$contentIn.html("function"==typeof t?t(this):t),this}},{key:"setDestroyOnClose",value:function(t){this.options.destroyOnClose=t}},{key:"setZIndex",value:function(t){return this.zIndex=t,this.trigger("change:zIndex",[this]),this}},{key:"toTop",value:function(){for(var t=y.length-1;t>=0;t--)y[t].zIndex>this.zIndex&&y[t].setZIndex(y[t].zIndex-1);return this.setZIndex(C+y.length),this}},{key:"isEventOut",value:function(t){var e,o,i;return this.options.isClickOutFn&&void 0!==(e=this.options.isClickOutFn(t))?e:(o=!0,i=$(t.target),i.get(0)!==this.$el.get(0)&&($(">*",this.$el).each(function(){i.get(0)===$(this).get(0)&&(o=!1),0===i.closest("HTML",$(this).get(0)).length&&(o=!1)}),o))}},{key:"focus",value:function(){var t=this;m&&m!==this&&m.unfocus(),this._setFocused(),this._focused=!0,this.$el.addClass(this.options.focusClass),this.trigger("focus",[this]),setTimeout(function(){w.on("mousedown.tv-dialog-unfocus-"+t._id,function(e){t.isEventOut(e)&&(t.unfocus(),w.off("mousedown.tv-dialog-unfocus-"+t._id))})},20)}},{key:"_setFocused",value:function(){m!==this&&(m=this)}},{key:"_setUnfocused",value:function(){m===this&&(m=void 0)}},{key:"unfocus",value:function(){m===this&&(this._setUnfocused(),this._focused=!1,this.$el.removeClass(this.options.focusClass).find(":focus").blur(),this.trigger("unfocus",[this]))}},{key:"isFocused",value:function(){return this._focused}},{key:"setTitle",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return this.$title.toggleClass("tv-dialog__section--one-line apply-overflow-tooltip",e),this.$title.html(t),this}},{key:"setTitleText",value:function(t){this.$title.find(".js-title-text").text(t)}},{key:"actionDispatcher",value:function(t){if(!this.disabledActions.includes(t)&&!this.loadingActions.includes(t)){for(var e=arguments.length,o=Array(e>1?e-1:0),i=1;i1&&void 0!==arguments[1]?arguments[1]:"init" +;return this.actions[t].tvButtonLoader(o),"init"===o&&(this.actions[t].off("tv-button-loader:start.dialog-action").on("tv-button-loader:start.dialog-action",function(){e.loadingActions.push(t)}),this.actions[t].off("tv-button-loader:stop.dialog-action").on("tv-button-loader:stop.dialog-action",function(){e.loadingActions=i.without(e.loadingActions,t)})),this}},{key:"error",value:function(e){var o=$(t.render(this.options.errorTemplate,{error:e,errorMod:this.errorMod})).appendTo(this.$el),i=function(){o.addClass("i-slided"),setTimeout(function(){return o.remove()},.75*p.dur)};return setTimeout(function(){return o.removeClass("i-slided")},20),w.one("touchstart mousedown keydown",i),this.trigger("error",[this,o]),this}},{key:"destroy",value:function(){y=i.without(y,this);for(var t=0;t'+this.$btn.html()+''),this.loading=this.$btn.hasClass("i-loading")}return s(t,[{key:"_start",value:function(){var t=this;this.starting=!0,this.$btn.addClass("i-start-load"),this.$btn.trigger("tv-button-loader:start"),setTimeout(function(){t.loading=!0,t.starting=!1,t._startPromise=!1,t.$btn.addClass("i-loading"),t.$btn.removeClass("i-start-load"),t._stopPromise&&t._stop()},2*l.dur)}},{key:"start",value:function(){this.starting||(this.stopping?this._startPromise=!0:this._start())}},{key:"_stop",value:function(){var t=this;this.stopping=!0,this.$btn.addClass("i-stop-load"),this.$btn.trigger("tv-button-loader:stop"),setTimeout(function(){t.loading=!1,t.stopping=!1,t._stopPromise=!1,t.$btn.removeClass("i-loading i-start-load i-stop-load"),t._startPromise&&t._start()},l.dur)}},{key:"stop", +value:function(){this.stopping||(this.starting?this._stopPromise=!0:this._stop())}},{key:"toggle",value:function(){this.loading?this.stop():this.start()}},{key:"contentHtml",value:function(t){return t?(this.$btn.find(".tv-button__text").html(t),t):this.$btn.find(".tv-button__text").html()}},{key:"contentNojQuery",value:function(){return this.$btn.get(0)}},{key:"disable",value:function(){this.stop(),this.$btn.addClass("i-disabled")}},{key:"enable",value:function(){this.$btn.removeClass("i-disabled")}}]),t}()},841:function(t,e){},842:function(t,e){},843:function(t,e,o){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function n(t){var e,o;if(t&&t.__esModule)return t;if(e={},null!=t)for(o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e.default=t,e}function s(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}var l,c,d,h,u,p,f,_,g,b,v,y,m;Object.defineProperty(e,"__esModule",{value:!0}),e.TVPopup=void 0,l=Object.assign||function(t){var e,o,i;for(e=1;e',scrollWrapInner:'
',withScroll:!0},m="js-dialog__scroll-wrap",e.TVPopup=function(t){function e(){var t,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return s(this,e),t=r(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,l({},y,o))),t.$scrollWrap=t.$content.hasClass(m)?t.$content:t.$content.find("."+m),t.$scrollWrap.length?t.$scrollWrapInner=t.$scrollWrap.children().first():(t.$scrollWrap=t.$content.wrap($(t.options.scrollWrap)).parent(),t.$scrollWrapInner=t.$content.wrap($(t.options.scrollWrapInner)).parent()),t.$actions&&t.$scrollWrap.addClass("i-with-actions"),t.options.withScroll&&(t.scroll=new _.SidebarCustomScroll(t.$scrollWrap,t.$scrollWrapInner),t.scroll.scrolled.subscribe(null,function(){return t.trigger("scroll")})),t.$scrollWrap.css("overflow",""),t.$el.addClass("tv-dialog--popup i-closed i-hidden"),t.options.width&&t.$el.css({width:"calc(100% - 20px)","max-width":t.options.width}),t.$el.on("mousedown touchstart",t.toTop.bind(t)), +t.options.closeOnOutsideClick&&(t.on("beforeOpen",function(){setTimeout(function(){t.opened&&$(document).on("click.tv-popup-"+t.id,function(e){var o=$(e.target).closest(".js-dialog");(t.options.closeOnClickAtOtherDialogs||0===o.length)&&t.isEventOut(e)&&t.close()})},0)}),t.on("beforeClose",function(){return $(document).off("click.tv-popup-"+t.id)})),t.on("change:zIndex",function(){t.$el.css("z-index",t.zIndex)}),t.on("destroy",function(){var e=function(){t.$el.remove()};t.opened?(t.close(),setTimeout(e,h.dur/2)):e()}),t}return a(e,t),c(e,[{key:"open",value:function(){var t=this;return this.opened?this:(this.opened=!0,this.trigger("beforeOpen",[this]),this.$el.appendTo(this.options.$wrap).removeClass("i-hidden").css(function(){var e,o,i,n,s;return t.calcHeight(),e=v.height(),o=v.width(),i=t.$el.height(),n=t.$el.width(),s=t.options.position,s||(s={top:e/2-i/2,left:o/2-n/2}),s.top>e-i&&(s.top=e-i),s.left>o-n&&(s.left=o-n),s}()),this.focus(),this.toTop(),this._doOpenAnimation().then(function(){t.opened&&(t.$el.removeClass("i-closed"),t.options.draggable&&((0,g.lazyJqueryUI)(t.$el).draggable({handle:".js-dialog__drag",cancel:"input, textarea, button, select, option, .js-dialog__no-drag, .js-dialog__close",containment:"window",cursor:"-webkit-grabbing"}),t.$el.find(".js-dialog__drag").addClass("tv-dialog__grab")),t.trigger("afterOpen",[t]))}),v.on("resize.tv-popup-"+this.id,function(){t.calcHeight(),t.fixPos()}),this)}},{key:"close",value:function(){var t=this;if(this.opened)return this.trigger("beforeClose",[this]),this.$el.addClass("i-closed"),this.opened=!1,this._doCloseAnimation().then(function(){t.opened||((0,g.lazyJqueryUI)(t.$el).draggable("instance").then(function(t){t&&t.destroy()}),t.$el.addClass("i-hidden").detach(),b.css("cursor","auto"),t.trigger("afterClose",[t]),t.options.destroyOnClose&&t.destroy())}),v.off("resize.tv-popup-"+this.id),this}},{key:"hide",value:function(){this.$el.addClass("i-hidden")}},{key:"show",value:function(){this.$el.removeClass("i-hidden")}},{key:"fixPos",value:function(){var t=this.$el[0].getBoundingClientRect(),e={};t.bottom>p.default.height-10&&(e.top=p.default.height-10-t.height,e.top<10&&(e.top=10)),t.right>p.default.width-10&&(e.left=p.default.width-10-t.width,e.left<10&&(e.left=10)),(e.top||e.left)&&this.$el.css(e)}},{key:"calcHeight",value:function(){var t,e,o=this.$el[0].getBoundingClientRect(),i=this.$scrollWrapInner[0].getBoundingClientRect(),n=this.$scrollWrap[0].getBoundingClientRect(),s=this.options.height&&this.options.heights)&&(s-=o.height-n.height,s<60&&(s=60),this.$scrollWrap.css({height:s})),this.options.withScroll&&this.scroll.resize(),e=s').html(" "),this._helpTooltipTrigger=$('').text("?").attr("title",$.t("Type the interval number for minute charts (i.e. 5 if it is going to be a five minute chart). Or number plus letter for H (Hourly), D (Daily), W (Weekly), M (Monthly) intervals (i.e. D or 2H)")),this._dialogTitle=$.t("Change Interval")}function a(t){var o=/[\dhdwms]/i,i=/[\dhdwm]/i;return r.enabled("seconds_resolution")?o.test(t):i.test(t)}var n=i(62).linking,s=i(311).parseIntervalValue,l=i(311).intervalIsSupported,d=i(311).sanitizeIntervalValue,r=i(5),c=i(61),u=i(883).TVOldDialogs;e.prototype._setInput=function(){this._input=$(''),this._input.on("keypress",this._handleInput.bind(this)).on("input",function(){this._validate(),this._updateCaption()}.bind(this)).on("blur",function(){setTimeout(this._submit.bind(this),0)}.bind(this))},e.prototype._validate=function(){var t,o=this._input.val();this._parsed=s(o),this._valid=!this._parsed.error,this._supported=!this._parsed.error&&l(o),t=this._parsed.unit,this._supported&&("R"===t&&this._parsed.qty>c.getMaxResolutionValue("R")?this._supported=!1:null!==t&&"H"!==t||this._parsed.qty*("H"===t?60:1)>1440&&(this._supported=!1))},e.prototype._updateCaption=function(){var t,o,i;this._valid&&this._supported?(o=this._parsed.qty||1,i=this._parsed.unit||"",t=c.getTranslatedResolutionModel(o+i).hint,this._input.add(this._caption).removeClass("error")):(t=this._parsed.error?" ":$.t("Not applicable"),this._input.add(this._caption).addClass("error")),this._caption.html(t)},e.prototype._handleInput=function(t){if(13===t.which)return void this._submit();t.ctrlKey||t.metaKey||!t.charCode||!t.which||t.which<=32||a(String.fromCharCode(t.charCode))||t.preventDefault()},e.prototype._submit=function(){var t,o;u.isOpen(this._dialogTitle)&&(this._valid&&this._supported&&(t=d(this._input.val()),o=n.interval.value(),t&&o!==t&&"function"==typeof this._options.callback&&this._options.callback(t)),u.destroy(this._dialogTitle))},e.prototype._setInitialValue=function(t){var o,i;t=t||this._options.initialValue,o="",i=!1,t&&","!==t?o=d(t)||"":(t=n.interval.value(),o=t,i=!0),this._input.val(o),i&&this._input.select()},e.prototype.isValid=function(){return!!this._valid},e.prototype.show=function(t){var o=u.createDialog(this._dialogTitle,{hideCloseCross:!0,addClass:"change-interval-dialog",ownerDocument:this._options.ownerDocument}),i=o.find("._tv-dialog-content");return o.css("min-width",0),i.css("min-width",0).mousedown(function(t){this._input.is(t.target)||t.preventDefault()}.bind(this)).append(this._input.add(this._caption).add(this._helpTooltipTrigger)),u.applyHandlers(o),u.positionDialog(o),this._setInitialValue(t),this._validate(),this._updateCaption(),o},t.exports.ChangeIntervalDialog=e},827:function(t,o,i){"use strict" +;function e(t){return t in $.fn?Promise.resolve():(s||(s=new Promise(function(t){i.e(31).then(function(o){i(831),t()}.bind(null,i)).catch(i.oe)})),s)}function a(t){return new l(t)}var n,s,l;Object.defineProperty(o,"__esModule",{value:!0}),i.d(o,"LazyJqueryUI",function(){return l}),o.lazyJqueryUI=a,n=i(14),i.n(n),l=function(){function t(t){this._$elem=t}return t.prototype.draggable=function(){var t=arguments,o=this._$elem;return e("draggable").then(function(){return o.draggable.apply(o,t)})},t.prototype.resizable=function(){var t=arguments,o=this._$elem;return e("resizable").then(function(){return o.resizable.apply(o,t)})},t.prototype.sortable=function(){var t=arguments,o=this._$elem;return e("sortable").then(function(){return o.sortable.apply(o,t)})},t.prototype.datepicker=function(){var t=arguments,o=this._$elem;return e("datepicker").then(function(){return o.datepicker.apply(o,t)})},t}()},836:function(t,o){t.exports=''},845:function(t,o,i){"use strict";function e(t){var o,i,e=(t+"").match(/(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/);return null===e?0:(o=e[1]?e[1].length:0,i=e[2]?parseInt(e[2],0):0,Math.max(0,o-i))}function a(t){return t=Math.abs(t),!Object(c.isInteger)(t)&&t>1&&(t=parseFloat((""+t).replace(/^.+\./,"0."))),0').appendTo(n.parent()),i=$('
').html(u).appendTo(o),e=$('
').html(u).appendTo(o),o.on("mousedown",function(t){t.preventDefault(),n.focus()}),i.click(function(){n.is(":disabled")||s(n)}),e.click(function(){n.is(":disabled")||l(n)}),n.keydown(function(t){n.is(":disabled")||(38===t.keyCode?i.addClass("i-active"):40===t.keyCode&&e.addClass("i-active"))}),n.keyup(function(t){ +n.is(":disabled")||(38===t.keyCode?(s(n),i.removeClass("i-active")):40===t.keyCode&&(l(n),e.removeClass("i-active")))}),n.mousewheel(function(t,o){o>0?i.click():e.click()}))})}},851:function(t,o){},883:function(t,o,i){"use strict";(function(o,e){var a,n=i(50).max,s=i(827).lazyJqueryUI;i(845),a={modalDialog:null,dialogs:[],NOTIFICATION_ANIMATION_START_OFFSET:"-33px",_constrainDraggableOptionsIfNeeded:function(t){return o.enabled("constraint_dialogs_movement")&&(t.containment=".chart-page"),t},showNotice:function(t,o,i){var n,s,l,d,r,c;return"object"==typeof o&&(i=o,o=""),i=i||{},n=i.doNotCloseOnBgClick||!1,s=i.html||"",l=i.width||"400px",d={},d.noClose=i.noClose||null,d.addClass=i.modalDialogClass||null,a.createModalDialog(t,d),r=i.centerCaption?"caption-big-center":"caption-big",a.modalDialog.find("._tv-dialog").css("width",l),c=i.customButtonCaption?i.customButtonCaption:$.t("OK"),a.modalDialog.find("._tv-dialog-content").html(e.render('
{{text}}'+s+'
{{^removeOkButton}}
{{/removeOkButton}}
',{captionClassName:r,classSuffix:i.classSuffix||"",text:o,removeOkButton:i&&i.removeOkButton})),a.modalDialog.find("._tv-button.ok").on("click",function(){a.destroy(),i.onOkButtonClick&&i.onOkButtonClick()}),a.positionDialog(),a.applyHandlers(!1,{doNotCloseOnBgClickIfShadowbox:n,beforeDestroy:i.onClose}),a.modalDialog},showCustomDialog:function(t){function o(t){a.destroy(),t.preventDefault()}return a.createModalDialog(t.title||$.t("Dialog"),{addClass:""}),a.modalDialog.find("._tv-dialog").css("width",t.width||"400px"),a.modalDialog.find("._tv-dialog-content").html('
'+(t.html||$.t("Content"))+"
"),a.modalDialog.find(".ok").click(o),a.modalDialog.find("form").submit(o),a.modalDialog.find(".cancel").click(o),a.modalDialog.find("._tv-dialog-title-close").click(o),a.positionDialog(),a.applyHandlers(),a.modalDialog},createModalDialog:function(t,o){var i,e;return o=o||{},null!==a.modalDialog&&a.destroy(),a.modalDialog=$('
'+(o.noHeader?"":'
'+(o.noClose?"":'')+''+t+"
")+'
').appendTo($("body")).data("title",t),a._addMessageCloseButton(a.modalDialog.find("._tv-dialog-error")),a._addMessageCloseButton(a.modalDialog.find("._tv-dialog-message")),o.noShadowBox&&a.modalDialog.addClass("transparent"),o.addClass&&a.modalDialog.addClass(o.addClass),o.width&&a.modalDialog.find("._tv-dialog").css({width:o.width}),o.content&&a.modalDialog.find("._tv-dialog-content").html(o.content),i=$(".fancybox-overlay"),i.length&&(e=i.css("z-index"), +$("._tv-dialog-shadowbox").css("z-index",e+1)),o.draggable&&s(a.modalDialog).draggable(a._constrainDraggableOptionsIfNeeded({handle:a.modalDialog.find("._tv-dialog-title")})),o.zIndex&&a.modalDialog.css("z-index",o.zIndex),a.modalDialog},_addMessageCloseButton:function(t){var o=$(i(884)).attr({class:"close",title:$.t("Close message")});t.append(o),$(o).on("click",function(){t.animate({marginTop:a.NOTIFICATION_ANIMATION_START_OFFSET,opacity:0},"fast",function(){t.hide()})})},createDialog:function(t,o){var i,l,d,r;return a.isOpen(t)?(i=a.get(t),i.find("._tv-dialog-content").html(""),i.data("new",!1),i):(o=o||{},l=o.ownerDocument||document,i=$(e.render('
{{^hideTitle}} {{&title}}{{/hideTitle}}{{^hideCloseCross}}{{/hideCloseCross}}
',{addClass:o.addClass||"",hideTitle:o.hideTitle,hideCloseCross:o.hideCloseCross,title:t}),l).appendTo(l.body),a._addMessageCloseButton(i.find("._tv-dialog-error")),a._addMessageCloseButton(i.find("._tv-dialog-message")),o.width&&i.css({width:o.width}),o.content&&i.find("._tv-dialog-content").html(o.content),d=0,d=o.zIndex?o.zIndex:a.dialogs&&a.dialogs.length?n($.map(a.dialogs,function(t){return parseInt((t.dialog||t).css("z-index"),10)}))+1:110,i.css("z-index",d),i.data("new",!0),i.data("title",t),i.data("id",a.dialogs.length+1),a.dialogs.push({title:t,dialog:i,id:a.dialogs.length+1}),r={start:function(t,o){var i,e,n=o.helper.css("z-index"),s=0,l=null;for(i=0;is&&(s=e,l=a.dialogs[i].dialog);o.helper.css("z-index",s),l.css("z-index",n)}},o.dragHandle?r.handle=o.dragHandle:o.hideTitle||(r.handle="._tv-dialog-title"),o.dragOptions&&$.extend(r,o.dragOptions),s(i).draggable(a._constrainDraggableOptionsIfNeeded(r)),i)},positionDialog:function(t,o,i){function e(){n.css("margin-left",-Math.round(n.outerWidth()/2)+"px"),n.css("margin-top",-Math.round(n.outerHeight()/2)+"px")}var n,s,l,d,r,c,u,p,g,h;i=i||{},o=o||i.position,t?(s=t.prop("ownerDocument"),l=s.defaultView,d=t.width(),r=t.height(),c=$(l).width(),u=$(l).height(),o&&o.top&&o.left?(g=i.forcePosition?o.left:Math.max(2,Math.min(c-d-4,o.left))+"px",p=i.forcePosition?o.top:Math.max(2,Math.min(u-r-4,o.top))+"px"):o&&o.considerScroll?(h=$(s),g=Math.round((c-d)/2+h.scrollLeft())+"px",p=Math.round((u-r)/2+h.scrollTop())+"px"):(g=Math.round((c-d)/2)+"px",p=Math.round((u-r)/2)+"px"),i.fadeIn?t.css({left:g,top:p}).hide().fadeIn("fast"):i.smooth?t.animate({left:g,top:p}):t.css({left:g,top:p})):(t=a.modalDialog,n=t.find("._tv-dialog"),e(),n.resize(e))},applyHandlers:function(t,o){var i,e,n,s=!t||t===this.modalDialog;o=o||{},i=s?function(){a.destroy()}:function(){ +a.destroy(t.data("title"))},t=t||a.modalDialog.find("._tv-dialog"),e=t.prop("ownerDocument"),o.beforeDestroy&&t.on("destroy",o.beforeDestroy),t.find("._tv-dialog-title ._tv-dialog-title-close, .js-dialog-close").on("click",function(t){o.closeHandler&&"function"==typeof o.closeHandler?o.closeHandler(t):i()}),o.doNotCloseOnBgClick||setTimeout(function(){$(e).on("mousedown.closeDialog",function(a){var n=$(a.target).parents().andSelf();n.is(t)||o.doNotCloseOnBgClickIfShadowbox&&n.is("._tv-dialog-shadowbox, .tv-dialog__modal-wrap")||n.is(".colorpicker, .charts-popup-list, ._tv-dialog, .tvcolorpicker-popup, .symbol-edit-popup, .ui-datepicker, .clockpicker-popover, .pac-container")||($(e).off("mousedown.closeDialog"),i())})},0),t.find('input[type="checkbox"]').change(function(){var t=$(this);t.next("._tv-dialog-checkbox-mask").toggleClass("disabled",t.prop("disabled")).toggleClass("_tv-dialog-checkbox-mask-active",t.is(":checked"))}),n=t.find('input[type="text"]').focus(function(){$(this).addClass("_tv-dialog-content-textactive")}).blur(function(){$(this).removeClass("_tv-dialog-content-textactive")}).first(),Modernizr.touch||o.notFocusFirst||n.focus(),t.find('input[type="password"]').focus(function(){$(this).addClass("_tv-dialog-content-textactive")}).blur(function(){$(this).removeClass("_tv-dialog-content-textactive")}),t.find("textarea").focus(function(){$(this).addClass("_tv-dialog-content-textareaactive")}).blur(function(){$(this).removeClass("_tv-dialog-content-textareaactive")}),t.find("._tv-dialog-checkbox-mask").click(function(){var t=$(this).prev();t.prop("disabled")||(t.prop("checked",!t[0].checked),t.change())}),o.doNotCloseOnEsc||$(e).bind("keyup.hideDialog",function(o){if(27===o.keyCode)return t?a.destroy(t.data("title")):a.destroy(),!1}),o.processEnterButton&&$(e).bind("keyup.confirmAndCloseDialog",function(t){13===t.keyCode&&"textarea"!==t.target.tagName.toLowerCase()&&(o.processEnterButton.click(),$(e).unbind("keyup.confirmAndCloseDialog"))})},showError:function(t,o,i){a.showMessage(t,o,$.extend(i||{},{isError:!0}))},showMessage:function(t,o,i){var e,n,s;o||(o=$("._tv-dialog")),i=i||{},e=i.isError&&"_tv-dialog-error"||"_tv-dialog-message",n=o.find("."+e),s=n.find(".message"),i.html?s.html("string"==typeof i.html?i.html:t):s.text(t),s.css("width",o.width()).toggleClass("selectable",!!i.selectable),n.toggleClass("with-close",!!i.withClose).css({marginTop:a.NOTIFICATION_ANIMATION_START_OFFSET,opacity:"0"}).show().animate({marginTop:0,opacity:1},"fast"),i.withClose||(i.hideWithoutAnimation?n.on("touchstartoutside mousedownoutside keydownoutside",function t(){n.hide(),n.off("touchstartoutside mousedownoutside keydownoutside",t)}):n.on("touchstartoutside mousedownoutside keydownoutside",function t(){n.animate({marginTop:a.NOTIFICATION_ANIMATION_START_OFFSET,opacity:0},"fast",function(){n.hide()}),n.off("touchstartoutside mousedownoutside keydownoutside",t)}))},isOpen:function(t){for(var o=0;oe&&(a-=t-e,a=Math.max(0,a),o.height(a))}},t.exports.TVOldDialogs=a}).call(o,i(5),i(126))},884:function(t,o){t.exports=''}}); \ No newline at end of file diff --git a/charting_library/static/bundles/chart-bottom-toolbar.1831f202498024e77558.js b/charting_library/static/bundles/chart-bottom-toolbar.1831f202498024e77558.js new file mode 100644 index 00000000..0b13bccd --- /dev/null +++ b/charting_library/static/bundles/chart-bottom-toolbar.1831f202498024e77558.js @@ -0,0 +1,17 @@ +webpackJsonp([12],{1041:function(e,t){e.exports={tabs:"tabs-3f6R4UrH-",tab:"tab-C-so14ap-",active:"active-3_gZ3PzW-",slider:"slider-XCKyHkum-"}},1165:function(e,t){e.exports={button:"button-1VVj8kLG-"}},1166:function(e,t){e.exports={item:"item-3cgIlGYO-",hovered:"hovered-2g31gdB--",isActive:"isActive-2M6dwA7--",isFirst:"isFirst-2kfAV5tf-",isLast:"isLast-voJ1bqZh-"}},1167:function(e,t){e.exports={slider:"slider-1ealLtjI-",inner:"inner-3lmAEIjy-"}},1168:function(e,t){e.exports={sliderRow:"sliderRow-Tv1W7hM5-"}},1169:function(e,t){e.exports={button:"button-2gir_Bbb-",hovered:"hovered-C6AkUeyT-"}},1170:function(e,t){e.exports={button:"button-88UE6omC-",hovered:"hovered-3xELmoc6-",inner:"inner-2FptJsfC-"}},1171:function(e,t){e.exports={button:"button-37qwTsBL-"}},1172:function(e,t){e.exports={separator:"separator-3bp1jCsV-"}},1173:function(e,t){e.exports=''},1174:function(e,t){e.exports={icon:"icon-2Gun4jqH-"}},1175:function(e,t){e.exports=''},1176:function(e,t){e.exports=''},1177:function(e,t){e.exports={toolbar:"toolbar-2MJefnwP-",dateRangeWrapper:"dateRangeWrapper-yS_7EK1i-",seriesControlWrapper:"seriesControlWrapper-1c7dZFwu-",dateRangeExpanded:"dateRangeExpanded-Eh9SAOEe-",dateRangeCollapsed:"dateRangeCollapsed-1-pFg0M1-",item:"item-2cWFW_ze-",first:"first-1XNI05qr-",last:"last-2VBe7EFW-",inline:"inline-2rwBBIxN-",timezone:"timezone-34WAZb8x-",icon:"icon-3VRthUnU-",hidden:"hidden-3Tq8Bf9V-",collapsed:"collapsed-2lhil-Rc-"}},816:function(e,t,n){"use strict";function i(e){var t;return t=function(t){function n(e,n){var i=t.call(this,e,n)||this;return i._handleSelectRange=function(e){var t,n,a;i.setState({activeRange:e.value}),t=i.context.chartWidget,n=t.model(),a={val:e.value,res:e.targetResolution},n.loadRange(a)},i.state={ranges:[]},i}return C.c(n,t),n.prototype.componentDidMount=function(){var e=this,t=this.context.chartWidget;t.withModel(null,function(){var n=t.model(),i=n.mainSeries();i.onStatusChanged().subscribe(e,e._updateAvailableRanges), +R.enabled("update_timeframes_set_on_symbol_resolve")&&i.dataEvents().symbolResolved().subscribe(e,e._updateAvailableRanges),i.priceScale().properties().lockScale.subscribe(e,e._updateAvailableRanges),i.onIntervalChanged().subscribe(e,e._onRangeChanged),n.model().onResetScales().subscribe(e,e._resetActiveInterval),i.dataEvents().symbolResolved().subscribe(e,e._resetActiveInterval),i.properties().extendedHours.subscribe(e,e._resetActiveInterval),e._updateAvailableRanges()}),t.onScroll().subscribe(this,this._resetActiveInterval)},n.prototype.componentWillUnmount=function(){var e=this,t=this.context.chartWidget;t.withModel(null,function(){var n=t.model(),i=n.mainSeries();i.onStatusChanged().unsubscribe(e,e._updateAvailableRanges),R.enabled("update_timeframes_set_on_symbol_resolve")&&i.dataEvents().symbolResolved().unsubscribe(e,e._updateAvailableRanges),i.priceScale().properties().lockScale.unsubscribe(e,e._updateAvailableRanges),i.onIntervalChanged().unsubscribe(e,e._onRangeChanged),n.model().onResetScales().unsubscribe(e,e._resetActiveInterval),i.dataEvents().symbolResolved().unsubscribe(e,e._resetActiveInterval),i.properties().extendedHours.unsubscribe(e,e._resetActiveInterval)}),t.onScroll().unsubscribe(this,this._resetActiveInterval)},n.prototype.render=function(){return y.createElement(e,{goToDateButton:this.props.goToDateButton,className:this.props.className,ranges:this.state.ranges,activeRange:this.state.activeRange,onSelectRange:this._handleSelectRange})},n.prototype._onRangeChanged=function(e,t){this.setState({activeRange:t.timeframe})},n.prototype._resetActiveInterval=function(){this.setState({activeRange:void 0})},n.prototype._updateAvailableRanges=function(){var e,t,n,i=this.context,a=i.availableTimeFrames,o=i.chartWidget;o.model()&&(e=o.model().mainSeries(),(t=e.status())!==M.STATUS_LOADING&&t!==M.STATUS_RESOLVING&&(n=a(e.symbolInfo(),e.status()),0!==n.length&&this.setState({ranges:n})))},n}(y.PureComponent),t.contextTypes={availableTimeFrames:S.func.isRequired,chartWidget:S.object.isRequired},t}function a(e){return y.createElement("div",{className:z.slider,ref:e.reference})}function o(e){return function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e._activeTab=null,e}return C.c(n,t),n.prototype.componentDidUpdate=function(){this._componentDidUpdate()},n.prototype.componentDidMount=function(){this._componentDidUpdate()},n.prototype.render=function(){var t=this,n=this.props.className,i=this._generateTabs();return y.createElement("div",{className:E(n,z.tabs)},i,y.createElement(e,{reference:function(e){t._slider=e}}))},n.prototype._generateTabs=function(){var e=this;return this._activeTab=null,y.Children.map(this.props.children,function(t){var n=t,i=!!n.props.isActive,a={reference:function(t){i&&(e._activeTab=t),n.props.reference&&n.props.reference(t)}};return y.cloneElement(n,a)})},n.prototype._componentDidUpdate=function(){var e,t,n=Object(B.ensureNotNull)(this._slider),i=n.style;this._activeTab?(e=this._activeTab.offsetWidth,t=this._activeTab.offsetLeft, +i.transform="translateX("+t+"px)",i.width=e+"px",i.opacity="1"):i.opacity="0"},n}(y.PureComponent)}function s(e){var t,n=E(I.item,(t={},t[I.isActive]=e.isActive,t[I.isFirst]=e.isFirst,t[I.isLast]=e.isLast,t));return y.createElement("div",{className:n,onClick:e.onClick,ref:e.reference},e.children)}function r(e){return y.createElement("div",{className:L.slider,ref:e.reference},y.createElement("div",{className:L.inner}))}function l(e){var t=e.className,n=e.ranges,i=e.activeRange,a=e.onSelectRange;return y.createElement(H,{className:E($.sliderRow,t)},n.map(function(e,t){return y.createElement(s,{key:e.value,isFirst:0===t,isLast:t===n.length-1,isActive:i===e.value,onClick:a&&a.bind(null,e)},y.createElement("div",{title:e.description||e.text,className:"apply-common-tooltip"},e.text))}))}function c(e){var t=e.reference,n=e.className,i=e.children,a=C.e(e,["reference","className","children"]);return y.createElement("button",C.a({},a,{className:E(n,X.button),ref:t}),y.createElement("span",{className:X.inner},i))}function d(e){e.updateActions();var t=e.actions();return t&&t.applyTimeZone&&t.applyTimeZone.subActions?t.applyTimeZone.subActions:[]}function u(e){return y.createElement("span",{className:E(oe.separator,e.className)})}function p(e){var t;return t=function(t){function n(e,n){var i=t.call(this,e,n)||this;return i._priceScale=null,i._handleSelect=function(){var e=i.context.chartWidget,t=e.model(),n=Object(B.ensureNotNull)(i.state.series),a=n.priceScale(),o=a.mode();n.priceScale().isLockScale()||t.setPriceScaleMode({log:!o.log},a,window.t("Toggle Log Scale"))},i.state={isActive:!1,series:null},i}return C.c(n,t),n.prototype.componentDidMount=function(){var e=this,t=this.context.chartWidget;t.withModel(null,function(){var n=t.model().mainSeries(),i=n.priceScale();e._handleMainSeriesPriceScaleChanged(i),n.priceScaleChanged().subscribe(e,e._handleMainSeriesPriceScaleChanged),e._handleModeChanged({},i.mode()),e.setState({isActive:n.priceScale().isLog(),series:n})})},n.prototype.componentWillUnmount=function(){var e=this,t=this.context.chartWidget;t.withModel(null,function(){t.model().mainSeries().priceScaleChanged().unsubscribe(e,e._handleMainSeriesPriceScaleChanged)}),null!==this._priceScale&&(this._priceScale.modeChanged().unsubscribeAll(this),this._priceScale=null)},n.prototype.render=function(){var t=this.props.className,n=this.state,i=n.isActive,a=n.series;return y.createElement(e,{className:t,isLogarithm:i,isDisabled:null===a,onClick:this._handleSelect})},n.prototype._handleMainSeriesPriceScaleChanged=function(e){var t={};null!==this._priceScale&&(t=this._priceScale.mode(),this._priceScale.modeChanged().unsubscribe(this,this._handleModeChanged)),this._priceScale=e,this._priceScale.modeChanged().subscribe(this,this._handleModeChanged),this._handleModeChanged(t,e.mode())},n.prototype._handleModeChanged=function(e,t){e.log!==t.log&&this.setState({isActive:t.log})},n}(y.PureComponent),t.contextTypes={chartWidget:S.object.isRequired},t}function h(e){var t;return t=function(t){function n(e,n){var i=t.call(this,e,n)||this +;return i._priceScale=null,i._handleSelect=function(){var e=i.context.chartWidget,t=e.model(),n=Object(B.ensureNotNull)(i.state.series),a=n.priceScale(),o=a.mode();t.setPriceScaleMode({autoScale:!o.autoScale},a,window.t("Toggle Auto Scale"))},i.state={isActive:!1,series:null},i}return C.c(n,t),n.prototype.componentDidMount=function(){var e=this,t=this.context.chartWidget;t.withModel(null,function(){var n=t.model().mainSeries(),i=n.priceScale();e._handleMainSeriesPriceScaleChanged(i),n.priceScaleChanged().subscribe(e,e._handleMainSeriesPriceScaleChanged),e._handleModeChanged({},i.mode()),e.setState({isActive:n.priceScale().isAutoScale(),series:n})})},n.prototype.componentWillUnmount=function(){var e=this,t=this.context.chartWidget;t.withModel(null,function(){t.model().mainSeries().priceScaleChanged().unsubscribe(e,e._handleMainSeriesPriceScaleChanged)}),null!==this._priceScale&&(this._priceScale.modeChanged().unsubscribeAll(this),this._priceScale=null)},n.prototype.render=function(){var t=this.props.className,n=this.state,i=n.isActive,a=n.series;return y.createElement(e,{className:t,isAuto:i,isDisabled:null===a,onClick:this._handleSelect})},n.prototype._handleMainSeriesPriceScaleChanged=function(e){var t={};null!==this._priceScale&&(t=this._priceScale.mode(),this._priceScale.modeChanged().unsubscribe(this,this._handleModeChanged)),this._priceScale=e,this._priceScale.modeChanged().subscribe(this,this._handleModeChanged),this._handleModeChanged(t,e.mode())},n.prototype._handleModeChanged=function(e,t){e.autoScale!==t.autoScale&&this.setState({isActive:t.autoScale})},n}(y.PureComponent),t.contextTypes={chartWidget:S.object.isRequired},t}function m(e){var t;return t=function(t){function n(e,n){var i=t.call(this,e,n)||this;return i._priceScale=null,i._handleSelect=function(){var e=i.context.chartWidget,t=e.model(),n=Object(B.ensureNotNull)(i.state.series),a=n.priceScale(),o=a.mode();n.priceScale().isLockScale()||t.setPriceScaleMode({percentage:!o.percentage},a,window.t("Toggle Percentage Scale"))},i.state={isActive:!1,series:null},i}return C.c(n,t),n.prototype.componentDidMount=function(){var e=this,t=this.context.chartWidget;t.withModel(null,function(){var n=t.model().mainSeries(),i=n.priceScale();e._handleMainSeriesPriceScaleChanged(i),n.priceScaleChanged().subscribe(e,e._handleMainSeriesPriceScaleChanged),e._handleScaleChange({},i.mode()),e.setState({isActive:n.priceScale().isPercentage(),series:n})})},n.prototype.componentWillUnmount=function(){var e=this,t=this.context.chartWidget;t.withModel(null,function(){t.model().mainSeries().priceScaleChanged().unsubscribe(e,e._handleMainSeriesPriceScaleChanged)}),null!==this._priceScale&&(this._priceScale.modeChanged().unsubscribeAll(this),this._priceScale=null)},n.prototype.render=function(){var t=this.props.className,n=this.state,i=n.isActive,a=n.series;return y.createElement(e,{className:t,isPercentage:i,isDisabled:null===a,onClick:this._handleSelect})},n.prototype._handleMainSeriesPriceScaleChanged=function(e){var t={};null!==this._priceScale&&(t=this._priceScale.mode(), +this._priceScale.modeChanged().unsubscribe(this,this._handleScaleChange)),this._priceScale=e,this._priceScale.modeChanged().subscribe(this,this._handleScaleChange),this._handleScaleChange(t,e.mode())},n.prototype._handleScaleChange=function(e,t){e.percentage!==t.percentage&&this.setState({isActive:t.percentage})},n}(y.PureComponent),t.contextTypes={chartWidget:S.object.isRequired},t}function f(e){var t;return t=function(t){function n(e,n){var i,a=t.call(this,e,n)||this;return a._handleClick=function(e){var t=a.context.resizerDetacher;e.shiftKey&&t.detachable.value()?t.detach():a.state.isFullscreen?t.exitFullscreen():t.requestFullscreen()},a._handleLayoutChange=function(e){a.setState({isFullscreen:e})},i=a.context.resizerDetacher,a.state={isFullscreen:i.fullscreen.value()},a}return C.c(n,t),n.prototype.componentDidMount=function(){this.context.resizerDetacher.fullscreen.subscribe(this._handleLayoutChange)},n.prototype.componentWillUnmount=function(){this.context.resizerDetacher.fullscreen.unsubscribe(this._handleLayoutChange)},n.prototype.render=function(){var t=this.props.className,n=this.state.isFullscreen;return y.createElement(e,{className:t,isFullscreen:n,onClick:this._handleClick})},n}(y.PureComponent),t.contextTypes={chartWidget:S.object.isRequired,resizerDetacher:S.object.isRequired},t}function g(e){if(e.map){return y.Children.toArray(e.children).map(e.map)}return e.children}function v(e){return Object.keys(e).map(function(t){return{name:t,width:e[t].offsetWidth}}).sort(function(e,t){return Te[e.name]-Te[t.name]})}function b(e){var t={};return Object.keys(e).forEach(function(n){var i,a=e[n];null!==a&&null!==(i=x.findDOMNode(a))&&(t[n]=i)}),t}function _(e,t){return function(n,i,a){var o,s,r,l;return y.isValidElement(n)&&"string"!=typeof n.type&&(o=n.props,"string"==typeof o.className)?(s={className:E(o.className,0===i&&fe.first,i===a.length-1&&fe.last)},r=e(),l=Object(B.ensureDefined)(Me.get(n.type)),y.createElement("div",{key:null===n.key?void 0:n.key,className:E(fe.inline,r[l]&&fe.collapsed),ref:function(e){return t(e,l)}},y.cloneElement(n,s))):n}}var C,y,x,S,E,w,R,N,T,M,W,k,A,D,O,j,B,z,I,F,P,L,$,H,U,q,G,V,Z,J,K,Y,X,Q,ee,te,ne,ie,ae,oe,se,re,le,ce,de,ue,pe,he,me,fe,ge,ve,be,_e,Ce,ye,xe,Se,Ee,we,Re,Ne,Te,Me,We,ke,Ae,De;Object.defineProperty(t,"__esModule",{value:!0}),C=n(1),y=n(20),x=n(59),n(11),S=n(104),E=n(102),w=n(313),R=n(5),N=n(880),T=n(846),M=n(40),W=n(849),k=n(328),A=n(1165),D={title:window.t("Date Range"),goToDate:window.t("Go to...")},O=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._handleGoToDateClick=function(){var e=t.context.chartWidget;Object(k.showGoToDateDialog)(e.model())},t._handleRangeSelect=function(e){e&&t.props.onSelectRange&&t.props.onSelectRange(e)},t}return C.c(t,e),t.prototype.render=function(){var e=this,t=this.props,n=t.ranges,i=t.activeRange,a=t.goToDateButton;return y.createElement(N.a,{className:A.button,content:D.title,arrow:!0,verticalAttachEdge:N.b.Top,verticalDropDirection:N.c.FromBottomToTop,horizontalMargin:4},n.map(function(t){ +return y.createElement(T.a,{key:t.value,label:t.description||t.text,isActive:i===t.value,onClick:e._handleRangeSelect,onClickArg:t})}),a&&y.createElement(W.a,null),a&&y.createElement(T.a,{label:D.goToDate,onClick:this._handleGoToDateClick}))},t.contextTypes={chartWidget:S.object.isRequired},t}(y.PureComponent),j=i(O),B=n(7),z=n(1041),o(a),I=n(1166),F=n(1167),P=n(882),L=Object(P.a)(z,F),$=n(1168),H=o(r),U=i(l),q=n(306),G=n(1169),V={title:window.t("Go to...")},Z=Object(q.b)({keys:["Alt","G"],text:"{0} + {1}"}),J=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._handleClick=function(){var e=t.context.chartWidget;Object(k.showGoToDateDialog)(e.model())},t}return C.c(t,e),t.prototype.render=function(){var e=this.props,t=e.className;return e.ranges.length>0&&y.createElement("div",{className:E("apply-common-tooltip",G.button,t),"data-tooltip-hotkey":Z,onClick:this._handleClick},V.title)},t.contextTypes={chartWidget:S.object.isRequired},t}(y.PureComponent),K=i(J),Y=n(847),X=n(1170),Q=n(340),ee=n(130),te=n(195),ne=n(1171),ie={hint:window.t("Timezone")},ae=function(e){function t(t,n){var i=e.call(this,t,n)||this;return i._element=null,i._timeFormatter=new ee.TimeFormatter,i._handleRef=function(e){i._element=e},i.state={time:"",timezone:""},i}return C.c(t,e),t.prototype.componentDidMount=function(){var e,t=this,n=this.context.chartWidget,i=this.props.withMenu;n.withModel(null,function(){var e=n.model();e.model().mainSeries().dataEvents().symbolResolved().subscribe(t,t.updateTimezonesButton),e.model().properties().timezone.subscribe(t,t.updateTimezonesButton)}),i&&(e=Object(B.ensureNotNull)(this._element),Object(Y.bindPopupMenu)(e,function(){return d(n).map(function(e){return{action:e.enabled?e.executeCallback.bind(e):null,addClass:e.enabled?"":"special",disabled:!e.enabled,iconClass:e.checkable&&e.checked?"icon checked-icon":"unchecked-icon",svg:e.checkable&&e.checked?te:"",title:e.text||""}})},{direction:"up",addClass:"context-menu",svg:!0,wrapIcon:!0}))},t.prototype.componentWillUnmount=function(){var e,t=this,n=this.context.chartWidget;n.withModel(null,function(){var e=n.model();e.model().mainSeries().dataEvents().symbolResolved().unsubscribe(t,t.updateTimezonesButton),e.model().properties().timezone.unsubscribe(t,t.updateTimezonesButton)}),e=Object(B.ensureNotNull)(this._element),Object(Y.unbindPopupMenu)(e)},t.prototype.render=function(){var e=this.props,t=e.className,n=e.isDisabled,i=this.state,a=i.time,o=i.timezone;return y.createElement(c,{className:E(t,ne.button,"apply-common-tooltip"),title:ie.hint,reference:this._handleRef,disabled:n},a&&o&&a+" ("+o+")")},t.prototype.updateTimezonesButton=function(){var e,t,n,i,a=this.context.chartWidget;a.model()&&null!==a.model().mainSeries().symbolInfo()&&(e=a.model().model().timezone(),"exchange"===e&&(t=Object(B.ensureNotNull)(a.model().mainSeries().symbolInfo()),(n=t.timezone)&&(e=n)),i=Object(Q.a)(e),this._timezoneOffset=i.offset,this.setState({timezone:i.string}),this.tickClock())},t.prototype.tickClock=function(){ +var e,t,n=this.context.chartApiInstance,i=this._timezoneOffset;void 0!==i&&(e=1e3*n.serverTimeOffset(),t=new Date(Date.now()+i+e),this.setState({time:this._timeFormatter.format(t)}))},t.contextTypes={chartWidget:S.object.isRequired,chartApiInstance:S.object.isRequired},t}(y.PureComponent),oe=n(1172),se=n(848),re=n(300),le=n(41),ce=n(1173),de=n(1174),ue={hint:window.t("Scales Properties")},pe=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._element=null,t._handleRef=function(e){t._element=e},t}return C.c(t,e),t.prototype.componentDidMount=function(){var e=this.context.chartWidget,t=Object(B.ensureNotNull)(this._element);Object(Y.bindPopupMenu)(t,function(){var t,n,i,a,o,s,r,l=e.paneWidgets();for(t=0;t'},836:function(e,t){e.exports=''},844:function(e,t,n){"use strict";function i(){h.fire()}var a,o,s,r,l,c,d,u,p,h;n.d(t,"a",function(){return p}),t.b=i,a=n(1),o=n(20),n.n(o),s=n(102),n.n(s),r=n(7),n.n(r),l=n(50), +c=n(871),n.n(c),d=n(8),u=n.n(d),p=function(e){function t(t){var n=e.call(this,t)||this;return n._containerRef=null,n._scrollWrapRef=null,n._handleContainerRef=function(e){return n._containerRef=e},n._handleScrollWrapRef=function(e){return n._scrollWrapRef=e},n._handleMeasure=function(){var e,t,i,a,o,s,c,d,u,p,h,m,f,g,v,b,_;n.state.isMeasureValid||(e=n.props.position,t=Object(r.ensureNotNull)(n._containerRef),i=t.getBoundingClientRect(),a=document.documentElement.clientHeight,o=document.documentElement.clientWidth,s=a-10,c=i.height>s,c&&(d=Object(r.ensureNotNull)(n._scrollWrapRef),d.style.overflowY="scroll",i=t.getBoundingClientRect()),u=i.width,p=i.height,h="function"==typeof e?e(u,p):e,m=5,f=o-u-5,g=Object(l.clamp)(h.x,m,Math.max(m,f)),v=5,b=a-p-5,_=Object(l.clamp)(h.y,v,Math.max(v,b)),n.setState({appearingMenuHeight:c?s:void 0,appearingMenuWidth:h.overrideWidth,appearingPosition:{x:g,y:_},isMeasureValid:!0}))},n._handleGlobalClose=function(){n.props.onClose()},n.state={},n}return a.c(t,e),t.prototype.componentWillReceiveProps=function(e){this.props.isOpened&&!e.isOpened&&this.setState({isMeasureValid:void 0})},t.prototype.componentDidMount=function(){this._handleMeasure(),h.subscribe(this,this._handleGlobalClose)},t.prototype.componentDidUpdate=function(){this._handleMeasure()},t.prototype.componentWillUnmount=function(){h.unsubscribe(this,this._handleGlobalClose)},t.prototype.render=function(){var e,t=this.props,n=t.children,i=t.minWidth,a=t.theme,r=void 0===a?c:a,l=t.className,d=this.state,u=d.appearingMenuHeight,p=d.appearingMenuWidth,h=d.appearingPosition,m=d.isMeasureValid;return o.createElement("div",{className:s(l,r.menuWrap,(e={},e[r.isMeasuring]=!m,e)),style:{height:u,left:h&&h.x,minWidth:i,position:"fixed",top:h&&h.y,width:p},ref:this._handleContainerRef},o.createElement("div",{className:r.scrollWrap,style:{overflowY:void 0!==u?"scroll":"auto"},ref:this._handleScrollWrapRef},o.createElement("div",{className:r.menuBox},n)))},t}(o.PureComponent),h=new u.a},846:function(e,t,n){"use strict";function i(e){return s.createElement(e.href?"a":"div",e)}function a(e){e.stopPropagation()}var o,s,r,l,c,d;n.d(t,"a",function(){return d}),o=n(1),s=n(20),n.n(s),r=n(102),n.n(r),l=n(844),c=n(879),n.n(c),d=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._handleClick=function(e){var n=t.props,i=n.dontClosePopup,a=n.isDisabled,o=n.onClick,s=n.onClickArg;a||(o&&o(s,e),i||Object(l.b)())},t}return o.c(t,e),t.prototype.render=function(){var e,t,n=this.props,o=n.className,l=n.forceShowHint,d=n.hint,u=n.icon,p=n.isActive,h=n.isDisabled,m=n.isHovered,f=n.appearAsDisabled,g=n.label,v=n.link,b=n.showToolboxOnHover,_=n.target,C=n.toolbox,y=n.theme,x=void 0===y?c:y;return s.createElement(i,{className:r(o,x.item,u&&x.withIcon,(e={},e[x.isActive]=p,e[x.isDisabled]=h||f,e[x.hovered]=m,e)),href:v,target:_,onClick:this._handleClick},void 0!==u&&s.createElement("div",{className:x.icon,dangerouslySetInnerHTML:{__html:u}}),s.createElement("div",{className:x.labelRow},s.createElement("div",{className:x.label +},g)),(void 0!==d||l)&&s.createElement("div",{className:x.hint},d),void 0!==C&&s.createElement("div",{onClick:a,className:r(x.toolbox,(t={},t[x.showOnHover]=b,t))},C))},t}(s.PureComponent)},847:function(e,t,n){"use strict";var i,a=n(192).ESC,o=function(e,t,i){var s,r,l,c,d,u,p=".popup-menu";e=$(e),i=i||{},i.activeClass=i.activeClass||"",s=(i.event||"click")+p,i.hideEvent&&(r=i.hideEvent+p),l=function(){},c=l,d={},u=function(s,u,h){function m(t){var n=$(t.target).parents().andSelf();n.is(_)||n.is(e)||n.is(".charts-popup-tab-headers, .charts-popup-itemheader")||c()}function f(e){if(d.preventFirstProcessClick)return void(d.preventFirstProcessClick=!1);var t=$(e.target).parents().andSelf();t.is(".charts-popup-tab-headers, .charts-popup-itemheader")||i.notCloseOnButtons&&t.is(".icon-delete")||c()}function g(e){e.keyCode===a&&c()}function v(t,a,s){var r,l,c,d,u,p,h,m,f,g,b,C,y,x,S,E;if(t instanceof o.TabGroup){if(!t.tabs||!t.tabs.length)return;return 1!==t.tabs.length||t.tabs[0].title?(r=$('
').appendTo(s),l=$('
').appendTo(r),c=null,void $.each(t.tabs||[],function(e,n){var i,a;n.items&&n.items.length&&(i=$('
').hide().appendTo(r),$.each(n.items,function(){v(this,void 0,i)}),a=$('').append($('').text(n.name)).appendTo(l),a.on("click",function(e){a.is(".active")||(l.find(".charts-popup-tab-header.active").removeClass("active"),a.addClass("active"),r.find(".charts-popup-tab").hide(),i.show(),e&&e.preventDefault(),"function"==typeof t.onChange&&t.onChange.call(t,n.name))}),c&&!n.active||(c=a,l.find(".charts-popup-tab-header.active").removeClass("active"),a.addClass("active"),r.find(".charts-popup-tab").hide(),i.show()))})):void $.each(t.tabs[0].items,function(){v(this,void 0,s)})}return t instanceof o.Group?(d=$('
').appendTo(s),t.title&&(u=$('
').text(t.title).prepend($('')),t.collapsible&&(d.addClass("charts-popup-group-collapsible"),d.toggleClass("collapsed",t.collapsed),u.on("click",function(){d.toggleClass("collapsed"),"function"==typeof t.onChange&&t.onChange(d.hasClass("collapsed")),_.height()===parseInt(_.css("max-height"))?_.addClass("popup-menu-scroll-y"):_.height()
').text(t.title)):t.separator?(p=$(''),void s.append(p)):(p=$(''),t.url&&p.attr("href",t.url),t.target&&p.attr("target",t.target),a||p.addClass("first"),"function"==typeof t.active?t.active(t)&&p.addClass("active"):t.active&&p.addClass("active"),t.addClass&&p.addClass(t.addClass),t.addData&&p.data(t.addData),t.disabled&&p.addClass("disabled"), +"function"==typeof t.action&&(h=t.action,m=function(e){$(e.target).parents().andSelf().is(x)||(h.apply(p,arguments),!t.url&&e&&"function"==typeof e.preventDefault&&e.preventDefault())},i.upAction?p.bind("mouseup",m):p.bind("click",m)),t.date?(f=$('').appendTo(p),$('').text(t.date||"").appendTo(p)):t.icon&&!i.svg?(g=$('').appendTo(p),g.css("background-image",t.icon.image||""),t.icon.offset&&g.css("background-position","string"==typeof t.icon.offset?t.icon.offset:t.icon.offset.x+"px "+t.icon.offset.y+"px"),f=$('').appendTo(p)):!0===i.svg&&t.svg?(i.wrapIcon?p.append($('').addClass(t.iconClass).append(t.svg)):p.append(t.svg),f=$('').appendTo(p)):t.iconClass?(p.append($('').addClass(t.iconClass)),f=$('').appendTo(p)):f=$('').appendTo(p),t.html?f.html(t.html):f.text(TradingView.clean(t.title,!0)||""),b=$('').appendTo(p),t.shortcut&&b.text(t.shortcut.keys),"function"==typeof t.deleteAction&&(C=t.deleteAction,y=t.deleteAction.title||$.t("Delete"),x=$(''),x.html(n(828)),x.attr("title",y),x.on("click",function(e){C.apply(p,arguments),e.preventDefault()}),p.append(x)),t.buttons instanceof Array&&t.buttons.length&&t.buttons.forEach(function(e){e.el instanceof $||(e.el=$(e.el)),e.el.appendTo(p),e.handler&&e.el.on("click",function(t){e.handler.apply(p,arguments)})}),void 0!==t.counter&&("function"==typeof t.counter?(S=$('').html(t.counter()),S.appendTo(p)):(E=t.counterBlue?"blue":"",$('').text(t.counter+"").addClass(E).appendTo(p))),s.append(p),void e.data("popup-menu",s))}var b,_,C,y,x,S,E,w,R,N,T,M,W,k,A,D,O,j,B,z,I,F,P,L,H,U,q=s.target.ownerDocument,G=q.defaultView,V=u||t;if("function"==typeof V&&(V=V()),$(this).hasClass("open")||$(this).hasClass("active"))return s.preventDefault(),c(),void(b=d.scrollTop);switch(c=function(){d.scrollTop=_.scrollTop(),_.remove(),e.removeClass("active open "+i.activeClass),e.data("popup-menu",null),$(q).off("click",f),$(q).off("mousedown",m),Modernizr.touch&&$(q).off("touchstart.chartgui",m),$(q).off("selectstart."+p),q.removeEventListener("keydown",g,!1),c=l,i.onRemove&&i.onRemove()},e.addClass("active open "+i.activeClass),_=$('
'),i.addClass&&_.addClass(i.addClass),i.zIndex&&_.css("z-index",i.zIndex),C=_,i.listInner&&(C=$('
').appendTo(C)),i.listTable&&(C=$('
').appendTo(C)),$.each(V,function(e){v(this,e,C)}),r||(d.preventFirstProcessClick=!0),$(q).on("click",f),$(q).on("mousedown",m),q.addEventListener("keydown",g,!1),Modernizr.touch&&$(q).on("touchstart.chartgui",m),i.upAction&&$(q).on("selectstart.popup-menu",function(){return!1}),_.appendTo(q.body),y=$(G).width(),x=Math.min($(G).height(),$("body").height()),S=e.outerWidth(),E=e.outerHeight(),w=e.offset(), +b=$(G).scrollTop()||0,w.top-=b,w.top=Math.round(w.top),w.left=Math.round(w.left),R=_.outerWidth(),N=_.outerHeight(),T=void 0!==i.viewportSpacing?i.viewportSpacing:10,M=i.popupSpacing?~~i.popupSpacing:1,W=i.popupDrift?~~i.popupDrift:0,k=N-_.height(),A="down",i.direction&&(A="function"==typeof i.direction?i.direction():i.direction),D=!!i.reverse,"down"===A?(O=x-w.top-E-M-T-k,j=w.top-M-T-k,OO&&(A="up")):"right"===A&&(B=y-w.left-S-M-T-k,z=w.left-M-T-k,BB&&(A="left")),A){case"down":case"up":"down"===A?_.css("top",w.top+E+M+"px"):_.css("bottom",x-w.top+M+"px").css("top","auto"),D?_.css("left",Math.max(w.left+W+S-R,T)+"px").css("right","auto"):_.css("left",w.left+W+"px").css("right","auto");break;case"right":case"left":M=Math.max(M,4),"right"===A?_.css("left",Math.floor(w.left+S+M)+"px").css("right","auto"):_.css("left",Math.floor(Math.max(w.left-R-M,T))+"px").css("right","auto"),D?_.css("top",Math.floor(Math.max(w.top+W+E-N,T))+"px"):_.css("top",Math.floor(w.top+W)+"px")}for(_.show(),I=w.top,"up"===A||{left:1,right:1}[A]&&D?"up"!==A?I+=E:I-=E+M+k+T:I=x-I-E-2*M-k,_.height()>I&&_.addClass("popup-menu-scroll-y"),_.css("max-height",I+"px"),i.careRightBorder&&(F=y+$(G).scrollLeft(),parseInt(_.css("left"))+_.width()+T>F&&_.css("left",F-_.width()-T+"px").css("right","auto")),i.careBottomBorder&&parseInt(_.css("top"))+_.height()+T>x+b&&_.css("top",x-_.height()-T+b+"px"),L=e.parents().andSelf(),H=L.size();H--;)if("fixed"===L.eq(H).css("position")){P=L.eq(H);break}P&&(U=_.offset(),_.css({position:"fixed",left:U.left-$(q).scrollLeft(),right:"auto"})),_[0].scrollHeight>_.height()&&_.addClass("popup-with-scroll"),s&&s.preventDefault()},s&&e.bind(s,u),r&&e.bind(r,function(){c()}),i.runOpened&&u()};o.TabGroup=function e(t){if(!(this instanceof e))return new e(t);t=t||{},this.tabs=[],"function"==typeof t.onChange&&(this.onChange=t.onChange)},o.TabGroup.prototype.appendTab=function(e,t,n){if(null==e?e="":e+="",t||(t=[]),n||(n={}),!Array.isArray(t))throw new TypeError("items must be an array");return this.tabs.push({name:e,items:t,active:!!n.active}),t},o.Header=function e(t){if(!(this instanceof e))return new e(t);this.title=t},o.Group=function e(t){if(!(this instanceof e))return new e(t);t=t||{},this.items=[],this.title=null==t.title?"":t.title+"",this.collapsible=!!t.collapsible,this.collapsed=!!t.collapsed,"function"==typeof t.onChange&&(this.onChange=t.onChange)},o.Group.prototype.push=function(){this.items.push.apply(this.items,arguments)},t.bindPopupMenu=o,i=function(e){e=$(e),e.unbind(".popup-menu"),e.removeData("popup-menu")},t.unbindPopupMenu=i},848:function(e,t,n){"use strict";function i(e){var t,n=e.icon,i=e.isActive,c=e.isOpened,d=e.isDisabled,u=e.onClick,p=e.text,h=e.textBeforeIcon,m=e.title,f=e.theme,g=void 0===f?l:f,v=e.className,b=e.forceInteractive,_=a.e(e,["icon","isActive","isOpened","isDisabled","onClick","text","textBeforeIcon","title","theme","className","forceInteractive"]),C=s(v,g.button,m&&"apply-common-tooltip",(t={},t[g.isActive]=i,t[g.isOpened]=c, +t[g.isInteractive]=(b||!!u)&&!d,t[g.isDisabled]=d,t)),y=n&&("string"==typeof n?o.createElement(r.a,{className:g.icon,icon:n}):o.cloneElement(n,{className:g.icon}));return o.createElement("div",a.a({},_,{className:C,onClick:d?void 0:u,title:m}),h&&p&&o.createElement("div",{className:s("js-button-text",g.text)},p),y,!h&&p&&o.createElement("div",{className:s("js-button-text",g.text)},p))}var a,o,s,r,l;t.a=i,a=n(1),o=n(20),n.n(o),s=n(102),n.n(s),r=n(300),l=n(855),n.n(l)},849:function(e,t,n){"use strict";function i(e){return a.createElement("div",{className:o.separator})}var a,o;t.a=i,a=n(20),n.n(a),o=n(881),n.n(o)},855:function(e,t){e.exports={button:"button-2ioYhFEY-",isInteractive:"isInteractive-20uLObIc-",hovered:"hovered-3perbaxJ-",isActive:"isActive-22S-lGpa-",isOpened:"isOpened-p-Ume5l9-",isDisabled:"isDisabled-1_tmrLfP-",text:"text-1sK7vbvh-",icon:"icon-beK_KS0k-"}},871:function(e,t){e.exports={menuWrap:"menuWrap-1gEtmoET-",isMeasuring:"isMeasuring-FZ0EJCM2-",scrollWrap:"scrollWrap-1B5MfTJt-",menuBox:"menuBox-20sJGjtG-",isHidden:"isHidden-2vLQpR1t-"}},872:function(e,t,n){"use strict";function i(e){var t=p(e),n=document.getElementById(t);return n||(n=document.createElement("div"),n.id=t,document.body.appendChild(n)),u[e]=(u[e]||0)+1,n}function a(e){var t=p(e),n=document.getElementById(t);u[e]&&(u[e]-=1),n&&0===u[e]&&document.body.removeChild(n)}var o,s=n(1),r=(n(127),n(20)),l=n(59),c=n(304),d=0,u={},p=function(e){return"__outside-render-"+e},h=function(e){function t(t){return e.call(this,t)||this}return s.c(t,e),t.prototype.componentDidMount=function(){this._rememberLayer(),this._renderLayer()},t.prototype.componentDidUpdate=function(e){this.props.layerId!==e.layerId&&(a(this._layerId),this._rememberLayer()),this._renderLayer()},t.prototype.componentWillUnmount=function(){l.unmountComponentAtNode(this._layer),a(this._layerId)},t.prototype.render=function(){return null},t.prototype._rememberLayer=function(){var e=this.props.layerId,t=void 0===e?d+++"":e;this._layerId=t,this._layer=i(t)},t.prototype._renderLayer=function(){l.render(r.createElement("div",null,this.props.children),this._layer)},t}(r.Component),m=n(844);n.d(t,"a",function(){return o}),o=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._handleClose=function(){t.props.onClose()},t._handleClickOutside=function(e){var n=t.props,i=n.closeOnClickOutside,a=n.onClickOutside,o=n.doNotCloseOn;a&&a(e),!i||void 0!==o&&l.findDOMNode(o).contains(e.target)||t._handleClose()},t}return s.c(t,e),t.prototype.componentWillReceiveProps=function(e){this.props.isOpened&&!e.isOpened&&this.setState({isMeasureValid:void 0})},t.prototype.render=function(){var e=this.props,t=e.children,n=e.isOpened,i=(e.closeOnClickOutside,e.doNotCloseOn,e.onClickOutside,e.onClose,s.e(e,["children","isOpened","closeOnClickOutside","doNotCloseOn","onClickOutside","onClose"]));return n?r.createElement(h,null,r.createElement(c.a,{handler:this._handleClickOutside,mouseDown:!0,touchStart:!0,ctor:"div"},r.createElement(m.a,s.a({},i,{isOpened:n,onClose:this._handleClose +}),t))):null},t.defaultProps={closeOnClickOutside:!0},t}(r.PureComponent)},879:function(e,t){e.exports={item:"item-2xPVYue0-",hovered:"hovered-1uf45E05-",isDisabled:"isDisabled-1wLqKupj-",isActive:"isActive-2j-GhQs_-",icon:"icon-2Qm7YIcz-",hint:"hint-1IhIvLPB-",toolbox:"toolbox-3ulPxfe--",withIcon:"withIcon-1xBjf-oB-",labelRow:"labelRow-3Q0rdE8--",label:"label-3Xqxy756-",showOnHover:"showOnHover-1q6ySzZc-"}},880:function(e,t,n){"use strict";var i,a,o,s,r,l,c,d,u,p,h,m;n.d(t,"b",function(){return d}),n.d(t,"c",function(){return p}),n.d(t,"a",function(){return m}),i=n(1),a=n(20),n.n(a),o=n(102),n.n(o),s=n(872),r=n(975),l=n(7),n.n(l),c=n(989),n.n(c),function(e){e[e.Top=0]="Top",e[e.Bottom=1]="Bottom"}(d||(d={})),function(e){e[e.Left=0]="Left",e[e.Right=1]="Right"}(u||(u={})),function(e){e[e.FromTopToBottom=0]="FromTopToBottom",e[e.FromBottomToTop=1]="FromBottomToTop"}(p||(p={})),function(e){e[e.FromLeftToRight=0]="FromLeftToRight",e[e.FromRightToLeft=1]="FromRightToLeft"}(h||(h={})),m=function(e){function t(t){var n=e.call(this,t)||this;return n._wrapperRef=null,n._handleWrapperRef=function(e){return n._wrapperRef=e},n._handleClick=function(){n._handleToggleDropdown()},n._handleToggleDropdown=function(e){var t=n.state.isOpened,i="boolean"==typeof e?e:!t;n.setState({isOpened:i})},n._handleClose=function(){n._handleToggleDropdown(!1)},n._getDropdownPosition=function(e,t){var i=Object(l.ensureNotNull)(n._wrapperRef).getBoundingClientRect(),a=n.props,o=a.verticalAttachEdge,s=a.verticalDropDirection,r=a.horizontalAttachEdge,c=a.horizontalDropDirection,m=a.horizontalMargin,f=void 0===m?0:m,g=a.verticalMargin,v=void 0===g?2:g,b=o===d.Top?-1*v:v,_=r===u.Right?i.right:i.left,C=o===d.Top?i.top:i.bottom;return{x:_-(c===h.FromRightToLeft?e:0)+f,y:C-(s===p.FromBottomToTop?t:0)+b}},n.state={isOpened:!1},n}return i.c(t,e),t.prototype.render=function(){var e,t=this.props,n=t.id,i=t.arrow,l=t.children,d=t.content,u=t.isDisabled,p=t.minWidth,h=t.title,m=t.className,f=t.hotKey,g=this.state.isOpened,v=o(m,c.button,"apply-common-tooltip",(e={},e[c.isDisabled]=u,e[c.isOpened]=g,e));return a.createElement("div",{id:n,className:v,onClick:u?void 0:this._handleClick,title:h,"data-tooltip-hotkey":f,ref:this._handleWrapperRef},d,i&&a.createElement("div",{className:c.arrow},a.createElement("div",{className:c.arrowWrap},a.createElement(r.a,{dropped:g}))),a.createElement(s.a,{closeOnClickOutside:this.props.closeOnClickOutside,doNotCloseOn:this,isOpened:g,minWidth:p,onClose:this._handleClose,position:this._getDropdownPosition},l))},t.defaultProps={arrow:!0,closeOnClickOutside:!0,verticalAttachEdge:d.Bottom,horizontalAttachEdge:u.Left,verticalDropDirection:p.FromTopToBottom,horizontalDropDirection:h.FromLeftToRight},t}(a.PureComponent)},881:function(e,t){e.exports={separator:"separator-25lkUpN--"}},882:function(e,t,n){"use strict";function i(e,t,n){var i,a,o,s,r;for(void 0===n&&(n={}),i=Object.assign({},t),a=0,o=Object.keys(t);a-1&&(o.splice(r,1),o.push(n)),a=o.length-1;a>=0;a--)h=o[a],(d=h.statusView())&&(!(u=h===n)||s.showSeriesTitle||s.showSeriesOHLC||s.showStudyTitles||s.showStudyValues)&&(u&&t.enabled("fundamental_widget")||(s.showLegend||!u?(u||s.showStudyTitles||s.showStudyValues)&&s.showLegend&&(p=$("
").addClass("pane-legend-line pane-legend-wrap"),this._options.sourceSelectionEnabled||p.addClass("legend-selection-disabled"),p.appendTo(this.$el),p.source=h,u?this._chartHasStudies()?(c=$('').append($(i(1149)).attr({class:"expand"})),p.addClass("main").append(c.on("click touchend",this.toggleTitles.bind(this)))):p.addClass("pane-legend-line--without-child-studies"):p.addClass("study"),h.properties().visible.value()||p.addClass("disabled"),this._generateItemsForRow(p,d,s),this._mouseEventHandlers.push(new l(p,this,!0))):this.$el.find(".expand-line").length||(p=$("
").addClass("pane-legend-line pane-legend-wrap main expand-line"), +this._options.sourceSelectionEnabled||p.addClass("legend-selection-disabled"),p.appendTo(this.$el),this._chartHasStudies()?(c=$('').append($(i(1148)).attr({class:"expand closed"})),p.append(c.on("click touchend",this.toggleTitles.bind(this)))):p.addClass("pane-legend-line--without-child-studies"),p.source=h,h.properties().visible.value()||p.addClass("disabled"),s={showStudyTitles:!1,showSeriesTitle:s.showSeriesTitle,showSeriesOHLC:s.showSeriesOHLC,showStudyValues:!1},this._generateItemsForRow(p,d,s),this._mouseEventHandlers.push(new l(p,this,!0)),this.update())));this.update()}},s.prototype._chartHasStudies=function(){return this._model.model().allStudies().some(function(t){return t.statusView()})},s.prototype._generateItemsForRow=function(e,s,n){var o,r,l,h,d,u,p,c,_,v,m,g=e.source,b=this,y=g===this._model.mainSeries();if((y&&n.showSeriesTitle||!y&&n.showStudyTitles)&&(r=$(""),r.addClass("pane-legend-line apply-overflow-tooltip"),this._options.contextMenuEnabled&&!this._chart.readOnly()||r.addClass("no-context-menu"),this._options.sourceSelectionEnabled||r.addClass("legend-selection-disabled"),y&&r.addClass("main"),g.properties().visible.value()||r.addClass("disabled"),r.css({"font-weight":s.bold()?"bold":"normal","font-size":s.size()}),this._options.contextMenuEnabled&&r.click(function(t){b.contextMenuEvent(t,e)}),r.appendTo(e),this._itemsBinding.push({value:s,cell:r,source:e.source}),!this._chart.readOnly()&&g.userEditEnabled()&&t.enabled("edit_buttons_in_legend")&&(o=$(''),a||o.appendTo(e),!y&&t.enabled("show_hide_button_in_legend")&&$('').append($(i(1150)).attr({width:14,height:14})).appendTo(o).on("click touchend",this._generateItemsForRow._onShowhideClick.bind(this,g)),!y&&t.enabled("property_pages")&&t.enabled("format_button_in_legend")&&$('').append($(i(1151)).attr({width:14,height:14})).appendTo(o).on("click touchend",this._generateItemsForRow._onFormatClick.bind(this,g)),!y&&t.enabled("delete_button_in_legend")&&$('').append($(i(1040)).attr({width:14,height:14})).appendTo(o).on("click touchend",this._generateItemsForRow._onDeleteClick.bind(this,g)))),l=g.legendView(),this.isDataWindowValuesVisible(l)&&l.isValuesVisible()){for(h=[],d=[],u=$('
'),this._options.contextMenuEnabled||u.addClass("no-context-menu"),this._options.sourceSelectionEnabled||u.addClass("legend-selection-disabled"),p=0;p").appendTo(u),_=y?$("").appendTo(c):null,v=$("").appendTo(c),y&&(_.addClass("pane-legend-item-value-title__main"), +v.addClass("pane-legend-item-value__main")),g.properties().visible.value()||(v.addClass("disabled"),_&&_.addClass("disabled")),h.push(v),_&&d.push(_);m=$("").appendTo(u.appendTo(e)),this._itemsBinding.push({value:l,cell:h,titleCells:d.length?d:null,source:g,additional:m})}o&&a&&o.appendTo(e)},s.prototype.isDataWindowValuesVisible=function(t){return this._chart.onWidget()?!!t&&!this._chart.isSmall():!!t},s.prototype._generateItemsForRow._onShowhideClick=function(t){this._model.setProperty(t.properties().visible,!t.properties().visible.value(),"Show/Hide "+t.title())},s.prototype._generateItemsForRow._onFormatClick=function(t,e){t.userEditEnabled()&&(TVSettings.setValue("properties_dialog.active_tab.chart",$.t("Style")),r(t,this._model))},s.prototype._generateItemsForRow._onDeleteClick=function(t){t.isUserDeletable()&&(t.hasChildren()?showDeleteStudyTreeConfirm(this._model.removeSource.bind(this._model,t)):this._model.removeSource(t))},s.prototype._generateItemsForRow._onAddChildSourceClick=function(t){var e,i,s=this._chart.showIndicators(t);s&&(e=function(){n("SOS","Apply SOS","Apply by Plus SOS")},i=this._model.model().studyInserted(),i.subscribe(this,e),s.visibilityChanged.subscribe(this,function(t){t||i.unsubscribe(this,e)},!0))},s.prototype._generateItemsForRow._onViewSorceClick=function(t){var e=t.metaInfo();this._getPineSourceCode(e).done(function(t){TradingView.bottomWidgetBar&&TradingView.bottomWidgetBar.activateScriptEditorTab(t)})},s.prototype._getPineSourceCode=function(t){return $.Deferred()},s.prototype.setItemEnabled=function(t,e){var i=!t.hasClass("disabled"),s=t.closest(".pane-legend-wrap");e&&!i?(t.removeClass("disabled"),s.removeClass("disabled")):!e&&i&&(t.addClass("disabled"),s.addClass("disabled"))},s.prototype.valueChanged=function(t,e,i){return t[e]!==i&&(t[e]=i,!0)},s.prototype.firstTitle=function(){return this.$el.find(".pane-legend-line.pane-legend-wrap:first-child")},s.prototype.updateTitle=function(){var e,i,s,n,o,r,a,l,h,d,u,p,c;for(s=this._itemsBinding.length;s--;)i=this._itemsBinding[s],Array.isArray(i.cell)||(i.last||(i.last={}),n=i.last,o=i.source,e=o.properties().visible.value(),this.valueChanged(n,"sourceVisible",e)&&this.setItemEnabled(i.cell,e),r=i.value.color(),a=o!==this._model.mainSeries()&&o===this._model.selectedSource()?"bold":"normal","function"==typeof i.value.getSplitTitle?(u=i.value.getSplitTitle(),l=u[0].trim(),h=u[1].trim(),d=u[2].trim()):(l=i.value.text().trim(),h="",d=""),t.enabled("fundamental_widget")&&(p=this._model.mainSeries(),c=p.symbolInfo(),l=(c?c.name:p.actualSymbol())+" "+l),i.isCellInited||(i.isCellInited=!0,d||h?(i.titleElement=document.createElement("div"),i.titleElement.classList.add("pane-legend-title__container"),i.cell[0].appendChild(i.titleElement),i.descriptionElement=document.createElement("div"),i.descriptionElement.classList.add("pane-legend-title__description"),i.titleElement.appendChild(i.descriptionElement),h&&(i.intervalElement=document.createElement("div"), +i.intervalElement.classList.add("pane-legend-title__interval"),i.titleElement.appendChild(i.intervalElement)),d&&(i.detailsElement=document.createElement("div"),i.detailsElement.classList.add("pane-legend-title__details"),i.titleElement.appendChild(i.detailsElement)),i.titleElement.classList.add("apply-overflow-tooltip","apply-overflow-tooltip--allow-text","apply-overflow-tooltip--check-children")):(i.titleElement=i.cell[0],i.descriptionElement=i.titleElement,i.descriptionElement.classList.add("apply-overflow-tooltip"))),(this.valueChanged(n,"color",r)||this.valueChanged(n,"fontWeight",a))&&(i.titleElement.style.color=r,i.titleElement.style.borderColor=r,i.titleElement.style.fontWeight=a),l!==i.description&&(i.descriptionElement.textContent=TradingView.clean(l,!0),i.description=l),i.intervalElement&&h&&h!==i.interval&&(i.intervalElement.textContent=TradingView.clean(h,!0),i.interval=h),i.detailsElement&&d&&d!==i.details&&(i.detailsElement.textContent=TradingView.clean(d,!0),i.details=d));this._chart.resizeIndicator()},s.prototype.update=function(t){var e,i,s,n,r,a,l,h,d,u,p;for(this.updateTitle(),h=this._itemsBinding.length;h--;)if(n=this._itemsBinding[h],e=n.cell,i=n.titleCells,s=n.source.properties().visible.value(),Array.isArray(e))for(n.last||(n.last={},n.last.dwView||(n.last.dwView={})),d=n.last,r=n.value.items(),u=this.valueChanged(d,"sourceVisible",s),a=0;a'),this._initVisibility(),this.update(),this.jqDiv.appendTo(i)}var n=i(976);s.prototype.update=function(){var t,e,s,n,o,r,a,l=this._paneWidget.state();if(l){if(!this._visible||!this._chart.isActive())return void this.jqDiv[0].classList.add("pane-controls--hidden");if(this.jqDiv[0].classList.remove("pane-controls--hidden"),t=this, +e=t._model,s=e.panes().indexOf(l),this.jqDiv.toggleClass("toppane",0===s||this._chart.isMaximizedPane()),n=!1,!l.containsMainSeries()&&!this._chart.isMaximizedPane()){for(o=0,r=l.dataSources(),a=r.length;a--;)if(r[a]instanceof TradingView.Study&&++o>1){n=!0;break}r=null}s>0&&!this._chart.isMaximizedPane()?(this._$upButton||(this._$upButton=$(document.createElement("a")).addClass("pane-legend-icon up").append($(i(1152)).attr({width:14,height:14})).attr("title",$.t("Move Up")).on("click",function(){t._model.rearrangePanes(t._chart,t._model.panes().indexOf(t._paneWidget.state()),"up")})),this._$upButton.appendTo(this.jqDiv)):this._$upButton&&this._$upButton.detach(),s1&&!this._chart.isMaximizedPane()?(this._$maximizeButton||(this._$maximizeButton=$(document.createElement("a")).addClass("pane-legend-icon maximize").append($(i(1154)).attr({width:14,height:14})).attr("title",$.t("Toggle Maximize Pane")).on("click",function(){t._chart.toggleMaximizePane(t._paneWidget)})),this._$maximizeButton.appendTo(this.jqDiv)):this._$maximizeButton&&this._$maximizeButton.detach(),this._model.panes().length>1&&this._chart.isMaximizedPane()?(this._$restoreButton||(this._$restoreButton=$(document.createElement("a")).addClass("pane-legend-icon restore").append($(i(1155)).attr({width:14,height:14})).attr("title",$.t("Toggle Maximize Pane")).on("click",function(){t._chart.toggleMaximizePane(t._paneWidget)})),this._$restoreButton.appendTo(this.jqDiv)):this._$restoreButton&&this._$restoreButton.detach()}},s.prototype.destroy=function(){this._visibilityProperty&&(this._visibilityProperty.unsubscribe(this,this._onVisibilityPropertyChange),this._visibilityProperty=null),this._boundMouseHandler&&(this._mainDiv[0].removeEventListener("mouseenter",this._boundMouseHandler,!1),this._mainDiv[0].removeEventListener("mouseleave",this._boundMouseHandler,!1),this._boundMouseHandler=null),this.jqDiv.remove()},s.prototype._initVisibility=function(){this._visible=!0,this._visibilityProperty=n.actualBehavior(),this._visibilityProperty.subscribe(this,this._onVisibilityPropertyChange),this._onVisibilityPropertyChange()},s.prototype._onVisibilityPropertyChange=function(){var t=this._visibilityProperty.value() +;"alwaysOn"===t||"alwaysOff"===t?(this._visible="alwaysOn"===t,this._boundMouseHandler&&(this._mainDiv[0].removeEventListener("mouseenter",this._boundMouseHandler),this._mainDiv[0].removeEventListener("mouseleave",this._boundMouseHandler),this._boundMouseHandler=null)):(this._boundMouseHandler||(this._boundMouseHandler=this._visibilityMouseHandler.bind(this),this._mainDiv[0].addEventListener("mouseenter",this._boundMouseHandler),this._mainDiv[0].addEventListener("mouseleave",this._boundMouseHandler)),this._visible=!1),this.update()},s.prototype._visibilityMouseHandler=function(t){this._visible="mouseenter"===t.type,this.update()},t.exports=s},817:function(t,e,i){"use strict";var s,n,o,r,a,l,h,d,u,p,c,_,v,m,g,b,y,w,f,M,B,C,S,x,T;Object.defineProperty(e,"__esModule",{value:!0}),i.d(e,"ControlBarNavigation",function(){return T}),i(11),s=i(1178),i.n(s),n=i(976),o=i(38),r=i(202),a=i(29),l=i(306),h=i(71),i.n(h),i(39),d=i(873),i.n(d),u=i(1179),i.n(u),p=i(1180),i.n(p),c=i(1181),i.n(c),_=i(973),i.n(_),v=i(1182),i.n(v),m=i(1183),i.n(m),g=i(1184),i.n(g),b=i(1185),i.n(b),w=Object(l.b)({keys:["Alt","R"],text:"{0} + {1}"}),f=Object(l.b)({keys:[m],text:"{0}"}),M=Object(l.b)({keys:[g],text:"{0}"}),B='
\n\t
\n\t\t
\n\t\t\t
\n\t\t\t\t'+u+'\n\t\t\t
\n\t\t\t
\n\t\t\t\t'+c+'\n\t\t\t
\n\t\t
\n\t\t
\n\t\t\t
\n\t\t\t\t'+d+'\n\t\t\t
\n\t\t\t
\n\t\t\t\t'+_+'\n\t\t\t
\n\t\t
\n\t\t
\n\t\t\t'+p+"\n\t\t
\n\t
\n
",C='
\n\t'+v+"\n
",y={},y.moving="wait_finishing",y.wait_finishing="stop",y.stop="moving",S=y,x="control-bar__btn--btn-hidden",T=function(){function t(t,e){this._back=null,this._backButtonVisible=!1,this._boundKeydownHandler=null,this._boundKeyupHandler=null,this._boundMouseHandler=null,this._chartBackgroundProperty=null,this._chartModel=null,this._checkIntervalId=0,this._controlBar=null,this._controlBarVisible=!1,this._currentDistance=0,this._deferredFinishTimeout=0,this._finishingTimeout=0,this._moveType="", +this._movingTimeout=0,this._pressedKey=[],this._priceAxisChanged=null,this._resetAvailabilityChanged=null,this._priceAxisName="",this._rafId=0,this._startTime=0,this._state="stop",this._visibilityTypeProperty=null,this._widget=null,this._btnGroups=null,this._chart=t,this._parent=e,this._init(),this._initHandlers()}return t.prototype.destroy=function(){null!==this._visibilityTypeProperty&&(this._visibilityTypeProperty.unsubscribe(this,this._onVisibilityTypeChange),this._visibilityTypeProperty=null),null!==this._boundMouseHandler&&(this._parent.removeEventListener("mousemove",this._boundMouseHandler,!1),this._parent.removeEventListener("mouseleave",this._boundMouseHandler,!1),this._boundMouseHandler=null),null!==this._boundKeydownHandler&&(this._parent.ownerDocument.removeEventListener("keydown",this._boundKeydownHandler),this._boundKeydownHandler=null),null!==this._boundKeyupHandler&&(this._parent.ownerDocument.removeEventListener("keyup",this._boundKeyupHandler),this._boundKeyupHandler=null),clearTimeout(this._movingTimeout),null!==this._priceAxisChanged&&(this._priceAxisChanged.unsubscribe(this,this._updateBackBtnPosition),this._priceAxisChanged=null),null!==this._chartBackgroundProperty&&(clearInterval(this._checkIntervalId),this._chartBackgroundProperty.unsubscribe(this,this._updateBgBarStyle),this._chartBackgroundProperty=null),null!==this._resetAvailabilityChanged&&(this._resetAvailabilityChanged.unsubscribe(this,this._updateResetScalesButtonVisibility),this._resetAvailabilityChanged=null),this._chart=null},t.prototype.updatePosition=function(t){null!==this._widget&&null!==this._controlBar&&this._updateBtnGroupVisibility(t)},t.prototype._init=function(){var t,e,i,s=this;if(this._widget=Object(r.a)(B).querySelector(".control-bar-wrapper"),this._back=Object(r.a)(C).querySelector(".control-bar__btn--back-present"),this._controlBar=this._widget.querySelector(".control-bar"),this._btnGroups=Array.from(this._controlBar.querySelectorAll(".js-btn-group")),h.CheckMobile.any())for(t=0,e=this._btnGroups;t=i.left-100&&t.clientX<=i.right+100&&t.clientY>=i.top-100&&t.clientY<=i.bottom+100),this._controlBarVisible!==e&&(this._controlBarVisible=e,null!==this._controlBar&&null===this._rafId&&(this._rafId=this._controlBar.ownerDocument.defaultView.requestAnimationFrame(this._updateControlBarVisibility.bind(this)))))},t.prototype._updateControlBarVisibility=function(){this._rafId=null,null!==this._controlBar&&this._controlBar.classList.toggle("control-bar--hidden",!this._controlBarVisible)},t.prototype._updateBackBtnPosition=function(){if("left"===this._priceAxisName||"right"===this._priceAxisName){var t=this._chart.getPriceAxisMaxWidthByName(this._priceAxisName)+14;t&&null!==this._back&&(this._back.style.marginRight=t+"px")}},t.prototype._updateBgBarStyle=function(){var t,e,i,s;if(null!==this._chartModel){for(t=Object(a.getLuminance)(this._chartModel.model().properties().paneProperties.background.value())<.5,e=0,i=Object.values(this._buttons);e0?86*e.length:50,this._widget.style.left="calc(50% - "+Math.ceil(t/2)+"px)")},t.prototype._updateResetScalesButtonVisibility=function(){if(null!==this._chartModel){var t=this._chartModel.model().isScalesResetAvailable();this._buttons.turn.classList.toggle(x,!t)}},t.prototype._move=function(t){var e,i,s,n=this;null!==this._chartModel&&"stop"===this._state&&this._chartModel.beginUndoMacro(1===t?"Move Left":"Move Right"),this._state=S.stop,this._moveType="animated",this._deferredFinishTimeout&&(clearTimeout(this._deferredFinishTimeout),this._deferredFinishTimeout=0),this._finishingTimeout&&(clearTimeout(this._finishingTimeout),this._finishingTimeout=0),this._startTime=Date.now(),0===this._movingTimeout&&(e=this._startTime,i=10,s=function(){n._moveStep(e,0,50*t,1e3),n._movingTimeout=setTimeout(s.bind(n),i)},this._movingTimeout=setTimeout(s.bind(this),i))},t.prototype._moveStep=function(t,e,i,s){var n,o,r;return null===this._chartModel||this._chartModel.timeScale().isEmpty()?void 0:(n=Date.now(),n1||!isFinite(o))&&(o=1),r=1-Math.pow(1-o,3),this._currentDistance=(i-e)*r+e, +this._chartModel.scrollChart(this._currentDistance),o)},t.prototype._finishMove=function(){var t,e,i,s=this;clearTimeout(this._movingTimeout),this._movingTimeout=0,this._deferredFinishTimeout=0,t=this._currentDistance,e=Date.now(),i=function(){var n=s._moveStep(e,t,0,700);n&&n<1?s._finishingTimeout=setTimeout(i.bind(s),10):null!==s._chartModel&&(s._state=S.wait_finishing,s._moveType="",s._movingTimeout=0,s._currentDistance=0,s._chartModel.endUndoMacro())},this._finishingTimeout=setTimeout(i.bind(this),10)},t.prototype._stopMove=function(){"moving"===this._state&&(this._state=S.moving,Date.now()-this._startTime<200?this._deferredFinishTimeout=setTimeout(this._finishMove.bind(this),200-(Date.now()-this._startTime)):this._finishMove())},t.prototype._moveByBar=function(t){var e,i,s,n,o,r,a=this;if(null!==this._chartModel){if(e=this._chartModel.timeScale(),e.isEmpty())return;"stop"===this._state&&this._chartModel.beginUndoMacro(1===t?"Move Left":"Move Right"),null!==e.visibleBars()&&(i=e.indexToCoordinate(e.visibleBars().lastBar())+e.barSpacing()/2,Math.abs(e.width()-i)>e.barSpacing()/6&&this._chartModel.scrollChart(e.width()-i)),this._state=S.stop,this._moveType="by_bar",this._startTime=Date.now(),this._movingTimeout||(s=0,n=150,o=400,r=function(){a._moveByBarStep(t),s++,n>100&&(n-=s/5*20),a._movingTimeout=setTimeout(r,n)},this._movingTimeout=setTimeout(r,o),this._moveByBarStep(t))}},t.prototype._moveByBarStep=function(t){if(null!==this._chartModel){if(this._chartModel.timeScale().isEmpty())return;this._chartModel.scrollChartByBar(t)}},t.prototype._stopMoveByBar=function(){"moving"===this._state&&(clearTimeout(this._movingTimeout),this._movingTimeout=0,this._state=S.wait_finishing,this._moveType="",this._movingTimeout=0,this._currentDistance=0,null!==this._chartModel&&this._chartModel.endUndoMacro())},t.prototype._keydownHandler=function(t){var e,i;t.metaKey||37!==(e=t.which)&&39!==e||this._pressedKey[e]||(this._pressedKey[e]=!0,t.target.closest("input, textarea")||(i=37===e?1:-1,t.ctrlKey||t.altKey?this._move(i):this._moveByBar(i),t.preventDefault()))},t.prototype._keyupHandler=function(t){var e=t.which;37!==e&&39!==e||t.target.closest("input, textarea")||(this._pressedKey[t.which]=!1,"by_bar"===this._moveType?this._stopMoveByBar():this._stopMove())},t.prototype._trackEvent=function(t){},t}()},873:function(t,e){t.exports=''},973:function(t,e){t.exports=''},976:function(t,e,i){"use strict";function s(t){return"alwaysOn"===t||"alwaysOff"===t?t:"visibleOnMouseOver"}function n(){if(!u){var t="NavigationButtons.visibility";u=new h.a,u.setValue(s(d.getValue(t))),u.subscribe(u,function(e){d.setValue(t,s(e.value()))})}return u}function o(){ +return[{value:"visibleOnMouseOver",title:window.t("Visible on Mouse Over")},{value:"alwaysOn",title:window.t("Always Visible")},{value:"alwaysOff",title:window.t("Always Invisible")}]}function r(){var t,e;return p||(p=new h.a,t=n(),e=function(){var e=t.value();"alwaysOn"!==e&&"alwaysOff"!==e&&(e=Modernizr.touch?"alwaysOn":"visibleOnMouseOver"),p&&p.setValue(e)},t.subscribe(p,e),e()),p}var a,l,h,d,u,p;Object.defineProperty(e,"__esModule",{value:!0}),e.property=n,e.availableValues=o,e.actualBehavior=r,i(11),a=i(127),i.n(a),l=i(13),h=i.n(l),d=i(49),i.n(d)}}); \ No newline at end of file diff --git a/charting_library/static/bundles/confirm-inputs-dialog.e8333025d1520384f361.js b/charting_library/static/bundles/confirm-inputs-dialog.e8333025d1520384f361.js new file mode 100644 index 00000000..72393ed0 --- /dev/null +++ b/charting_library/static/bundles/confirm-inputs-dialog.e8333025d1520384f361.js @@ -0,0 +1,28 @@ +webpackJsonp([16,2],{188:function(t,e,i){"use strict";function o(t){var e=t.type||"popup";return delete t.type,"modal"===e?new n.TVModal(t):new s.TVPopup(t)}var n,s;Object.defineProperty(e,"__esModule",{value:!0}),n=i(837),s=i(843),e.createDialog=o},690:function(t,e,i){"use strict";var o;Object.defineProperty(e,"__esModule",{value:!0}),o=i(839),i.n(o),i.o(o,"TVDialogAbstract")&&i.d(e,"TVDialogAbstract",function(){return o.TVDialogAbstract}),i.o(o,"closeAllDialogs")&&i.d(e,"closeAllDialogs",function(){return o.closeAllDialogs})},692:function(t,e,i){(function(t){function o(t,e,i,o,n){h.call(this,t,e),this._study=i,this._showOnlyConfirmInputs=o,this._symbolSearchZindex=n,this.prepareLayout(),this._$symbolSearchPopup=null}var n=i(823),s=n.UppercaseTransformer,r=n.SymbolBinder,a=n.BarTimeBinder,l=n.SessionBinder,h=n.PropertyPage,c=n.GreateTransformer,u=n.LessTransformer,d=n.ToIntTransformer,p=n.ToFloatTransformer,f=n.SymbolInfoSymbolTransformer,_=n.SimpleComboBinder,v=n.BooleanBinder,g=n.SimpleStringBinder,y=i(128).bindToInput,m=i(105).NumericFormatter,b=i(26),C=i(4).getLogger("Chart.Study.PropertyPage.Inputs");inherit(o,h),o.prototype._addSessionEditor=function(t,e,i,o){var n,s,r,a,h,c;if("session"!==i.type)return void C.logError("Session editor adding FAILED: wrong input type.");n=function(t,e){var i,o=$("");o.appendTo(t),o.css("padding-left","0px"),o.css("padding-right","0px"),i=$(""),i.attr("type","text"),i.addClass("ticker"),i.css("width","40px"),i.attr("id",e),i.appendTo(o)},s=function(t,e,i){var o,n=$("");n.css("padding-left",i),n.css("padding-right",i),n.appendTo(t),o=$("
"),o.appendTo(n),o.append(e),o.css("font-size","150%")},r=$(""),r.appendTo(t),a=$(""),a.appendTo(r),h=["start_hours","start_minutes","end_hours","end_minutes"],n.call(this,a,h[0]),s.call(this,a,":",0),n.call(this,a,h[1]),s.call(this,a,"-",4),n.call(this,a,h[2]),s.call(this,a,":",0),n.call(this,a,h[3]),c=!1,this.bindControl(new l(a,h,e,c,this.model(),o))},o.prototype.prepareControl=function(e,i,o){function n(t){return function(e){var i,o,n,s=this,r=null;if(0===e.indexOf("#")){if(i=e.slice(1,e.indexOf("$")),null===(o=I._model.model().getStudyById(i)))return void C.logError("Can not get Study by id "+i);if(o.isStarted()||o.start(null,!0),!(n=o.sourceId()))return void C.logError("Can not get source id for "+o.metaInfo().id);r=e.replace(/^[^\$]+/,n)}!~e.indexOf("$")&&!~e.indexOf("#")||I._study.isStarted()||I._study.start(null,!0),I._study.testInputValue(t,e)?s.setValueToProperty(r||s.value()):s.setValue(I._property.inputs[t.id].value())}}function s(t){return function(e){var i,o,n,s;if(t.hasOwnProperty(e)||0===e.indexOf("#")||!~e.indexOf("$"))return e;for(i=e.slice(0,e.indexOf("$")),o=I._model.model().allStudies(),n=0;n");else if("symbol"===e.type)V=$(''),y(V,{onPopupOpen:function(t){this._$symbolSearchPopup=t,this._symbolSearchZindex&&t.css("z-index",this._symbolSearchZindex)}.bind(this),onPopupClose:function(){this._$symbolSearchPopup=null}.bind(this)}),i.attr("colspan",5);else if("session"===e.type)this._addSessionEditor(i,this._property.inputs[e.id],e,o);else if("source"===e.type){for(r={},a={open:window.t("open"),high:window.t("high"),low:window.t("low"),close:window.t("close"),hl2:window.t("hl2"),hlc3:window.t("hlc3"),ohlc4:window.t("ohlc4")},l=Object.keys(a),h=0;h").attr("value",M).text(P).appendTo(V);i.addClass("js-value-cell")}else if(e.options)for(V=$(""),"bool"===e.type?V.attr("type","checkbox"):V.attr("type","text");return V&&(V.appendTo(i),V.is(":checkbox")||"symbol"===e.type||V.css("width","100px")),{valueEditor:V,valueSetter:E,propertyChangedHook:B}},o.prototype._symbolInfoBySymbolProperty=function(t){return this._study.resolvedSymbolInfoBySymbol(t.value())},o.prototype._sortInputs=function(t){return t},o.prototype.prepareLayoutImpl=function(t,e){function i(t){return(new m).format(t)}var o,n,l,h,y,b,C,w,T,k,x,S,O,M,P,I,V,E,B=this._sortInputs(t.inputs);for(o=0;o"),b.appendTo(e),C=$("
"),C.appendTo(b),C.addClass("propertypage-name-label"),C.text(window.t(h,{context:"input"})),w=$(""),w.appendTo(b),T=this.prepareControl(n,w,y),k=T.valueEditor,x=T.valueSetter,S=T.propertyChangedHook,n.options?this.bindControl(new _(k,this._property.inputs[l],null,!0,this.model(),y,x,S)):"bar_time"===n.type?(O=10,this.bindControl(new a(k,this._property.inputs[l],!0,this.model(),y,this.model().mainSeries(),O)),k.addClass("ticker")):"integer"===n.type?(M=[d(n.defval)],(0===n.min||n.min)&&M.push(c(n.min)),(0===n.max||n.max)&&M.push(u(n.max)),this.bindControl(new g(k,this._property.inputs[l],M,!1,this.model(),y)),k.addClass("ticker"),isFinite(n.step)&&n.step>0&&k.attr("data-step",n.step)):"float"===n.type?(M=[p(n.defval)],(0===n.min||n.min)&&M.push(c(n.min)),(0===n.max||n.max)&&M.push(u(n.max)),P=new g(k,this._property.inputs[l],M,!1,this.model(),y),P.addFormatter(i),this.bindControl(P),k.addClass("ticker"),isFinite(n.step)&&n.step>0&&k.attr("data-step",n.step)):"text"===n.type?this.bindControl(new g(k,this._property.inputs[l],null,!1,this.model(),y)):"bool"===n.type?this.bindControl(new v(k,this._property.inputs[l],!0,this.model(),y)):"resolution"===n.type?this.bindControl(new _(k,this._property.inputs[l],s,!0,this.model(),"Change Interval")):"symbol"===n.type&&(I=this._symbolInfoBySymbolProperty.bind(this,this._property.inputs[l]),V=f(I,this._property.inputs[l]),E=new r(k,this._property.inputs[l],!0,this.model(),"Change Symbol",V,this._study.symbolsResolved()),this.bindControl(E))));this._property.offset&&(h=this._property.offset.title?this._property.offset.title.value():window.t("Offset"),k=this.addOffsetEditorRow(e,h),M=[d(this._property.offset.val)],M.push(c(this._property.offset.min)),M.push(u(this._property.offset.max)),this.bindControl(new g(k,this._property.offset.val,M,!1,this.model(),"Undo "+h))),this._property.offsets&&$.each(t.plots,function(t,i){var o,n,s;this._property.offsets[i.id]&&(o=this._property.offsets[i.id],void 0!==o.isHidden&&o.isHidden.value()||(n=o.title.value(),k=this.addOffsetEditorRow(e,n),s=[d(o.val)],s.push(c(o.min)),s.push(u(o.max)),this.bindControl(new g(k,o.val,s,!1,this.model(),"Undo "+n))))}.bind(this))},o.prototype.prepareLayout=function(){this._table=$(""),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2");var t=this._study.metaInfo();this.prepareLayoutImpl(t,this._table),this.loadData()},o.prototype.symbolSearchPopup=function(){return this._$symbolSearchPopup},o.prototype.widget=function(){return this._table},e.StudyInputsPropertyPage=o}).call(e,i(5))},695:function(t,e,i){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}function n(t,e){var i,o,n,s,h,p,f,_,v,g,y,m=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};for(m=$.extend({},{title:$.t("Confirm Inputs"),callback:function(t){}},m),i=null,o=(0,r.createDialog)({title:m.title,contentWrapTemplate:'
',width:u, +closeOnClickAtOtherDialogs:!0,destroyOnClose:!0,actionsWrapTemplate:'
',isClickOutFn:function(t){var e=i.symbolSearchPopup();if(e)return e[0]!==t.target&&!e[0].contains(t.target)&&void 0},actions:[{name:"apply",type:"primary",text:$.t("Apply"),key:13}]}),d=o,n=(0,l.merge)({},e.defaults.inputs),s=0;su&&o.$el.css("max-width",y),_.find("input,select").first().focus()}function s(){return d}var r,a,l,h,c,u,d;Object.defineProperty(e,"__esModule",{value:!0}),e.show=n,e.instance=s,r=i(188),a=i(692),l=i(12),h=i(13),c=o(h),i(845),u=450,d=null},823:function(t,e,i){"use strict";(function(t){function o(t,e){return'"}function n(t,e){this._model=e,this._bindings=[],this._property=t,this.supportThemeSwitcher=!1}function s(t){return t.toUpperCase()}function r(t){return function(e){return et?t:e}}function l(t){return function(e){var i=parseInt(e,10);return B(i)?t:i}}function h(t){var e=new D;return function(i){var o=e.parse(i);return B(o)?t:o}}function c(t){var e=new D;return function(i){var o=e.parse(i);return B(o)?t():o}}function u(t,e){var i=new z(e);return function(e){var o=i.format(e);return B(o)?t:o}}function d(){return function(t){for(var e=t,i=t.replace(/[^\u0000-\u007F]/,"");i.length!==e.length;)e=i,i=e.replace(/[^\u0000-\u007F]/,"");return i}}function p(t){return function(e){return 0===e.length?t:e}}function f(t,e){return function(i){var o=t();return i===e.value()&&o&&(o.ticker||o.full_name)?o.ticker||o.full_name:i}}function _(t,e,i,o,n,s,r){U.call(this,t,e,o,n,s),this._transformFunction=i,this._setter=r,this._attachToControl(t,o)}function v(t,e,i,o,n){_.call(this,t,e,h(e.value()),i,o,n),this.addFormatter(function(t){return(new D).format(t)})}function g(t,e,i,o,n,s){this._subControlIds=e,U.call(this,t,i,o,n,s),this._forEachSubControl(function(t){this._attachToControl(t,o)})}function y(t,e,i,o,n,s,r){this._model=o,this._mainSeries=s,this._toIntTransformer=l(r),this._disabled=!1,U.call(this,t,e,i,o,n);var a=this;i&&t.change(function(){a.setValueToProperty(a.value())}),this._mainSeries.dataEvents().barReceived().subscribe(this,function(){ +a.setValue(this.property().value())})}function m(t,e,i,o,n,s,r){U.call(this,t,e,i,o,n),this._transform=s,i&&t.on("accept-symbol",function(t,e){this.setValueToProperty(e),this.setValue(e)}.bind(this)),r&&(r.subscribe(this,this._updateDisplayedSymbol),this._updateDelegate=r)}function b(t,e,i,o,n,s,r,a){U.call(this,t,e,o,n,s),this._transformFunction=i,this._propertyChangedHook=a,this._setter=r;var l=this;o&&t.change(function(){l._setter?l._setter.call(l,l.value()):l.setValueToProperty(l.value())})}function C(t,e){U.call(this,t,e)}function w(t,e,i,o,n,s){if(!t.is(":checkbox, :radio"))return new k(t,e,i,o,n);U.call(this,t,e,i,o,n),this._setter=s;var r=this;i&&t.change(function(){r._setter?r._setter.call(r,r.value()):r.setValueToProperty(r.value())})}function T(t,e,i,o,n,s){U.call(this,t,e,i,o,n),this._inverted=!0===s}function k(t,e,i,o,n){U.call(this,t,e,i,o,n);var s=this;i&&t.click(function(){var t=$(this).toggleClass("active").hasClass("active");s.setValueToProperty(t)})}function x(t,e,i,o,n,s){var r,a;r=t.is("input")?t:t.find("input"),U.call(this,r,e,i,o,n),this._transparencyProperty=s,this.applyOldTransparency(),a=this,i&&r.change(function(){a.setValueToProperty(a.value())})}function S(e,i,o,n,s,r){function a(t,e){var i=h.control().slider("option","min"),o=h.control().slider("option","max"),n=h._property.value();(i<=n&&n<=o||il._transformers[1]&&$(s[1]).val(l._transformers[1]),-1!==$.inArray(t.keyCode,[46,8,9,27,13,110,190])||65===t.keyCode&&!0===t.ctrlKey||67===t.keyCode&&!0===t.ctrlKey||88===t.keyCode&&!0===t.ctrlKey||t.keyCode>=35&&t.keyCode<=39||(t.shiftKey||t.keyCode<48||t.keyCode>57)&&(t.keyCode<96||t.keyCode>105)&&t.preventDefault()})}),$(s[0]).on("keyup",function(t){parseInt($(this).val())l._transformers[1]&&$(this).val(l._transformers[1]),parseInt($(this).val())>parseInt($(s[1]).val())&&$(this).val(s[1].val()),l._control.slider("values",0,$(this).val()),I.prototype.setValueToProperty.call(l,l._control.slider("values"),"from")}),$(s[1]).on("keyup",function(t){parseInt($(this).val())l._transformers[1]&&$(this).val(l._transformers[1]),parseInt($(this).val())<$(s[0]).val()&&$(this).val(s[0].val()),l._control.slider("values",1,$(this).val()),I.prototype.setValueToProperty.call(l,l._control.slider("values"),"to")})),this._propFrom.listeners().subscribe(this,I.prototype.propertyChanged),this._propTo.listeners().subscribe(this,I.prototype.propertyChanged),o&&t.on("slide",function(t,e){l.setValueToProperty(l._control.slider("values"),e.handle)}),t.slider({stop:function(t,e){s&&($(s[0]).val(l._control.slider("values",0)),$(s[1]).val(l._control.slider("values",1))),l.setValueToProperty(l._control.slider("values"),e.handle)},start:function(t,e){s&&($(s[0]).val(l._control.slider("values",0)),$(s[1]).val(l._control.slider("values",1))),l.setValueToProperty(l._control.slider("values"),e.handle)}})}function V(t,e,i,o,n,s){U.call(this,t,e,i,o,n),this._separator=s||" ";var r=this;i&&t.change(function(){r.setValueToProperty(r.value())})}var E,B,j,H,A,F,W,D,z,L,R,U,N;i(866),E=i(7).ensureNotNull,B=i(83).isNaN,j=i(24),H=j.rgba,A=j.rgbaToString,F=j.parseRgb,W=i(72).TimePointIndexSearchMode,D=i(105).NumericFormatter,z=i(193).LimitedPrecisionNumericFormatter,L=i(29),R=i(829).addColorPicker,U=i(317).Binding,N=i(4).getLogger("Chart.PropertyPage"),n.prototype.model=function(){return this._model},n.prototype.bindControl=function(t){return this._bindings.push(t),t},n.prototype.unbindControl=function(t){var e=this._bindings.indexOf(t);-1!==e&&this._bindings.splice(e,1)},n.prototype.loadData=function(){var t,e,i;for(t=0;t',t).slider({max:4,min:1,step:1})},n.prototype.createColorPicker=function(t){return R(null,t)},n.prototype.createTextEditor=function(t,e){var i={};return t&&(i.width=t),e&&(i.height=e),$(document.createElement("textarea")).css(i).addClass("tv-control-input")},n.prototype.createCombo=function(t){var e=$(document.createElement("select")),i=t.reduce(function(t,e){return t.add($(document.createElement("option")).prop({value:e,text:e}))},$());return e.append(i)},n.prototype.createKeyCombo=function(t){var e=$(document.createElement("select"));return $.each(t||[],function(t,i){$(document.createElement("option")).prop({value:t,text:i}).appendTo(e)}),e},n.prototype.createFontEditor=function(t){var e=t||TradingView.factoryDefaults("chartproperties.editorFontsList");return this.createCombo(e)},n.prototype.createFontSizeEditor=function(t){var e=t||[10,11,12,14,16,20,24,28,32,40];return this.createCombo(e).addClass("tv-select-container-fontsize")},n.prototype.createSeriesMinTickEditor=function(){var t,e,i,o,n="",$(n)},n.prototype.createPrecisionEditor=function(){var t,e="",$(e)},n.prototype.createLabeledCell=function(t,e,i){var o,n,s,r,a=null;return"number"==typeof t.valueOf()?(a=t,o=e,n=i):(o=t,n=e),o+="",s=this._labelToId(o),r=$("
").appendTo(t),i=$("
"),$("
").appendTo(e);return $('').appendTo(i)},n.prototype._labelToId=function(t){return"control"+t.replace(/(^| )\w/g,function(t){return"-"+t.trim().toLowerCase() +})+Math.floor(1e3*Math.random())},n.prototype.addRow=function(t){return $(document.createElement("tr")).appendTo(t)},n.prototype.addLabeledRow=function(t,e,i,n){var s,r=e&&e.length>0?$.t(e):"",a=$(document.createElement("tr")),l=$(document.createElement("td")).html(r);return n&&(n=parseInt(n),B(n)&&(n=2),l.attr("colspan",n)),i&&(s=this._labelToId(e),i.attr("id",s),l.html(o(r,s))),a.append(l).appendTo(t)},n.prototype.addEditorRow=function(t,e,i,o){var n=$(document.createElement("td"));return i.row=this.addLabeledRow(t,e,i,o),i.appendTo(n.appendTo(i.row)),i},n.prototype.addColorPickerRow=function(t,e){return this.addEditorRow(t,e,this.createColorPicker())},n.prototype.addOffsetEditorRow=function(t,e){var i=$("");return i.attr("type","text"),i.css("width","100px"),i.addClass("ticker"),this.addEditorRow(t,e,i)},n.prototype.addFontEditorRow=function(t,e){return this.addEditorRow(t,e,this.createFontEditor())},n.prototype.refreshStateControls=function(t,e,i){var o,n,s;for(o=0;o0&&(i=e[0],this._control.selectbox("change",i.value,i.text))}catch(t){}},b.prototype.propertyChanged=function(t){var e=t.value();"function"==typeof this._propertyChangedHook&&(e=this._propertyChangedHook(e)),this.setValue(e)},inherit(C,U),C.prototype.value=function(){return this._property.value()},C.prototype.setValue=function(t){return this._control.html(t)},inherit(w,U),w.prototype.value=function(){return this.control().is(":checked")},w.prototype.setValue=function(t){var e,i,o,n;return this.control().is(".visibility-checker")&&(t?(this.control().closest("tr").find(".slider-range").slider("enable"),this.control().closest("tr").find('input[type="text"]').each(function(){$(this).prop("disabled",!1)})):(this.control().closest("tr").find(".slider-range").slider("disable"),this.control().closest("tr").find('input[type="text"]').each(function(){$(this).prop("disabled",!0)}))),this.control().is(".visibility-switch")&&(e={opacity:t?1:.5},i=t?"enable":"disable",o=this.control().data("hides"),o?o.closest("td").css(e):(n=this.control(),n.parent().parent().data("visible",t).find("td").filter(function(){var t=$(this);return!t.find("label").length&&t.find(":checkbox").attr("id")!==n.attr("id")}).each(function(){var o=$(this);o.children().each(function(){var n=$(this);n.is(".ui-slider")?n.slider(i):n.is("select")?(n.selectbox(i),o.css(e)):n.is(".custom-select")?(n.data(i)(),o.css(e)):n.is(".tvcolorpicker-container")?(n.find("input").prop("disabled",!t),o.css(e)):(n.prop("disabled",!t),o.css(e))})}))),this.control().attr("checked",!!t)},w.prototype.destroy=function(){U.prototype.destroy.call(this), +this._control.off("change")},inherit(T,U),T.prototype.value=function(){return this.control().is(":disabled")},T.prototype.setValue=function(t){return t=!!t,this._inverted&&(t=!t),this.control().parents("label").toggleClass("disabled",t),this.control().attr("disabled",t)},inherit(k,U),k.prototype.value=function(){return this.control().hasClass("active")},k.prototype.setValue=function(t){return this.control().toggleClass("active",!!t)},inherit(x,U),x.prototype.applyOldTransparency=function(){var t,e,i;this.transparencyProperty()&&(L.isHexColor(this.property().value())?(t=this.transparencyProperty().value?this.transparencyProperty().value():this.transparencyProperty(),e=F(this.property().value()),i=(100-t)/100,this.control().val(A(H(e,i)))):this.control().val(this.property().value()),this.control().change())},x.prototype.transparencyProperty=function(){return this._transparencyProperty},x.prototype.value=function(){return this._control.val()},x.prototype.setValue=function(t){this._control.val(t),this._control.change(),this._control.color&&this._control.color.fromString(t)},inherit(S,U),S.prototype.value=function(){return this._control.slider("option","value")},S.prototype.setValue=function(t){this._control.slider("option","value",t)},inherit(O,w),O.prototype.onIntervalChanged=function(){+this._intervalProperty.value()<1440?this._control.attr({disabled:!1,checked:!!this._property.value()}):this._control.attr({disabled:!0,checked:!1})},O.prototype.value=function(){return this._control.is(":disabled")?this._property.value():w.prototype.value.call(this)},O.prototype.setValue=function(t){if(!this._control.is(":disabled"))return w.prototype.setValue.call(this,t)},O.prototype.destroy=function(){this._intervalProperty.listeners().unsubscribe(this,this.onIntervalChanged),delete this._intervalProperty,w.prototype.destroy.call(this,arguments)},M.prototype._attachToControl=function(t){var e=this;this._wv.subscribe(this._setValueBinded,{callWithLast:!0}),$(this._control).on("change",function(){e.setValueToProperty(e.value())})},M.prototype.control=function(){return this._control},M.prototype.value=function(){var t=$(this._control).val();return this._transformFunction&&(t=this._transformFunction(t)),t},M.prototype.setValue=function(t){$(this._control).val(t)},M.prototype.setValueToProperty=function(t){this._undoModel.undoHistory.setWatchedValue(this._wv,t,this._undoText)},M.prototype.watchedValue=function(){return this._wv},M.prototype.destroy=function(){this._wv.unsubscribe(this._setValueBinded)},inherit(P,M),P.prototype._attachToControl=function(t){var e=this;this._wv.subscribe(this.setValue.bind(this),{callWithLast:!0}),$(this._control).on("click",function(){e.setValueToProperty(e.value())})},P.prototype.value=function(){var t=$(this._control).attr("checked");return this._not&&(t=!t),this._transformFunction&&(t=this._transformFunction(t)),t},P.prototype.setValue=function(t){this._not&&(t=!t),$(this._control).attr("checked",!!t)},I.prototype.properties=function(){return this._properties},I.prototype.value=function(t){ +return this._control.slider("values",t)},I.prototype.setValue=function(t,e){this._control.slider("values",e,t.value()),this._inputsText&&$(this._inputsText[e]).val(t.value())},I.prototype.propertyChanged=function(t){this.setValue(t)},I.prototype.setValueToProperty=function(t,e){($(e).hasClass("from")||"from"===e)&&(this._undoModel.beginUndoMacro(this._undoText[0]),this._undoModel.setProperty(this._propFrom,t[0],this._undoText[0]),this._propFrom.setValue(t[0],0),this._undoModel.endUndoMacro()),($(e).hasClass("to")||"to"===e)&&(this._undoModel.beginUndoMacro(this._undoText[1]),this._undoModel.setProperty(this._propTo,t[1],this._undoText[1]),this._propTo.setValue(t[1],1),this._undoModel.endUndoMacro())},I.prototype.destroy=function(){this._propFrom&&this._propTo&&(this._propFrom.listeners().unsubscribe(this,U.prototype.propertyChanged),this._propTo.listeners().unsubscribe(this,U.prototype.propertyChanged))},inherit(V,U),V.prototype.value=function(){var t=[];return this._control.each(function(){var e=$(this);e.is(":checked")&&t.push(e.attr("value"))}),t.join(this._separator)},V.prototype.setValue=function(t){var e=t.split(this._separator).filter(Boolean);this._control.each(function(){var t=$(this),i=-1!==e.indexOf(t.attr("value"));t.attr("checked",i),t.parents("label").toggleClass("active",i)})},e.PropertyPage=n,e.UppercaseTransformer=s,e.GreateTransformer=r,e.LessTransformer=a,e.ToIntTransformer=l,e.ToFloatTransformer=h,e.ToFloatTransformerWithDynamicDefaultValue=c,e.ToFloatLimitedPrecisionTransformer=u,e.ToAsciiTransformer=d,e.ReplaceEmptyTransformer=p,e.SymbolInfoSymbolTransformer=f,e.SimpleStringBinder=_,e.FloatBinder=v,e.SessionBinder=g,e.BarTimeBinder=y,e.SymbolBinder=m,e.SimpleComboBinder=b,e.StaticContentBinder=C,e.BooleanBinder=w,e.DisabledBinder=T,e.ColorBinding=x,e.SliderBinder=S,e.CheckboxWVBinding=P,e.RangeBinder=I,e.generateLabelElementStr=o}).call(e,i(13))},827:function(t,e,i){"use strict";function o(t){return t in $.fn?Promise.resolve():(r||(r=new Promise(function(t){i.e(31).then(function(e){i(831),t()}.bind(null,i)).catch(i.oe)})),r)}function n(t){return new a(t)}var s,r,a;Object.defineProperty(e,"__esModule",{value:!0}),i.d(e,"LazyJqueryUI",function(){return a}),e.lazyJqueryUI=n,s=i(14),i.n(s),a=function(){function t(t){this._$elem=t}return t.prototype.draggable=function(){var t=arguments,e=this._$elem;return o("draggable").then(function(){return e.draggable.apply(e,t)})},t.prototype.resizable=function(){var t=arguments,e=this._$elem;return o("resizable").then(function(){return e.resizable.apply(e,t)})},t.prototype.sortable=function(){var t=arguments,e=this._$elem;return o("sortable").then(function(){return e.sortable.apply(e,t)})},t.prototype.datepicker=function(){var t=arguments,e=this._$elem;return o("datepicker").then(function(){return e.datepicker.apply(e,t)})},t}()},828:function(t,e){ +t.exports=''},829:function(t,e,i){"use strict";function o(t){var e=Object(l.parseRgb)(t),i=e.map(function(t){return t>50?t-50:0});return Object(l.rgbToString)(i)}function n(t){var e,i,o,n=[];for(e=0,i=t;e');return null!==t&&i.appendTo(t),void 0!==e.addClass&&i.addClass(e.addClass),$('
').appendTo(i),$('').tvcolorpicker({customColors:n(Object(h.getJSON)("pickerCustomColors",[])),direction:e.direction,hideTransparency:!!e.hideTransparency}).on("change",function(){$(this).css("border-color",o($(this).val()||c))}).bind("customcolorchange",function(t,e){Object(h.setJSON)("pickerCustomColors",e)}).appendTo(i),i}var r,a,l,h,c;Object.defineProperty(e,"__esModule",{value:!0}),e.addColorPicker=s,r=i(14),i.n(r),a=i(316),i.n(a),l=i(24),i.n(l),h=i(49),i.n(h),c="#727272"},832:function(t,e,i){"use strict";(function(o){function n(t){return t&&t.__esModule?t:{default:t}}function s(){var t,e,i=c.width();for(d.width=i,d.height=c.height(),t=0;tt.height()},breakpoints:l.breakpoints,widgetbarBreakpoint:1064,setFixedBodyState:function(t){var e,i;t&&1==++u?("hidden"!==$(document.body).css("overflow").toLowerCase()&&document.body.scrollHeight>document.body.offsetHeight&&($(".widgetbar-wrap").css("right",d.getScrollbarWidth()),h.css("padding-right",parseInt(h.css("padding-right").replace("px",""))+d.getScrollbarWidth()+"px").data("wasScroll",!0)),h.addClass("i-no-scroll")):!t&&u>0&&0==--u&&(h.removeClass("i-no-scroll"),h.data("wasScroll")&&(e=h.get(0),$(".widgetbar-wrap").css("right",0),i=$(".widgetbar-wrap").width()||0,e.scrollHeight<=e.clientHeight&&(i-=d.getScrollbarWidth()), +h.css("padding-right",(i<0?0:i)+"px").data("wasScroll",void 0)))}},p=Object.keys(d.breakpoints).sort(function(t,e){return d.breakpoints[t]-d.breakpoints[e]}),o.extend(d,a.default.prototype),s(),$(s),c.on("resize",s),e.default=d,t.exports=e.default}).call(e,i(187))},833:function(t,e,i){"use strict";(function(t){function o(e,i,o){var n,s,r,a,l,h,c=this;if(this._options=$.extend({},this._defaultOptions,o||{}),this._$wrapper=e,this._$content=i,this._scroll_speed=40,this._shadow_offset=10,this._header_height=this._options.headerHeight,this._scroll_margin_top=this._options.scrollMarginTop,this.scrolled=new t,this.scrolltoend=new t,this.scrolltostart=new t,this.visibilityCallbacks=[],n=navigator.platform.toLowerCase(),s=navigator.userAgent.toLowerCase(),r=s.indexOf("firefox")>-1,a=n.indexOf("android")>-1||s.indexOf("android")>-1,this._touch=Modernizr.touch||navigator.msMaxTouchPoints||r&&a,this._touch)return this._$content.css("position","relative"),void this._$wrapper.css({"overflow-y":"auto","-webkit-overflow-scrolling":"touch","-ms-overflow-style":"-ms-autohiding-scrollbar"}).scroll(this._onScroll.bind(this));this._$wrapper.css("overflow","hidden"),this._$wrapper.on("mouseenter.sidebar-scroll",function(){c._bottomFixed||c._dragging||(c._options.alwaysVisible||c._$scrollBar.addClass("active"),c._onScroll())}).on("mouseleave.sidebar-scroll",function(){c._bottomFixed||c._dragging||(c._options.alwaysVisible||c._$scrollBar.removeClass("active"),c._onScroll())}).on("mousewheel.sidebar-scroll",function(t,e){if(!t.isDefaultPrevented())return c.scroll(e,"MozMousePixelScroll"===t.originalEvent.type?2:null)}),!1!==this._options.showTopShadow&&(this._$shadowTop=$('
').appendTo(this._$wrapper)),!1!==this._options.showBottomShadow&&(this._$shadowBottom=$('
').appendTo(this._$wrapper)),this._$shadowTop&&this._header_height&&this._$shadowTop.css("top",this._header_height-this._shadow_offset),l=this._options.additionalClass?" "+this._options.additionalClass:"",h=this._options.alwaysVisible?" active-always":"",this._$scrollBarWrapper=$('
').appendTo(this._$wrapper),this._$scrollBar=$('
').appendTo(this._$scrollBarWrapper),this._onScroll()}var n=i(827).lazyJqueryUI;o.prototype.isTouch=function(){return this._touch},o.prototype.getScrollBar=function(){return this._$scrollBar},o.prototype._defaultOptions={headerHeight:0,additionalClass:"",alwaysVisible:!1,showBottomShadow:!0,scrollMarginTop:1,bubbleScrollEvent:!1},o.prototype.initDraggable=function(){if(this._dragInitialized)return this;var t=this;return n(this._$scrollBar).draggable({axis:"y",containment:this._$scrollBarWrapper,start:function(){t._dragging=!0},stop:function(){t._dragging=!1},drag:function(e,i){t.updateScroll()}}),this._dragInitialized=!0,this},o.prototype.updateScroll=function(){var t,e,i,o,n;return this._touch?this:(t=1,e=Math.ceil(this._$scrollBar.position().top-this._scroll_margin_top-this._header_height), +i=this.getContainerHeightWithoutHeader(),o=this._$content.outerHeight(),n=o-i-t,i<=0?this:(this._scroll_target_top=n<=0?this._header_height:Math.min(-e*o/i+this._header_height,this._header_height),e+this._$scrollBar.height()+2>=i?this.scrollToEnd():(this._$content.css("top",this._scroll_target_top+"px"),this._onScroll()),this))},o.prototype.getContainerHeightWithoutHeader=function(){return this._$wrapper[0].getBoundingClientRect().height-this._header_height},o.prototype.getContainerHeight=function(){return this._$wrapper[0].getBoundingClientRect().height},o.prototype.getContentHeight=function(){return this._$content[0].getBoundingClientRect().height},o.prototype.updateScrollBar=function(){var t,e,i,o,n,s,r,a,l;return this._touch?this:(t=1,e=this._$content.position().top,i=this.getContentHeight(),o=this.getContainerHeight(),n=this.getContainerHeightWithoutHeader(),s=t+this._header_height,r=n-2*t,a=(Math.abs(e)-this._header_height)*r/i,l=o*o/i,this.isContentShort()?(this._$scrollBar.addClass("js-hidden"),this._$wrapper.removeClass("sb-scroll-active")):(this._$scrollBar.removeClass("js-hidden").height(l).css("top",s+a),this._$wrapper.addClass("sb-scroll-active"),this.initDraggable()),this)},o.prototype.scroll=function(t,e){var i,o,n,s,r;return this._touch?this:(i=this._$content.position().top,o=this._$content.outerHeight(),n=this.getContainerHeightWithoutHeader(),s=o-n-1,r=e||this._scroll_speed,s<=0||(this._scroll_target_top=Math.max(-s+this._header_height,Math.min(this._header_height,i+t*r)),this.setContentTop(this._scroll_target_top),this._onScroll()))},o.prototype.animateTo=function(t){var e,i,o;return this._touch?this:(e=this._$content.outerHeight(),i=this.getContainerHeightWithoutHeader(),(o=e-i-1)<=0||(this._scroll_target_top=Math.max(-o+this._header_height,Math.min(this._header_height,-t)),void this._$content.animate({top:this._scroll_target_top},500,function(){this._onScroll()}.bind(this))))},o.prototype.resize=function(){var t,e;if(!this._bottomFixed){if(t=this._$content.outerHeight(),e=this._$wrapper.outerHeight(),!this._options.vAlignBottom&&ts&&t+e.areaHeightr?r-t-e.areaHeight:s-t}else"top"===e.position&&(a=s-t);return this.scroll(a,1),this._onScroll(),!1}, +o.prototype.scrollToEnd=function(){var t=this._$content.position().top,e=this._$content.outerHeight(),i=this._$wrapper.outerHeight(),o=e+t;return this.setContentTop(t+(i-o)+1),this._onScroll(),this},o.prototype.scrollToStart=function(){return this.setContentTop(this._header_height),this._onScroll(),this},o.prototype.currentPosition=function(){return Math.round(this._$content.position().top)},o.prototype.atStart=function(){return Math.round(this._$content.position().top)>=this._header_height},o.prototype.atEnd=function(t){var e,i,o,n;return"number"==typeof t&&isFinite(t)||(t=0),e=1,i=Math.round(this._$content.position().top),o=this._$content.outerHeight(),n=this._$wrapper.outerHeight(),o-Math.abs(i)-e<=n+t},o.prototype._onScroll=function(t){var e,i;return this._touch||this._$content.css("bottom","auto"),this.scrolled.fire(),this._dragging&&!0!==t||this.updateScrollBar(),e=this.atStart(),i=this.atEnd(),this._$shadowTop&&this._$shadowTop.toggleClass("i-invisible",!!e),this._$shadowBottom&&this._$shadowBottom.toggleClass("i-invisible",!!i),this._onContentVisible(),!this._atStart&&e?(this._atStart=!0,this.scrolltostart.fire()):this._atStart&&!e&&delete this._atStart,!this._atEnd&&i?(this._atEnd=!0,this.scrolltoend.fire()):this._atEnd&&!i&&delete this._atEnd,this._options.vAlignBottom&&(this._stickyBottom=this._$content.outerHeight()-Math.abs(this._$content.position().top)-this._$wrapper.outerHeight()),!(!this._atStart&&!this._atEnd||("function"==typeof this._options.bubbleScrollEvent?!this._options.bubbleScrollEvent():!this._options.bubbleScrollEvent))},o.prototype.checkContentVisibility=function(){this._onContentVisible()},o.prototype.subscribeToContentVisible=function(t,e,i){this.visibilityCallbacks.push({id:t,$el:e,callback:i})},o.prototype.triggerVisibilityCallbacks=function(t){this._onContentVisible(t)},o.prototype._contentIsVisible=function(t){return t.$el.position().top>-1*this.currentPosition()},o.prototype._onContentVisible=function(t){var e,i,o;this.visibilityCallbacks.length&&(e=t||this._contentIsVisible.bind(this),i=[],o=this.visibilityCallbacks.filter(function(t,o){if(!$.contains(this._$content,t.$el[0]))return!1;var n=e(t);return n&&i.push(o),!n},this),i.forEach(function(e){this.visibilityCallbacks[e].callback(!!t)},this),delete this.visibilityCallbacks,this.visibilityCallbacks=o)},o.prototype.save=function(){return this._saved={top:this._$content.position().top,height:this._$content.outerHeight()},this},o.prototype.restore=function(){if(this._saved){if(this._saved.top===this._$content.position().top&&this._saved.height===this._$content.outerHeight())return delete this._saved,this;this._options.vAlignBottom&&(this._saved.top-=this._$content.outerHeight()-this._saved.height,this._saved.top>this._header_height&&(this._saved.top=this._header_height)),this.setContentTop(this._saved.top),delete this._saved,this._onScroll(!0)}return this},o.prototype.fixBottom=function(){var t,e;return this._bottomFixed?this:(this._touch?(t=this._$content.outerHeight(),e=this._$wrapper.scrollTop(), +this._tempIntervalID=setInterval(function(){this._$wrapper.scrollTop(e+(this._$content.outerHeight()-t))}.bind(this),0)):this._$content.css({top:"auto",bottom:this._$wrapper.outerHeight()-this._$content.position().top-this._$content.outerHeight()}),this._bottomFixed=!0,this)},o.prototype.releaseBottom=function(){return this._bottomFixed?(this._touch?clearInterval(this._tempIntervalID):this._$content.css({top:this._$content.position().top,bottom:"auto"}),delete this._bottomFixed,this._onScroll(),this):this},o.prototype.setContentTop=function(t){return this._touch?this._options.vAlignBottom&&this._$content.outerHeight()'},837:function(t,e,i){"use strict";(function(t){function o(t){return t&&t.__esModule?t:{default:t}}function n(t){var e,i;if(t&&t.__esModule)return t;if(e={},null!=t)for(i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e.default=t,e}function s(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function l(){return 0!==C.length}var h,c,u,d,p,f,_,v,g,y,m,b,C,w;Object.defineProperty(e,"__esModule",{value:!0}),e.TVModal=void 0,h=Object.assign||function(t){var e,i,o;for(e=1;e
',containerTemplate:'
',ajaxErrorTemplate:'
'+$.t("Error")+"
"},e.TVModal=function(e){function i(){var t,e,o,n,a=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return s(this,i),t=r(this,(i.__proto__||Object.getPrototypeOf(i)).call(this,h({},w,a))),t.$overlay=$(t.options.overlayTemplate),t.$modalWrap=$(t.options.containerTemplate),t.$body=t.$modalWrap.find(".tv-dialog__modal-body").append(t.$el),t.options.closeOnOutsideClick&&t.$overlay.add(t.$modalWrap).click(function(e){t.isEventOut(e)&&t.close()}),t.on("change:zIndex",function(){t.$overlay.css("z-index",t.zIndex),t.$modalWrap.css("z-index",t.zIndex)}),t.on("destroy",function(){var e=function(){t.$overlay.remove(),t.$modalWrap.remove()};t.opened?(t.close(),setTimeout(e,t.options.closingDuration)):e()}),t.on("beforeOpen",function(){C.push(t)}),t.options.ajax.url&&(e=t.options.ajax.beforeSend||$.noop,o=t.options.ajax.success||!1,n=t.options.ajax.error||$.noop,$.extend(t.options.ajax,{beforeSend:function(){t.trigger("beforeLoading",[t]),t.startSpinner(),e(t)},success:function(e){t.trigger("afterLoading",[t]),t.renderContent(o?o(t,e):e).showContent(),t.trigger("afterLoadingShow",[t])},error:function(){t.renderContent(t.options.ajaxErrorTemplate),n(t),t.trigger("errorLoading",[t])}})),t.on("error",function(e,i){t.$modalWrap[0].getBoundingClientRect().height0&&C[C.length-1].focus(),e.options.destroyOnClose&&e.destroy() +},this.options.closingDuration),this}},{key:"showContent",value:function(){var t=this;return this.$modalWrap.removeClass("i-hidden"),setTimeout(function(){t.$modalWrap.removeClass("i-closed")},20),setTimeout(function(){t.trigger("afterOpen",[t]),t.spinner&&t.stopSpinner()},.75*d.dur+20),this}},{key:"hideContent",value:function(){if(this.$el)return this.$modalWrap.addClass("i-closed"),this.unfocus(),this}},{key:"startSpinner",value:function(){return this.spinner=new v.Spinner("large"),this.spinner.spin(this.$overlay[0]),this}},{key:"stopSpinner",value:function(){if(this.spinner)return this.spinner.stop(),delete this.spinner,this}}]),i}(_.TVDialogAbstract)}).call(e,i(187))},838:function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),i.d(e,"breakpoints",function(){return o});var o={desktop:1/0,desktopHd:1919,phone:767,"phone-vertical":479,tablet:1019}},839:function(t,e,i){"use strict";(function(t,o){function n(t){return t&&t.__esModule?t:{default:t}}function s(t){var e,i;if(t&&t.__esModule)return t;if(e={},null!=t)for(i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e.default=t,e}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function a(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function h(){m.forEach(function(t){return t.close()})}var c,u,d,p,f,_,v,g,y,m,b,C,w,T,k,x,S;Object.defineProperty(e,"__esModule",{value:!0}),e.TVDialogAbstract=void 0,c=Object.assign||function(t){var e,i,o;for(e=1;e',errorTemplate:'
{{{ error }}}
',titleTemplate:'
{{{ title }}}
',contentWrapTemplate:'
',actionsWrapTemplate:'
', +closeButtonTemplate:'
'+i(828)+"
",helpButtonTemplate:'',helpActionsMod:"tv-dialog__section--actions_with-help"},k={default:"tv-button tv-button--default",primary:"tv-button tv-button--primary",success:"tv-button tv-button--success",danger:"tv-button tv-button--danger",warning:"tv-button tv-button--warning",link:"tv-button tv-button--link",checkbox:"tv-control-checkbox tv-control-checkbox--in-actions","default-ghost":"tv-button tv-button--default_ghost","primary-ghost":"tv-button tv-button--primary_ghost","success-ghost":"tv-button tv-button--success_ghost","danger-ghost":"tv-button tv-button--danger_ghost","warning-ghost":"tv-button tv-button--warning_ghost"},x={_default:'
{{ text }}
',"submit-success":''},$(function(){T.$wrap=$(document.all&&!document.querySelector?"html":"body")}),S=function(e){function i(){var e,o,n,s,l,h=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};for(r(this,i),e=a(this,(i.__proto__||Object.getPrototypeOf(i)).call(this)),e._id=y++,e.loadingActions=[],e.disabledActions=[],e.firstFocusControl=null,e.options=c({},T,h),e.$el=$(t.render(e.options.template,{title:e.options.title,closeButton:e.options.closeButton})),e.$el.addClass("js-dialog"),e.el=e.$el[0],e.options.addClass&&e.$el.addClass(e.options.addClass),e.options.width&&e.$el.css({width:"100%","max-width":e.options.width}),e.options.title&&(e.$title=$(t.render(e.options.titleTemplate,{title:e.options.title})).appendTo(e.$el)),e.$content=$(e.options.contentWrapTemplate).appendTo(e.$el),e.$contentIn=e.$content;e.$contentIn.length;)e.$contentIn=e.$contentIn.children();if(e.$contentIn=e.$contentIn.end(),e.options.content&&e.renderContent(e.options.content),(e.options.actions||e.options.help)&&(e.$content.hasClass("tv-dialog__section")&&e.$content.addClass("tv-dialog__section--no-padding_bottom"),e.$actions=$(e.options.actionsWrapTemplate).appendTo(e.$el)),e.options.actions)for(e.actions={},e.$el.on("click touchend",".js-dialog__action-click",function(t){t.preventDefault(),e.actionDispatcher($(t.currentTarget).data("name"))}),o=function(i){var o,n,s,r,a,l,h=e.options.actions[i];h.type||(h.type="default"),h.class||(h.class=k[h.type]?k[h.type]:k.default),"checkbox"===h.type?(o=new _.default({labelRight:h.text,name:h.name,checked:h.checked}),e.actions[h.name]=o.$el.appendTo(e.$actions),e.actions[h.name].on("change",function(){setTimeout(function(){return e.actionDispatcher(h.name,o.checked)})})):e.actions[h.name]=$(t.render(h.template?h.template:x[h.type]||x._default,h,h)).appendTo(e.$actions),h.method&&"function"==typeof e[h.method]&&e.on("action:"+h.name,e[h.method].bind(e)),h.addClass&&e.actions[h.name].addClass(h.addClass),h.key&&(n=void 0,"string"==typeof h.key&&h.key.split("+").length>1?(s=[], +r=h.key.split("+"),n=function(t){s=[]},a=function(t){var i=""+t.keyCode;-1!==r.indexOf(i)&&s.indexOf(i)&&s.push(i),e._focused&&s.length===r.length&&(s=[],e.actionDispatcher(h.name))},e.on("afterOpen",function(){w.on("keydown",a),w.on("keyup",n)}),e.on("beforeClose",function(){w.off("keydown",a),w.off("keyup",n)})):(l=$.isArray(h.key)?h.key:[h.key],n=function(t){!t.isDefaultPrevented()&&e._focused&&-1!==l.indexOf(t.keyCode)&&e.actionDispatcher(h.name)},e.on("afterOpen",function(){return w.on("keyup",n)}),e.on("beforeClose",function(){return w.off("keyup",n)})))},n=e.options.actions.length-1;n>=0;n--)o(n);return e.options.help&&$(t.render(e.options.helpButtonTemplate,e.options.help)).prependTo(e.$actions.addClass(e.options.helpActionsMod)),e.options.closeButton&&(s=$(e.options.closeButtonTemplate),s.addClass(e.options.closeButtonAddClass||""),l=e.$el,1===e.$el.find(".js-close-button-place").length&&(l=e.$el.find(".js-close-button-place")),s.appendTo(l)),e.setZIndex(C+m.length),h.errorMod&&(e.errorMod=h.errorMod),e.on("afterOpen",function(){e.options.focusFirstControl&&!Modernizr.touch&&(e.firstFocusControl||e.$el.find('input:not([type="hidden"]), textarea').first()).focus()}),e.$el.on("click touchend",".js-dialog__close",e.close.bind(e)),e.$el.on("mousedown touchstart",e.focus.bind(e)),m.push(e),e}return l(i,e),u(i,[{key:"renderContent",value:function(t){return this.$contentIn.html("function"==typeof t?t(this):t),this}},{key:"setDestroyOnClose",value:function(t){this.options.destroyOnClose=t}},{key:"setZIndex",value:function(t){return this.zIndex=t,this.trigger("change:zIndex",[this]),this}},{key:"toTop",value:function(){for(var t=m.length-1;t>=0;t--)m[t].zIndex>this.zIndex&&m[t].setZIndex(m[t].zIndex-1);return this.setZIndex(C+m.length),this}},{key:"isEventOut",value:function(t){var e,i,o;return this.options.isClickOutFn&&void 0!==(e=this.options.isClickOutFn(t))?e:(i=!0,o=$(t.target),o.get(0)!==this.$el.get(0)&&($(">*",this.$el).each(function(){o.get(0)===$(this).get(0)&&(i=!1),0===o.closest("HTML",$(this).get(0)).length&&(i=!1)}),i))}},{key:"focus",value:function(){var t=this;b&&b!==this&&b.unfocus(),this._setFocused(),this._focused=!0,this.$el.addClass(this.options.focusClass),this.trigger("focus",[this]),setTimeout(function(){w.on("mousedown.tv-dialog-unfocus-"+t._id,function(e){t.isEventOut(e)&&(t.unfocus(),w.off("mousedown.tv-dialog-unfocus-"+t._id))})},20)}},{key:"_setFocused",value:function(){b!==this&&(b=this)}},{key:"_setUnfocused",value:function(){b===this&&(b=void 0)}},{key:"unfocus",value:function(){b===this&&(this._setUnfocused(),this._focused=!1,this.$el.removeClass(this.options.focusClass).find(":focus").blur(),this.trigger("unfocus",[this]))}},{key:"isFocused",value:function(){return this._focused}},{key:"setTitle",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return this.$title.toggleClass("tv-dialog__section--one-line apply-overflow-tooltip",e),this.$title.html(t),this}},{key:"setTitleText",value:function(t){this.$title.find(".js-title-text").text(t)}},{ +key:"actionDispatcher",value:function(t){if(!this.disabledActions.includes(t)&&!this.loadingActions.includes(t)){for(var e=arguments.length,i=Array(e>1?e-1:0),o=1;o1&&void 0!==arguments[1]?arguments[1]:"init";return this.actions[t].tvButtonLoader(i),"init"===i&&(this.actions[t].off("tv-button-loader:start.dialog-action").on("tv-button-loader:start.dialog-action",function(){e.loadingActions.push(t)}),this.actions[t].off("tv-button-loader:stop.dialog-action").on("tv-button-loader:stop.dialog-action",function(){e.loadingActions=o.without(e.loadingActions,t)})),this}},{key:"error",value:function(e){var i=$(t.render(this.options.errorTemplate,{error:e,errorMod:this.errorMod})).appendTo(this.$el),o=function(){i.addClass("i-slided"),setTimeout(function(){return i.remove()},.75*p.dur)};return setTimeout(function(){return i.removeClass("i-slided")},20),w.one("touchstart mousedown keydown",o),this.trigger("error",[this,i]),this}},{key:"destroy",value:function(){m=o.without(m,this);for(var t=0;t'+this.$btn.html()+''),this.loading=this.$btn.hasClass("i-loading")}return s(t,[{key:"_start",value:function(){var t=this;this.starting=!0,this.$btn.addClass("i-start-load"), +this.$btn.trigger("tv-button-loader:start"),setTimeout(function(){t.loading=!0,t.starting=!1,t._startPromise=!1,t.$btn.addClass("i-loading"),t.$btn.removeClass("i-start-load"),t._stopPromise&&t._stop()},2*l.dur)}},{key:"start",value:function(){this.starting||(this.stopping?this._startPromise=!0:this._start())}},{key:"_stop",value:function(){var t=this;this.stopping=!0,this.$btn.addClass("i-stop-load"),this.$btn.trigger("tv-button-loader:stop"),setTimeout(function(){t.loading=!1,t.stopping=!1,t._stopPromise=!1,t.$btn.removeClass("i-loading i-start-load i-stop-load"),t._startPromise&&t._start()},l.dur)}},{key:"stop",value:function(){this.stopping||(this.starting?this._stopPromise=!0:this._stop())}},{key:"toggle",value:function(){this.loading?this.stop():this.start()}},{key:"contentHtml",value:function(t){return t?(this.$btn.find(".tv-button__text").html(t),t):this.$btn.find(".tv-button__text").html()}},{key:"contentNojQuery",value:function(){return this.$btn.get(0)}},{key:"disable",value:function(){this.stop(),this.$btn.addClass("i-disabled")}},{key:"enable",value:function(){this.$btn.removeClass("i-disabled")}}]),t}()},841:function(t,e){},842:function(t,e){},843:function(t,e,i){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}function n(t){var e,i;if(t&&t.__esModule)return t;if(e={},null!=t)for(i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e.default=t,e}function s(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}var l,h,c,u,d,p,f,_,v,g,y,m,b;Object.defineProperty(e,"__esModule",{value:!0}),e.TVPopup=void 0,l=Object.assign||function(t){var e,i,o;for(e=1;e',scrollWrapInner:'
',withScroll:!0},b="js-dialog__scroll-wrap",e.TVPopup=function(t){function e(){var t,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return s(this,e),t=r(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,l({},m,i))),t.$scrollWrap=t.$content.hasClass(b)?t.$content:t.$content.find("."+b), +t.$scrollWrap.length?t.$scrollWrapInner=t.$scrollWrap.children().first():(t.$scrollWrap=t.$content.wrap($(t.options.scrollWrap)).parent(),t.$scrollWrapInner=t.$content.wrap($(t.options.scrollWrapInner)).parent()),t.$actions&&t.$scrollWrap.addClass("i-with-actions"),t.options.withScroll&&(t.scroll=new _.SidebarCustomScroll(t.$scrollWrap,t.$scrollWrapInner),t.scroll.scrolled.subscribe(null,function(){return t.trigger("scroll")})),t.$scrollWrap.css("overflow",""),t.$el.addClass("tv-dialog--popup i-closed i-hidden"),t.options.width&&t.$el.css({width:"calc(100% - 20px)","max-width":t.options.width}),t.$el.on("mousedown touchstart",t.toTop.bind(t)),t.options.closeOnOutsideClick&&(t.on("beforeOpen",function(){setTimeout(function(){t.opened&&$(document).on("click.tv-popup-"+t.id,function(e){var i=$(e.target).closest(".js-dialog");(t.options.closeOnClickAtOtherDialogs||0===i.length)&&t.isEventOut(e)&&t.close()})},0)}),t.on("beforeClose",function(){return $(document).off("click.tv-popup-"+t.id)})),t.on("change:zIndex",function(){t.$el.css("z-index",t.zIndex)}),t.on("destroy",function(){var e=function(){t.$el.remove()};t.opened?(t.close(),setTimeout(e,u.dur/2)):e()}),t}return a(e,t),h(e,[{key:"open",value:function(){var t=this;return this.opened?this:(this.opened=!0,this.trigger("beforeOpen",[this]),this.$el.appendTo(this.options.$wrap).removeClass("i-hidden").css(function(){var e,i,o,n,s;return t.calcHeight(),e=y.height(),i=y.width(),o=t.$el.height(),n=t.$el.width(),s=t.options.position,s||(s={top:e/2-o/2,left:i/2-n/2}),s.top>e-o&&(s.top=e-o),s.left>i-n&&(s.left=i-n),s}()),this.focus(),this.toTop(),this._doOpenAnimation().then(function(){t.opened&&(t.$el.removeClass("i-closed"),t.options.draggable&&((0,v.lazyJqueryUI)(t.$el).draggable({handle:".js-dialog__drag",cancel:"input, textarea, button, select, option, .js-dialog__no-drag, .js-dialog__close",containment:"window",cursor:"-webkit-grabbing"}),t.$el.find(".js-dialog__drag").addClass("tv-dialog__grab")),t.trigger("afterOpen",[t]))}),y.on("resize.tv-popup-"+this.id,function(){t.calcHeight(),t.fixPos()}),this)}},{key:"close",value:function(){var t=this;if(this.opened)return this.trigger("beforeClose",[this]),this.$el.addClass("i-closed"),this.opened=!1,this._doCloseAnimation().then(function(){t.opened||((0,v.lazyJqueryUI)(t.$el).draggable("instance").then(function(t){t&&t.destroy()}),t.$el.addClass("i-hidden").detach(),g.css("cursor","auto"),t.trigger("afterClose",[t]),t.options.destroyOnClose&&t.destroy())}),y.off("resize.tv-popup-"+this.id),this}},{key:"hide",value:function(){this.$el.addClass("i-hidden")}},{key:"show",value:function(){this.$el.removeClass("i-hidden")}},{key:"fixPos",value:function(){var t=this.$el[0].getBoundingClientRect(),e={};t.bottom>p.default.height-10&&(e.top=p.default.height-10-t.height,e.top<10&&(e.top=10)),t.right>p.default.width-10&&(e.left=p.default.width-10-t.width,e.left<10&&(e.left=10)),(e.top||e.left)&&this.$el.css(e)}},{key:"calcHeight",value:function(){ +var t,e,i=this.$el[0].getBoundingClientRect(),o=this.$scrollWrapInner[0].getBoundingClientRect(),n=this.$scrollWrap[0].getBoundingClientRect(),s=this.options.height&&this.options.heights)&&(s-=i.height-n.height,s<60&&(s=60),this.$scrollWrap.css({height:s})),this.options.withScroll&&this.scroll.resize(),e=s1&&(t=parseFloat((""+t).replace(/^.+\./,"0."))),0').appendTo(s.parent()),i=$('
').html(u).appendTo(e),o=$('
').html(u).appendTo(e),e.on("mousedown",function(t){t.preventDefault(),s.focus()}),i.click(function(){s.is(":disabled")||r(s)}),o.click(function(){s.is(":disabled")||a(s)}),s.keydown(function(t){s.is(":disabled")||(38===t.keyCode?i.addClass("i-active"):40===t.keyCode&&o.addClass("i-active"))}),s.keyup(function(t){s.is(":disabled")||(38===t.keyCode?(r(s),i.removeClass("i-active")):40===t.keyCode&&(a(s), +o.removeClass("i-active")))}),s.mousewheel(function(t,e){e>0?i.click():o.click()}))})}},850:function(t,e,i){var o,n,s;!function(r){n=[i(14),i(80)],o=r,void 0!==(s="function"==typeof o?o.apply(e,n):o)&&(t.exports=s)}(function(t){return t.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38}})},851:function(t,e){},866:function(t,e,i){var o,n,s;!function(r){n=[i(14),i(310),i(850),i(80),i(191)],o=r,void 0!==(s="function"==typeof o?o.apply(e,n):o)&&(t.exports=s)}(function(t){return t.widget("ui.slider",t.ui.mouse,{version:"1.12.1",widgetEventPrefix:"slide",options:{animate:!1,classes:{"ui-slider":"ui-corner-all","ui-slider-handle":"ui-corner-all","ui-slider-range":"ui-corner-all ui-widget-header"},distance:0,max:100,min:0,orientation:"horizontal",range:!1,step:1,value:0,values:null,change:null,slide:null,start:null,stop:null},numPages:5,_create:function(){this._keySliding=!1,this._mouseSliding=!1,this._animateOff=!0,this._handleIndex=null,this._detectOrientation(),this._mouseInit(),this._calculateNewMax(),this._addClass("ui-slider ui-slider-"+this.orientation,"ui-widget ui-widget-content"),this._refresh(),this._animateOff=!1},_refresh:function(){this._createRange(),this._createHandles(),this._setupEvents(),this._refreshValue()},_createHandles:function(){var e,i,o=this.options,n=this.element.find(".ui-slider-handle"),s=[];for(i=o.values&&o.values.length||1,n.length>i&&(n.slice(i).remove(),n=n.slice(0,i)),e=n.length;e");this.handles=n.add(t(s.join("")).appendTo(this.element)),this._addClass(this.handles,"ui-slider-handle","ui-state-default"),this.handle=this.handles.eq(0),this.handles.each(function(e){t(this).data("ui-slider-handle-index",e).attr("tabIndex",0)})},_createRange:function(){var e=this.options;e.range?(!0===e.range&&(e.values?e.values.length&&2!==e.values.length?e.values=[e.values[0],e.values[0]]:t.isArray(e.values)&&(e.values=e.values.slice(0)):e.values=[this._valueMin(),this._valueMin()]),this.range&&this.range.length?(this._removeClass(this.range,"ui-slider-range-min ui-slider-range-max"),this.range.css({left:"",bottom:""})):(this.range=t("
").appendTo(this.element),this._addClass(this.range,"ui-slider-range")),"min"!==e.range&&"max"!==e.range||this._addClass(this.range,"ui-slider-range-"+e.range)):(this.range&&this.range.remove(),this.range=null)},_setupEvents:function(){this._off(this.handles),this._on(this.handles,this._handleEvents),this._hoverable(this.handles),this._focusable(this.handles)},_destroy:function(){this.handles.remove(),this.range&&this.range.remove(),this._mouseDestroy()},_mouseCapture:function(e){var i,o,n,s,r,a,l,h=this,c=this.options;return!c.disabled&&(this.elementSize={width:this.element.outerWidth(),height:this.element.outerHeight()},this.elementOffset=this.element.offset(),i={x:e.pageX,y:e.pageY},o=this._normValueFromMouse(i),n=this._valueMax()-this._valueMin()+1,this.handles.each(function(e){var i=Math.abs(o-h.values(e)) +;(n>i||n===i&&(e===h._lastChangedValue||h.values(e)===c.min))&&(n=i,s=t(this),r=e)}),!1!==this._start(e,r)&&(this._mouseSliding=!0,this._handleIndex=r,this._addClass(s,null,"ui-state-active"),s.trigger("focus"),a=s.offset(),l=!t(e.target).parents().addBack().is(".ui-slider-handle"),this._clickOffset=l?{left:0,top:0}:{left:e.pageX-a.left-s.width()/2,top:e.pageY-a.top-s.height()/2-(parseInt(s.css("borderTopWidth"),10)||0)-(parseInt(s.css("borderBottomWidth"),10)||0)+(parseInt(s.css("marginTop"),10)||0)},this.handles.hasClass("ui-state-hover")||this._slide(e,r,o),this._animateOff=!0,!0))},_mouseStart:function(){return!0},_mouseDrag:function(t){var e={x:t.pageX,y:t.pageY},i=this._normValueFromMouse(e);return this._slide(t,this._handleIndex,i),!1},_mouseStop:function(t){return this._removeClass(this.handles,null,"ui-state-active"),this._mouseSliding=!1,this._stop(t,this._handleIndex),this._change(t,this._handleIndex),this._handleIndex=null,this._clickOffset=null,this._animateOff=!1,!1},_detectOrientation:function(){this.orientation="vertical"===this.options.orientation?"vertical":"horizontal"},_normValueFromMouse:function(t){var e,i,o,n,s;return"horizontal"===this.orientation?(e=this.elementSize.width,i=t.x-this.elementOffset.left-(this._clickOffset?this._clickOffset.left:0)):(e=this.elementSize.height,i=t.y-this.elementOffset.top-(this._clickOffset?this._clickOffset.top:0)),o=i/e,o>1&&(o=1),o<0&&(o=0),"vertical"===this.orientation&&(o=1-o),n=this._valueMax()-this._valueMin(),s=this._valueMin()+o*n,this._trimAlignValue(s)},_uiHash:function(t,e,i){var o={handle:this.handles[t],handleIndex:t,value:void 0!==e?e:this.value()};return this._hasMultipleValues()&&(o.value=void 0!==e?e:this.values(t),o.values=i||this.values()),o},_hasMultipleValues:function(){return this.options.values&&this.options.values.length},_start:function(t,e){return this._trigger("start",t,this._uiHash(e))},_slide:function(t,e,i){var o,n=this.value(),s=this.values();this._hasMultipleValues()&&(o=this.values(e?0:1),n=this.values(e),2===this.options.values.length&&!0===this.options.range&&(i=0===e?Math.min(o,i):Math.max(o,i)),s[e]=i),i!==n&&!1!==this._trigger("slide",t,this._uiHash(e,i,s))&&(this._hasMultipleValues()?this.values(e,i):this.value(i))},_stop:function(t,e){this._trigger("stop",t,this._uiHash(e))},_change:function(t,e){this._keySliding||this._mouseSliding||(this._lastChangedValue=e,this._trigger("change",t,this._uiHash(e)))},value:function(t){return arguments.length?(this.options.value=this._trimAlignValue(t),this._refreshValue(),void this._change(null,0)):this._value()},values:function(e,i){var o,n,s;if(arguments.length>1)return this.options.values[e]=this._trimAlignValue(i),this._refreshValue(),void this._change(null,e);if(!arguments.length)return this._values();if(!t.isArray(arguments[0]))return this._hasMultipleValues()?this._values(e):this.value();for(o=this.options.values,n=arguments[0],s=0;s=0;o--)this._change(null,o);this._animateOff=!1;break;case"step":case"min":case"max":this._animateOff=!0,this._calculateNewMax(),this._refreshValue(),this._animateOff=!1;break;case"range":this._animateOff=!0,this._refresh(),this._animateOff=!1}},_setOptionDisabled:function(t){this._super(t),this._toggleClass(null,"ui-state-disabled",!!t)},_value:function(){var t=this.options.value;return t=this._trimAlignValue(t)},_values:function(t){var e,i,o;if(arguments.length)return e=this.options.values[t],e=this._trimAlignValue(e);if(this._hasMultipleValues()){for(i=this.options.values.slice(),o=0;o=this._valueMax())return this._valueMax();var e=this.options.step>0?this.options.step:1,i=(t-this._valueMin())%e,o=t-i;return 2*Math.abs(i)>=e&&(o+=i>0?e:-e),parseFloat(o.toFixed(5))},_calculateNewMax:function(){var t=this.options.max,e=this._valueMin(),i=this.options.step;t=Math.round((t-e)/i)*i+e,t>this.options.max&&(t-=i),this.max=parseFloat(t.toFixed(this._precision()))},_precision:function(){var t=this._precisionOf(this.options.step);return null!==this.options.min&&(t=Math.max(t,this._precisionOf(this.options.min))),t},_precisionOf:function(t){var e=""+t,i=e.indexOf(".");return-1===i?0:e.length-i-1},_valueMin:function(){return this.options.min},_valueMax:function(){return this.max},_refreshRange:function(t){"vertical"===t&&this.range.css({width:"",left:""}),"horizontal"===t&&this.range.css({height:"",bottom:""})},_refreshValue:function(){var e,i,o,n,s,r=this.options.range,a=this.options,l=this,h=!this._animateOff&&a.animate,c={};this._hasMultipleValues()?this.handles.each(function(o){i=(l.values(o)-l._valueMin())/(l._valueMax()-l._valueMin())*100,c["horizontal"===l.orientation?"left":"bottom"]=i+"%",t(this).stop(1,1)[h?"animate":"css"](c,a.animate),!0===l.options.range&&("horizontal"===l.orientation?(0===o&&l.range.stop(1,1)[h?"animate":"css"]({left:i+"%"},a.animate),1===o&&l.range[h?"animate":"css"]({width:i-e+"%"},{queue:!1,duration:a.animate})):(0===o&&l.range.stop(1,1)[h?"animate":"css"]({bottom:i+"%"},a.animate),1===o&&l.range[h?"animate":"css"]({height:i-e+"%"},{queue:!1,duration:a.animate}))),e=i}):(o=this.value(),n=this._valueMin(),s=this._valueMax(), +i=s!==n?(o-n)/(s-n)*100:0,c["horizontal"===this.orientation?"left":"bottom"]=i+"%",this.handle.stop(1,1)[h?"animate":"css"](c,a.animate),"min"===r&&"horizontal"===this.orientation&&this.range.stop(1,1)[h?"animate":"css"]({width:i+"%"},a.animate),"max"===r&&"horizontal"===this.orientation&&this.range.stop(1,1)[h?"animate":"css"]({width:100-i+"%"},a.animate),"min"===r&&"vertical"===this.orientation&&this.range.stop(1,1)[h?"animate":"css"]({height:i+"%"},a.animate),"max"===r&&"vertical"===this.orientation&&this.range.stop(1,1)[h?"animate":"css"]({height:100-i+"%"},a.animate))},_handleEvents:{keydown:function(e){var i,o,n,s=t(e.target).data("ui-slider-handle-index");switch(e.keyCode){case t.ui.keyCode.HOME:case t.ui.keyCode.END:case t.ui.keyCode.PAGE_UP:case t.ui.keyCode.PAGE_DOWN:case t.ui.keyCode.UP:case t.ui.keyCode.RIGHT:case t.ui.keyCode.DOWN:case t.ui.keyCode.LEFT:if(e.preventDefault(),!this._keySliding&&(this._keySliding=!0,this._addClass(t(e.target),null,"ui-state-active"),!1===this._start(e,s)))return}switch(n=this.options.step,i=o=this._hasMultipleValues()?this.values(s):this.value(),e.keyCode){case t.ui.keyCode.HOME:o=this._valueMin();break;case t.ui.keyCode.END:o=this._valueMax();break;case t.ui.keyCode.PAGE_UP:o=this._trimAlignValue(i+(this._valueMax()-this._valueMin())/this.numPages);break;case t.ui.keyCode.PAGE_DOWN:o=this._trimAlignValue(i-(this._valueMax()-this._valueMin())/this.numPages);break;case t.ui.keyCode.UP:case t.ui.keyCode.RIGHT:if(i===this._valueMax())return;o=this._trimAlignValue(i+n);break;case t.ui.keyCode.DOWN:case t.ui.keyCode.LEFT:if(i===this._valueMin())return;o=this._trimAlignValue(i-n)}this._slide(e,s,o)},keyup:function(e){var i=t(e.target).data("ui-slider-handle-index");this._keySliding&&(this._keySliding=!1,this._stop(e,i),this._change(e,i),this._removeClass(t(e.target),null,"ui-state-active"))}}})})}}); \ No newline at end of file diff --git a/charting_library/static/bundles/confirm-symbol-input-dialog.741858b9ef54b3611d31.js b/charting_library/static/bundles/confirm-symbol-input-dialog.741858b9ef54b3611d31.js new file mode 100644 index 00000000..5a7d2908 --- /dev/null +++ b/charting_library/static/bundles/confirm-symbol-input-dialog.741858b9ef54b3611d31.js @@ -0,0 +1,13 @@ +webpackJsonp([19,2],{188:function(t,e,o){"use strict";function i(t){var e=t.type||"popup";return delete t.type,"modal"===e?new n.TVModal(t):new s.TVPopup(t)}var n,s;Object.defineProperty(e,"__esModule",{value:!0}),n=o(837),s=o(843),e.createDialog=i},690:function(t,e,o){"use strict";var i;Object.defineProperty(e,"__esModule",{value:!0}),i=o(839),o.n(i),o.o(i,"TVDialogAbstract")&&o.d(e,"TVDialogAbstract",function(){return i.TVDialogAbstract}),o.o(i,"closeAllDialogs")&&o.d(e,"closeAllDialogs",function(){return i.closeAllDialogs})},818:function(t,e,o){"use strict";function i(t,e,o){var i,n,a,l=$('');l.css({float:"none","box-sizing":"border-box",width:"100%"}),i=null,n=Object(s.createDialog)({title:e||window.t("Add Symbol"),width:400,actions:[{name:"apply",text:window.t("Apply"),type:"primary"}],content:l,isClickOutFn:function(t){if(i&&(t.target===i[0]||i[0].contains(t.target)))return!1}}),a=Object(r.bindToInput)(l,{callback:function(e){t(e),n.close()},onPopupOpen:function(t){t.css("z-index",n.zIndex),i=t},onPopupClose:function(){i=null}}),n.on("action:apply",function(){a.then(function(t){t.acceptTypeIn()})}),o&&n.on("beforeClose",function(){o()}),n.open()}var n,s,r;Object.defineProperty(e,"__esModule",{value:!0}),e.showConfirmSymbolInputDialog=i,n=o(14),o.n(n),o(11),s=o(188),r=o(128)},827:function(t,e,o){"use strict";function i(t){return t in $.fn?Promise.resolve():(r||(r=new Promise(function(t){o.e(31).then(function(e){o(831),t()}.bind(null,o)).catch(o.oe)})),r)}function n(t){return new a(t)}var s,r,a;Object.defineProperty(e,"__esModule",{value:!0}),o.d(e,"LazyJqueryUI",function(){return a}),e.lazyJqueryUI=n,s=o(14),o.n(s),a=function(){function t(t){this._$elem=t}return t.prototype.draggable=function(){var t=arguments,e=this._$elem;return i("draggable").then(function(){return e.draggable.apply(e,t)})},t.prototype.resizable=function(){var t=arguments,e=this._$elem;return i("resizable").then(function(){return e.resizable.apply(e,t)})},t.prototype.sortable=function(){var t=arguments,e=this._$elem;return i("sortable").then(function(){return e.sortable.apply(e,t)})},t.prototype.datepicker=function(){var t=arguments,e=this._$elem;return i("datepicker").then(function(){return e.datepicker.apply(e,t)})},t}()},828:function(t,e){t.exports=''},832:function(t,e,o){"use strict";(function(i){function n(t){return t&&t.__esModule?t:{default:t}}function s(){var t,e,o=h.width();for(d.width=o,d.height=h.height(),t=0;tt.height()},breakpoints:l.breakpoints,widgetbarBreakpoint:1064,setFixedBodyState:function(t){var e,o;t&&1==++u?("hidden"!==$(document.body).css("overflow").toLowerCase()&&document.body.scrollHeight>document.body.offsetHeight&&($(".widgetbar-wrap").css("right",d.getScrollbarWidth()),c.css("padding-right",parseInt(c.css("padding-right").replace("px",""))+d.getScrollbarWidth()+"px").data("wasScroll",!0)),c.addClass("i-no-scroll")):!t&&u>0&&0==--u&&(c.removeClass("i-no-scroll"),c.data("wasScroll")&&(e=c.get(0),$(".widgetbar-wrap").css("right",0),o=$(".widgetbar-wrap").width()||0,e.scrollHeight<=e.clientHeight&&(o-=d.getScrollbarWidth()),c.css("padding-right",(o<0?0:o)+"px").data("wasScroll",void 0)))}},p=Object.keys(d.breakpoints).sort(function(t,e){return d.breakpoints[t]-d.breakpoints[e]}),i.extend(d,a.default.prototype),s(),$(s),h.on("resize",s),e.default=d,t.exports=e.default}).call(e,o(187))},833:function(t,e,o){"use strict";(function(t){function i(e,o,i){var n,s,r,a,l,c,h=this;if(this._options=$.extend({},this._defaultOptions,i||{}),this._$wrapper=e,this._$content=o,this._scroll_speed=40,this._shadow_offset=10,this._header_height=this._options.headerHeight,this._scroll_margin_top=this._options.scrollMarginTop,this.scrolled=new t,this.scrolltoend=new t,this.scrolltostart=new t,this.visibilityCallbacks=[],n=navigator.platform.toLowerCase(),s=navigator.userAgent.toLowerCase(),r=s.indexOf("firefox")>-1,a=n.indexOf("android")>-1||s.indexOf("android")>-1,this._touch=Modernizr.touch||navigator.msMaxTouchPoints||r&&a,this._touch)return this._$content.css("position","relative"),void this._$wrapper.css({"overflow-y":"auto","-webkit-overflow-scrolling":"touch","-ms-overflow-style":"-ms-autohiding-scrollbar"}).scroll(this._onScroll.bind(this));this._$wrapper.css("overflow","hidden"),this._$wrapper.on("mouseenter.sidebar-scroll",function(){h._bottomFixed||h._dragging||(h._options.alwaysVisible||h._$scrollBar.addClass("active"),h._onScroll())}).on("mouseleave.sidebar-scroll",function(){h._bottomFixed||h._dragging||(h._options.alwaysVisible||h._$scrollBar.removeClass("active"),h._onScroll())}).on("mousewheel.sidebar-scroll",function(t,e){if(!t.isDefaultPrevented())return h.scroll(e,"MozMousePixelScroll"===t.originalEvent.type?2:null)}), +!1!==this._options.showTopShadow&&(this._$shadowTop=$('
').appendTo(this._$wrapper)),!1!==this._options.showBottomShadow&&(this._$shadowBottom=$('
').appendTo(this._$wrapper)),this._$shadowTop&&this._header_height&&this._$shadowTop.css("top",this._header_height-this._shadow_offset),l=this._options.additionalClass?" "+this._options.additionalClass:"",c=this._options.alwaysVisible?" active-always":"",this._$scrollBarWrapper=$('
').appendTo(this._$wrapper),this._$scrollBar=$('
').appendTo(this._$scrollBarWrapper),this._onScroll()}var n=o(827).lazyJqueryUI;i.prototype.isTouch=function(){return this._touch},i.prototype.getScrollBar=function(){return this._$scrollBar},i.prototype._defaultOptions={headerHeight:0,additionalClass:"",alwaysVisible:!1,showBottomShadow:!0,scrollMarginTop:1,bubbleScrollEvent:!1},i.prototype.initDraggable=function(){if(this._dragInitialized)return this;var t=this;return n(this._$scrollBar).draggable({axis:"y",containment:this._$scrollBarWrapper,start:function(){t._dragging=!0},stop:function(){t._dragging=!1},drag:function(e,o){t.updateScroll()}}),this._dragInitialized=!0,this},i.prototype.updateScroll=function(){var t,e,o,i,n;return this._touch?this:(t=1,e=Math.ceil(this._$scrollBar.position().top-this._scroll_margin_top-this._header_height),o=this.getContainerHeightWithoutHeader(),i=this._$content.outerHeight(),n=i-o-t,o<=0?this:(this._scroll_target_top=n<=0?this._header_height:Math.min(-e*i/o+this._header_height,this._header_height),e+this._$scrollBar.height()+2>=o?this.scrollToEnd():(this._$content.css("top",this._scroll_target_top+"px"),this._onScroll()),this))},i.prototype.getContainerHeightWithoutHeader=function(){return this._$wrapper[0].getBoundingClientRect().height-this._header_height},i.prototype.getContainerHeight=function(){return this._$wrapper[0].getBoundingClientRect().height},i.prototype.getContentHeight=function(){return this._$content[0].getBoundingClientRect().height},i.prototype.updateScrollBar=function(){var t,e,o,i,n,s,r,a,l;return this._touch?this:(t=1,e=this._$content.position().top,o=this.getContentHeight(),i=this.getContainerHeight(),n=this.getContainerHeightWithoutHeader(),s=t+this._header_height,r=n-2*t,a=(Math.abs(e)-this._header_height)*r/o,l=i*i/o,this.isContentShort()?(this._$scrollBar.addClass("js-hidden"),this._$wrapper.removeClass("sb-scroll-active")):(this._$scrollBar.removeClass("js-hidden").height(l).css("top",s+a),this._$wrapper.addClass("sb-scroll-active"),this.initDraggable()),this)},i.prototype.scroll=function(t,e){var o,i,n,s,r;return this._touch?this:(o=this._$content.position().top,i=this._$content.outerHeight(),n=this.getContainerHeightWithoutHeader(),s=i-n-1,r=e||this._scroll_speed,s<=0||(this._scroll_target_top=Math.max(-s+this._header_height,Math.min(this._header_height,o+t*r)),this.setContentTop(this._scroll_target_top),this._onScroll()))},i.prototype.animateTo=function(t){var e,o,i +;return this._touch?this:(e=this._$content.outerHeight(),o=this.getContainerHeightWithoutHeader(),(i=e-o-1)<=0||(this._scroll_target_top=Math.max(-i+this._header_height,Math.min(this._header_height,-t)),void this._$content.animate({top:this._scroll_target_top},500,function(){this._onScroll()}.bind(this))))},i.prototype.resize=function(){var t,e;if(!this._bottomFixed){if(t=this._$content.outerHeight(),e=this._$wrapper.outerHeight(),!this._options.vAlignBottom&&ts&&t+e.areaHeightr?r-t-e.areaHeight:s-t}else"top"===e.position&&(a=s-t);return this.scroll(a,1),this._onScroll(),!1},i.prototype.scrollToEnd=function(){var t=this._$content.position().top,e=this._$content.outerHeight(),o=this._$wrapper.outerHeight(),i=e+t;return this.setContentTop(t+(o-i)+1),this._onScroll(),this},i.prototype.scrollToStart=function(){return this.setContentTop(this._header_height),this._onScroll(),this},i.prototype.currentPosition=function(){return Math.round(this._$content.position().top)},i.prototype.atStart=function(){return Math.round(this._$content.position().top)>=this._header_height},i.prototype.atEnd=function(t){var e,o,i,n;return"number"==typeof t&&isFinite(t)||(t=0),e=1,o=Math.round(this._$content.position().top),i=this._$content.outerHeight(),n=this._$wrapper.outerHeight(),i-Math.abs(o)-e<=n+t},i.prototype._onScroll=function(t){var e,o;return this._touch||this._$content.css("bottom","auto"),this.scrolled.fire(),this._dragging&&!0!==t||this.updateScrollBar(),e=this.atStart(),o=this.atEnd(),this._$shadowTop&&this._$shadowTop.toggleClass("i-invisible",!!e),this._$shadowBottom&&this._$shadowBottom.toggleClass("i-invisible",!!o),this._onContentVisible(),!this._atStart&&e?(this._atStart=!0,this.scrolltostart.fire()):this._atStart&&!e&&delete this._atStart,!this._atEnd&&o?(this._atEnd=!0,this.scrolltoend.fire()):this._atEnd&&!o&&delete this._atEnd,this._options.vAlignBottom&&(this._stickyBottom=this._$content.outerHeight()-Math.abs(this._$content.position().top)-this._$wrapper.outerHeight()),!(!this._atStart&&!this._atEnd||("function"==typeof this._options.bubbleScrollEvent?!this._options.bubbleScrollEvent():!this._options.bubbleScrollEvent))},i.prototype.checkContentVisibility=function(){ +this._onContentVisible()},i.prototype.subscribeToContentVisible=function(t,e,o){this.visibilityCallbacks.push({id:t,$el:e,callback:o})},i.prototype.triggerVisibilityCallbacks=function(t){this._onContentVisible(t)},i.prototype._contentIsVisible=function(t){return t.$el.position().top>-1*this.currentPosition()},i.prototype._onContentVisible=function(t){var e,o,i;this.visibilityCallbacks.length&&(e=t||this._contentIsVisible.bind(this),o=[],i=this.visibilityCallbacks.filter(function(t,i){if(!$.contains(this._$content,t.$el[0]))return!1;var n=e(t);return n&&o.push(i),!n},this),o.forEach(function(e){this.visibilityCallbacks[e].callback(!!t)},this),delete this.visibilityCallbacks,this.visibilityCallbacks=i)},i.prototype.save=function(){return this._saved={top:this._$content.position().top,height:this._$content.outerHeight()},this},i.prototype.restore=function(){if(this._saved){if(this._saved.top===this._$content.position().top&&this._saved.height===this._$content.outerHeight())return delete this._saved,this;this._options.vAlignBottom&&(this._saved.top-=this._$content.outerHeight()-this._saved.height,this._saved.top>this._header_height&&(this._saved.top=this._header_height)),this.setContentTop(this._saved.top),delete this._saved,this._onScroll(!0)}return this},i.prototype.fixBottom=function(){var t,e;return this._bottomFixed?this:(this._touch?(t=this._$content.outerHeight(),e=this._$wrapper.scrollTop(),this._tempIntervalID=setInterval(function(){this._$wrapper.scrollTop(e+(this._$content.outerHeight()-t))}.bind(this),0)):this._$content.css({top:"auto",bottom:this._$wrapper.outerHeight()-this._$content.position().top-this._$content.outerHeight()}),this._bottomFixed=!0,this)},i.prototype.releaseBottom=function(){return this._bottomFixed?(this._touch?clearInterval(this._tempIntervalID):this._$content.css({top:this._$content.position().top,bottom:"auto"}),delete this._bottomFixed,this._onScroll(),this):this},i.prototype.setContentTop=function(t){return this._touch?this._options.vAlignBottom&&this._$content.outerHeight()
',containerTemplate:'
',ajaxErrorTemplate:'
'+$.t("Error")+"
"},e.TVModal=function(e){function o(){var t,e,i,n,a=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return s(this,o),t=r(this,(o.__proto__||Object.getPrototypeOf(o)).call(this,c({},C,a))),t.$overlay=$(t.options.overlayTemplate),t.$modalWrap=$(t.options.containerTemplate),t.$body=t.$modalWrap.find(".tv-dialog__modal-body").append(t.$el),t.options.closeOnOutsideClick&&t.$overlay.add(t.$modalWrap).click(function(e){t.isEventOut(e)&&t.close()}),t.on("change:zIndex",function(){t.$overlay.css("z-index",t.zIndex),t.$modalWrap.css("z-index",t.zIndex)}),t.on("destroy",function(){var e=function(){t.$overlay.remove(),t.$modalWrap.remove()};t.opened?(t.close(),setTimeout(e,t.options.closingDuration)):e()}),t.on("beforeOpen",function(){w.push(t)}),t.options.ajax.url&&(e=t.options.ajax.beforeSend||$.noop,i=t.options.ajax.success||!1,n=t.options.ajax.error||$.noop,$.extend(t.options.ajax,{beforeSend:function(){t.trigger("beforeLoading",[t]),t.startSpinner(),e(t)},success:function(e){t.trigger("afterLoading",[t]),t.renderContent(i?i(t,e):e).showContent(),t.trigger("afterLoadingShow",[t])},error:function(){t.renderContent(t.options.ajaxErrorTemplate),n(t),t.trigger("errorLoading",[t])}})),t.on("error",function(e,o){t.$modalWrap[0].getBoundingClientRect().height0&&w[w.length-1].focus(),e.options.destroyOnClose&&e.destroy()},this.options.closingDuration),this}},{key:"showContent",value:function(){var t=this;return this.$modalWrap.removeClass("i-hidden"),setTimeout(function(){t.$modalWrap.removeClass("i-closed")},20),setTimeout(function(){t.trigger("afterOpen",[t]),t.spinner&&t.stopSpinner()},.75*d.dur+20),this}},{key:"hideContent",value:function(){if(this.$el)return this.$modalWrap.addClass("i-closed"),this.unfocus(),this}},{key:"startSpinner",value:function(){return this.spinner=new _.Spinner("large"),this.spinner.spin(this.$overlay[0]),this}},{key:"stopSpinner",value:function(){if(this.spinner)return this.spinner.stop(),delete this.spinner,this}}]),o}(g.TVDialogAbstract)}).call(e,o(187))},838:function(t,e,o){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),o.d(e,"breakpoints",function(){return i});var i={desktop:1/0,desktopHd:1919,phone:767,"phone-vertical":479,tablet:1019}},839:function(t,e,o){"use strict";(function(t,i){function n(t){return t&&t.__esModule?t:{default:t}}function s(t){var e,o;if(t&&t.__esModule)return t;if(e={},null!=t)for(o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e.default=t,e}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function a(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function c(){y.forEach(function(t){return t.close()})}var h,u,d,p,f,g,_,v,b,y,m,w,C,k,T,x,O;Object.defineProperty(e,"__esModule",{value:!0}),e.TVDialogAbstract=void 0, +h=Object.assign||function(t){var e,o,i;for(e=1;e',errorTemplate:'
{{{ error }}}
',titleTemplate:'
{{{ title }}}
',contentWrapTemplate:'
',actionsWrapTemplate:'
',closeButtonTemplate:'
'+o(828)+"
",helpButtonTemplate:'',helpActionsMod:"tv-dialog__section--actions_with-help"},T={default:"tv-button tv-button--default",primary:"tv-button tv-button--primary",success:"tv-button tv-button--success",danger:"tv-button tv-button--danger",warning:"tv-button tv-button--warning",link:"tv-button tv-button--link",checkbox:"tv-control-checkbox tv-control-checkbox--in-actions","default-ghost":"tv-button tv-button--default_ghost","primary-ghost":"tv-button tv-button--primary_ghost","success-ghost":"tv-button tv-button--success_ghost","danger-ghost":"tv-button tv-button--danger_ghost","warning-ghost":"tv-button tv-button--warning_ghost"},x={_default:'
{{ text }}
',"submit-success":''},$(function(){k.$wrap=$(document.all&&!document.querySelector?"html":"body")}),O=function(e){function o(){var e,i,n,s,l,c=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};for(r(this,o),e=a(this,(o.__proto__||Object.getPrototypeOf(o)).call(this)),e._id=b++,e.loadingActions=[],e.disabledActions=[],e.firstFocusControl=null,e.options=h({},k,c),e.$el=$(t.render(e.options.template,{title:e.options.title,closeButton:e.options.closeButton})),e.$el.addClass("js-dialog"),e.el=e.$el[0],e.options.addClass&&e.$el.addClass(e.options.addClass),e.options.width&&e.$el.css({width:"100%","max-width":e.options.width}),e.options.title&&(e.$title=$(t.render(e.options.titleTemplate,{title:e.options.title})).appendTo(e.$el)),e.$content=$(e.options.contentWrapTemplate).appendTo(e.$el), +e.$contentIn=e.$content;e.$contentIn.length;)e.$contentIn=e.$contentIn.children();if(e.$contentIn=e.$contentIn.end(),e.options.content&&e.renderContent(e.options.content),(e.options.actions||e.options.help)&&(e.$content.hasClass("tv-dialog__section")&&e.$content.addClass("tv-dialog__section--no-padding_bottom"),e.$actions=$(e.options.actionsWrapTemplate).appendTo(e.$el)),e.options.actions)for(e.actions={},e.$el.on("click touchend",".js-dialog__action-click",function(t){t.preventDefault(),e.actionDispatcher($(t.currentTarget).data("name"))}),i=function(o){var i,n,s,r,a,l,c=e.options.actions[o];c.type||(c.type="default"),c.class||(c.class=T[c.type]?T[c.type]:T.default),"checkbox"===c.type?(i=new g.default({labelRight:c.text,name:c.name,checked:c.checked}),e.actions[c.name]=i.$el.appendTo(e.$actions),e.actions[c.name].on("change",function(){setTimeout(function(){return e.actionDispatcher(c.name,i.checked)})})):e.actions[c.name]=$(t.render(c.template?c.template:x[c.type]||x._default,c,c)).appendTo(e.$actions),c.method&&"function"==typeof e[c.method]&&e.on("action:"+c.name,e[c.method].bind(e)),c.addClass&&e.actions[c.name].addClass(c.addClass),c.key&&(n=void 0,"string"==typeof c.key&&c.key.split("+").length>1?(s=[],r=c.key.split("+"),n=function(t){s=[]},a=function(t){var o=""+t.keyCode;-1!==r.indexOf(o)&&s.indexOf(o)&&s.push(o),e._focused&&s.length===r.length&&(s=[],e.actionDispatcher(c.name))},e.on("afterOpen",function(){C.on("keydown",a),C.on("keyup",n)}),e.on("beforeClose",function(){C.off("keydown",a),C.off("keyup",n)})):(l=$.isArray(c.key)?c.key:[c.key],n=function(t){!t.isDefaultPrevented()&&e._focused&&-1!==l.indexOf(t.keyCode)&&e.actionDispatcher(c.name)},e.on("afterOpen",function(){return C.on("keyup",n)}),e.on("beforeClose",function(){return C.off("keyup",n)})))},n=e.options.actions.length-1;n>=0;n--)i(n);return e.options.help&&$(t.render(e.options.helpButtonTemplate,e.options.help)).prependTo(e.$actions.addClass(e.options.helpActionsMod)),e.options.closeButton&&(s=$(e.options.closeButtonTemplate),s.addClass(e.options.closeButtonAddClass||""),l=e.$el,1===e.$el.find(".js-close-button-place").length&&(l=e.$el.find(".js-close-button-place")),s.appendTo(l)),e.setZIndex(w+y.length),c.errorMod&&(e.errorMod=c.errorMod),e.on("afterOpen",function(){e.options.focusFirstControl&&!Modernizr.touch&&(e.firstFocusControl||e.$el.find('input:not([type="hidden"]), textarea').first()).focus()}),e.$el.on("click touchend",".js-dialog__close",e.close.bind(e)),e.$el.on("mousedown touchstart",e.focus.bind(e)),y.push(e),e}return l(o,e),u(o,[{key:"renderContent",value:function(t){return this.$contentIn.html("function"==typeof t?t(this):t),this}},{key:"setDestroyOnClose",value:function(t){this.options.destroyOnClose=t}},{key:"setZIndex",value:function(t){return this.zIndex=t,this.trigger("change:zIndex",[this]),this}},{key:"toTop",value:function(){for(var t=y.length-1;t>=0;t--)y[t].zIndex>this.zIndex&&y[t].setZIndex(y[t].zIndex-1);return this.setZIndex(w+y.length),this}},{key:"isEventOut",value:function(t){var e,o,i +;return this.options.isClickOutFn&&void 0!==(e=this.options.isClickOutFn(t))?e:(o=!0,i=$(t.target),i.get(0)!==this.$el.get(0)&&($(">*",this.$el).each(function(){i.get(0)===$(this).get(0)&&(o=!1),0===i.closest("HTML",$(this).get(0)).length&&(o=!1)}),o))}},{key:"focus",value:function(){var t=this;m&&m!==this&&m.unfocus(),this._setFocused(),this._focused=!0,this.$el.addClass(this.options.focusClass),this.trigger("focus",[this]),setTimeout(function(){C.on("mousedown.tv-dialog-unfocus-"+t._id,function(e){t.isEventOut(e)&&(t.unfocus(),C.off("mousedown.tv-dialog-unfocus-"+t._id))})},20)}},{key:"_setFocused",value:function(){m!==this&&(m=this)}},{key:"_setUnfocused",value:function(){m===this&&(m=void 0)}},{key:"unfocus",value:function(){m===this&&(this._setUnfocused(),this._focused=!1,this.$el.removeClass(this.options.focusClass).find(":focus").blur(),this.trigger("unfocus",[this]))}},{key:"isFocused",value:function(){return this._focused}},{key:"setTitle",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return this.$title.toggleClass("tv-dialog__section--one-line apply-overflow-tooltip",e),this.$title.html(t),this}},{key:"setTitleText",value:function(t){this.$title.find(".js-title-text").text(t)}},{key:"actionDispatcher",value:function(t){if(!this.disabledActions.includes(t)&&!this.loadingActions.includes(t)){for(var e=arguments.length,o=Array(e>1?e-1:0),i=1;i1&&void 0!==arguments[1]?arguments[1]:"init";return this.actions[t].tvButtonLoader(o),"init"===o&&(this.actions[t].off("tv-button-loader:start.dialog-action").on("tv-button-loader:start.dialog-action",function(){e.loadingActions.push(t)}),this.actions[t].off("tv-button-loader:stop.dialog-action").on("tv-button-loader:stop.dialog-action",function(){e.loadingActions=i.without(e.loadingActions,t)})),this}},{key:"error",value:function(e){var o=$(t.render(this.options.errorTemplate,{error:e,errorMod:this.errorMod})).appendTo(this.$el),i=function(){o.addClass("i-slided"),setTimeout(function(){return o.remove()},.75*p.dur)};return setTimeout(function(){return o.removeClass("i-slided")},20),C.one("touchstart mousedown keydown",i),this.trigger("error",[this,o]),this}},{key:"destroy",value:function(){y=i.without(y,this);for(var t=0;t'+this.$btn.html()+''),this.loading=this.$btn.hasClass("i-loading")}return s(t,[{key:"_start",value:function(){var t=this;this.starting=!0,this.$btn.addClass("i-start-load"),this.$btn.trigger("tv-button-loader:start"),setTimeout(function(){t.loading=!0,t.starting=!1,t._startPromise=!1,t.$btn.addClass("i-loading"),t.$btn.removeClass("i-start-load"),t._stopPromise&&t._stop()},2*l.dur)}},{key:"start",value:function(){this.starting||(this.stopping?this._startPromise=!0:this._start())}},{key:"_stop",value:function(){var t=this;this.stopping=!0,this.$btn.addClass("i-stop-load"),this.$btn.trigger("tv-button-loader:stop"),setTimeout(function(){t.loading=!1,t.stopping=!1,t._stopPromise=!1,t.$btn.removeClass("i-loading i-start-load i-stop-load"),t._startPromise&&t._start()},l.dur)}},{key:"stop",value:function(){this.stopping||(this.starting?this._stopPromise=!0:this._stop())}},{key:"toggle",value:function(){this.loading?this.stop():this.start()}},{key:"contentHtml",value:function(t){return t?(this.$btn.find(".tv-button__text").html(t),t):this.$btn.find(".tv-button__text").html()}},{key:"contentNojQuery",value:function(){return this.$btn.get(0)}},{key:"disable",value:function(){this.stop(),this.$btn.addClass("i-disabled")}},{key:"enable",value:function(){this.$btn.removeClass("i-disabled")}}]),t}()},841:function(t,e){},842:function(t,e){},843:function(t,e,o){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function n(t){var e,o;if(t&&t.__esModule)return t;if(e={},null!=t)for(o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e.default=t,e}function s(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e) +;t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}var l,c,h,u,d,p,f,g,_,v,b,y,m;Object.defineProperty(e,"__esModule",{value:!0}),e.TVPopup=void 0,l=Object.assign||function(t){var e,o,i;for(e=1;e',scrollWrapInner:'
',withScroll:!0},m="js-dialog__scroll-wrap",e.TVPopup=function(t){function e(){var t,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return s(this,e),t=r(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,l({},y,o))),t.$scrollWrap=t.$content.hasClass(m)?t.$content:t.$content.find("."+m),t.$scrollWrap.length?t.$scrollWrapInner=t.$scrollWrap.children().first():(t.$scrollWrap=t.$content.wrap($(t.options.scrollWrap)).parent(),t.$scrollWrapInner=t.$content.wrap($(t.options.scrollWrapInner)).parent()),t.$actions&&t.$scrollWrap.addClass("i-with-actions"),t.options.withScroll&&(t.scroll=new g.SidebarCustomScroll(t.$scrollWrap,t.$scrollWrapInner),t.scroll.scrolled.subscribe(null,function(){return t.trigger("scroll")})),t.$scrollWrap.css("overflow",""),t.$el.addClass("tv-dialog--popup i-closed i-hidden"),t.options.width&&t.$el.css({width:"calc(100% - 20px)","max-width":t.options.width}),t.$el.on("mousedown touchstart",t.toTop.bind(t)),t.options.closeOnOutsideClick&&(t.on("beforeOpen",function(){setTimeout(function(){t.opened&&$(document).on("click.tv-popup-"+t.id,function(e){var o=$(e.target).closest(".js-dialog");(t.options.closeOnClickAtOtherDialogs||0===o.length)&&t.isEventOut(e)&&t.close()})},0)}),t.on("beforeClose",function(){return $(document).off("click.tv-popup-"+t.id)})),t.on("change:zIndex",function(){t.$el.css("z-index",t.zIndex)}),t.on("destroy",function(){var e=function(){t.$el.remove()};t.opened?(t.close(),setTimeout(e,u.dur/2)):e()}),t}return a(e,t),c(e,[{key:"open",value:function(){var t=this;return this.opened?this:(this.opened=!0,this.trigger("beforeOpen",[this]),this.$el.appendTo(this.options.$wrap).removeClass("i-hidden").css(function(){var e,o,i,n,s;return t.calcHeight(),e=b.height(),o=b.width(),i=t.$el.height(),n=t.$el.width(),s=t.options.position,s||(s={top:e/2-i/2,left:o/2-n/2}),s.top>e-i&&(s.top=e-i),s.left>o-n&&(s.left=o-n),s}()),this.focus(),this.toTop(),this._doOpenAnimation().then(function(){t.opened&&(t.$el.removeClass("i-closed"),t.options.draggable&&((0,_.lazyJqueryUI)(t.$el).draggable({handle:".js-dialog__drag", +cancel:"input, textarea, button, select, option, .js-dialog__no-drag, .js-dialog__close",containment:"window",cursor:"-webkit-grabbing"}),t.$el.find(".js-dialog__drag").addClass("tv-dialog__grab")),t.trigger("afterOpen",[t]))}),b.on("resize.tv-popup-"+this.id,function(){t.calcHeight(),t.fixPos()}),this)}},{key:"close",value:function(){var t=this;if(this.opened)return this.trigger("beforeClose",[this]),this.$el.addClass("i-closed"),this.opened=!1,this._doCloseAnimation().then(function(){t.opened||((0,_.lazyJqueryUI)(t.$el).draggable("instance").then(function(t){t&&t.destroy()}),t.$el.addClass("i-hidden").detach(),v.css("cursor","auto"),t.trigger("afterClose",[t]),t.options.destroyOnClose&&t.destroy())}),b.off("resize.tv-popup-"+this.id),this}},{key:"hide",value:function(){this.$el.addClass("i-hidden")}},{key:"show",value:function(){this.$el.removeClass("i-hidden")}},{key:"fixPos",value:function(){var t=this.$el[0].getBoundingClientRect(),e={};t.bottom>p.default.height-10&&(e.top=p.default.height-10-t.height,e.top<10&&(e.top=10)),t.right>p.default.width-10&&(e.left=p.default.width-10-t.width,e.left<10&&(e.left=10)),(e.top||e.left)&&this.$el.css(e)}},{key:"calcHeight",value:function(){var t,e,o=this.$el[0].getBoundingClientRect(),i=this.$scrollWrapInner[0].getBoundingClientRect(),n=this.$scrollWrap[0].getBoundingClientRect(),s=this.options.height&&this.options.heights)&&(s-=o.height-n.height,s<60&&(s=60),this.$scrollWrap.css({height:s})),this.options.withScroll&&this.scroll.resize(),e=st.height()},breakpoints:l.breakpoints,widgetbarBreakpoint:1064,setFixedBodyState:function(t){var e,o +;t&&1==++d?("hidden"!==$(document.body).css("overflow").toLowerCase()&&document.body.scrollHeight>document.body.offsetHeight&&($(".widgetbar-wrap").css("right",u.getScrollbarWidth()),c.css("padding-right",parseInt(c.css("padding-right").replace("px",""))+u.getScrollbarWidth()+"px").data("wasScroll",!0)),c.addClass("i-no-scroll")):!t&&d>0&&0==--d&&(c.removeClass("i-no-scroll"),c.data("wasScroll")&&(e=c.get(0),$(".widgetbar-wrap").css("right",0),o=$(".widgetbar-wrap").width()||0,e.scrollHeight<=e.clientHeight&&(o-=u.getScrollbarWidth()),c.css("padding-right",(o<0?0:o)+"px").data("wasScroll",void 0)))}},p=Object.keys(u.breakpoints).sort(function(t,e){return u.breakpoints[t]-u.breakpoints[e]}),i.extend(u,a.default.prototype),s(),$(s),h.on("resize",s),e.default=u,t.exports=e.default}).call(e,o(187))},833:function(t,e,o){"use strict";(function(t){function i(e,o,i){var n,s,r,a,l,c,h=this;if(this._options=$.extend({},this._defaultOptions,i||{}),this._$wrapper=e,this._$content=o,this._scroll_speed=40,this._shadow_offset=10,this._header_height=this._options.headerHeight,this._scroll_margin_top=this._options.scrollMarginTop,this.scrolled=new t,this.scrolltoend=new t,this.scrolltostart=new t,this.visibilityCallbacks=[],n=navigator.platform.toLowerCase(),s=navigator.userAgent.toLowerCase(),r=s.indexOf("firefox")>-1,a=n.indexOf("android")>-1||s.indexOf("android")>-1,this._touch=Modernizr.touch||navigator.msMaxTouchPoints||r&&a,this._touch)return this._$content.css("position","relative"),void this._$wrapper.css({"overflow-y":"auto","-webkit-overflow-scrolling":"touch","-ms-overflow-style":"-ms-autohiding-scrollbar"}).scroll(this._onScroll.bind(this));this._$wrapper.css("overflow","hidden"),this._$wrapper.on("mouseenter.sidebar-scroll",function(){h._bottomFixed||h._dragging||(h._options.alwaysVisible||h._$scrollBar.addClass("active"),h._onScroll())}).on("mouseleave.sidebar-scroll",function(){h._bottomFixed||h._dragging||(h._options.alwaysVisible||h._$scrollBar.removeClass("active"),h._onScroll())}).on("mousewheel.sidebar-scroll",function(t,e){if(!t.isDefaultPrevented())return h.scroll(e,"MozMousePixelScroll"===t.originalEvent.type?2:null)}),!1!==this._options.showTopShadow&&(this._$shadowTop=$('
').appendTo(this._$wrapper)),!1!==this._options.showBottomShadow&&(this._$shadowBottom=$('
').appendTo(this._$wrapper)),this._$shadowTop&&this._header_height&&this._$shadowTop.css("top",this._header_height-this._shadow_offset),l=this._options.additionalClass?" "+this._options.additionalClass:"",c=this._options.alwaysVisible?" active-always":"",this._$scrollBarWrapper=$('
').appendTo(this._$wrapper),this._$scrollBar=$('
').appendTo(this._$scrollBarWrapper),this._onScroll()}var n=o(827).lazyJqueryUI;i.prototype.isTouch=function(){return this._touch},i.prototype.getScrollBar=function(){return this._$scrollBar},i.prototype._defaultOptions={headerHeight:0,additionalClass:"",alwaysVisible:!1, +showBottomShadow:!0,scrollMarginTop:1,bubbleScrollEvent:!1},i.prototype.initDraggable=function(){if(this._dragInitialized)return this;var t=this;return n(this._$scrollBar).draggable({axis:"y",containment:this._$scrollBarWrapper,start:function(){t._dragging=!0},stop:function(){t._dragging=!1},drag:function(e,o){t.updateScroll()}}),this._dragInitialized=!0,this},i.prototype.updateScroll=function(){var t,e,o,i,n;return this._touch?this:(t=1,e=Math.ceil(this._$scrollBar.position().top-this._scroll_margin_top-this._header_height),o=this.getContainerHeightWithoutHeader(),i=this._$content.outerHeight(),n=i-o-t,o<=0?this:(this._scroll_target_top=n<=0?this._header_height:Math.min(-e*i/o+this._header_height,this._header_height),e+this._$scrollBar.height()+2>=o?this.scrollToEnd():(this._$content.css("top",this._scroll_target_top+"px"),this._onScroll()),this))},i.prototype.getContainerHeightWithoutHeader=function(){return this._$wrapper[0].getBoundingClientRect().height-this._header_height},i.prototype.getContainerHeight=function(){return this._$wrapper[0].getBoundingClientRect().height},i.prototype.getContentHeight=function(){return this._$content[0].getBoundingClientRect().height},i.prototype.updateScrollBar=function(){var t,e,o,i,n,s,r,a,l;return this._touch?this:(t=1,e=this._$content.position().top,o=this.getContentHeight(),i=this.getContainerHeight(),n=this.getContainerHeightWithoutHeader(),s=t+this._header_height,r=n-2*t,a=(Math.abs(e)-this._header_height)*r/o,l=i*i/o,this.isContentShort()?(this._$scrollBar.addClass("js-hidden"),this._$wrapper.removeClass("sb-scroll-active")):(this._$scrollBar.removeClass("js-hidden").height(l).css("top",s+a),this._$wrapper.addClass("sb-scroll-active"),this.initDraggable()),this)},i.prototype.scroll=function(t,e){var o,i,n,s,r;return this._touch?this:(o=this._$content.position().top,i=this._$content.outerHeight(),n=this.getContainerHeightWithoutHeader(),s=i-n-1,r=e||this._scroll_speed,s<=0||(this._scroll_target_top=Math.max(-s+this._header_height,Math.min(this._header_height,o+t*r)),this.setContentTop(this._scroll_target_top),this._onScroll()))},i.prototype.animateTo=function(t){var e,o,i;return this._touch?this:(e=this._$content.outerHeight(),o=this.getContainerHeightWithoutHeader(),(i=e-o-1)<=0||(this._scroll_target_top=Math.max(-i+this._header_height,Math.min(this._header_height,-t)),void this._$content.animate({top:this._scroll_target_top},500,function(){this._onScroll()}.bind(this))))},i.prototype.resize=function(){var t,e;if(!this._bottomFixed){if(t=this._$content.outerHeight(),e=this._$wrapper.outerHeight(),!this._options.vAlignBottom&&ts&&t+e.areaHeightr?r-t-e.areaHeight:s-t}else"top"===e.position&&(a=s-t);return this.scroll(a,1),this._onScroll(),!1},i.prototype.scrollToEnd=function(){var t=this._$content.position().top,e=this._$content.outerHeight(),o=this._$wrapper.outerHeight(),i=e+t;return this.setContentTop(t+(o-i)+1),this._onScroll(),this},i.prototype.scrollToStart=function(){return this.setContentTop(this._header_height),this._onScroll(),this},i.prototype.currentPosition=function(){return Math.round(this._$content.position().top)},i.prototype.atStart=function(){return Math.round(this._$content.position().top)>=this._header_height},i.prototype.atEnd=function(t){var e,o,i,n;return"number"==typeof t&&isFinite(t)||(t=0),e=1,o=Math.round(this._$content.position().top),i=this._$content.outerHeight(),n=this._$wrapper.outerHeight(),i-Math.abs(o)-e<=n+t},i.prototype._onScroll=function(t){var e,o;return this._touch||this._$content.css("bottom","auto"),this.scrolled.fire(),this._dragging&&!0!==t||this.updateScrollBar(),e=this.atStart(),o=this.atEnd(),this._$shadowTop&&this._$shadowTop.toggleClass("i-invisible",!!e),this._$shadowBottom&&this._$shadowBottom.toggleClass("i-invisible",!!o),this._onContentVisible(),!this._atStart&&e?(this._atStart=!0,this.scrolltostart.fire()):this._atStart&&!e&&delete this._atStart,!this._atEnd&&o?(this._atEnd=!0,this.scrolltoend.fire()):this._atEnd&&!o&&delete this._atEnd,this._options.vAlignBottom&&(this._stickyBottom=this._$content.outerHeight()-Math.abs(this._$content.position().top)-this._$wrapper.outerHeight()),!(!this._atStart&&!this._atEnd||("function"==typeof this._options.bubbleScrollEvent?!this._options.bubbleScrollEvent():!this._options.bubbleScrollEvent))},i.prototype.checkContentVisibility=function(){this._onContentVisible()},i.prototype.subscribeToContentVisible=function(t,e,o){this.visibilityCallbacks.push({id:t,$el:e,callback:o})},i.prototype.triggerVisibilityCallbacks=function(t){this._onContentVisible(t)},i.prototype._contentIsVisible=function(t){return t.$el.position().top>-1*this.currentPosition()},i.prototype._onContentVisible=function(t){var e,o,i;this.visibilityCallbacks.length&&(e=t||this._contentIsVisible.bind(this),o=[],i=this.visibilityCallbacks.filter(function(t,i){if(!$.contains(this._$content,t.$el[0]))return!1;var n=e(t);return n&&o.push(i),!n},this),o.forEach(function(e){this.visibilityCallbacks[e].callback(!!t)},this),delete this.visibilityCallbacks,this.visibilityCallbacks=i)},i.prototype.save=function(){return this._saved={top:this._$content.position().top,height:this._$content.outerHeight()},this},i.prototype.restore=function(){if(this._saved){ +if(this._saved.top===this._$content.position().top&&this._saved.height===this._$content.outerHeight())return delete this._saved,this;this._options.vAlignBottom&&(this._saved.top-=this._$content.outerHeight()-this._saved.height,this._saved.top>this._header_height&&(this._saved.top=this._header_height)),this.setContentTop(this._saved.top),delete this._saved,this._onScroll(!0)}return this},i.prototype.fixBottom=function(){var t,e;return this._bottomFixed?this:(this._touch?(t=this._$content.outerHeight(),e=this._$wrapper.scrollTop(),this._tempIntervalID=setInterval(function(){this._$wrapper.scrollTop(e+(this._$content.outerHeight()-t))}.bind(this),0)):this._$content.css({top:"auto",bottom:this._$wrapper.outerHeight()-this._$content.position().top-this._$content.outerHeight()}),this._bottomFixed=!0,this)},i.prototype.releaseBottom=function(){return this._bottomFixed?(this._touch?clearInterval(this._tempIntervalID):this._$content.css({top:this._$content.position().top,bottom:"auto"}),delete this._bottomFixed,this._onScroll(),this):this},i.prototype.setContentTop=function(t){return this._touch?this._options.vAlignBottom&&this._$content.outerHeight()
',containerTemplate:'
',ajaxErrorTemplate:'
'+$.t("Error")+"
"},e.TVModal=function(e){function o(){var t,e,i,n,a=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return s(this,o),t=r(this,(o.__proto__||Object.getPrototypeOf(o)).call(this,c({},C,a))),t.$overlay=$(t.options.overlayTemplate),t.$modalWrap=$(t.options.containerTemplate),t.$body=t.$modalWrap.find(".tv-dialog__modal-body").append(t.$el),t.options.closeOnOutsideClick&&t.$overlay.add(t.$modalWrap).click(function(e){t.isEventOut(e)&&t.close()}),t.on("change:zIndex",function(){t.$overlay.css("z-index",t.zIndex),t.$modalWrap.css("z-index",t.zIndex)}),t.on("destroy",function(){var e=function(){t.$overlay.remove(),t.$modalWrap.remove()};t.opened?(t.close(),setTimeout(e,t.options.closingDuration)):e()}),t.on("beforeOpen",function(){w.push(t)}),t.options.ajax.url&&(e=t.options.ajax.beforeSend||$.noop,i=t.options.ajax.success||!1,n=t.options.ajax.error||$.noop,$.extend(t.options.ajax,{beforeSend:function(){t.trigger("beforeLoading",[t]),t.startSpinner(),e(t)},success:function(e){t.trigger("afterLoading",[t]),t.renderContent(i?i(t,e):e).showContent(),t.trigger("afterLoadingShow",[t])},error:function(){t.renderContent(t.options.ajaxErrorTemplate),n(t),t.trigger("errorLoading",[t])}})),t.on("error",function(e,o){t.$modalWrap[0].getBoundingClientRect().height0&&w[w.length-1].focus(),e.options.destroyOnClose&&e.destroy()},this.options.closingDuration),this}},{key:"showContent",value:function(){var t=this;return this.$modalWrap.removeClass("i-hidden"),setTimeout(function(){t.$modalWrap.removeClass("i-closed")},20),setTimeout(function(){t.trigger("afterOpen",[t]),t.spinner&&t.stopSpinner()},.75*u.dur+20),this}},{key:"hideContent",value:function(){if(this.$el)return this.$modalWrap.addClass("i-closed"),this.unfocus(),this}},{key:"startSpinner",value:function(){return this.spinner=new _.Spinner("large"),this.spinner.spin(this.$overlay[0]),this}},{key:"stopSpinner",value:function(){if(this.spinner)return this.spinner.stop(),delete this.spinner,this}}]),o}(g.TVDialogAbstract)}).call(e,o(187))},838:function(t,e,o){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),o.d(e,"breakpoints",function(){return i});var i={desktop:1/0,desktopHd:1919,phone:767,"phone-vertical":479,tablet:1019}},839:function(t,e,o){"use strict";(function(t,i){function n(t){return t&&t.__esModule?t:{default:t}}function s(t){var e,o;if(t&&t.__esModule)return t;if(e={},null!=t)for(o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e.default=t,e}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function a(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function c(){y.forEach(function(t){return t.close()})}var h,d,u,p,f,g,_,v,b,y,m,w,C,k,T,x,O;Object.defineProperty(e,"__esModule",{value:!0}),e.TVDialogAbstract=void 0,h=Object.assign||function(t){var e,o,i;for(e=1;e',errorTemplate:'
{{{ error }}}
', +titleTemplate:'
{{{ title }}}
',contentWrapTemplate:'
',actionsWrapTemplate:'
',closeButtonTemplate:'
'+o(828)+"
",helpButtonTemplate:'',helpActionsMod:"tv-dialog__section--actions_with-help"},T={default:"tv-button tv-button--default",primary:"tv-button tv-button--primary",success:"tv-button tv-button--success",danger:"tv-button tv-button--danger",warning:"tv-button tv-button--warning",link:"tv-button tv-button--link",checkbox:"tv-control-checkbox tv-control-checkbox--in-actions","default-ghost":"tv-button tv-button--default_ghost","primary-ghost":"tv-button tv-button--primary_ghost","success-ghost":"tv-button tv-button--success_ghost","danger-ghost":"tv-button tv-button--danger_ghost","warning-ghost":"tv-button tv-button--warning_ghost"},x={_default:'
{{ text }}
',"submit-success":''},$(function(){k.$wrap=$(document.all&&!document.querySelector?"html":"body")}),O=function(e){function o(){var e,i,n,s,l,c=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};for(r(this,o),e=a(this,(o.__proto__||Object.getPrototypeOf(o)).call(this)),e._id=b++,e.loadingActions=[],e.disabledActions=[],e.firstFocusControl=null,e.options=h({},k,c),e.$el=$(t.render(e.options.template,{title:e.options.title,closeButton:e.options.closeButton})),e.$el.addClass("js-dialog"),e.el=e.$el[0],e.options.addClass&&e.$el.addClass(e.options.addClass),e.options.width&&e.$el.css({width:"100%","max-width":e.options.width}),e.options.title&&(e.$title=$(t.render(e.options.titleTemplate,{title:e.options.title})).appendTo(e.$el)),e.$content=$(e.options.contentWrapTemplate).appendTo(e.$el),e.$contentIn=e.$content;e.$contentIn.length;)e.$contentIn=e.$contentIn.children();if(e.$contentIn=e.$contentIn.end(),e.options.content&&e.renderContent(e.options.content),(e.options.actions||e.options.help)&&(e.$content.hasClass("tv-dialog__section")&&e.$content.addClass("tv-dialog__section--no-padding_bottom"),e.$actions=$(e.options.actionsWrapTemplate).appendTo(e.$el)),e.options.actions)for(e.actions={},e.$el.on("click touchend",".js-dialog__action-click",function(t){t.preventDefault(),e.actionDispatcher($(t.currentTarget).data("name"))}),i=function(o){var i,n,s,r,a,l,c=e.options.actions[o];c.type||(c.type="default"),c.class||(c.class=T[c.type]?T[c.type]:T.default),"checkbox"===c.type?(i=new g.default({labelRight:c.text,name:c.name,checked:c.checked}),e.actions[c.name]=i.$el.appendTo(e.$actions),e.actions[c.name].on("change",function(){setTimeout(function(){ +return e.actionDispatcher(c.name,i.checked)})})):e.actions[c.name]=$(t.render(c.template?c.template:x[c.type]||x._default,c,c)).appendTo(e.$actions),c.method&&"function"==typeof e[c.method]&&e.on("action:"+c.name,e[c.method].bind(e)),c.addClass&&e.actions[c.name].addClass(c.addClass),c.key&&(n=void 0,"string"==typeof c.key&&c.key.split("+").length>1?(s=[],r=c.key.split("+"),n=function(t){s=[]},a=function(t){var o=""+t.keyCode;-1!==r.indexOf(o)&&s.indexOf(o)&&s.push(o),e._focused&&s.length===r.length&&(s=[],e.actionDispatcher(c.name))},e.on("afterOpen",function(){C.on("keydown",a),C.on("keyup",n)}),e.on("beforeClose",function(){C.off("keydown",a),C.off("keyup",n)})):(l=$.isArray(c.key)?c.key:[c.key],n=function(t){!t.isDefaultPrevented()&&e._focused&&-1!==l.indexOf(t.keyCode)&&e.actionDispatcher(c.name)},e.on("afterOpen",function(){return C.on("keyup",n)}),e.on("beforeClose",function(){return C.off("keyup",n)})))},n=e.options.actions.length-1;n>=0;n--)i(n);return e.options.help&&$(t.render(e.options.helpButtonTemplate,e.options.help)).prependTo(e.$actions.addClass(e.options.helpActionsMod)),e.options.closeButton&&(s=$(e.options.closeButtonTemplate),s.addClass(e.options.closeButtonAddClass||""),l=e.$el,1===e.$el.find(".js-close-button-place").length&&(l=e.$el.find(".js-close-button-place")),s.appendTo(l)),e.setZIndex(w+y.length),c.errorMod&&(e.errorMod=c.errorMod),e.on("afterOpen",function(){e.options.focusFirstControl&&!Modernizr.touch&&(e.firstFocusControl||e.$el.find('input:not([type="hidden"]), textarea').first()).focus()}),e.$el.on("click touchend",".js-dialog__close",e.close.bind(e)),e.$el.on("mousedown touchstart",e.focus.bind(e)),y.push(e),e}return l(o,e),d(o,[{key:"renderContent",value:function(t){return this.$contentIn.html("function"==typeof t?t(this):t),this}},{key:"setDestroyOnClose",value:function(t){this.options.destroyOnClose=t}},{key:"setZIndex",value:function(t){return this.zIndex=t,this.trigger("change:zIndex",[this]),this}},{key:"toTop",value:function(){for(var t=y.length-1;t>=0;t--)y[t].zIndex>this.zIndex&&y[t].setZIndex(y[t].zIndex-1);return this.setZIndex(w+y.length),this}},{key:"isEventOut",value:function(t){var e,o,i;return this.options.isClickOutFn&&void 0!==(e=this.options.isClickOutFn(t))?e:(o=!0,i=$(t.target),i.get(0)!==this.$el.get(0)&&($(">*",this.$el).each(function(){i.get(0)===$(this).get(0)&&(o=!1),0===i.closest("HTML",$(this).get(0)).length&&(o=!1)}),o))}},{key:"focus",value:function(){var t=this;m&&m!==this&&m.unfocus(),this._setFocused(),this._focused=!0,this.$el.addClass(this.options.focusClass),this.trigger("focus",[this]),setTimeout(function(){C.on("mousedown.tv-dialog-unfocus-"+t._id,function(e){t.isEventOut(e)&&(t.unfocus(),C.off("mousedown.tv-dialog-unfocus-"+t._id))})},20)}},{key:"_setFocused",value:function(){m!==this&&(m=this)}},{key:"_setUnfocused",value:function(){m===this&&(m=void 0)}},{key:"unfocus",value:function(){m===this&&(this._setUnfocused(),this._focused=!1,this.$el.removeClass(this.options.focusClass).find(":focus").blur(),this.trigger("unfocus",[this]))}},{ +key:"isFocused",value:function(){return this._focused}},{key:"setTitle",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return this.$title.toggleClass("tv-dialog__section--one-line apply-overflow-tooltip",e),this.$title.html(t),this}},{key:"setTitleText",value:function(t){this.$title.find(".js-title-text").text(t)}},{key:"actionDispatcher",value:function(t){if(!this.disabledActions.includes(t)&&!this.loadingActions.includes(t)){for(var e=arguments.length,o=Array(e>1?e-1:0),i=1;i1&&void 0!==arguments[1]?arguments[1]:"init";return this.actions[t].tvButtonLoader(o),"init"===o&&(this.actions[t].off("tv-button-loader:start.dialog-action").on("tv-button-loader:start.dialog-action",function(){e.loadingActions.push(t)}),this.actions[t].off("tv-button-loader:stop.dialog-action").on("tv-button-loader:stop.dialog-action",function(){e.loadingActions=i.without(e.loadingActions,t)})),this}},{key:"error",value:function(e){var o=$(t.render(this.options.errorTemplate,{error:e,errorMod:this.errorMod})).appendTo(this.$el),i=function(){o.addClass("i-slided"),setTimeout(function(){return o.remove()},.75*p.dur)};return setTimeout(function(){return o.removeClass("i-slided")},20),C.one("touchstart mousedown keydown",i),this.trigger("error",[this,o]),this}},{key:"destroy",value:function(){y=i.without(y,this);for(var t=0;t'+this.$btn.html()+''),this.loading=this.$btn.hasClass("i-loading")}return s(t,[{key:"_start",value:function(){var t=this;this.starting=!0,this.$btn.addClass("i-start-load"),this.$btn.trigger("tv-button-loader:start"),setTimeout(function(){t.loading=!0,t.starting=!1,t._startPromise=!1,t.$btn.addClass("i-loading"),t.$btn.removeClass("i-start-load"),t._stopPromise&&t._stop()},2*l.dur)}},{key:"start",value:function(){this.starting||(this.stopping?this._startPromise=!0:this._start())}},{key:"_stop",value:function(){var t=this;this.stopping=!0,this.$btn.addClass("i-stop-load"),this.$btn.trigger("tv-button-loader:stop"),setTimeout(function(){t.loading=!1,t.stopping=!1,t._stopPromise=!1,t.$btn.removeClass("i-loading i-start-load i-stop-load"),t._startPromise&&t._start()},l.dur)}},{key:"stop",value:function(){this.stopping||(this.starting?this._stopPromise=!0:this._stop())}},{key:"toggle",value:function(){this.loading?this.stop():this.start()}},{key:"contentHtml",value:function(t){return t?(this.$btn.find(".tv-button__text").html(t),t):this.$btn.find(".tv-button__text").html()}},{key:"contentNojQuery",value:function(){return this.$btn.get(0)}},{key:"disable",value:function(){this.stop(),this.$btn.addClass("i-disabled")}},{key:"enable",value:function(){this.$btn.removeClass("i-disabled")}}]),t}()},841:function(t,e){},842:function(t,e){},843:function(t,e,o){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function n(t){var e,o;if(t&&t.__esModule)return t;if(e={},null!=t)for(o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e.default=t,e}function s(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}var l,c,h,d,u,p,f,g,_,v,b,y,m;Object.defineProperty(e,"__esModule",{value:!0}),e.TVPopup=void 0,l=Object.assign||function(t){var e,o,i;for(e=1;e',scrollWrapInner:'
',withScroll:!0},m="js-dialog__scroll-wrap",e.TVPopup=function(t){function e(){var t,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return s(this,e),t=r(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,l({},y,o))),t.$scrollWrap=t.$content.hasClass(m)?t.$content:t.$content.find("."+m),t.$scrollWrap.length?t.$scrollWrapInner=t.$scrollWrap.children().first():(t.$scrollWrap=t.$content.wrap($(t.options.scrollWrap)).parent(),t.$scrollWrapInner=t.$content.wrap($(t.options.scrollWrapInner)).parent()),t.$actions&&t.$scrollWrap.addClass("i-with-actions"),t.options.withScroll&&(t.scroll=new g.SidebarCustomScroll(t.$scrollWrap,t.$scrollWrapInner),t.scroll.scrolled.subscribe(null,function(){return t.trigger("scroll")})),t.$scrollWrap.css("overflow",""),t.$el.addClass("tv-dialog--popup i-closed i-hidden"),t.options.width&&t.$el.css({width:"calc(100% - 20px)","max-width":t.options.width}),t.$el.on("mousedown touchstart",t.toTop.bind(t)),t.options.closeOnOutsideClick&&(t.on("beforeOpen",function(){setTimeout(function(){t.opened&&$(document).on("click.tv-popup-"+t.id,function(e){var o=$(e.target).closest(".js-dialog");(t.options.closeOnClickAtOtherDialogs||0===o.length)&&t.isEventOut(e)&&t.close()})},0)}),t.on("beforeClose",function(){return $(document).off("click.tv-popup-"+t.id)})),t.on("change:zIndex",function(){t.$el.css("z-index",t.zIndex)}),t.on("destroy",function(){var e=function(){t.$el.remove()};t.opened?(t.close(),setTimeout(e,d.dur/2)):e()}),t}return a(e,t),c(e,[{key:"open",value:function(){var t=this;return this.opened?this:(this.opened=!0,this.trigger("beforeOpen",[this]),this.$el.appendTo(this.options.$wrap).removeClass("i-hidden").css(function(){var e,o,i,n,s;return t.calcHeight(),e=b.height(),o=b.width(),i=t.$el.height(),n=t.$el.width(),s=t.options.position,s||(s={top:e/2-i/2,left:o/2-n/2}),s.top>e-i&&(s.top=e-i),s.left>o-n&&(s.left=o-n),s}()),this.focus(),this.toTop(),this._doOpenAnimation().then(function(){t.opened&&(t.$el.removeClass("i-closed"),t.options.draggable&&((0,_.lazyJqueryUI)(t.$el).draggable({handle:".js-dialog__drag",cancel:"input, textarea, button, select, option, .js-dialog__no-drag, .js-dialog__close",containment:"window",cursor:"-webkit-grabbing"}),t.$el.find(".js-dialog__drag").addClass("tv-dialog__grab")),t.trigger("afterOpen",[t]))}),b.on("resize.tv-popup-"+this.id,function(){t.calcHeight(),t.fixPos()}),this)}},{key:"close",value:function(){var t=this;if(this.opened)return this.trigger("beforeClose",[this]),this.$el.addClass("i-closed"),this.opened=!1,this._doCloseAnimation().then(function(){t.opened||((0,_.lazyJqueryUI)(t.$el).draggable("instance").then(function(t){t&&t.destroy()}),t.$el.addClass("i-hidden").detach(),v.css("cursor","auto"),t.trigger("afterClose",[t]),t.options.destroyOnClose&&t.destroy())}),b.off("resize.tv-popup-"+this.id),this}},{key:"hide",value:function(){this.$el.addClass("i-hidden")}},{key:"show",value:function(){this.$el.removeClass("i-hidden")} +},{key:"fixPos",value:function(){var t=this.$el[0].getBoundingClientRect(),e={};t.bottom>p.default.height-10&&(e.top=p.default.height-10-t.height,e.top<10&&(e.top=10)),t.right>p.default.width-10&&(e.left=p.default.width-10-t.width,e.left<10&&(e.left=10)),(e.top||e.left)&&this.$el.css(e)}},{key:"calcHeight",value:function(){var t,e,o=this.$el[0].getBoundingClientRect(),i=this.$scrollWrapInner[0].getBoundingClientRect(),n=this.$scrollWrap[0].getBoundingClientRect(),s=this.options.height&&this.options.heights)&&(s-=o.height-n.height,s<60&&(s=60),this.$scrollWrap.css({height:s})),this.options.withScroll&&this.scroll.resize(),e=s=t()?"":s.favorites[e]}function l(o){return!r(o)&&(s.favorites.push(o),s.saveFavorites(),e.favoriteAdded.fire(o),!0)}function a(o){var t=s.favoriteIndex(o);return-1!==t&&(s.favorites.splice(t,1),s.saveFavorites(),e.favoriteRemoved.fire(o),!0)}function r(e){return-1!==s.favoriteIndex(e)}function c(o,n){if(n<0||n>=t())return!1;var i=s.favoriteIndex(o);return-1!==i&&n!==i&&(s.favorites.splice(i,1),s.favorites.splice(n,0,o),s.saveFavorites(),e.favoriteMoved.fire(o,i,n),!0)}e.favoriteAdded=new i.a,e.favoriteRemoved=new i.a,e.favoriteMoved=new i.a,e.favoritesSynced=s.favoritesSynced,e.favorites=o,e.favoritesCount=t,e.favorite=n,e.addFavorite=l,e.removeFavorite=a,e.isFavorite=r,e.moveFavorite=c}(a||(a={}))},1092:function(e,o){e.exports={wrap:"wrap-1h7U5nKd-",scrollWrap:"scrollWrap-3gtPS0Fe-",noScrollBar:"noScrollBar-ieMwbfur-",content:"content-YhoA_L2m-",icon:"icon-2xObs8DI-",scrollBot:"scrollBot-2HHpZNuf-",scrollTop:"scrollTop-1eXi8ltS-",isVisible:"isVisible-3zZOL3TO-",iconWrap:"iconWrap-2Q69rfEO-",fadeBot:"fadeBot-3JstnoWq-",fadeTop:"fadeTop-3oJzNyTq-"}},1093:function(e,o){e.exports={button:"button-263WXsg--",bg:"bg-1kRv1Pf2-",isBgFull:"isBgFull-CmoDGRQP-",icon:"icon-1Y-3MM9F-",hovered:"hovered--MYZioUu-",isActive:"isActive-2mI1-NUL-",isGrayed:"isGrayed-1kWObWVr-",isTransparent:"isTransparent-sRmateFl-",isHidden:"isHidden-2VzaskeU-"}},1094:function(e,o){e.exports={dropdown:"dropdown-3_ASLzSj-",buttonWrap:"buttonWrap-3fZWypJl-",control:"control-1TyEfSIx-",arrow:"arrow-1cFKS5Ok-",arrowIcon:"arrowIcon-2wA7q8om-",isOpened:"isOpened-22vLOY9o-",isGrayed:"isGrayed-xr-mULNo-"}},1095:function(e,o){e.exports={wrap:"wrap-2I6DAtXG-",buttonIcon:"buttonIcon-2rBwJ1QM-",item:"item-31XunD5q-",hovered:"hovered-2A1Cpat5-",button:"button-21ihqWJ8-"}},1096:function(e,o){e.exports={item:"item-62xp8vsV-",enter:"enter-21AyqfcZ-",enterActive:"enterActive-kua-y7K8-",leave:"leave-4EzZ54xf-"}},1097:function(e,o){e.exports={container:"container-3_8ayT2Q-",mirror:"mirror-crJbq8d0-",background:"background-Q1Fcmxly-",arrow:"arrow-WcYWFXUn-"}},1098:function(e,o){e.exports={drawingToolbar:"drawingToolbar-U3_QXRof-",isHidden:"isHidden-2d-PYkzV-",inner:"inner-1xuW-gY4-",toggleButton:"toggleButton-13QgefpG-",collapsed:"collapsed-2trH0gCi-", +group:"group-2JyOhh7Z-",separator:"separator-1BAqp1-l-"}},701:function(e,o,t){"use strict";function n(e){var o,t=e.activeClass,n=e.children,i=e.className,l=e.icon,s=e.isActive,a=e.isBgFull,c=e.isGrayed,d=e.isHidden,p=e.isTransparent,v=e.onClick,z=e.title,u=e.buttonHotKey;return r.createElement("div",{className:h(A.button,i,s?t:"",(o={},o["apply-common-tooltip common-tooltip-vertical"]=!!z,o[A.isActive]=s,o[A.isBgFull]=a,o[A.isGrayed]=c,o[A.isHidden]=d,o[A.isTransparent]=p,o)),onClick:v,title:z,"data-tooltip-hotkey":u},r.createElement("div",{className:A.bg},l&&("string"==typeof l?r.createElement(T.a,{className:A.icon,icon:l}):r.createElement("span",{className:A.icon},l)),n))}function i(e){var o=e.action,t=e.isActive,i=e.isBgFull,l=e.isHidden,s=e.isTransparent,a=e.toolName;return r.createElement(n,{icon:g.a[a].icon,isActive:t,isBgFull:i,isHidden:l,isTransparent:s,onClick:o,title:g.a[a].localizedName})}function l(e){return r.createElement("svg",{xmlns:ie,width:"9",height:"27",viewBox:"0 0 9 27",className:h(ne.container,"right"===e.direction?ne.mirror:null)},r.createElement("g",{fill:"none",fillRule:"evenodd"},r.createElement("path",{className:ne.background,d:"M4.5.5a4 4 0 0 1 4 4v18a4 4 0 1 1-8 0v-18a4 4 0 0 1 4-4z"}),r.createElement("path",{className:ne.arrow,d:"M5.5 10l-2 3.5 2 3.5"})))}var s,a,r,c,h,d,p,v,z,u,g,m,w,f,M,T,L,x,b,y,C,_,B,N,A,k,S,E,D,I,P,F,R,O,W,V,H,j,G,U,K,Z,q,J,Q,Y,X,$,ee,oe,te,ne,ie,le,se,ae,re,ce;Object.defineProperty(o,"__esModule",{value:!0}),s=t(1),t(11),a=t(127),r=t(20),c=t(59),h=t(102),d=t(49),p=t(5),v=t(32),z=t(31),u=t(71),g=t(853),m=function(){function e(e){this._drawingsAccess=e||{tools:[],type:"black"}}return e.prototype.isToolEnabled=function(e){var o=this._findTool(e);return!(!o||!o.grayed)||("black"===this._drawingsAccess.type?!o:!!o)},e.prototype.isToolGrayed=function(e){var o=this._findTool(e);return!(!o||!o.grayed)},e.prototype._findTool=function(e){return this._drawingsAccess.tools.find(function(o){return o.name===e})},e}(),w=[[{name:"cursor"},{name:"dot"},{name:"arrow"},{name:"eraser"}],[{name:"LineToolTrendLine"},{name:"LineToolInfoLine"},{name:"LineToolTrendAngle"},{name:"LineToolHorzLine",shortcut:{keys:"Alt+H",immediately:!0}},{name:"LineToolHorzRay"},{name:"LineToolVertLine",shortcut:{keys:"Alt+V",immediately:!0}},{name:"LineToolCrossLine",shortcut:{keys:"Alt+C",immediately:!0}},{name:"LineToolArrow"},{name:"LineToolRay"},{name:"LineToolExtended"},{name:"LineToolParallelChannel"},{name:"LineToolDisjointAngle"},{name:"LineToolFlatBottom"},null].filter(Boolean),[{name:"LineToolPitchfork"},{name:"LineToolSchiffPitchfork2"},{name:"LineToolSchiffPitchfork"},{name:"LineToolInsidePitchfork"},{name:"LineToolPitchfan"},{name:"LineToolGannSquare"},{name:"LineToolGannComplex"},{name:"LineToolGannFixed"},{name:"LineToolGannFan"},{name:"LineToolFibRetracement"},{name:"LineToolTrendBasedFibExtension"},{name:"LineToolFibSpeedResistanceFan"},{name:"LineToolFibTimeZone"},{name:"LineToolTrendBasedFibTime"},{name:"LineToolFibCircles"},{name:"LineToolFibSpiral"},{ +name:"LineToolFibSpeedResistanceArcs"},{name:"LineToolFibWedge"},{name:"LineToolFibChannel"}],[{name:"LineToolBrush"},{name:"LineToolRectangle"},{name:"LineToolRotatedRectangle"},{name:"LineToolEllipse"},{name:"LineToolTriangle"},{name:"LineToolPolyline"},{name:"LineToolBezierQuadro"},{name:"LineToolBezierCubic"},{name:"LineToolArc"}],[{name:"LineToolText"},{name:"LineToolTextAbsolute"},{name:"LineToolNote"},{name:"LineToolNoteAbsolute"},{name:"LineToolCallout"},{name:"LineToolBalloon"},{name:"LineToolPriceLabel"},{name:"LineToolArrowMarkLeft"},{name:"LineToolArrowMarkRight"},{name:"LineToolArrowMarkUp"},{name:"LineToolArrowMarkDown"},{name:"LineToolFlagMark"}],[{name:"LineTool5PointsPattern"},{name:"LineToolCypherPattern"},{name:"LineToolABCD"},{name:"LineToolTrianglePattern"},{name:"LineToolThreeDrivers"},{name:"LineToolHeadAndShoulders"},{name:"LineToolElliottImpulse"},{name:"LineToolElliottTriangle"},{name:"LineToolElliottTripleCombo"},{name:"LineToolElliottCorrection"},{name:"LineToolElliottDoubleCombo"},{name:"LineToolCircleLines"},{name:"LineToolTimeCycles"},{name:"LineToolSineLine"}],[{name:"LineToolRiskRewardLong"},{name:"LineToolRiskRewardShort"},{name:"LineToolPrediction"},{name:"LineToolDateRange"},{name:"LineToolPriceRange"},{name:"LineToolDateAndPriceRange"},{name:"LineToolBarsPattern"},{name:"LineToolGhostFeed"},{name:"LineToolProjection"}]],f=t(206),M=t(313),T=t(300),L=t(194),x=t(1092),b=t(184),y=t(990),C=function(e){function o(o){var t=e.call(this,o)||this;return t._scroll=null,t._handleScrollTop=function(){t.animateTo(Math.max(0,t.currentPosition()-(t.state.heightWrap-50)))},t._handleScrollBot=function(){t.animateTo(Math.min((t.state.heightContent||0)-(t.state.heightWrap||0),t.currentPosition()+(t.state.heightWrap-50)))},t._handleResizeWrap=function(e){var o=e.height;t.setState({heightWrap:o})},t._handleResizeContent=function(e){var o=e.height;t.setState({heightContent:o})},t._handleScroll=function(){var e=t.props.onScroll;e&&e(t.currentPosition(),t.isAtTop(),t.isAtBot()),t._checkButtonsVisibility()},t._checkButtonsVisibility=function(){var e,o,n,i,l;(t.props.isVisibleButtons||t.props.isVisibleFade)&&(e=t.state,o=e.isVisibleTopButton,n=e.isVisibleBotButton,i=t.isAtTop(),l=t.isAtBot(),i||o?i&&o&&t.setState({isVisibleTopButton:!1}):t.setState({isVisibleTopButton:!0}),l||n?l&&n&&t.setState({isVisibleBotButton:!1}):t.setState({isVisibleBotButton:!0}))},t.state={heightContent:0,heightWrap:0,isVisibleBotButton:!1,isVisibleTopButton:!1},t}return s.c(o,e),o.prototype.componentDidMount=function(){this._checkButtonsVisibility()},o.prototype.componentDidUpdate=function(e,o){o.heightWrap===this.state.heightWrap&&o.heightContent===this.state.heightContent||this._handleScroll()},o.prototype.currentPosition=function(){return this._scroll?this._scroll.scrollTop:0},o.prototype.isAtTop=function(){return this.currentPosition()<=1},o.prototype.isAtBot=function(){return this.currentPosition()+this.state.heightWrap>=this.state.heightContent-1},o.prototype.animateTo=function(e,o){if(void 0===o&&(o=b.dur),this._scroll){ +var t=c.findDOMNode(this._scroll);Object(L.doAnimate)({onStep:function(e,o){t.scrollTop=o},from:t.scrollTop,to:Math.round(e),easing:b.easingFunc.easeInOutCubic,duration:o})}},o.prototype.render=function(){var e,o,t,n,i,l=this,s=this.props,a=s.children,c=s.isVisibleScrollbar,d=s.isVisibleFade,p=s.isVisibleButtons,v=this.state,z=v.heightContent,u=v.heightWrap,g=v.isVisibleBotButton,m=v.isVisibleTopButton;return r.createElement(M,{whitelist:["height"],onMeasure:this._handleResizeWrap},r.createElement("div",{className:x.wrap},r.createElement("div",{className:h(x.scrollWrap,(e={},e[x.noScrollBar]=!c,e)),onScroll:this._handleScroll,ref:function(e){return l._scroll=e}},r.createElement(M,{onMeasure:this._handleResizeContent,whitelist:["height"]},r.createElement("div",{className:x.content},a))),d&&r.createElement("div",{className:h(x.fadeTop,(o={},o[x.isVisible]=m&&z>u,o))}),d&&r.createElement("div",{className:h(x.fadeBot,(t={},t[x.isVisible]=g&&z>u,t))}),p&&r.createElement("div",{className:h(x.scrollTop,(n={},n[x.isVisible]=m&&z>u,n)),onClick:this._handleScrollTop},r.createElement("div",{className:x.iconWrap},r.createElement(T.a,{icon:y,className:x.icon}))),p&&r.createElement("div",{className:h(x.scrollBot,(i={},i[x.isVisible]=g&&z>u,i)),onClick:this._handleScrollBot},r.createElement("div",{className:x.iconWrap},r.createElement(T.a,{icon:y,className:x.icon})))))},o.defaultProps={isVisibleScrollbar:!0},o}(r.PureComponent),_=t(852),B=t(324),N=t(844),A=t(1093),k=t(133),S=t(335),E=t(872),D=t(1094),I=t(1008),P=function(e){function o(o){var t=e.call(this,o)||this;return t._toggleDropdown=function(e){t.setState({isOpened:void 0!==e?e:!t.state.isOpened})},t._handleClose=function(){t._toggleDropdown(!1)},t._getDropdownPosition=function(){if(!t._control)return{x:0,y:0};var e=t._control.getBoundingClientRect();return{x:e.left+e.width+1,y:e.top-6}},t._handleClickArrow=function(){t._toggleDropdown()},t._handleTouchStart=function(){t.props.onClickButton(),t._toggleDropdown()},t._handlePressStart=function(){if(Modernizr.touch)t._longPressDelay||t.props.onClickButton();else{if(t._doubleClickDelay)return clearTimeout(t._doubleClickDelay),delete t._doubleClickDelay,void t._toggleDropdown(!0);t._doubleClickDelay=setTimeout(function(){delete t._doubleClickDelay,t._longPressDelay||t.props.onClickButton()},175)}t._longPressDelay=setTimeout(function(){delete t._longPressDelay,t._toggleDropdown(!0)},300)},t._handlePressEnd=function(){t._longPressDelay&&(clearTimeout(t._longPressDelay),delete t._longPressDelay,t.state.isOpened?t._toggleDropdown(!1):t.state.isOpened||!t.props.isActive||Modernizr.touch||t._toggleDropdown(!0))},t.state={isOpened:!1},t}return s.c(o,e),o.prototype.render=function(){var e,o=this,t=this.props,i=t.buttonActiveClass,l=t.buttonClass,s=t.buttonIcon,a=t.buttonTitle,c=t.buttonHotKey,d=t.children,p=t.isActive,v=t.isGrayed,z=t.onClickWhenGrayed,u=this.state.isOpened;return r.createElement("div",{className:h(D.dropdown,(e={},e["apply-common-tooltip common-tooltip-vertical"]=!!a,e[D.isGrayed]=v,e[D.isActive]=p,e[D.isOpened]=u,e)), +onClick:v?z:void 0,title:a,"data-tooltip-hotkey":c,"data-tooltip-delay":1500},r.createElement("div",{ref:function(e){return o._control=e},className:D.control},r.createElement("div",{className:D.buttonWrap,onMouseDown:v||Modernizr.touch?void 0:this._handlePressStart,onMouseUp:v||Modernizr.touch?void 0:this._handlePressEnd,onClick:!v&&Modernizr.touch?this._handleTouchStart:void 0},r.createElement(n,{activeClass:i,className:l,icon:s,isActive:p,isGrayed:v,isTransparent:!0})),!v&&!Modernizr.touch&&r.createElement("div",{className:D.arrow,onClick:this._handleClickArrow},r.createElement(T.a,{className:D.arrowIcon,icon:I}))),!v&&r.createElement(E.a,{doNotCloseOn:this,isOpened:u,onClose:this._handleClose,position:this._getDropdownPosition},d))},o}(r.PureComponent),F=t(849),R=t(1095),O={icon:window.t("Icon")},W=10,V=function(e){function o(o){var t=e.call(this,o)||this;return t._renderItem=function(e){return r.createElement("div",{className:R.item,key:e,onClick:function(){t._handleSelect(e),Object(N.b)()}},String.fromCharCode(e))},t._onChangeDrawingState=function(){t.setState({isActive:t._isActive()})},t._handleSelect=function(e){var o,n;Object(k.saveDefaults)("linetoolicon",s.a({},Object(k.defaults)("linetoolicon"),{icon:e})),v.tool.setValue("LineToolIcon"),o=t.state.recents,n=o.indexOf(e),-1!==n&&o.splice(n,1),o=[e].concat(o.slice(0,W-1)),Object(d.setJSON)("linetoolicon.recenticons",o),t.setState({current:e,recents:o})},t.state={current:Object(k.defaults)("linetoolicon").icon,recents:Object(d.getJSON)("linetoolicon.recenticons")||[]},t}return s.c(o,e),o.prototype.componentDidMount=function(){v.tool.subscribe(this._onChangeDrawingState),d.onSync.subscribe(this,this._onSyncSettings)},o.prototype.componentWillUnmount=function(){v.tool.unsubscribe(this._onChangeDrawingState),d.onSync.unsubscribe(this,this._onSyncSettings)},o.prototype.render=function(){var e=this,o=this.props,t=o.isGrayed,n=o.toolName,i=this.state,l=i.current,s=i.isActive,a=i.recents;return r.createElement(P,{buttonClass:R.button,buttonIcon:r.createElement("div",{className:R.buttonIcon},String.fromCharCode(l||S.availableIcons[0])),buttonTitle:O.icon,isActive:s,isGrayed:t,onClickButton:function(){return e._handleSelect(l||S.availableIcons[0])},onClickWhenGrayed:function(){return Object(z.emit)("onGrayedObjectClicked",{type:"drawing",name:g.a[n].localizedName})}},a&&[r.createElement("div",{key:"recent",className:R.wrap},a.map(this._renderItem)),r.createElement(F.a,{key:"separator"})],r.createElement("div",{key:"all",className:R.wrap},S.availableIcons.map(this._renderItem)))},o.prototype._isActive=function(){return v.tool.value()===this.props.toolName},o.prototype._onSyncSettings=function(){this.setState({recents:Object(d.getJSON)("linetoolicon.recenticons")})},o}(r.Component),H=t(3),j=function(e){function o(o){var t=e.call(this,o)||this;return t._handleClick=function(){t.props.saveDefaultOnChange&&Object(H.saveDefaultProperties)(!0),t.props.property.setValue(!t.props.property.value()),t.props.saveDefaultOnChange&&Object(H.saveDefaultProperties)(!1)},t.state={ +isActive:t.props.property.value()},t}return s.c(o,e),o.prototype.componentDidMount=function(){this.props.property.subscribe(this,this._onChange)},o.prototype.componentWillUnmount=function(){this.props.property.unsubscribe(this,this._onChange)},o.prototype.render=function(){var e=this.props.toolName,o=this.state.isActive,t=g.a[e];return r.createElement(n,{icon:o&&t.iconActive?t.iconActive:t.icon,isActive:o,onClick:this._handleClick,title:t.localizedName})},o.prototype._onChange=function(e){this.setState({isActive:e.value()})},o}(r.PureComponent),G=function(e){function o(o){var t=e.call(this,o)||this;return t._handleClick=function(){v.tool.setValue(t.props.toolName)},t._onChange=function(){t.setState({isActive:v.tool.value()===t.props.toolName})},t.state={isActive:v.tool.value()===t.props.toolName},t}return s.c(o,e),o.prototype.componentDidMount=function(){v.tool.subscribe(this._onChange)},o.prototype.componentWillUnmount=function(){v.tool.unsubscribe(this._onChange)},o.prototype.render=function(){var e=this.props.toolName,o=this.state.isActive,t=g.a[e];return r.createElement(n,{icon:g.a[e].icon,isActive:o,isTransparent:!0,onClick:this._handleClick,title:t.localizedName,buttonHotKey:t.hotKey})},o}(r.PureComponent),U=t(302),K=t(1096),Z=function(e){function o(){return null!==e&&e.apply(this,arguments)||this}return s.c(o,e),o.prototype.render=function(){var e=this.props.enterAnimationClass,o=void 0===e?K.enter:e,t=this.props.enterActiveAnimationClass,n=void 0===t?K.enterActive:t,i=this.props.enterLeaveAnimationClass,l=void 0===i?K.leave:i,s=this.props.itemClassName,a=void 0===s?K.item:s;return r.createElement(U.CSSTransitionGroup,{transitionName:{enter:o,enterActive:n,leave:l},transitionEnter:!0,transitionEnterTimeout:b.dur/2,transitionLeave:!0,transitionLeaveTimeout:.75*b.dur},this.props.isVisible&&r.createElement("div",{key:"button",className:a},this.props.children))},o}(r.PureComponent),q=function(e){function o(o){var t=e.call(this,o)||this;return t._boundUndoModel=null,t._handleClick=function(){var e=t._activeChartWidget().model();e&&e.zoomFromViewport()},t._syncUnzoomButton=function(){var e=t._activeChartWidget(),o=e.model(),n=!1;o?(t._boundUndoModel!==o&&(t._boundUndoModel&&t._boundUndoModel.zoomStack().onChange().unsubscribe(null,t._syncUnzoomButton),o.zoomStack().onChange().subscribe(null,t._syncUnzoomButton),t._boundUndoModel=o),n=!o.zoomStack().isEmpty()):e.withModel(null,t._syncUnzoomButton),t.setState({isVisible:n})},t.state={isVisible:!1},t}return s.c(o,e),o.prototype.componentDidMount=function(){this.props.chartWidgetCollection.activeChartWidget.subscribe(this._syncUnzoomButton,{callWithLast:!0})},o.prototype.componentWillUnmount=function(){this.props.chartWidgetCollection.activeChartWidget.unsubscribe(this._syncUnzoomButton)},o.prototype.render=function(){return r.createElement(Z,{isVisible:this.state.isVisible},r.createElement(i,{action:this._handleClick,isTransparent:!0,toolName:"zoom-out"}))},o.prototype._activeChartWidget=function(){return this.props.chartWidgetCollection.activeChartWidget.value()},o +}(r.PureComponent),J=t(1009),Q=t(878),Y=t(846),X=t(189),$=function(e){function o(){return null!==e&&e.apply(this,arguments)||this}return s.c(o,e),o.prototype.componentDidMount=function(){X.bind(this.props.keys,this.props.handler)},o.prototype.componentDidUpdate=function(e){this.props.keys===e.keys&&this.props.handler===e.handler||(X.unbind(e.keys),X.bind(this.props.keys,this.props.handler))},o.prototype.componentWillUnmount=function(){X.unbind(this.props.keys)},o.prototype.render=function(){return null},o}(r.PureComponent),ee=function(e){function o(o){var t,n=e.call(this,o)||this;return n._onChangeDrawingState=function(){var e=n._getActiveToolIndex();n.setState({current:-1!==e?e:n.state.current,isActive:-1!==e})},n._handleClickButton=function(){var e=n._getCurrentToolName();n._selectTool(e)},n._handleClickItem=function(e){n._selectTool(e)},n._handleGrayedClick=function(e){Object(z.emit)("onGrayedObjectClicked",{type:"drawing",name:g.a[e].localizedName})},n._handleShortcut=function(e){var o=n.props.lineTools.find(function(o){return o.name===e}),t=o&&o.shortcut;t&&t.immediately?n._drawLinetoolImmediately(e):n._selectTool(e)},n._drawLinetoolImmediately=function(e){var o=n.props.chartWidgetCollection.activeChartWidget.value();o.activePaneWidget&&o.activePaneWidget.drawRightThere(e)},n._handleClickFavorite=function(e){n.state.favState&&n.state.favState[e]?J.a.removeFavorite(e):J.a.addFavorite(e)},n._onAddFavorite=function(e){var o;n.setState({favState:s.a({},n.state.favState,(o={},o[e]=!0,o))})},n._onRemoveFavorite=function(e){var o;n.setState({favState:s.a({},n.state.favState,(o={},o[e]=!1,o))})},n._onSyncFavorites=function(){n.setState({favState:n._composeFavState()})},t=n._getActiveToolIndex(),n.state={current:-1===t?n._firstNonGrayedTool():t,favState:n._composeFavState(),isActive:-1!==t},n}return s.c(o,e),o.prototype.componentDidMount=function(){v.tool.subscribe(this._onChangeDrawingState),J.a.favoriteAdded.subscribe(null,this._onAddFavorite),J.a.favoriteRemoved.subscribe(null,this._onRemoveFavorite),J.a.favoritesSynced.subscribe(null,this._onSyncFavorites)},o.prototype.componentWillUnmount=function(){v.tool.unsubscribe(this._onChangeDrawingState),J.a.favoriteAdded.unsubscribe(null,this._onAddFavorite),J.a.favoriteRemoved.unsubscribe(null,this._onRemoveFavorite),J.a.favoritesSynced.unsubscribe(null,this._onSyncFavorites)},o.prototype.componentDidUpdate=function(e,o){e.lineTools!==this.props.lineTools&&this.setState({favState:this._composeFavState()})},o.prototype.render=function(){var e=this,o=this.props,t=o.favoriting,n=o.grayedTools,i=o.lineTools,l=this.state,s=l.current,a=l.favState,c=l.isActive,h=this._getCurrentToolName(),d=g.a[h],p=this._showHint();return r.createElement("span",null,r.createElement(P,{buttonIcon:d.icon,buttonTitle:d.localizedName,buttonHotKey:d.hotKey,isActive:c,onClickButton:this._handleClickButton},i.map(function(o,i){var l=o.name,h=g.a[l],d=n[l];return r.createElement(Y.a,{key:l,dontClosePopup:d,forceShowHint:p,hint:o.shortcut&&o.shortcut.keys,icon:h.icon,isActive:c&&s===i,appearAsDisabled:d, +label:h.localizedName,onClick:d?e._handleGrayedClick:e._handleClickItem,onClickArg:l,showToolboxOnHover:!a[l],toolbox:t&&!d?r.createElement(Q.a,{isFilled:a[l],onClick:e._handleClickFavorite,onClickArg:l}):void 0})})),i.map(function(o,t){var n=o.name,i=o.shortcut;return i&&r.createElement($,{handler:function(o){o.preventDefault(),e._handleShortcut(n)},key:n,keys:i.keys})}))},o.prototype._getCurrentToolName=function(){var e=this.state.current;return this.props.lineTools[e||0].name},o.prototype._firstNonGrayedTool=function(){var e=this.props,o=e.grayedTools;return e.lineTools.findIndex(function(e){return!o[e.name]})},o.prototype._getActiveToolIndex=function(){return this.props.lineTools.findIndex(function(e){return e.name===v.tool.value()})},o.prototype._showHint=function(){return this.props.lineTools.some(function(e){return"shortcut"in e})},o.prototype._selectTool=function(e){v.tool.setValue(e)},o.prototype._composeFavState=function(){var e={};return this.props.lineTools.forEach(function(o){e[o.name]=J.a.isFavorite(o.name)}),e},o}(r.PureComponent),oe={all:window.t("Remove Drawing Tools & Indicators"),drawings:window.t("Remove Drawing Tools"),studies:window.t("Remove Indicators")},te=function(e){function o(){var o=null!==e&&e.apply(this,arguments)||this;return o._handleRemoveDrawings=function(){o.props.chartWidgetCollection.activeChartWidget.value().removeAllDrawingTools()},o._handleRemoveStudies=function(){o.props.chartWidgetCollection.activeChartWidget.value().removeAllStudies()},o._handleRemoveAll=function(){o.props.chartWidgetCollection.activeChartWidget.value().removeAllStudiesDrawingTools()},o}return s.c(o,e),o.prototype.render=function(){return r.createElement(P,{buttonIcon:g.a[this.props.toolName].icon,buttonTitle:oe.drawings,onClickButton:this._handleRemoveDrawings},r.createElement(Y.a,{label:oe.drawings,onClick:this._handleRemoveDrawings}),r.createElement(Y.a,{label:oe.studies,onClick:this._handleRemoveStudies}),r.createElement(Y.a,{label:oe.all,onClick:this._handleRemoveAll}))},o}(r.PureComponent),ne=t(1097),ie="http://www.w3.org/2000/svg",le=t(334),se=t(1098),t.d(o,"DrawingToolbar",function(){return ce}),ae={hide:window.t("Hide Drawings Toolbar"),show:window.t("Show Drawings Toolbar")},re=Object(u.onWidget)(),ce=function(e){function o(o){var t=e.call(this,o)||this;return t._grayedTools={},t._handleChangeVisibility=function(e){t.setState({isVisible:e})},t._toggleVisibility=function(){f.isDrawingToolbarVisible.setValue(!f.isDrawingToolbarVisible.value())},t._handleEsc=function(){v.resetToCursor(!0),Object(N.b)()},v.init(),t._toolsFilter=new m(t.props.drawingsAccess),t._filteredLineTools=w.map(function(e){return e.filter(function(e){return t._toolsFilter.isToolEnabled(g.a[e.name].localizedName)})}).filter(function(e){return 0!==e.length}),t._filteredLineTools.forEach(function(e){return e.forEach(function(e){t._grayedTools[e.name]=t._toolsFilter.isToolGrayed(g.a[e.name].localizedName)})}),t.state={isVisible:f.isDrawingToolbarVisible.value()},t._features={favoriting:!re&&p.enabled("items_favoriting"), +multicharts:p.enabled("support_multicharts"),tools:!re||p.enabled("charting_library_base")},t._negotiateResizer(),t}return s.c(o,e),o.prototype.componentDidMount=function(){f.isDrawingToolbarVisible.subscribe(this._handleChangeVisibility),c.findDOMNode(this).addEventListener("contextmenu",function(e){return e.preventDefault()})},o.prototype.componentWillUnmount=function(){f.isDrawingToolbarVisible.unsubscribe(this._handleChangeVisibility)},o.prototype.componentDidUpdate=function(e,o){var t=this.state.isVisible;t!==o.isVisible&&(z.emit("toggle_sidebar",!t),d.setValue("ChartDrawingToolbarWidget.visible",t),this._negotiateResizer())},o.prototype.render=function(){var e,o=this,t=this.props,n=t.bgColor,s=t.chartWidgetCollection,a=t.readOnly,c=this.state.isVisible,d={backgroundColor:n&&"#"+n};return r.createElement("div",{className:h(se.drawingToolbar,(e={},e[se.isHidden]=!c,e)),style:d},r.createElement(C,{onScroll:N.b,isVisibleFade:Modernizr.touch,isVisibleButtons:!Modernizr.touch,isVisibleScrollbar:!1},r.createElement("div",{className:se.inner},!1,!a&&r.createElement("div",{className:se.group,style:d},this._filteredLineTools.map(function(e,t){return r.createElement(ee,{chartWidgetCollection:s,favoriting:o._features.favoriting,grayedTools:o._grayedTools,key:t,lineTools:e})}),this._toolsFilter.isToolEnabled("Font Icons")&&r.createElement(V,{isGrayed:this._grayedTools["Font Icons"],toolName:"LineToolIcon"})),!a&&r.createElement("div",{className:se.group,style:d},r.createElement(G,{toolName:"measure"}),r.createElement(G,{toolName:"zoom"}),r.createElement(q,{chartWidgetCollection:s})),!a&&r.createElement("div",{className:se.group,style:d},r.createElement(j,{property:v.properties().magnet,saveDefaultOnChange:!0,toolName:"magnet"}),this._features.tools&&r.createElement(j,{property:v.properties().stayInDrawingMode,saveDefaultOnChange:!0,toolName:"drawginmode"}),this._features.tools&&r.createElement(j,{property:v.lockDrawings(),toolName:"lockAllDrawings"}),this._features.tools&&r.createElement(j,{property:v.hideAllDrawings(),toolName:"hideAllDrawings"}),!1),!a&&this._features.tools&&r.createElement("div",{className:se.group,style:d},r.createElement(i,{action:function(){return o._activeChartWidget().showObjectsTreeDialog()},toolName:"showObjectsTree"}),r.createElement(te,{chartWidgetCollection:s,toolName:"removeAllDrawingTools"})))),r.createElement("div",{className:h(se.toggleButton,"apply-common-tooltip common-tooltip-vertical",!c&&se.collapsed),onClick:this._toggleVisibility,title:c?ae.hide:ae.show},r.createElement(l,{direction:c?"left":"right"})),r.createElement(_.a,{keyCode:B.a.Escape,handler:this._handleEsc}))},o.prototype._activeChartWidget=function(){return this.props.chartWidgetCollection.activeChartWidget.value()},o.prototype._negotiateResizer=function(){this.props.resizerBridge.negotiateWidth(this.state.isVisible?le.b:le.a)},o}(r.PureComponent)},844:function(e,o,t){"use strict";function n(){v.fire()}var i,l,s,a,r,c,h,d,p,v;t.d(o,"a",function(){return p}),o.b=n,i=t(1),l=t(20),t.n(l),s=t(102),t.n(s),a=t(7),t.n(a),r=t(50), +c=t(871),t.n(c),h=t(8),d=t.n(h),p=function(e){function o(o){var t=e.call(this,o)||this;return t._containerRef=null,t._scrollWrapRef=null,t._handleContainerRef=function(e){return t._containerRef=e},t._handleScrollWrapRef=function(e){return t._scrollWrapRef=e},t._handleMeasure=function(){var e,o,n,i,l,s,c,h,d,p,v,z,u,g,m,w,f;t.state.isMeasureValid||(e=t.props.position,o=Object(a.ensureNotNull)(t._containerRef),n=o.getBoundingClientRect(),i=document.documentElement.clientHeight,l=document.documentElement.clientWidth,s=i-10,c=n.height>s,c&&(h=Object(a.ensureNotNull)(t._scrollWrapRef),h.style.overflowY="scroll",n=o.getBoundingClientRect()),d=n.width,p=n.height,v="function"==typeof e?e(d,p):e,z=5,u=l-d-5,g=Object(r.clamp)(v.x,z,Math.max(z,u)),m=5,w=i-p-5,f=Object(r.clamp)(v.y,m,Math.max(m,w)),t.setState({appearingMenuHeight:c?s:void 0,appearingMenuWidth:v.overrideWidth,appearingPosition:{x:g,y:f},isMeasureValid:!0}))},t._handleGlobalClose=function(){t.props.onClose()},t.state={},t}return i.c(o,e),o.prototype.componentWillReceiveProps=function(e){this.props.isOpened&&!e.isOpened&&this.setState({isMeasureValid:void 0})},o.prototype.componentDidMount=function(){this._handleMeasure(),v.subscribe(this,this._handleGlobalClose)},o.prototype.componentDidUpdate=function(){this._handleMeasure()},o.prototype.componentWillUnmount=function(){v.unsubscribe(this,this._handleGlobalClose)},o.prototype.render=function(){var e,o=this.props,t=o.children,n=o.minWidth,i=o.theme,a=void 0===i?c:i,r=o.className,h=this.state,d=h.appearingMenuHeight,p=h.appearingMenuWidth,v=h.appearingPosition,z=h.isMeasureValid;return l.createElement("div",{className:s(r,a.menuWrap,(e={},e[a.isMeasuring]=!z,e)),style:{height:d,left:v&&v.x,minWidth:n,position:"fixed",top:v&&v.y,width:p},ref:this._handleContainerRef},l.createElement("div",{className:a.scrollWrap,style:{overflowY:void 0!==d?"scroll":"auto"},ref:this._handleScrollWrapRef},l.createElement("div",{className:a.menuBox},t)))},o}(l.PureComponent),v=new d.a},846:function(e,o,t){"use strict";function n(e){return s.createElement(e.href?"a":"div",e)}function i(e){e.stopPropagation()}var l,s,a,r,c,h;t.d(o,"a",function(){return h}),l=t(1),s=t(20),t.n(s),a=t(102),t.n(a),r=t(844),c=t(879),t.n(c),h=function(e){function o(){var o=null!==e&&e.apply(this,arguments)||this;return o._handleClick=function(e){var t=o.props,n=t.dontClosePopup,i=t.isDisabled,l=t.onClick,s=t.onClickArg;i||(l&&l(s,e),n||Object(r.b)())},o}return l.c(o,e),o.prototype.render=function(){var e,o,t=this.props,l=t.className,r=t.forceShowHint,h=t.hint,d=t.icon,p=t.isActive,v=t.isDisabled,z=t.isHovered,u=t.appearAsDisabled,g=t.label,m=t.link,w=t.showToolboxOnHover,f=t.target,M=t.toolbox,T=t.theme,L=void 0===T?c:T;return s.createElement(n,{className:a(l,L.item,d&&L.withIcon,(e={},e[L.isActive]=p,e[L.isDisabled]=v||u,e[L.hovered]=z,e)),href:m,target:f,onClick:this._handleClick},void 0!==d&&s.createElement("div",{className:L.icon,dangerouslySetInnerHTML:{__html:d}}),s.createElement("div",{className:L.labelRow},s.createElement("div",{className:L.label +},g)),(void 0!==h||r)&&s.createElement("div",{className:L.hint},h),void 0!==M&&s.createElement("div",{onClick:i,className:a(L.toolbox,(o={},o[L.showOnHover]=w,o))},M))},o}(s.PureComponent)},849:function(e,o,t){"use strict";function n(e){return i.createElement("div",{className:l.separator})}var i,l;o.a=n,i=t(20),t.n(i),l=t(881),t.n(l)},852:function(e,o,t){"use strict";var n,i,l;t.d(o,"a",function(){return l}),n=t(1),i=t(20),t.n(i),l=function(e){function o(){var o=null!==e&&e.apply(this,arguments)||this;return o._handleKeyDown=function(e){e.keyCode===o.props.keyCode&&o.props.handler(e)},o}return n.c(o,e),o.prototype.componentDidMount=function(){document.addEventListener("keydown",this._handleKeyDown,!1)},o.prototype.componentWillUnmount=function(){document.removeEventListener("keydown",this._handleKeyDown,!1)},o.prototype.render=function(){return null},o}(i.PureComponent)},853:function(e,o,t){"use strict";var n,i,l,s,a=(t(11),t(306)),r=t(875),c={SyncDrawing:t(991),arrow:t(992),cursor:t(993),dot:t(994),drawginmode:t(995),drawginmodeActive:t(996),eraser:t(997),group:t(998),hideAllDrawings:t(885),hideAllDrawingsActive:t(999),lockAllDrawings:t(1e3),lockAllDrawingsActive:t(1001),magnet:t(1002),measure:t(1003),removeAllDrawingTools:t(1004),showObjectsTree:t(1005),zoom:t(1006),"zoom-out":t(1007)};t.d(o,"a",function(){return s}),n={keys:["Shift"],text:window.t("{0} — drawing a straight line at angles of 45")},i={keys:["Shift"],text:window.t("{0} — circle")},l={keys:["Shift"],text:window.t("{0} — square")},s={LineTool5PointsPattern:{icon:r.lineToolsIcons.LineTool5PointsPattern,localizedName:window.t("XABCD Pattern")},LineToolABCD:{icon:r.lineToolsIcons.LineToolABCD,localizedName:window.t("ABCD Pattern")},LineToolArc:{icon:r.lineToolsIcons.LineToolArc,localizedName:window.t("Arc")},LineToolArrow:{icon:r.lineToolsIcons.LineToolArrow,localizedName:window.t("Arrow")},LineToolArrowMarkDown:{icon:r.lineToolsIcons.LineToolArrowMarkDown,localizedName:window.t("Arrow Mark Down")},LineToolArrowMarkLeft:{icon:r.lineToolsIcons.LineToolArrowMarkLeft,localizedName:window.t("Arrow Mark Left")},LineToolArrowMarkRight:{icon:r.lineToolsIcons.LineToolArrowMarkRight,localizedName:window.t("Arrow Mark Right")},LineToolArrowMarkUp:{icon:r.lineToolsIcons.LineToolArrowMarkUp,localizedName:window.t("Arrow Mark Up")},LineToolBalloon:{icon:r.lineToolsIcons.LineToolBalloon,localizedName:window.t("Balloon")},LineToolBarsPattern:{icon:r.lineToolsIcons.LineToolBarsPattern,localizedName:window.t("Bars Pattern")},LineToolBezierCubic:{icon:r.lineToolsIcons.LineToolBezierCubic,localizedName:window.t("Double Curve")},LineToolBezierQuadro:{icon:r.lineToolsIcons.LineToolBezierQuadro,localizedName:window.t("Curve")},LineToolBrush:{icon:r.lineToolsIcons.LineToolBrush,localizedName:window.t("Brush")},LineToolCallout:{icon:r.lineToolsIcons.LineToolCallout,localizedName:window.t("Callout")},LineToolCircleLines:{icon:r.lineToolsIcons.LineToolCircleLines,localizedName:window.t("Cyclic Lines")},LineToolCypherPattern:{icon:r.lineToolsIcons.LineToolCypherPattern, +localizedName:window.t("Cypher Pattern")},LineToolDateAndPriceRange:{icon:r.lineToolsIcons.LineToolDateAndPriceRange,localizedName:window.t("Date and Price Range")},LineToolDateRange:{icon:r.lineToolsIcons.LineToolDateRange,localizedName:window.t("Date Range")},LineToolDisjointAngle:{icon:r.lineToolsIcons.LineToolDisjointAngle,localizedName:window.t("Disjoint Angle"),hotKey:Object(a.b)(n)},LineToolElliottCorrection:{icon:r.lineToolsIcons.LineToolElliottCorrection,localizedName:window.t("Elliott Correction Wave (ABC)")},LineToolElliottDoubleCombo:{icon:r.lineToolsIcons.LineToolElliottDoubleCombo,localizedName:window.t("Elliott Double Combo Wave (WXY)")},LineToolElliottImpulse:{icon:r.lineToolsIcons.LineToolElliottImpulse,localizedName:window.t("Elliott Impulse Wave (12345)")},LineToolElliottTriangle:{icon:r.lineToolsIcons.LineToolElliottTriangle,localizedName:window.t("Elliott Triangle Wave (ABCDE)")},LineToolElliottTripleCombo:{icon:r.lineToolsIcons.LineToolElliottTripleCombo,localizedName:window.t("Elliott Triple Combo Wave (WXYXZ)")},LineToolEllipse:{icon:r.lineToolsIcons.LineToolEllipse,localizedName:window.t("Ellipse"),hotKey:Object(a.b)(i)},LineToolExtended:{icon:r.lineToolsIcons.LineToolExtended,localizedName:window.t("Extended")},LineToolFibChannel:{icon:r.lineToolsIcons.LineToolFibChannel,localizedName:window.t("Fib Channel")},LineToolFibCircles:{icon:r.lineToolsIcons.LineToolFibCircles,localizedName:window.t("Fib Circles"),hotKey:Object(a.b)(i)},LineToolFibRetracement:{icon:r.lineToolsIcons.LineToolFibRetracement,localizedName:window.t("Fib Retracement")},LineToolFibSpeedResistanceArcs:{icon:r.lineToolsIcons.LineToolFibSpeedResistanceArcs,localizedName:window.t("Fib Speed Resistance Arcs")},LineToolFibSpeedResistanceFan:{icon:r.lineToolsIcons.LineToolFibSpeedResistanceFan,localizedName:window.t("Fib Speed Resistance Fan"),hotKey:Object(a.b)(l)},LineToolFibSpiral:{icon:r.lineToolsIcons.LineToolFibSpiral,localizedName:window.t("Fib Spiral")},LineToolFibTimeZone:{icon:r.lineToolsIcons.LineToolFibTimeZone,localizedName:window.t("Fib Time Zone")},LineToolFibWedge:{icon:r.lineToolsIcons.LineToolFibWedge,localizedName:window.t("Fib Wedge")},LineToolFlagMark:{icon:r.lineToolsIcons.LineToolFlagMark,localizedName:window.t("Flag Mark")},LineToolFlatBottom:{icon:r.lineToolsIcons.LineToolFlatBottom,localizedName:window.t("Flat Top/Bottom"),hotKey:Object(a.b)(n)},LineToolGannComplex:{icon:r.lineToolsIcons.LineToolGannComplex,localizedName:window.t("Gann Square")},LineToolGannFixed:{icon:r.lineToolsIcons.LineToolGannFixed,localizedName:window.t("Gann Square Fixed")},LineToolGannFan:{icon:r.lineToolsIcons.LineToolGannFan,localizedName:window.t("Gann Fan")},LineToolGannSquare:{icon:r.lineToolsIcons.LineToolGannSquare,localizedName:window.t("Gann Box"),hotKey:Object(a.b)({keys:["Shift"],text:window.t("{0} — fixed increments")})},LineToolGhostFeed:{icon:r.lineToolsIcons.LineToolGhostFeed,localizedName:window.t("Ghost Feed")},LineToolHeadAndShoulders:{icon:r.lineToolsIcons.LineToolHeadAndShoulders, +localizedName:window.t("Head and Shoulders")},LineToolHorzLine:{icon:r.lineToolsIcons.LineToolHorzLine,localizedName:window.t("Horizontal Line"),hotKey:Object(a.b)({keys:["Alt","H"],text:"{0} + {1}"})},LineToolHorzRay:{icon:r.lineToolsIcons.LineToolHorzRay,localizedName:window.t("Horizontal Ray")},LineToolIcon:{icon:r.lineToolsIcons.LineToolIcon,localizedName:window.t("Font Icons")},LineToolInsidePitchfork:{icon:r.lineToolsIcons.LineToolInsidePitchfork,localizedName:window.t("Inside Pitchfork")},LineToolNote:{icon:r.lineToolsIcons.LineToolNote,localizedName:window.t("Note")},LineToolNoteAbsolute:{icon:r.lineToolsIcons.LineToolNoteAbsolute,localizedName:window.t("Anchored Note")},LineToolParallelChannel:{icon:r.lineToolsIcons.LineToolParallelChannel,localizedName:window.t("Parallel Channel"),hotKey:Object(a.b)(n)},LineToolPitchfan:{icon:r.lineToolsIcons.LineToolPitchfan,localizedName:window.t("Pitchfan")},LineToolPitchfork:{icon:r.lineToolsIcons.LineToolPitchfork,localizedName:window.t("Pitchfork")},LineToolPolyline:{icon:r.lineToolsIcons.LineToolPolyline,localizedName:window.t("Polyline")},LineToolPrediction:{icon:r.lineToolsIcons.LineToolPrediction,localizedName:window.t("Forecast")},LineToolPriceLabel:{icon:r.lineToolsIcons.LineToolPriceLabel,localizedName:window.t("Price Label")},LineToolPriceRange:{icon:r.lineToolsIcons.LineToolPriceRange,localizedName:window.t("Price Range")},LineToolProjection:{icon:r.lineToolsIcons.LineToolProjection,localizedName:window.t("Projection")},LineToolRay:{icon:r.lineToolsIcons.LineToolRay,localizedName:window.t("Ray")},LineToolRectangle:{icon:r.lineToolsIcons.LineToolRectangle,localizedName:window.t("Rectangle"),hotKey:Object(a.b)({keys:["Shift"],text:window.t("{0} — square")})},LineToolRegressionTrend:{icon:r.lineToolsIcons.LineToolRegressionTrend,localizedName:window.t("Regression Trend")},LineToolRiskRewardLong:{icon:r.lineToolsIcons.LineToolRiskRewardLong,localizedName:window.t("Long Position")},LineToolRiskRewardShort:{icon:r.lineToolsIcons.LineToolRiskRewardShort,localizedName:window.t("Short Position")},LineToolRotatedRectangle:{icon:r.lineToolsIcons.LineToolRotatedRectangle,localizedName:window.t("Rotated Rectangle"),hotKey:Object(a.b)(n)},LineToolSchiffPitchfork:{icon:r.lineToolsIcons.LineToolSchiffPitchfork,localizedName:window.t("Modified Schiff Pitchfork")},LineToolSchiffPitchfork2:{icon:r.lineToolsIcons.LineToolSchiffPitchfork2,localizedName:window.t("Schiff Pitchfork")},LineToolSineLine:{icon:r.lineToolsIcons.LineToolSineLine,localizedName:window.t("Sine Line")},LineToolText:{icon:r.lineToolsIcons.LineToolText,localizedName:window.t("Text",{context:"tool"})},LineToolTextAbsolute:{icon:r.lineToolsIcons.LineToolTextAbsolute,localizedName:window.t("Anchored Text")},LineToolThreeDrivers:{icon:r.lineToolsIcons.LineToolThreeDrivers,localizedName:window.t("Three Drives Pattern")},LineToolTimeCycles:{icon:r.lineToolsIcons.LineToolTimeCycles,localizedName:window.t("Time Cycles")},LineToolTrendAngle:{icon:r.lineToolsIcons.LineToolTrendAngle, +localizedName:window.t("Trend Angle"),hotKey:Object(a.b)(n)},LineToolTrendBasedFibExtension:{icon:r.lineToolsIcons.LineToolTrendBasedFibExtension,localizedName:window.t("Trend-Based Fib Extension")},LineToolTrendBasedFibTime:{icon:r.lineToolsIcons.LineToolTrendBasedFibTime,localizedName:window.t("Trend-Based Fib Time")},LineToolTrendLine:{icon:r.lineToolsIcons.LineToolTrendLine,localizedName:window.t("Trend Line"),hotKey:Object(a.b)(n)},LineToolInfoLine:{icon:r.lineToolsIcons.LineToolInfoLine,localizedName:window.t("Info Line")},LineToolTriangle:{icon:r.lineToolsIcons.LineToolTriangle,localizedName:window.t("Triangle")},LineToolTrianglePattern:{icon:r.lineToolsIcons.LineToolTrianglePattern,localizedName:window.t("Triangle Pattern")},LineToolVertLine:{icon:r.lineToolsIcons.LineToolVertLine,localizedName:window.t("Vertical Line"),hotKey:Object(a.b)({keys:["Alt","V"],text:"{0} + {1}"})},LineToolCrossLine:{icon:r.lineToolsIcons.LineToolCrossLine,localizedName:$.t("Cross Line")},SyncDrawing:{icon:c.SyncDrawing,iconActive:c.SyncDrawingActive,localizedName:window.t("Sync drawings to all charts")},arrow:{icon:c.arrow,localizedName:window.t("Arrow")},cursor:{icon:c.cursor,localizedName:window.t("Cross")},dot:{icon:c.dot,localizedName:window.t("Dot")},drawginmode:{icon:c.drawginmode,iconActive:c.drawginmodeActive,localizedName:window.t("Stay in Drawing Mode")},eraser:{icon:c.eraser,localizedName:window.t("Eraser")},group:{icon:c.group,localizedName:window.t("Show Hidden Tools")},hideAllDrawings:{icon:c.hideAllDrawings,iconActive:c.hideAllDrawingsActive,localizedName:window.t("Hide All Drawing Tools")},lockAllDrawings:{icon:c.lockAllDrawings,iconActive:c.lockAllDrawingsActive,localizedName:window.t("Lock All Drawing Tools")},magnet:{icon:c.magnet,localizedName:window.t("Magnet Mode snaps drawings placed near price bars to the closest OHLC value")},measure:{icon:c.measure,localizedName:window.t("Measure"),hotKey:Object(a.b)({keys:["Shift"],text:window.t("{0} + Click on the chart")})},removeAllDrawingTools:{icon:c.removeAllDrawingTools,localizedName:window.t("Remove All Drawing Tools")},showObjectsTree:{icon:c.showObjectsTree,localizedName:window.t("Show Objects Tree")},zoom:{icon:c.zoom,localizedName:window.t("Zoom In")},"zoom-out":{icon:c["zoom-out"],localizedName:window.t("Zoom Out")}}},869:function(e,o){e.exports=''},870:function(e,o){ +e.exports=''},871:function(e,o){e.exports={menuWrap:"menuWrap-1gEtmoET-",isMeasuring:"isMeasuring-FZ0EJCM2-",scrollWrap:"scrollWrap-1B5MfTJt-",menuBox:"menuBox-20sJGjtG-",isHidden:"isHidden-2vLQpR1t-"}},872:function(e,o,t){"use strict";function n(e){var o=p(e),t=document.getElementById(o);return t||(t=document.createElement("div"),t.id=o,document.body.appendChild(t)),d[e]=(d[e]||0)+1,t}function i(e){var o=p(e),t=document.getElementById(o);d[e]&&(d[e]-=1),t&&0===d[e]&&document.body.removeChild(t)}var l,s=t(1),a=(t(127),t(20)),r=t(59),c=t(304),h=0,d={},p=function(e){return"__outside-render-"+e},v=function(e){function o(o){return e.call(this,o)||this}return s.c(o,e),o.prototype.componentDidMount=function(){this._rememberLayer(),this._renderLayer()},o.prototype.componentDidUpdate=function(e){this.props.layerId!==e.layerId&&(i(this._layerId),this._rememberLayer()),this._renderLayer()},o.prototype.componentWillUnmount=function(){r.unmountComponentAtNode(this._layer),i(this._layerId)},o.prototype.render=function(){return null},o.prototype._rememberLayer=function(){var e=this.props.layerId,o=void 0===e?h+++"":e;this._layerId=o,this._layer=n(o)},o.prototype._renderLayer=function(){r.render(a.createElement("div",null,this.props.children),this._layer)},o}(a.Component),z=t(844);t.d(o,"a",function(){return l}),l=function(e){function o(){var o=null!==e&&e.apply(this,arguments)||this;return o._handleClose=function(){o.props.onClose()},o._handleClickOutside=function(e){var t=o.props,n=t.closeOnClickOutside,i=t.onClickOutside,l=t.doNotCloseOn;i&&i(e),!n||void 0!==l&&r.findDOMNode(l).contains(e.target)||o._handleClose()},o}return s.c(o,e),o.prototype.componentWillReceiveProps=function(e){this.props.isOpened&&!e.isOpened&&this.setState({isMeasureValid:void 0})},o.prototype.render=function(){var e=this.props,o=e.children,t=e.isOpened,n=(e.closeOnClickOutside,e.doNotCloseOn,e.onClickOutside,e.onClose,s.e(e,["children","isOpened","closeOnClickOutside","doNotCloseOn","onClickOutside","onClose"]));return t?a.createElement(v,null,a.createElement(c.a,{handler:this._handleClickOutside,mouseDown:!0,touchStart:!0,ctor:"div"},a.createElement(z.a,s.a({},n,{isOpened:t, +onClose:this._handleClose}),o))):null},o.defaultProps={closeOnClickOutside:!0},o}(a.PureComponent)},875:function(e,o,t){"use strict";Object.defineProperty(o,"__esModule",{value:!0}),t.d(o,"lineToolsIcons",function(){return n});var n={LineTool5PointsPattern:t(886),LineToolABCD:t(887),LineToolArc:t(888),LineToolArrow:t(889),LineToolArrowMarkDown:t(890),LineToolArrowMarkLeft:t(891),LineToolArrowMarkRight:t(892),LineToolArrowMarkUp:t(893),LineToolBalloon:t(894),LineToolBarsPattern:t(895),LineToolBezierCubic:t(896),LineToolBezierQuadro:t(897),LineToolBrush:t(898),LineToolCallout:t(899),LineToolCircleLines:t(900),LineToolCypherPattern:t(901),LineToolDateAndPriceRange:t(902),LineToolDateRange:t(903),LineToolDisjointAngle:t(904),LineToolElliottCorrection:t(905),LineToolElliottDoubleCombo:t(906),LineToolElliottImpulse:t(907),LineToolElliottTriangle:t(908),LineToolElliottTripleCombo:t(909),LineToolEllipse:t(910),LineToolExtended:t(911),LineToolFibChannel:t(912),LineToolFibCircles:t(913),LineToolFibRetracement:t(914),LineToolFibSpeedResistanceArcs:t(915),LineToolFibSpeedResistanceFan:t(916),LineToolFibSpiral:t(917),LineToolFibTimeZone:t(918),LineToolFibWedge:t(919),LineToolFlagMark:t(920),LineToolFlatBottom:t(921),LineToolGannComplex:t(922),LineToolGannFixed:t(923),LineToolGannFan:t(924),LineToolGannSquare:t(925),LineToolGhostFeed:t(926),LineToolHeadAndShoulders:t(927),LineToolHorzLine:t(928),LineToolHorzRay:t(929),LineToolIcon:"icon",LineToolInsidePitchfork:t(930),LineToolNote:t(931),LineToolNoteAbsolute:t(932),LineToolParallelChannel:t(933),LineToolPitchfan:t(934),LineToolPitchfork:t(935),LineToolPolyline:t(936),LineToolPrediction:t(937),LineToolPriceLabel:t(938),LineToolPriceRange:t(939),LineToolProjection:t(940),LineToolRay:t(941),LineToolRectangle:t(942),LineToolRegressionTrend:t(943),LineToolRiskRewardLong:t(944),LineToolRiskRewardShort:t(945),LineToolRotatedRectangle:t(946),LineToolSchiffPitchfork:t(947),LineToolSchiffPitchfork2:t(948),LineToolSineLine:t(949),LineToolText:t(950),LineToolTextAbsolute:t(951),LineToolThreeDrivers:t(952),LineToolTimeCycles:t(953),LineToolTrendAngle:t(954),LineToolTrendBasedFibExtension:t(955),LineToolTrendBasedFibTime:t(956),LineToolTrendLine:t(957),LineToolInfoLine:t(958),LineToolTriangle:t(959),LineToolTrianglePattern:t(960),LineToolVertLine:t(961),LineToolCrossLine:t(962)}},878:function(e,o,t){"use strict";var n,i,l,s,a,r,c,h;t.d(o,"a",function(){return h}),n=t(1),t(11),i=t(20),t.n(i),l=t(102),t.n(l),s=t(987),t.n(s),a=t(869),t.n(a),r=t(870),t.n(r),c={add:window.t("Add to favorites"),remove:window.t("Remove from favorites")},h=function(e){function o(){var o=null!==e&&e.apply(this,arguments)||this;return o._handleClick=function(e){var t=o.props,n=t.onClick,i=t.onClickArg;n&&n(i,e)},o}return n.c(o,e),o.prototype.render=function(){var e,o=this.props.isFilled;return i.createElement("span",{className:l(s.star,"apply-common-tooltip",(e={},e[s.checked]=o,e)),dangerouslySetInnerHTML:{__html:o?a:r},onClick:this._handleClick,title:o?c.remove:c.add})},o}(i.PureComponent)},879:function(e,o){ +e.exports={item:"item-2xPVYue0-",hovered:"hovered-1uf45E05-",isDisabled:"isDisabled-1wLqKupj-",isActive:"isActive-2j-GhQs_-",icon:"icon-2Qm7YIcz-",hint:"hint-1IhIvLPB-",toolbox:"toolbox-3ulPxfe--",withIcon:"withIcon-1xBjf-oB-",labelRow:"labelRow-3Q0rdE8--",label:"label-3Xqxy756-",showOnHover:"showOnHover-1q6ySzZc-"}},881:function(e,o){e.exports={separator:"separator-25lkUpN--"}},885:function(e,o){e.exports=''},886:function(e,o){e.exports=''},887:function(e,o){ +e.exports=''},888:function(e,o){e.exports=''},889:function(e,o){e.exports=''},890:function(e,o){e.exports=''},891:function(e,o){ +e.exports=''},892:function(e,o){e.exports=''},893:function(e,o){e.exports=''},894:function(e,o){e.exports=''},895:function(e,o){e.exports=''},896:function(e,o){e.exports=''},897:function(e,o){ +e.exports=''},898:function(e,o){e.exports=''},899:function(e,o){e.exports=''},900:function(e,o){e.exports=''},901:function(e,o){ +e.exports=''},902:function(e,o){e.exports=''},903:function(e,o){ +e.exports=''},904:function(e,o){e.exports=''},905:function(e,o){ +e.exports=''},906:function(e,o){e.exports=''},907:function(e,o){ +e.exports=''},908:function(e,o){e.exports=''},909:function(e,o){ +e.exports=''},910:function(e,o){e.exports=''},911:function(e,o){ +e.exports=''},912:function(e,o){e.exports=''},913:function(e,o){e.exports=''},914:function(e,o){ +e.exports=''},915:function(e,o){e.exports=''},916:function(e,o){e.exports=''},917:function(e,o){ +e.exports=''},918:function(e,o){e.exports=''},919:function(e,o){e.exports=''},920:function(e,o){e.exports=''},921:function(e,o){ +e.exports=''},922:function(e,o){e.exports=''},923:function(e,o){e.exports=''},924:function(e,o){ +e.exports=''},925:function(e,o){e.exports=''},926:function(e,o){e.exports=''},927:function(e,o){ +e.exports=''},928:function(e,o){e.exports=''},929:function(e,o){e.exports=''},930:function(e,o){ +e.exports=''},931:function(e,o){e.exports=''},932:function(e,o){e.exports=''},933:function(e,o){e.exports=''},934:function(e,o){ +e.exports=''},935:function(e,o){e.exports=''},936:function(e,o){ +e.exports=''},937:function(e,o){e.exports=''},938:function(e,o){e.exports=''},939:function(e,o){ +e.exports=''},940:function(e,o){e.exports=''},941:function(e,o){e.exports=''},942:function(e,o){e.exports=''},943:function(e,o){ +e.exports=''},944:function(e,o){e.exports=''},945:function(e,o){e.exports=''},946:function(e,o){ +e.exports=''},947:function(e,o){e.exports=''},948:function(e,o){ +e.exports=''},949:function(e,o){e.exports=''},950:function(e,o){e.exports=''},951:function(e,o){e.exports=''},952:function(e,o){ +e.exports=''},953:function(e,o){e.exports=''},954:function(e,o){ +e.exports=''},955:function(e,o){e.exports=''},956:function(e,o){e.exports=''},957:function(e,o){e.exports=''},958:function(e,o){ +e.exports=''},959:function(e,o){e.exports=''},960:function(e,o){ +e.exports=''},961:function(e,o){e.exports=''},962:function(e,o){e.exports=''},987:function(e,o){e.exports={star:"star-uhAI7sV4-",checked:"checked-2bhy04CF-"}},990:function(e,o){e.exports=''},991:function(e,o){e.exports=''},992:function(e,o){ +e.exports=''},993:function(e,o){e.exports=''},994:function(e,o){e.exports=''},995:function(e,o){e.exports=''},996:function(e,o){e.exports=''},997:function(e,o){e.exports=''},998:function(e,o){ +e.exports=''},999:function(e,o){e.exports=''}}); \ No newline at end of file diff --git a/charting_library/static/bundles/ds-property-pages.4650c8fe6629bba016a1.js b/charting_library/static/bundles/ds-property-pages.4650c8fe6629bba016a1.js deleted file mode 100644 index 1cda9cac..00000000 --- a/charting_library/static/bundles/ds-property-pages.4650c8fe6629bba016a1.js +++ /dev/null @@ -1,79 +0,0 @@ -webpackJsonp([3],{1077:function(e,t,o){"use strict";function i(e,t,o){a.call(this,e,t),this._linetool=o,this.prepareLayout()}var n=o(239),a=n.PropertyPage,r=n.GreateTransformer,l=n.LessTransformer,p=n.ToIntTransformer,s=n.SimpleStringBinder;o(242),inherit(i,a),i.BarIndexPastLimit=-5e4,i.BarIndexFutureLimit=15e3,i.prototype.bindBarIndex=function(e,t,o,n){var a=[p(e.value()),r(i.BarIndexPastLimit),l(i.BarIndexFutureLimit)];this.bindControl(this.createStringBinder(t,e,a,!0,o,n))},i.prototype.createPriceEditor=function(e){var t,o,i,n=this._linetool,a=n.ownerSource().formatter(),r=function(e){return a.format(e)},l=function(e){var t=a.parse(e);if(t.res)return t.price?t.price:t.value},p=$("");return p.TVTicker({step:a._minMove/a._priceScale||1,formatter:r,parser:l}),e&&(t=[function(t){var o=l(t);return void 0===o?e.value():o}],o="Change "+n.title()+" point price",i=this.createStringBinder(p,e,t,!1,this.model(),o),i.addFormatter(function(e){return a.format(e)}),this.bindControl(i)),p},i.prototype._createPointRow=function(e,t,o){var i,n,a,r,l,p=$("
"),s=$("").appendTo(this._table),c=$("
");return s.html($.t("Price")+o),s.appendTo(p),i=$(""),i.appendTo(p),n=this.createPriceEditor(t.price),n.appendTo(i),a=$(""),a.html($.t("Bar #")),a.appendTo(p),r=$(""),r.appendTo(p),l=$(""),l.appendTo(r),l.addClass("ticker"),this.bindBarIndex(t.bar,l,this.model(),"Change "+this._linetool.title()+" point bar index"),p},i.prototype.prepareLayoutForTable=function(e){var t,o,i,n,a,r=this._linetool.points(),l=r.length;for(t=0;t1?" "+(t+1):"",a=this._createPointRow(o,i,n),a.appendTo(e))},i.prototype.prepareLayout=function(){this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),this.prepareLayoutForTable(this._table),this.loadData()},i.prototype.widget=function(){return this._table},i.prototype.createStringBinder=function(e,t,o,i,n,a){return new s(e,t,o,i,n,a)},e.exports=i},1079:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.FloatBinder,l=a.BooleanBinder,p=a.SliderBinder,s=a.ColorBinding,d=a.SimpleComboBinder,h=o(373).addColorPicker,c=o(1198).createLineStyleEditor,b=o(1197).createLineWidthEditor,u=o(1199).createTransparencyEditor;inherit(i,n),i.prototype.addLevelEditor=function(e,t){var o,i,n,a,p,d=t||$("
");return c.appendTo(d),o=$(""),o.appendTo(c),t&&o.css("margin-left","15px"),i=$(""),i.appendTo(d),n=$(""),n.appendTo(i),n.css("width","70px"),this.bindControl(new r(n,e.coeff,!1,this.model(),"Change Pitchfork Line Coeff")),a=$(""),a.appendTo(d),p=h(a),this.bindControl(new l(o,e.visible,!0,this.model(),"Change Fib Retracement Line Visibility")),this.bindControl(new s(p,e.color,!0,this.model(),"Change Fib Retracement Line Color",0)),d}, -i.prototype.prepareLayout=function(){var e,t,o,i,n,a,r,C,y,g,T,w,_,m,f,L,v,k,S,P,x,B,R,E,F,I,D,A,W,V,O,z,M;for(this._div=$(document.createElement("div")).addClass("property-page"),e=this._linetool.properties().trendline,t=$("").appendTo(this._div).css("padding-bottom","3px"),e&&(o=$("").appendTo(t),i=$(""),$("").appendTo(t),$("").appendTo(w),$("
").append(i).appendTo(o),$("").append($.t("Trend Line")).appendTo(o),this.bindControl(new l(i,e.visible,!0,this.model(),"Change Fib Retracement Line Visibility")),n=$("").appendTo(o),a=h(n),this.bindControl(new s(a,e.color,!0,this.model(),"Change Fib Retracement Line Color",0)),r=$("").appendTo(o),C=b(),C.appendTo(r),this.bindControl(new p(C,e.linewidth,parseInt,this.model(),"Change Fib Retracement Line Width")),y=$("").appendTo(o),g=c(),g.render().appendTo(y),this.bindControl(new d(g,e.linestyle,parseInt,!0,this.model(),"Change Fib Retracement Line Style"))),T=this._linetool.properties().levelsStyle,w=$("
").appendTo(w),$(""+$.t("Levels Line")+"").appendTo(w),r=$("").appendTo(w),C=b(),C.appendTo(r),this.bindControl(new p(C,T.linewidth,parseInt,this.model(),"Change Fib Retracement Line Width")),y=$("").appendTo(w),g=c(),g.render().appendTo(y),this.bindControl(new d(g,T.linestyle,parseInt,!0,this.model(),"Change Fib Retracement Line Style")),this._table=$(document.createElement("table")).appendTo(this._div),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),_={},m=0;m<24;m++)f=m%8,w=_[f],L="level"+(m+1),_[f]=this.addLevelEditor(this._linetool.properties()[L],w);this.addOneColorPropertyWidget(this._table),v=$("").appendTo(this._div),k=$("").appendTo(v),this._linetool.properties().extendLines&&(S=$(""),P=$("").appendTo(v),F=$(""),P=$("
").append(P).appendTo(k)),this._linetool.properties().extendLeft&&(x=$(""),P=$("").append(P).appendTo(k)),this._linetool.properties().extendRight&&(B=$(""),P=$("").append(P).appendTo(k)),this._linetool.properties().reverse&&(R=$(""),P=$("").append(P).appendTo(k)),E=$("
").append(P).appendTo(E),I=$(""),P=$("").append(P).appendTo(E),D=$(""),P=$("").append(P).appendTo(E),A=$("").appendTo(this._div), -W=$(""),V=$(""),w=$(""),w.append("").append(W).append("").append(V),w.appendTo(A),O=$("
"+$.t("Labels")+" 
").appendTo(this._div),w=$("").appendTo(O),z=$(""),$("
").append(z).appendTo(w),this.createLabeledCell($.t("Background"),z).appendTo(w),M=u(),$("").append(M).appendTo(w),this.bindControl(new l(I,this._linetool.properties().showPrices,!0,this.model(),"Change Gann Fan Prices Visibility")),this.bindControl(new l(F,this._linetool.properties().showCoeffs,!0,this.model(),"Change Gann Fan Levels Visibility")),this.bindControl(new l(z,this._linetool.properties().fillBackground,!0,this.model(),"Change Fib Retracement Background Visibility")),this.bindControl(new p(M,this._linetool.properties().transparency,!0,this.model(),"Change Fib Retracement Background Transparency")),this._linetool.properties().extendLines&&this.bindControl(new l(S,this._linetool.properties().extendLines,!0,this.model(),"Change Fib Retracement Extend Lines")),this._linetool.properties().extendLeft&&this.bindControl(new l(x,this._linetool.properties().extendLeft,!0,this.model(),"Change Fib Retracement Extend Lines")),this._linetool.properties().extendRight&&this.bindControl(new l(B,this._linetool.properties().extendRight,!0,this.model(),"Change Fib Retracement Extend Lines")),this._linetool.properties().reverse&&this.bindControl(new l(R,this._linetool.properties().reverse,!0,this.model(),"Change Fib Retracement Reverse")),this.bindControl(new d(W,this._linetool.properties().horzLabelsAlign,null,!0,this.model(),"Change Fib Labels Horizontal Alignment")),this.bindControl(new d(V,this._linetool.properties().vertLabelsAlign,null,!0,this.model(),"Change Fib Labels Vertical Alignment")),this.bindControl(new l(D,this._linetool.properties().coeffsAsPercents,!0,this.model(),"Change Fib Retracement Coeffs As Percents")),this.loadData()},i.prototype.widget=function(){return this._div},e.exports=i},1084:function(e,t,o){"use strict";(function(t){function i(e,t,o){var i,n,a=t.m_model.properties();l.call(this,a,t),i=this._series=t.mainSeries(),this._chart=t.m_model,this._model=t,this._source=o,this._property=a,this._seriesProperty=i.properties(),this._scaleProperty=i.priceScale().properties(),this._mainSeriesScaleRatioProperty=t.mainSeriesScaleRatioProperty(),n=null,t.m_model.panes().forEach(function(e){e.dataSources().forEach(function(t){if(t===i)return n=e,!1})}),this._pane=n,this.prepareLayout(),this._themes=[],this.supportThemeSwitcher=!1} -var n=o(1235),a=o(1202),r=o(239),l=r.PropertyPage,p=r.GreateTransformer,s=r.LessTransformer,d=r.ToIntTransformer,h=r.SimpleStringBinder,c=r.BooleanBinder,b=r.SliderBinder,u=r.ColorBinding,C=r.SimpleComboBinder,y=r.DisabledBinder,g=r.CheckboxWVBinding,T=r.ToFloatTransformerWithDynamicDefaultValue,w=r.ToFloatLimitedPrecisionTransformer,_=o(49),m=o(22),f=o(373).addColorPicker,L=o(1198).createLineStyleEditor,v=o(1197).createLineWidthEditor,k=(o(133).bindPopupMenu,o(6).DefaultProperty),S=o(171).availableTimezones,P=o(249),x=(o(112).createConfirmDialog,o(40).trackEvent);inherit(i,l),inherit(i,n),i.prototype.setScalesOpenTab=function(){this.scalesTab&&this.scalesTab.data("layout-tab-open",a.TabOpenFrom.Override)},i.prototype.setTmzOpenTab=function(){this.tmzSessTable&&this.tmzSessTable.data("layout-tab-open",a.TabOpenFrom.Override)},i.prototype.prepareLayout=function(){var e,o,i,n,r,l,k,B,R,E,F,I,D,A,W,V,O,z,M,j,H,G,N,U,q,Y,K,Q,J,Z,X,ee,te,oe,ie,ne,ae,re,le,pe,se,de,he,ce,be,ue,Ce,ye,ge,$e,Te,we,_e,me,fe,Le,ve,ke,Se,Pe,xe,Be,Re,Ee,Fe,Ie,De,Ae,We,Ve,Oe,ze,Me,je,He,Ge,Ne,Ue,qe,Ye,Ke,Qe,Je,Ze,Xe,et,tt,ot,it,nt,at,rt,lt,pt,st,dt,ht,ct,bt,ut,Ct,yt,gt,$t,Tt,wt,_t,mt,ft,Lt,vt,kt,St,Pt,xt,Bt,Rt,Et,Ft,It,Dt,At,Wt,Vt,Ot,zt,Mt,jt=this;if(t.enabled("chart_property_page_style")&&(e=$('').data("layout-tab",a.TabNames.style),o=$('
').data("layout-tab",a.TabNames.style),i=$('
').data("layout-tab",a.TabNames.style),this._prepareSeriesStyleLayout(e,o,i,this._seriesProperty),this._hasSeriesStyleLayout=!0,l=$('
').data("layout-tab",a.TabNames.style),W=$(''),V=this.addLabeledRow(l,$.t("Price Line"),W),$("
").append(W).prependTo(V),this.bindControl(new c(W,this._seriesProperty.showPriceLine,!0,this.model(),"Change Price Price Line")),O=f($("").appendTo(V)),this.bindControl(new u(O,this._seriesProperty.priceLineColor,!0,this.model(),"Change Price Line Color")),z=v(),$('').append(z).appendTo(V),this.bindControl(new b(z,this._seriesProperty.priceLineWidth,!0,this.model(),"Change Price Line Width")),B=$('').data("layout-tab",a.TabNames.style),this._pane&&(-1!==this._pane.leftPriceScale().dataSources().indexOf(this._series)?M="left":-1!==this._pane.rightPriceScale().dataSources().indexOf(this._series)?M="right":this._pane.isOverlay(this._series)&&(M="none")),M&&(j={left:$.t("Scale Left"),right:$.t("Scale Right")},jt._pane.actionNoScaleIsEnabled(jt._series)&&(j.none=$.t("Screen (No Scale)")),H=this.createKeyCombo(j).val(M).change(function(){switch(this.value){case"left":jt._model.move(jt._series,jt._pane,jt._pane.leftPriceScale());break;case"right":jt._model.move(jt._series,jt._pane,jt._pane.rightPriceScale());break;case"none":jt._model.move(jt._series,jt._pane,null)}}),G=this.addRow(B), -$("").appendTo(G),$("
"+$.t("Scale")+"").appendTo(G).append(H))),t.enabled("chart_property_page_scales")&&(N=$('').data("layout-tab",a.TabNames.scales),U=$('').change(function(){this.checked&&setTimeout(function(){jt._model.m_model.invalidate(new m(m.LIGHT_UPDATE))},0)}),q=this.addLabeledRow(N,$.t("Auto Scale"),U),Y=function(e){this._undoModel.setAutoScaleProperty(this._property,e,jt._series.priceScale(),this._undoText)},$("
").append(U).prependTo(q),this.bindControl(new c(U,this._scaleProperty.autoScale,!0,this.model(),"Auto Scale",Y)),this.bindControl(new y(U,this._scaleProperty.autoScaleDisabled,!0,this.model(),"Auto Scale")),K=$(''),Q=this.addLabeledRow(N,$.t("Percentage"),K),J=function(e){this._undoModel.setPercentProperty(this._property,e,jt._series.priceScale(),this._undoText)},$("").append(K).prependTo(Q),this.bindControl(new c(K,this._scaleProperty.percentage,!0,this.model(),"Scale Percentage",J)),this.bindControl(new y(K,this._scaleProperty.percentageDisabled,!0,this.model(),"Scale Percentage")),Z=$(''),X=this.addLabeledRow(N,$.t("Log Scale"),Z),ee=function(e){this._undoModel.setLogProperty(this._property,e,jt._series.priceScale(),this._undoText)},$("").append(Z).prependTo(X),this.bindControl(new c(Z,this._scaleProperty.log,!0,this.model(),"Log Scale",ee)),this.bindControl(new y(Z,this._scaleProperty.logDisabled,!0,this.model(),"Log Scale")),te=$('').change(function(){this.checked&&setTimeout(function(){jt._model.m_model.invalidate(new m(m.LIGHT_UPDATE))},0)}),oe=this.addLabeledRow(N,$.t("Scale Series Only"),te),$("").append(te).prependTo(oe),this.bindControl(new c(te,this._property.scalesProperties.scaleSeriesOnly,!0,this.model(),"Scale Series Only")),ie=$(""),ne=this.addLabeledRow(N,$.t("Lock scale"),ie),ae=function(e){this._undoModel.setLockScaleProperty(this._property,e,jt._series,this._undoText)},re=function(e){ne.toggle(e.value()===_.STYLE_PNF)},$("").append(ie).prependTo(ne),this.bindControl(new c(ie,this._scaleProperty.lockScale,!0,this.model(),"Change lock scale",ae)),this._seriesProperty.style.listeners().subscribe(this,re),t.enabled("support_multicharts")&&(le=$(""),pe=this.addLabeledRow(N,$.t("Track time"),le),$("").append(le).prependTo(pe),this.bindControl(new g(le,this._model.trackTime(),null,this.model(),"Change track time"))),se=$('').data("layout-tab",a.TabNames.scales),de=$(''),he=this.addLabeledRow(se,$.t("Top Margin"),de),$("").appendTo(he),ce=[d(this._property.paneProperties.topMargin.value())],ce.push(s(25)),ce.push(p(0)),this.bindControl(new h(de,this._property.paneProperties.topMargin,ce,!0,this.model(),"Top Margin")),be=$(''), -ue=this.addLabeledRow(se,$.t("Bottom Margin"),be),$("").appendTo(ue),Ce=[d(this._property.paneProperties.bottomMargin.value())],Ce.push(s(25)),Ce.push(p(0)),this.bindControl(new h(be,this._property.paneProperties.bottomMargin,Ce,!0,this.model(),"Bottom Margin")),ye=$(''),ge=this.addLabeledRow(se,$.t("Right Margin"),ye),$("").appendTo(ge),$e=this._chart.timeScale(),Te=[d($e.defaultRightOffsetProperty().value())],Te.push(s(~~$e.maxRightOffset())),Te.push(p(0)),this.bindControl(new h(ye,$e.defaultRightOffsetProperty(),Te,!0,this.model(),"Right Margin")),we=$(''),ge=this.addLabeledRow(se,$.t("Price/Bar Ratio"),we),_e=!0,me=function(e){this._undoModel.setScaleRatioProperty(this._property,e,jt._series,this._undoText),_e&&(x("GUI","Scales","Edit scale ratio value"),_e=!1)},$("
").appendTo(he).append(de),$("%").appendTo(ue).append(be),$("%").appendTo(ge).append(ye),$(""+$.t("bars",{context:"margin"})+"").appendTo(ge).append(we),we.TVTicker({step:this._mainSeriesScaleRatioProperty.getStepChangeValue()}),fe=w("",7),Le=[T(this._mainSeriesScaleRatioProperty.value.bind(this._mainSeriesScaleRatioProperty)),p(this._mainSeriesScaleRatioProperty.getMinValue()),s(this._mainSeriesScaleRatioProperty.getMaxValue()),fe],ve=new h(we,this._mainSeriesScaleRatioProperty,Le,!1,this.model(),"Price/Bar Ratio",me),ve.addFormatter(fe),this.bindControl(ve),ke=$('').data("layout-tab",a.TabNames.scales),Se=$(""),Pe=this.addLabeledRow(ke,$.t("Left Axis"),Se),$("
").append(Se).prependTo(Pe),setTimeout(function(){this.bindControl(new c(Se,this._property.scalesProperties.showLeftScale,!0,this.model(),"Show Left Axis"))}.bind(this),0),xe=$(""),Be=this.addLabeledRow(ke,$.t("Right Axis"),xe),$("").append(xe).prependTo(Be),setTimeout(function(){this.bindControl(new c(xe,this._property.scalesProperties.showRightScale,!0,this.model(),"Show Right Axis"))}.bind(this),0),t.enabled("countdown")&&(Re=$(""),Ee=this.addLabeledRow(ke,$.t("Countdown"),Re),$("").append(Re).prependTo(Ee),this.bindControl(new c(Re,this._seriesProperty.showCountdown,!0,this.model(),"Change Show Countdown"))),Fe=$(''),Ie=this.addLabeledRow(ke,$.t("Symbol Last Value"),Fe),$("").append(Fe).prependTo(Ie),this.bindControl(new c(Fe,this._property.scalesProperties.showSeriesLastValue,!0,this.model(),"Change Symbol Last Value Visibility")),De=$(''),Ae=this.addLabeledRow(ke,$.t("Indicator Last Value"),De),$("").append(De).prependTo(Ae),this.bindControl(new c(De,this._property.scalesProperties.showStudyLastValue,!0,this.model(),"Change Indicator Last Value Visibility")),We=$(''),Ve=this.addLabeledRow(ke,$.t("Symbol Labels"),We),$("").append(We).prependTo(Ve), -this.bindControl(new c(We,this._property.scalesProperties.showSymbolLabels,!0,this.model(),"Show Symbol Labels")),Oe=$(''),ze=this.addLabeledRow(ke,$.t("Indicator Labels"),Oe),$("").append(Oe).prependTo(ze),this.bindControl(new c(Oe,this._property.scalesProperties.showStudyPlotLabels,!0,this.model(),"Show Study Plots Labels")),Me=$(""),je=this.addLabeledRow(ke,$.t("No Overlapping Labels"),Me),$("").append(Me).prependTo(je),this.bindControl(new c(Me,this._scaleProperty.alignLabels,!0,this.model(),"No Overlapping Labels")),He=$('
').append(N).append(se),Ge=$('
').append(ke),R=$("
").css("min-width","520px").data("layout-tab",a.TabNames.scales),R.append(He).append(Ge),this.scalesTab=R,k=$('').data("layout-tab",a.TabNames.style),Ne=this.createSeriesMinTickEditor(),Ue=$(""),qe=$("").appendTo(ke),Ye=$('").appendTo(Ue),$("
').appendTo(qe),$(""+$.t("Decimal Places")+"").append(Ne).appendTo(Ue),k.append(Ue).appendTo(Ye),this.bindControl(new C(Ne,this._seriesProperty.minTick,null,!0,this.model(),"Change Decimal Places"))),t.enabled("chart_property_page_background")&&(Ke=$(''),Qe=this.createColorPicker({hideTransparency:!0}),Je=this.addLabeledRow(Ke,$.t("Background")),$('
').append(Qe).appendTo(Je),this.bindControl(new u(Qe,this._property.paneProperties.background,!0,this.model(),"Change Chart Background Color")),Ze=this.addLabeledRow(Ke,$.t("Vert Grid Lines")),Xe=this.createColorPicker(),$("").append(Xe).appendTo(Ze),this.bindControl(new u(Xe,this._property.paneProperties.vertGridProperties.color,!0,this.model(),"Change Vert Grid Lines Color")),et=L(),$('').append(et.render()).appendTo(Ze),this.bindControl(new C(et,this._property.paneProperties.vertGridProperties.style,parseInt,!0,this.model(),"Change Vert Grid Lines Style")),tt=this.addLabeledRow(Ke,$.t("Horz Grid Lines")),ot=this.createColorPicker(),$("").append(ot).appendTo(tt),this.bindControl(new u(ot,this._property.paneProperties.horzGridProperties.color,!0,this.model(),"Change Horz Grid Lines Color")),it=L(),$('').append(it.render()).appendTo(tt),this.bindControl(new C(it,this._property.paneProperties.horzGridProperties.style,parseInt,!0,this.model(),"Change Horz Grid Lines Style")),nt=this.createColorPicker(),at=this.addLabeledRow(Ke,$.t("Scales Text")),$("").append(nt).appendTo(at),this.bindControl(new u(nt,this._property.scalesProperties.textColor,!0,this.model(),"Change Scales Text Color")),rt=this.createFontSizeEditor(),$("").append(rt).appendTo(at),this.bindControl(new C(rt,this._property.scalesProperties.fontSize,parseInt,!0,this.model(),"Change Scales Font Size")),lt=this.createColorPicker(),pt=this.addLabeledRow(Ke,$.t("Scales Lines")),$('').append(lt).appendTo(pt), -this.bindControl(new u(lt,this._property.scalesProperties.lineColor,!0,this.model(),"Change Scales Lines Color")),st=this.addLabeledRow(Ke,$.t("Watermark")),dt=this.createColorPicker(),$("").append(dt).appendTo(st),this.bindControl(new u(dt,this._property.symbolWatermarkProperties.color,!0,this.model(),"Change Symbol Watermark Color",this._property.symbolWatermarkProperties.transparency)),ht=this.addLabeledRow(Ke,$.t("Crosshair")),ct=this.createColorPicker(),$("").append(ct).appendTo(ht),this.bindControl(new u(ct,this._property.paneProperties.crossHairProperties.color,!0,this.model(),"Change Crosshair Color",this._property.paneProperties.crossHairProperties.transparency)),bt=L(),$("").append(bt.render()).appendTo(ht),this.bindControl(new C(bt,this._property.paneProperties.crossHairProperties.style,parseInt,!0,this.model(),"Change Crosshair Style")),ut=v(),$("").append(ut).appendTo(this.addRow(Ke).prepend("")),this.bindControl(new b(ut,this._property.paneProperties.crossHairProperties.width,!0,this.model(),"Change Crosshair Width")),Ct=$(''),yt=this.addLabeledRow(Ct,$.t("Navigation Buttons"),null,!0),gt=$(document.createElement("select")),P.availableValues().forEach(function(e){$(document.createElement("option")).attr("value",e.value).text(e.title).appendTo(gt)}),$("
").append(gt).appendTo(yt),this.bindControl(new C(gt,P.property(),null,!0,this.model(),"Change Navigation Buttons Visibility")),$t=$(''),Tt=$(''),wt=this.addLabeledRow($t,$.t("Symbol Description"),Tt),$("
").append(Tt).prependTo(wt),this.bindControl(new c(Tt,this._property.paneProperties.legendProperties.showSeriesTitle,!0,this.model(),"Change Symbol Description Visibility")),_t=$(''),mt=this.addLabeledRow($t,$.t("OHLC Values"),_t),$("").append(_t).prependTo(mt),this.bindControl(new c(_t,this._property.paneProperties.legendProperties.showSeriesOHLC,!0,this.model(),"Change OHLC Values Visibility")),ft=$(''),Lt=this.addLabeledRow($t,$.t("Indicator Titles"),ft),$("").append(ft).prependTo(Lt),this.bindControl(new c(ft,this._property.paneProperties.legendProperties.showStudyTitles,!0,this.model(),"Change Indicator Titles Visibility")),vt=$(''),kt=this.addLabeledRow($t,$.t("Indicator Arguments"),vt),St=function(e){vt.prop("disabled",!e.value())},$("").append(vt).prependTo(kt),this.bindControl(new c(vt,this._property.paneProperties.legendProperties.showStudyArguments,!0,this.model(),"Change Indicator Arguments Visibility")),this._property.paneProperties.legendProperties.showStudyTitles.listeners().subscribe(this,St),St(this._property.paneProperties.legendProperties.showStudyTitles),Pt=$(''),xt=this.addLabeledRow($t,$.t("Indicator Values"),Pt),$("").append(Pt).prependTo(xt), -this.bindControl(new c(Pt,this._property.paneProperties.legendProperties.showStudyValues,!0,this.model(),"Change Indicator Values Visibility")),Bt=$('
').append(Ke),Rt=$('
').append($t),Et=$('
').append(Ct),E=$("
").css("min-width","520px").data("layout-tab",a.TabNames.background),E.append(Bt).append(Rt).append(Et)),t.enabled("chart_property_page_timezone_sessions")){for(I=$('').data("layout-tab",a.TabNames.timezoneSessions),this.tmzSessTable=I,ge=$("").appendTo(I),Ft=$("
").appendTo(ge),It=$('').appendTo(Ft),Dt=$(""),Dt.appendTo(It),At=$("
"),At.appendTo(Dt),At.text($.t("Time Zone")),Wt=$(''),Wt.appendTo(Dt),Vt="",Ot=0;Ot'+S[Ot].title+"";zt=$(""),zt.appendTo(Wt),this.bindControl(new C(zt,this._property.timezone,null,!0,this.model(),"Change Timezone")),this._series.createSessStudy(),this.createSessTable(I)}Mt=t.enabled("trading_options")||t.enabled("chart_property_page_trading"),Mt&&(D=this.createTradingTable()),n=$(''),r=$('
').css({width:"100%"}).data("layout-separated",!0),F=$('
').data("layout-tab",a.TabNames.drawings),this._table=$().add(e).add(o).add(i).add(n).add(r).add(l).add(B).add(R).add(E).add(F).add(I).add(D).add(A),this.loadData()},i.prototype.widget=function(){return this._table},i.prototype.loadData=function(){this.superclass.prototype.loadData.call(this),this.switchStyle()},i.prototype.loadTheme=function(e,t,o){},i.prototype.applyTheme=function(e,t){this._model._chartWidget._chartWidgetCollection.applyTheme(e,t),this.loadData()},i.prototype.createTemplateButton=function(e){return t.enabled("chart_property_page_template_button")?(this,e||(e={}),$(''+$.t("Template")+'')):$("")},i.prototype.switchStyle=function(){if(this._hasSeriesStyleLayout)switch($(this._barsTbody).add(this._barsColorerTbody).add(this._renkoTbody).add(this._pbTbody).add(this._kagiTbody).add(this._pnfTbody).add(this._candlesTbody).add(this._candlesColorerTbody).add(this._hollowCandlesTbody).add(this._lineTbody).add(this._areaTbody).add(this._haTbody).add(this._haColorerTbody).add(this._baselineTbody).css("display","none"),this._seriesProperty.style.value()){case _.STYLE_BARS:this._barsTbody.css("display","table-row-group"),this._barsColorerTbody.css("display","table-row-group");break;case _.STYLE_CANDLES:this._candlesTbody.css("display","table-row-group"),this._candlesColorerTbody.css("display","table-row-group");break;case _.STYLE_HOLLOW_CANDLES:this._hollowCandlesTbody.css("display","table-row-group");break;case _.STYLE_LINE: -this._lineTbody.css("display","table-row-group");break;case _.STYLE_AREA:this._areaTbody.css("display","table-row-group");break;case _.STYLE_RENKO:this._renkoTbody.css("display","table-row-group");break;case _.STYLE_PB:this._pbTbody.css("display","table-row-group");break;case _.STYLE_KAGI:this._kagiTbody.css("display","table-row-group");break;case _.STYLE_PNF:this._pnfTbody.css("display","table-row-group");break;case _.STYLE_HEIKEN_ASHI:this._haTbody.css("display","table-row-group"),this._haColorerTbody.css("display","table-row-group");break;case _.STYLE_BASELINE:this._baselineTbody.css("display","table-row-group")}},i.prototype.onResoreDefaults=function(){var e,t,o=this._model.model().properties().paneProperties.topMargin,i=this._model.model().properties().paneProperties.bottomMargin;o.listeners().fire(o),i.listeners().fire(i),e=this._chart.timeScale(),e.restoreRightOffsetPropertyToDefault(),t=this._model.model().properties().timezone,t.listeners().fire(t)},i.prototype.defaultProperties=function(){var e=this,t=[e._seriesProperty.extendedHours,e._property.scalesProperties.showLeftScale,e._property.scalesProperties.showRightScale].map(function(e){return{property:e,previousValue:e.value()}});return setTimeout(function(){t.forEach(function(e){e.property.value()!==e.previousValue&&e.property.listeners().fire(e.property)});var o=new k("chartproperties.paneProperties.rightAxisProperties");["autoScale","percentage","log"].forEach(function(t){var i=e._scaleProperty[t],n=o[t].value();n!==i.value()&&i.setValue(n)})},0),[this._property,this._seriesProperty]},i.prototype.createSessTable=function(e){var t,o=this._series.sessionsStudy().properties(),i=this.createTableInTable(e),n=o.name.value(),a=$(""),r=this.addLabeledRow(i,$.t("Session Breaks"),a),l=L(),p=this.createColorPicker(),s=v();return $("
").append(a).prependTo(r),$("").append(p).appendTo(r),$("").append(l.render()).appendTo(r),$("").append(s).appendTo(r),this.bindControl(new c(a,o.graphics.vertlines.sessBreaks.visible,!0,this.model(),"Change "+n+" visibility")),this.bindControl(new u(p,o.graphics.vertlines.sessBreaks.color,!0,this.model(),"Change "+n+" color")),this.bindControl(new C(l,o.graphics.vertlines.sessBreaks.style,parseInt,!0,this.model(),"Change "+n+" style")),this.bindControl(new b(s,o.graphics.vertlines.sessBreaks.width,!0,this.model(),"Change "+n+" width")),t=this._series.isIntradayInterval(),a.prop("disabled",!t),i},i.prototype._createStudySessRow=function(e,t,o){var i,n=$(""),a=this.addLabeledRow(e,t,n),r=f($("").appendTo(a));return this.bindControl(new c(n,o.visible,!0,this.model(),"Change "+t+" visibility")),this.bindControl(new u(r,o.color,!0,this.model(),t+" color",o.transparency)),i=$(""),i.append(n).prependTo(a),a.addClass("offset-row"),n},i.prototype.createTradingTable=function(){ -var e,t,o,i,n,r,l,u,y,g,T,w=$('').data("layout-tab",a.TabNames.trading),_=$("").appendTo(w),m=$("
").appendTo(_),f=$('').appendTo(m),k=$('');return _=this.addLabeledRow(f,$.t("Show Positions"),k),$(""),y=this.addLabeledRow(f,$.t("Connecting Line"),u),$("").appendTo(y),g=$(''),T=this.addLabeledRow(f,$.t("Show Executions"),g),$("
").append(k).prependTo(_),this.bindControl(new c(k,this._property.tradingProperties.showPositions,!0,this.model(),"Change Positions Visibility")),e=$(''),_=this.addLabeledRow(f,$.t("Show Orders"),e),$("").append(e).prependTo(_),this.bindControl(new c(e,this._property.tradingProperties.showOrders,!0,this.model(),"Change Orders Visibility")),t=$(''),o=this.addLabeledRow(f,$.t("Extend Lines Left"),t),$("").append(t).prependTo(o),this.bindControl(new c(t,this._property.tradingProperties.extendLeft,!0,this.model(),"Extend Lines Left")),i=v(),this.bindControl(new b(i,this._property.tradingProperties.lineWidth,!0,this.model(),"Change Connecting Line Width")),n=L(),this.bindControl(new C(n,this._property.tradingProperties.lineStyle,parseInt,!0,this.model(),"Change Connecting Line Style")),r=$(''),l=[d(this._property.tradingProperties.lineLength.value()),s(100),p(0)],this.bindControl(new h(r,this._property.tradingProperties.lineLength,l,!0,this.model(),"Change Connecting Line Length")),u=$("
").prependTo(y),$("").append(i).appendTo(y),$('').append(n.render()).appendTo(y),$('').append(r).appendTo(y),$("%").append(g).prependTo(T),this.bindControl(new c(g,this._property.tradingProperties.showExecutions,!0,this.model(),"Change Executions Visibility")),w},e.exports=i}).call(t,o(5))},1085:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.ColorBinding,l=a.SliderBinder,p=a.SimpleComboBinder,s=a.BooleanBinder,d=o(1197).createLineWidthEditor;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n,a,h,c,b;this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),e=d(),t=this.createColorPicker(),o=this.createColorPicker(),i=$(''),n=$(''),a=this.createFontSizeEditor(),h=this.createFontEditor(),c=this.addLabeledRow(this._table,"Border"),c.prepend(""),$("").append(t).appendTo(c),$("").append(e).appendTo(c),h=this.createFontEditor(),this.bindControl(new r(t,this._linetool.properties().color,!0,this.model(),"Change Pattern Line Color")),this.bindControl(new r(o,this._linetool.properties().textcolor,!0,this.model(),"Change Pattern Text Color")), -this.bindControl(new l(e,this._linetool.properties().linewidth,!0,this.model(),"Change Pattern Border Width")),this.bindControl(new p(a,this._linetool.properties().fontsize,parseInt,!0,this.model(),"Change Text Font Size")),this.bindControl(new p(h,this._linetool.properties().font,null,!0,this.model(),"Change Text Font")),this.bindControl(new s(i,this._linetool.properties().bold,!0,this.model(),"Change Text Font Bold")),this.bindControl(new s(n,this._linetool.properties().italic,!0,this.model(),"Change Text Font Italic")),b=$('').append($(document.createElement("td")).attr({width:1}).append(o)).append($(document.createElement("td")).attr({width:1}).append(h)).append($(document.createElement("td")).attr({width:1}).append(a)).append($(document.createElement("td")).css("vertical-align","top").attr({width:1}).append(i)).append($(document.createElement("td")).css("vertical-align","top").append(n)).append($("
")),c=this.addLabeledRow(this._table,""),$('
').append(b).appendTo(c),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1086:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.BooleanBinder,l=a.ColorBinding,p=a.SliderBinder,s=o(1197).createLineWidthEditor;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n;this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),e=s(),t=this.createColorPicker(),o=this.addLabeledRow(this._table,"Border"),o.prepend(""),$("").append(t).appendTo(o),$("").append(e).appendTo(o),i=$(''),n=this.createColorPicker(),o=this.addLabeledRow(this._table,"Background",i),$("").append(i).prependTo(o),$("").append(n).appendTo(o),this.bindControl(new r(i,this._linetool.properties().fillBackground,!0,this.model(),"Change Arc Filling")),this.bindControl(new l(t,this._linetool.properties().color,!0,this.model(),"Change Arc Line Color")),this.bindControl(new l(n,this._linetool.properties().backgroundColor,!0,this.model(),"Change Arc Background Color",this._linetool.properties().transparency)),this.bindControl(new p(e,this._linetool.properties().linewidth,!0,this.model(),"Change Arc Border Width")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1087:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.SimpleStringBinder,l=a.ColorBinding,p=a.SimpleComboBinder;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n;this._table=$('').css({width:"100%"}),e=$("").css({width:"100%"}),t=$('
').append(e),o=this.createColorPicker(),i=this.createFontEditor(),n=$("
").appendTo(this._table),$("
").css({width:"0" -}).html($.t("Text")).appendTo(n),$('').append(t).appendTo(n),n=this.addLabeledRow(this._table,$.t("Text Font")),n.children().css({whiteSpace:"nowrap"}),$("").append(o).appendTo(n).css({width:"0"}),$("").append(i).appendTo(n),this.bindControl(new l(o,this._linetool.properties().color,!0,this.model(),"Change Arrow Mark Text Color")),this.bindControl(new r(e,this._linetool.properties().text,null,!0,this.model(),"Change Arrow Mark Text")),this.bindControl(new p(i,this._linetool.properties().font,null,!0,this.model(),"Change Arrow Mark Font")),this.loadData(),setTimeout(function(){e.select(),e.focus()},20)},i.prototype.widget=function(){return this._table},e.exports=i},1088:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.SimpleComboBinder,l=a.ColorBinding,p=a.SimpleStringBinder,s=o(1202).TabOpenFrom;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n,a,d,h,c=$('').css({width:"100%"}).data("layout-tab-open",s.Override),b=$('
');this._table=c.add(b),e=$("").css({width:"100%"}),t=this.createColorPicker(),o=this.createFontSizeEditor(),i=this.createColorPicker(),n=this.createColorPicker(),a=$("").appendTo(c),d=$('
').append(e),$("
").appendTo(this._table),t=this.createColorPicker(),o=this.addLabeledRow(e,"Color"),$("").appendTo(e),$("").appendTo(o),n=$(""),$("").appendTo(e),$("").appendTo(o),a=$(""),$(""),e.appendTo(this._table),t=$("
").append(d).appendTo(a),h=this.addLabeledRow(b,$.t("Text")),$("").append(t).appendTo(h),$("").append(o).appendTo(h),h=this.addLabeledRow(b,$.t("Background")),$("").appendTo(h).append(i),h=this.addLabeledRow(b,$.t("Border")),$("").appendTo(h).append(n),$(""),this.bindControl(new p(e,this._linetool.properties().text,null,!0,this.model(),"Change Balloon Text")),this.bindControl(new l(t,this._linetool.properties().color,!0,this.model(),"Change Baloon Text Color")),this.bindControl(new r(o,this._linetool.properties().fontsize,parseInt,!0,this.model(),"Change Balloon Text Font Size")),this.bindControl(new l(i,this._linetool.properties().backgroundColor,!0,this.model(),"Change Balloon Background Color",this._linetool.properties().transparency)),this.bindControl(new l(n,this._linetool.properties().borderColor,!0,this.model(),"Change Balloon Border Color")),this.loadData(),setTimeout(function(){e.select(),e.focus()},0)},i.prototype.widget=function(){return this._table},e.exports=i},1089:function(e,t,o){"use strict";function i(e,t,o){a.call(this,e,t,o),this.prepareLayout()}function n(e,t,o){r.call(this,e,t,o)}var a=o(1196),r=o(1077),l=o(239),p=l.ToFloatTransformer,s=l.SimpleComboBinder,d=l.ColorBinding,h=l.BooleanBinder,c=l.SimpleStringBinder;inherit(i,a),i.prototype.prepareLayout=function(){var e,t,o,i,n,a;this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),e=$("
").append(t).appendTo(o), -i=$('"),o=this.addLabeledRow(e,"Mode"),$("").append(i).appendTo(o),o=$("
"+$.t("Mirrored")+"").append(n).appendTo(o),o=$("
"+$.t("Flipped")+"").append(a).appendTo(o),this.bindControl(new h(n,this._linetool.properties().mirrored,!0,this.model(),"Change Bars Pattern Mirroring")),this.bindControl(new h(a,this._linetool.properties().flipped,!0,this.model(),"Change Bars Pattern Flipping")),this.bindControl(new d(t,this._linetool.properties().color,!0,this.model(),"Change Bars Pattern Color")),this.bindControl(new s(i,this._linetool.properties().mode,null,!0,this.model(),"Change Bars Pattern Mode")),this.loadData()},i.prototype.widget=function(){return this._table},inherit(n,r),n.prototype.prepareLayout=function(){var e,t,o,i,n,a,r,l,s;this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),e=$("
"),t.html($.t("Price")),t.appendTo(e),o=$(""),o.appendTo(e),i=$(""),i.appendTo(o),n=$(""),n.html($.t("Bar #")),n.appendTo(e),a=$(""),a.appendTo(e),r=$(""),r.appendTo(a),r.addClass("ticker"),l=this._linetool.properties().points[0],s=[p(l.price.value())],this.bindControl(new c(i,l.price,s,!1,this.model(),"Change "+this._linetool+" point price")),this.bindBarIndex(l.bar,r,this.model(),"Change "+this._linetool+" point bar index"),this.loadData()},t.LineToolBarsPatternStylesPropertyPage=i,t.LineToolBarsPatternInputsPropertyPage=n},1090:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.ColorBinding,l=a.SimpleComboBinder,p=a.SliderBinder,s=a.BooleanBinder,d=o(1198).createLineStyleEditor,h=o(1197).createLineWidthEditor;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n,a,c,b,u,C,y,g,T,w,_,m;this._block=$("
").addClass("property-page"),e=$('').appendTo(this._block),t=$("").appendTo(e),o=h(),i=d(),n=this.createColorPicker(),a=this.addLabeledRow(t,$.t("Line")),$("
").append(n).appendTo(a),$("").append(o).appendTo(a),$('').append(i.render()).appendTo(a),c=$('').appendTo(this._block),a=this.addLabeledRow(c,$.t("Background"),b),b=$(''),u=this.createColorPicker(),$("
").append(b).prependTo(a),$("").append(u).appendTo(a),C=$('').appendTo(this._block), -y=$(""),g=$(""),T=$("").css({"margin-left":"8px"}),w=$('').appendTo(T),_=$("").css({"margin-left":"8px"}),m=$('').appendTo(_),a=this.addLabeledRow(C,$.t("Left End")),$('
').appendTo(a).append(y).append(T),a=this.addLabeledRow(C,$.t("Right End")),$('').appendTo(a).append(g).append(_),this.bindControl(new r(n,this._linetool.properties().linecolor,!0,this.model(),"Change Curve Line Color")),this.bindControl(new l(i,this._linetool.properties().linestyle,parseInt,!0,this.model(),"Change Curve Line Style")),this.bindControl(new p(o,this._linetool.properties().linewidth,!0,this.model(),"Change Curve Line Width")),this.bindControl(new s(b,this._linetool.properties().fillBackground,!0,this.model(),"Change Curve Filling")),this.bindControl(new r(u,this._linetool.properties().backgroundColor,!0,this.model(),"Change Curve Background Color",this._linetool.properties().transparency)),this.bindControl(new l(y,this._linetool.properties().leftEnd,parseInt,!0,this.model(),"Change Curve Line Left End")),this.bindControl(new l(g,this._linetool.properties().rightEnd,parseInt,!0,this.model(),"Change Curve Line Right End")),this.bindControl(new s(w,this._linetool.properties().extendLeft,!0,this.model(),"Change Curve Line Extending Left")),this.bindControl(new s(m,this._linetool.properties().extendRight,!0,this.model(),"Change Curve Line Extending Right")),this.loadData()},i.prototype.widget=function(){return this._block},e.exports=i},1091:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.SliderBinder,l=a.BooleanBinder,p=a.ColorBinding,s=a.SimpleComboBinder,d=o(1197).createLineWidthEditor;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n,a,h,c;this._table=$(''),e=d(),t=this.createColorPicker(),o=$(''),i=this.createColorPicker(),n=this.addLabeledRow(this._table,"Line"),$("").appendTo(this._table),h=$(""),c=$(""),n=this.addLabeledRow(a,$.t("Left End")),$("
").prependTo(n),$("").append(t).appendTo(n),$("").append(e).appendTo(n),n=this.addLabeledRow(this._table,"Background",o),$("").append(o).prependTo(n),$("").append(i).appendTo(n),a=$("
").prependTo(n),$('').appendTo(n).append(h),n=this.addLabeledRow(a,$.t("Right End")),$("").prependTo(n),$('').appendTo(n).append(c), -this.bindControl(new p(t,this._linetool.properties().linecolor,!0,this.model(),"Change Brush Color")),this.bindControl(new r(e,this._linetool.properties().linewidth,!0,this.model(),"Change Brush Line Width")),this.bindControl(new l(o,this._linetool.properties().fillBackground,!0,this.model(),"Change Brush Filling")),this.bindControl(new p(i,this._linetool.properties().backgroundColor,!0,this.model(),"Change Brush Background Color",this._linetool.properties().transparency)),this.bindControl(new s(h,this._linetool.properties().leftEnd,parseInt,!0,this.model(),"Change Trend Line Left End")),this.bindControl(new s(c,this._linetool.properties().rightEnd,parseInt,!0,this.model(),"Change Trend Line Right End")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1092:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.BooleanBinder,l=a.ColorBinding,p=a.SimpleComboBinder,s=a.SliderBinder,d=a.SimpleStringBinder,h=o(1197).createLineWidthEditor,c=o(1202).TabOpenFrom;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n=this.createColorPicker(),a=this.createFontSizeEditor(),b=this.createFontEditor(),u=this.createTextEditor(350,200),C=this.createColorPicker(),y=h(),g=this.createColorPicker(),T=$(''),w=$(''),_=$('');this.bindControl(new l(n,this._linetool.properties().color,!0,this.model(),"Change Text Color")),this.bindControl(new p(a,this._linetool.properties().fontsize,parseInt,!0,this.model(),"Change Text Font Size")),this.bindControl(new p(b,this._linetool.properties().font,null,!0,this.model(),"Change Text Font")),this.bindControl(new d(u,this._linetool.properties().text,null,!0,this.model(),"Change Text")),this.bindControl(new l(C,this._linetool.properties().backgroundColor,!0,this.model(),"Change Text Background",this._linetool.properties().transparency)),this.bindControl(new l(g,this._linetool.properties().bordercolor,!0,this.model(),"Change Text Color")),this.bindControl(new s(y,this._linetool.properties().linewidth,!0,this.model(),"Change Border Width")),this.bindControl(new r(T,this._linetool.properties().wordWrap,!0,this.model(),"Change Text Wrap")),this.bindControl(new r(w,this._linetool.properties().bold,!0,this.model(),"Change Text Font Bold")),this.bindControl(new r(_,this._linetool.properties().italic,!0,this.model(),"Change Text Font Italic")),e=$('').data("layout-tab-open",c.Override),t=$('
'),o=$('
'),this._table=e.add(o).add(t),$(document.createElement("tr")).append($(document.createElement("td")).attr({width:1}).append(n)).append($(document.createElement("td")).attr({width:1 -}).append(b)).append($(document.createElement("td")).attr({width:1}).append(a)).append($(document.createElement("td")).attr({width:1}).append(w)).append($(document.createElement("td")).append(_)).appendTo(e),$(document.createElement("tr")).append($(document.createElement("td")).attr({colspan:5}).append(u)).appendTo(e),i=this.addLabeledRow(t,"Text Wrap",T),$("
").append(T).prependTo(i),i=this.addLabeledRow(o,"Background"),$("").append(C).appendTo(i),i=this.addLabeledRow(o,"Border"),$("").append(g).appendTo(i),$("").append(y).appendTo(i),this.loadData(),setTimeout(function(){u.select(),u.focus()},20)},i.prototype.widget=function(){return this._table},e.exports=i},1093:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.SimpleComboBinder,l=a.ColorBinding,p=a.SliderBinder,s=o(1198).createLineStyleEditor,d=o(1197).createLineWidthEditor;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i;this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),e=d(),t=s(),o=this.createColorPicker(),i=this.addLabeledRow(this._table,"Lines"),$("").append(o).appendTo(i),$("").append(e).appendTo(i),$("").append(t.render()).appendTo(i),this.bindControl(new l(o,this._linetool.properties().linecolor,!0,this.model(),"Change Circle Lines Color")),this.bindControl(new r(t,this._linetool.properties().linestyle,parseInt,!0,this.model(),"Change Circle Lines Style")),this.bindControl(new p(e,this._linetool.properties().linewidth,!0,this.model(),"Change Circle Lines Width")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1094:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.SimpleComboBinder,l=a.ColorBinding,p=a.BooleanBinder,s=a.SliderBinder,d=o(1197).createLineWidthEditor;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n,a,h,c,b,u,C,y,g,T;this._table=$(''),e=$("").appendTo(this._table),t=d(),o=this.createColorPicker(),i=this.addLabeledRow(e,$.t("Line")),$("
").prependTo(i),$("").append(o).appendTo(i),$("").append(t).appendTo(i),n=this.createColorPicker(),a=this.createColorPicker(),h=this.createFontSizeEditor(),c=this.createFontEditor(),b=this.createColorPicker(),u=$(''),C=this.createColorPicker(),y=$(''),this.bindControl(new l(n,this._linetool.properties().textcolor,!0,this.model(),"Change Text Color")),this.bindControl(new r(h,this._linetool.properties().fontsize,parseInt,!0,this.model(),"Change Text Font Size")),this.bindControl(new r(c,this._linetool.properties().font,null,!0,this.model(),"Change Text Font")), -this.bindControl(new l(b,this._linetool.properties().labelBackgroundColor,!0,this.model(),"Change Text Background",this._linetool.properties().labelBackgroundTransparency)),this.bindControl(new p(u,this._linetool.properties().fillLabelBackground,!0,this.model(),"Change Text Background Fill")),this.bindControl(new l(C,this._linetool.properties().backgroundColor,!0,this.model(),"Change Text Background",this._linetool.properties().backgroundTransparency)),this.bindControl(new p(y,this._linetool.properties().fillBackground,!0,this.model(),"Change Text Background Fill")),this.bindControl(new l(a,this._linetool.properties().borderColor,!0,this.model(),"Change Text Border Color")),g=this.addLabeledRow(e,$.t("Background"),y),$("").append(y).prependTo(g),$("").append(C).appendTo(g),T=this.addLabeledRow(e,$.t("Label")),$("").prependTo(T),$("").append(n).appendTo(T),$("").append(c).appendTo(T),$("").append(h).appendTo(T),g=this.addLabeledRow(e,$.t("Label Background"),u),$("").append(u).prependTo(g),$("").append(b).appendTo(g),this.bindControl(new l(o,this._linetool.properties().linecolor,!0,this.model(),"Change Date Range Color")),this.bindControl(new s(t,this._linetool.properties().linewidth,!0,this.model(),"Change Date Range Line Width")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1095:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.SimpleComboBinder,l=a.ColorBinding,p=a.BooleanBinder,s=a.SliderBinder,d=o(1197).createLineWidthEditor;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n,a,h,c,b,u,C,y,g,T,w,_,m,f,L,v,k,S,P;this._table=$(''),e=$("").appendTo(this._table),t=d(),o=this.createColorPicker(),i=this.addLabeledRow(e,$.t("Line")),$("
").prependTo(i),$("").append(o).appendTo(i),$("").append(t).appendTo(i),n=this.createColorPicker(),a=this.createColorPicker(),h=this.createFontSizeEditor(),c=this.createFontEditor(),b=this.createColorPicker(),u=$(''),C=this.createColorPicker(),y=$(''),this.bindControl(new l(n,this._linetool.properties().textcolor,!0,this.model(),"Change Text Color")),this.bindControl(new r(h,this._linetool.properties().fontsize,parseInt,!0,this.model(),"Change Text Font Size")),this.bindControl(new r(c,this._linetool.properties().font,null,!0,this.model(),"Change Text Font")),this.bindControl(new l(b,this._linetool.properties().labelBackgroundColor,!0,this.model(),"Change Text Background",this._linetool.properties().labelBackgroundTransparency)),this.bindControl(new p(u,this._linetool.properties().fillLabelBackground,!0,this.model(),"Change Text Background Fill")),this.bindControl(new l(C,this._linetool.properties().backgroundColor,!0,this.model(),"Change Text Background",this._linetool.properties().backgroundTransparency)), -this.bindControl(new p(y,this._linetool.properties().fillBackground,!0,this.model(),"Change Text Background Fill")),this.bindControl(new l(a,this._linetool.properties().borderColor,!0,this.model(),"Change Text Border Color")),g=this.addLabeledRow(e,$.t("Background"),y),$("").append(y).prependTo(g),$("").append(C).appendTo(g),T=this.addLabeledRow(e,$.t("Label")),$("").prependTo(T),$("").append(n).appendTo(T),$("").append(c).appendTo(T),$("").append(h).appendTo(T),g=this.addLabeledRow(e,$.t("Label Background"),u),$("").append(u).prependTo(g),$("").append(b).appendTo(g),this.bindControl(new l(o,this._linetool.properties().linecolor,!0,this.model(),"Change Date Range Color")),this.bindControl(new s(t,this._linetool.properties().linewidth,!0,this.model(),"Change Date Range Line Width")),w=this._linetool.properties(),void 0!==w.extendTop&&void 0!==w.extendBottom&&(_=$(''),m=$(''),this.bindControl(new p(_,this._linetool.properties().extendTop,!0,this.model(),"Change Extend Top")),this.bindControl(new p(m,this._linetool.properties().extendBottom,!0,this.model(),"Change Extend Bottom")),f=this.addLabeledRow(e,$.t("Extend Top"),_),$("").append(_).prependTo(f),L=this.addLabeledRow(e,$.t("Extend Bottom"),m),$("").append(m).prependTo(L)),void 0!==w.extendLeft&&void 0!==w.extendRight&&(v=$(''),k=$(''),this.bindControl(new p(v,this._linetool.properties().extendLeft,!0,this.model(),"Change Extend Left")),this.bindControl(new p(k,this._linetool.properties().extendRight,!0,this.model(),"Change Extend Right")),S=this.addLabeledRow(e,$.t("Extend Left"),v),$("").append(v).prependTo(S),P=this.addLabeledRow(e,$.t("Extend Right"),k),$("").append(k).prependTo(P)),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1096:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.SimpleComboBinder,l=a.BooleanBinder,p=a.ColorBinding,s=a.SliderBinder,d=o(1198).createLineStyleEditor,h=o(1197).createLineWidthEditor;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n,a,c,b,u,C,y,g,T,w,_,m,f,L,v,k,S,P,x,B;this._table=$(''),e=$("").appendTo(this._table),t=h(),o=d(),i=this.createColorPicker(),n=this.addLabeledRow(e,$.t("Line")),$("").appendTo(this._table), -g=$(''),T=this.createColorPicker(),n=this.addLabeledRow(y,$.t("Background"),g),w=$("
").append(i).appendTo(n),$("").append(t).appendTo(n),$('').append(o.render()).appendTo(n),n=this.addLabeledRow(e,$.t("Text")),a=this.createColorPicker(),c=this.createFontSizeEditor(),b=this.createFontEditor(),u=$(''),C=$(''),$("").append(a).appendTo(n),$("").append(b).appendTo(n),$("").append(c).appendTo(n),$("").append(u).appendTo(n),$("").append(C).appendTo(n),y=$("
"),$('").appendTo(w),$("").appendTo(this._table),m=$("").css({"margin-left":"8px"}),f=$('').appendTo(m),L=$("").css({"margin-left":"8px"}),v=$('').appendTo(L),k=$(""),S=$(""),n=this.addLabeledRow(_,$.t("Left End")),$('").appendTo(this._table),n=$("").appendTo(P),x=$(""),B=$("
').append(w).appendTo(n),n=$("
").append(g).appendTo(n),$("").append(T).appendTo(n),_=$("
').appendTo(n).append(k).append(m),n=this.addLabeledRow(_,$.t("Right End")),$('').appendTo(n).append(S).append(L),P=$("
").append(B).appendTo(n),this.bindControl(new r(c,this._linetool.properties().fontsize,parseInt,!0,this.model(),"Change Text Font Size")),this.bindControl(new r(b,this._linetool.properties().font,null,!0,this.model(),"Change Text Font")),this.bindControl(new p(a,this._linetool.properties().textcolor,!0,this.model(),"Change Text Color")),this.bindControl(new l(u,this._linetool.properties().bold,!0,this.model(),"Change Text Font Bold")),this.bindControl(new l(C,this._linetool.properties().italic,!0,this.model(),"Change Text Font Italic")),this.bindControl(new l(x,this._linetool.properties().showPrices,!0,this.model(),"Change Disjoint Angle Show Prices")),this.bindControl(new l(f,this._linetool.properties().extendLeft,!0,this.model(),"Change Disjoint Angle Extending Left")),this.bindControl(new l(v,this._linetool.properties().extendRight,!0,this.model(),"Change Disjoint Angle Extending Right")),this.bindControl(new p(i,this._linetool.properties().linecolor,!0,this.model(),"Change Disjoint Angle Color")),this.bindControl(new r(o,this._linetool.properties().linestyle,parseInt,!0,this.model(),"Change Disjoint Angle Style")),this.bindControl(new s(t,this._linetool.properties().linewidth,!0,this.model(),"Change Disjoint Angle Width")),this.bindControl(new r(k,this._linetool.properties().leftEnd,parseInt,!0,this.model(),"Change Disjoint Angle Left End")),this.bindControl(new r(S,this._linetool.properties().rightEnd,parseInt,!0,this.model(),"Change Disjoint Angle Right End")),this.bindControl(new l(g,this._linetool.properties().fillBackground,!0,this.model(),"Change Disjoint Angle Filling")),this.bindControl(new p(T,this._linetool.properties().backgroundColor,!0,this.model(),"Change Disjoint Angle Background Color",this._linetool.properties().transparency)),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1097:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o), -this.prepareLayout()}var n,a,r,l,p,s,d;o(12),n=o(1196),a=o(239),r=a.SimpleComboBinder,l=a.ColorBinding,p=a.SliderBinder,s=a.BooleanBinder,d=o(1197).createLineWidthEditor,inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n,a;this._table=$(''),e=this._linetool.getDegrees(),t=this.createKeyCombo(e),t.width(300),o=this.createColorPicker(),i=$(''),n=this.addLabeledRow(this._table,window.t("Degree")),$("");m.appendTo(this._table),i=$(""),i.appendTo(this._table),a=$(""),$("");m.appendTo(this._table),i=$("").appendTo(m),C=$(""),i.appendTo(this._table),a=$(""),$("").appendTo(i),r=u(),$('");b.appendTo(e),i=$("").appendTo(this._table),t=$(""),t.appendTo(e),o=$('
").prependTo(n),$("").append(t).appendTo(n),n=this.addLabeledRow(this._table,window.t("Line Width")),a=d(),$("").prependTo(n),$("").append(a).appendTo(n),n=this.addLabeledRow(this._table,window.t("Color")),$("").prependTo(n),$("").append(o).appendTo(n),n=this.addLabeledRow(this._table,window.t("Show Wave"),i),$("").append(i).prependTo(n),this.bindControl(new l(o,this._linetool.properties().color,!0,this.model(),"Change Elliott Label Color")),this.bindControl(new r(t,this._linetool.properties().degree,parseInt,!0,this.model(),"Change Elliott Wave Size")),this.bindControl(new s(i,this._linetool.properties().showWave,!0,this.model(),"Change Elliott Labels Background")),this.bindControl(new p(a,this._linetool.properties().linewidth,parseInt,this.model(),"Change Elliott Wave Line Width")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1098:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.BooleanBinder,l=a.ColorBinding,p=a.SliderBinder,s=o(1197).createLineWidthEditor;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n;this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),e=s(),t=this.createColorPicker(),o=this.addLabeledRow(this._table,$.t("Border")),o.prepend(""),$("").append(t).appendTo(o),$("").append(e).appendTo(o),i=$(''),n=this.createColorPicker(),o=this.addLabeledRow(this._table,$.t("Background"),i),$("").append(i).prependTo(o),$("").append(n).appendTo(o),this.bindControl(new r(i,this._linetool.properties().fillBackground,!0,this.model(),"Change Ellipse Filling")),this.bindControl(new l(t,this._linetool.properties().color,!0,this.model(),"Change Ellipse Line Color")),this.bindControl(new l(n,this._linetool.properties().backgroundColor,!0,this.model(),"Change Ellipse Background Color",this._linetool.properties().transparency)),this.bindControl(new p(e,this._linetool.properties().linewidth,!0,this.model(),"Change Ellipse Border Width")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1099:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o)}var n=o(1079);inherit(i,n),e.exports=i},1100:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()} -var n=o(1196),a=o(239),r=a.FloatBinder,l=a.SimpleComboBinder,p=a.BooleanBinder,s=a.ColorBinding,d=a.SliderBinder,h=o(373).addColorPicker,c=o(1198).createLineStyleEditor,b=o(1197).createLineWidthEditor,u=o(1199).createTransparencyEditor;inherit(i,n),i.prototype.addLevelEditor=function(e,t,o){var i,n,a,u,C,y,g,T,w,_,m=$("
"),i.appendTo(m),n=$(""),n.appendTo(i),e?(a=$(""),a.appendTo(m),u=$(""),u.appendTo(a),u.css("width","70px"),this.bindControl(new r(u,t.coeff,!1,this.model(),"Change Pitchfork Line Coeff"))):this.createLabeledCell("Trend Line",n).appendTo(m),C=$(""),C.appendTo(m),y=h(C),g=$(""),g.appendTo(m),T=b(),T.appendTo(g),e||(w=$(""),w.appendTo(m),_=c(),_.render().appendTo(w),this.bindControl(new l(_,t.linestyle,parseInt,!0,this.model(),"Change Fib Circle Style"))),this.bindControl(new p(n,t.visible,!0,this.model(),"Change Fib Circle Visibility")),this.bindControl(new s(y,t.color,!0,this.model(),"Change Fib Circle Line Color",0)),this.bindControl(new d(T,t.linewidth,!0,this.model(),"Change Fib Circle Width"))},i.prototype.prepareLayout=function(){var e,t,o,i,n,a,r;for(this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),this.addLevelEditor(null,this._linetool.properties().trendline,!1),e=1;e<=11;e++)t="level"+e,this.addLevelEditor("Level "+e,this._linetool.properties()[t],!1);this.addOneColorPropertyWidget(this._table),o=$(""),i=this.addLabeledRow(this._table,"Levels",o),$("").append(o).prependTo(i),n=$(""),i=this.addLabeledRow(this._table,"Coeffs As Percents",n),$("").append(n).prependTo(i),this.bindControl(new p(o,this._linetool.properties().showCoeffs,!0,this.model(),"Change Fib Circle Levels Visibility")),i=$("
").append(a).appendTo(i),this.createLabeledCell("Background",a).appendTo(i),r=u(),$('').append(r).appendTo(i),this.bindControl(new p(a,this._linetool.properties().fillBackground,!0,this.model(),"Change Pitchfork Background Visibility")),this.bindControl(new d(r,this._linetool.properties().transparency,!0,this.model(),"Change Pitchfork Background Transparency")),this.bindControl(new p(n,this._linetool.properties().coeffsAsPercents,!0,this.model(),"Change Fib Retracement Coeffs As Percents")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1101:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.FloatBinder,l=a.SimpleComboBinder,p=a.BooleanBinder,s=a.ColorBinding,d=a.SliderBinder,h=o(373).addColorPicker,c=o(1198).createLineStyleEditor,b=o(1197).createLineWidthEditor,u=o(1199).createTransparencyEditor;inherit(i,n), -i.prototype.addLevelEditor=function(e,t,o){var i,n,a,u,C,y,g,T,w,_,m=$("
"),i.appendTo(m),n=$(""),n.appendTo(i),e?(a=$(""),a.appendTo(m),u=$(""),u.appendTo(a),u.css("width","70px"),this.bindControl(new r(u,t.coeff,!1,this.model(),"Change Pitchfork Line Coeff"))):$(""+$.t("Trend Line")+""),C.appendTo(m),y=h(C),g=$(""),g.appendTo(m),T=b(),T.appendTo(g),e||(w=$(""),w.appendTo(m),_=c(),_.render().appendTo(w),this.bindControl(new l(_,t.linestyle,parseInt,!0,this.model(),"Change Fib Speed Resistance Arcs Style"))),this.bindControl(new p(n,t.visible,!0,this.model(),"Change Fib Speed Resistance Arcs Visibility")),this.bindControl(new s(y,t.color,!0,this.model(),"Change Fib Speed Resistance Arcs Line Color",0)),this.bindControl(new d(T,t.linewidth,!0,this.model(),"Change Fib Speed Resistance Arcs Width"))},i.prototype.prepareLayout=function(){var e,t,o,i,n,a,r;for(this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),this.addLevelEditor(null,this._linetool.properties().trendline,!1),e=1;e<=11;e++)t="level"+e,this.addLevelEditor("Level "+e,this._linetool.properties()[t],!1);this.addOneColorPropertyWidget(this._table),o=$(""),i=this.addLabeledRow(this._table,$.t("Levels")),$("").append(o).prependTo(i),this.bindControl(new p(o,this._linetool.properties().showCoeffs,!0,this.model(),"Change Fib Speed Resistance Arcs Levels Visibility")),n=$(""),i=this.addLabeledRow(this._table,$.t("Full Circles")),$("").append(n).prependTo(i),this.bindControl(new p(n,this._linetool.properties().fullCircles,!0,this.model(),"Change Fib Speed Resistance Arcs Full Cirlces Mode")),i=$("
").append(a).appendTo(i),$(""+$.t("Background")+"').append(r).appendTo(i),this.bindControl(new p(a,this._linetool.properties().fillBackground,!0,this.model(),"Change Fib Arcs Background Visibility")),this.bindControl(new d(r,this._linetool.properties().transparency,!0,this.model(),"Change Fib Arcs Background Transparency")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1102:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.BooleanBinder,l=a.ColorBinding,p=a.FloatBinder,s=a.SimpleComboBinder,d=a.SliderBinder,h=o(373).addColorPicker,c=o(1198).createLineStyleEditor,b=o(1197).createLineWidthEditor,u=o(1199).createTransparencyEditor;inherit(i,n),i.prototype.addLevelEditor=function(e,t,o){var i,n,a,s,d,c,b=$("
"),i.appendTo(b),n=$(""),n.appendTo(i),a=$(""),a.appendTo(b), -s=$(""),s.appendTo(a),s.css("width","70px"),this.bindControl(new r(n,o.visible,!0,this.model(),"Change Gann Square Line Visibility")),this.bindControl(new p(s,o.coeff,!1,this.model(),"Change Pitchfork Line Coeff")),d=$(""),d.appendTo(b),c=h(d),this.bindControl(new l(c,o.color,!0,this.model(),"Change Gann Square Line Color",0))},i.prototype.prepareLayout=function(){var e,t,o,i,n,a,p,h,C,y,g,T,w,_,m,f,L,v,k,S,P,x,B;for(this._table=$(document.createElement("table")),this._table.addClass("property-page property-page-unpadded"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),this._table.css({width:"100%"}),e=$("
'),o.appendTo(t),i=$(''),i.appendTo(t),n=$(''),n.appendTo(o),n.addClass("property-page"),a=$('
'),a.appendTo(i),a.addClass("property-page"),$("").appendTo(n),$("").appendTo(a),p=1;p<=7;p++)h="hlevel"+p,this.addLevelEditor(n,"Level "+p,this._linetool.properties()[h]);for(p=1;p<=7;p++)h="vlevel"+p,this.addLevelEditor(a,"Level "+p,this._linetool.properties()[h]);this.addOneColorPropertyWidget(n),i.css({"vertical-align":"top"}),C=$(""),y=$(""),g=$(""),T=$(""),w=$('
"+$.t("Price Levels")+"
"+$.t("Time Levels")+"
').css({width:"100%"}),_=$("").appendTo(w),m=$('
').appendTo($("
").css({width:"50%"}).appendTo(_)),f=$('').appendTo($("
").css({width:"50%"}).appendTo(_)),L=this.addLabeledRow(m,$.t("Left Labels"),C),$("").append(C).prependTo(L),L=this.addLabeledRow(f,$.t("Right Labels"),y),$("").append(y).prependTo(L),L=this.addLabeledRow(m,$.t("Top Labels"),g),$("").append(g).prependTo(L),L=this.addLabeledRow(f,$.t("Bottom Labels"),T),$("").append(T).prependTo(L),this.bindControl(new r(C,this._linetool.properties().showLeftLabels,!0,this.model(),"Change Gann Square Left Labels Visibility")),this.bindControl(new r(y,this._linetool.properties().showRightLabels,!0,this.model(),"Change Gann Square Right Labels Visibility")),this.bindControl(new r(g,this._linetool.properties().showTopLabels,!0,this.model(),"Change Gann Square Top Labels Visibility")),this.bindControl(new r(T,this._linetool.properties().showBottomLabels,!0,this.model(),"Change Gann Square Bottom Labels Visibility")),v=$(''),k=b(),S=c(),P=this.createColorPicker(),x=$(""),L=this.addLabeledRow(v,$.t("Grid"),x), -$(""),L.appendTo(v),x=$(""),$("
").append(x).prependTo(L),$("").append(P).appendTo(L),$("").append(k).appendTo(L),$("").append(S.render()).appendTo(L),this.bindControl(new r(x,this._linetool.properties().grid.visible,!0,this.model(),"Change Fib Speed Resistance Fan Grid Visibility")),this.bindControl(new l(P,this._linetool.properties().grid.color,!0,this.model(),"Change Fib Speed Resistance Fan Grid Line Color",0)),this.bindControl(new s(S,this._linetool.properties().grid.linestyle,parseInt,!0,this.model(),"Change Fib Speed Resistance Fan Grid Line Style")),this.bindControl(new d(k,this._linetool.properties().grid.linewidth,!0,this.model(),"Change Fib Speed Resistance Fan Grid Line Width")),this._table=this._table.add(w).add(v),L=$("
").append(x).appendTo(L),this.createLabeledCell("Background",x).appendTo(L),B=u(),$('').append(B).appendTo(L),this.bindControl(new r(x,this._linetool.properties().fillBackground,!0,this.model(),"Change Fib Speed/Resistance Fan Background Visibility")),this.bindControl(new d(B,this._linetool.properties().transparency,!0,this.model(),"Change Fib Speed/Resistance Fan Background Transparency")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1103:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.SimpleComboBinder,l=a.ColorBinding,p=a.SliderBinder,s=o(1198).createLineStyleEditor,d=o(1197).createLineWidthEditor;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n;this._table=$(''),e=$("").appendTo(this._table),t=d(),o=s(),i=this.createColorPicker(),n=this.addLabeledRow(e,"Line"),$("");m.appendTo(this._table),i=$("
").append(i).appendTo(n),$("").append(t).appendTo(n),$('').append(o.render()).appendTo(n),this.bindControl(new l(i,this._linetool.properties().linecolor,!0,this.model(),"Change Fib Spiral Line Color")),this.bindControl(new r(o,this._linetool.properties().linestyle,parseInt,!0,this.model(),"Change Fib Spiral Line Style")),this.bindControl(new p(t,this._linetool.properties().linewidth,!0,this.model(),"Change Fib Spiral Line Width")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1104:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.FloatBinder,l=a.BooleanBinder,p=a.ColorBinding,s=a.SimpleComboBinder,d=a.SliderBinder,h=o(373).addColorPicker,c=o(1198).createLineStyleEditor,b=o(1197).createLineWidthEditor,u=o(1199).createTransparencyEditor;inherit(i,n),i.prototype.addLevelEditor=function(e,t,o){var i,n,a,u,C,y,g,T,w,_,m=$("
"),i.appendTo(m),n=$(""),n.appendTo(i),e?(a=$(""),a.appendTo(m),u=$(""),u.appendTo(a),u.css("width","70px"), -this.bindControl(new r(u,t.coeff,!1,this.model(),"Change Pitchfork Line Coeff"))):this.createLabeledCell($.t("Trend Line"),n).appendTo(m),C=$(""),C.appendTo(m),y=h(C),g=$(""),g.appendTo(m),T=b(),T.appendTo(g),w=$(""),w.appendTo(m),_=c(),_.render().appendTo(w),this.bindControl(new l(n,t.visible,!0,this.model(),"Change Pitchfork Line Visibility")),this.bindControl(new p(y,t.color,!0,this.model(),"Change Pitchfork Line Color",0)),this.bindControl(new s(_,t.linestyle,parseInt,!0,this.model(),"Change Pitchfork Line Style")),this.bindControl(new d(T,t.linewidth,parseInt,this.model(),"Change Pitchfork Line Width"))},i.prototype.prepareLayout=function(){var e,t,o,i,n,a,r,p,h;for(this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),e=1;e<=11;e++)t="level"+e,this.addLevelEditor("Level "+e,this._linetool.properties()[t],!1);this.addOneColorPropertyWidget(this._table),o=$(""),i=this.addLabeledRow(this._table,$.t("Show Labels"),o),$("").append(o).prependTo(i),n=$(""),a=$(""),r=$(""),i=$(""),i.append("").append(a).append("").append(r),i.appendTo(n),i=$(""),$(""),i.appendTo(this._table),p=$(""),$("") -;g.appendTo(this._table),i=$(""),i.appendTo(this._table),n=$(""),$("
"+$.t("Labels")+" 
").append(n).appendTo(i),i.appendTo(this._table),this.bindControl(new s(a,this._linetool.properties().horzLabelsAlign,null,!0,this.model(),"Change Fib Time Zone Labels Alignment")),this.bindControl(new s(r,this._linetool.properties().vertLabelsAlign,null,!0,this.model(),"Change Fib Time Zone Labels Alignment")),i=$("
").append(p).appendTo(i),this.createLabeledCell($.t("Background"),p).appendTo(i),h=u(),$('').append(h).appendTo(i),this.bindControl(new l(o,this._linetool.properties().showLabels,!0,this.model(),"Change Fib Time Zone Labels Visibility")),this.bindControl(new d(h,this._linetool.properties().transparency,!0,this.model(),"Change Fib Retracement Background Transparency")),this.bindControl(new l(p,this._linetool.properties().fillBackground,!0,this.model(),"Change Fib Retracement Background Visibility")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1105:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.FloatBinder,l=a.BooleanBinder,p=a.ColorBinding,s=a.SliderBinder,d=o(373).addColorPicker,h=o(1197).createLineWidthEditor,c=o(1199).createTransparencyEditor;inherit(i,n),i.prototype.addLevelEditor=function(e,t,o){var i,n,a,c,b,u,C,y,g=$("
"),i.appendTo(g),n=$(""),n.appendTo(i),e?(a=$(""),a.appendTo(g),c=$(""),c.appendTo(a),c.css("width","70px"),this.bindControl(new r(c,t.coeff,!1,this.model(),"Change Pitchfork Line Coeff"))):this.createLabeledCell("Trend Line",n).appendTo(g),b=$(""),b.appendTo(g),u=d(b),C=$(""),C.appendTo(g),y=h(),y.appendTo(C),this.bindControl(new l(n,t.visible,!0,this.model(),"Change Fib Wedge Visibility")),this.bindControl(new p(u,t.color,!0,this.model(),"Change Fib Wedge Line Color",0)),this.bindControl(new s(y,t.linewidth,!0,this.model(),"Change Fib Wedge Width"))},i.prototype.prepareLayout=function(){var e,t,o,i,n,a;for(this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),this.addLevelEditor(null,this._linetool.properties().trendline,!1),e=1;e<=11;e++)t="level"+e,this.addLevelEditor("Level "+e,this._linetool.properties()[t],!1);this.addOneColorPropertyWidget(this._table),o=$(""),i=this.addLabeledRow(this._table,"Levels",o),$("").append(o).prependTo(i),this.bindControl(new l(o,this._linetool.properties().showCoeffs,!0,this.model(),"Change Fib Wedge Levels Visibility")),i=$("
").append(n).appendTo(i),this.createLabeledCell("Background",n).appendTo(i),a=c(),$('').append(a).appendTo(i),this.bindControl(new l(n,this._linetool.properties().fillBackground,!0,this.model(),"Change Wedge Background Visibility")),this.bindControl(new s(a,this._linetool.properties().transparency,!0,this.model(),"Change Wedge Background Transparency")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1106:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.SimpleComboBinder,l=a.ColorBinding,p=a.BooleanBinder,s=a.SliderBinder,d=o(1198).createLineStyleEditor,h=o(1197).createLineWidthEditor;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n,a,c,b,u,C,y,g,T,w,_,m,f,L,v,k,S,P,x,B;this._table=$(''),e=$("").appendTo(this._table),t=h(),o=d(),i=this.createColorPicker(),n=this.addLabeledRow(e,$.t("Line")),$("").appendTo(this._table),g=$(''),T=this.createColorPicker(),n=this.addLabeledRow(y,$.t("Background"),g),w=$("
").append(i).appendTo(n),$("").append(t).appendTo(n),$('').append(o.render()).appendTo(n),n=this.addLabeledRow(e,$.t("Text")),a=this.createColorPicker(),c=this.createFontSizeEditor(),b=this.createFontEditor(),u=$(''),C=$(''),$("").append(a).appendTo(n),$("").append(b).appendTo(n),$("").append(c).appendTo(n),$("").append(u).appendTo(n),$("").append(C).appendTo(n), -y=$("
"),$('").appendTo(w),$("").appendTo(this._table),m=$("").css({"margin-left":"8px"}),f=$('').appendTo(m),L=$("").css({"margin-left":"8px"}),v=$('').appendTo(L),k=$(""),S=$(""),n=this.addLabeledRow(_,$.t("Left End")),$('").appendTo(this._table),n=$("").appendTo(P),x=$(""),B=$("");o.append($(""),e.appendTo(this._table),t=this.model(),o=this._linetool,i=o.properties(),n=$("
').append(w).appendTo(n),n=$("
").append(g).appendTo(n),$("").append(T).appendTo(n),_=$("
').appendTo(n).append(k).append(m),n=this.addLabeledRow(_,$.t("Right End")),$('').appendTo(n).append(S).append(L),P=$("
").append(B).appendTo(n),this.bindControl(new r(c,this._linetool.properties().fontsize,parseInt,!0,this.model(),"Change Text Font Size")),this.bindControl(new r(b,this._linetool.properties().font,null,!0,this.model(),"Change Text Font")),this.bindControl(new l(a,this._linetool.properties().textcolor,!0,this.model(),"Change Text Color")),this.bindControl(new p(u,this._linetool.properties().bold,!0,this.model(),"Change Text Font Bold")),this.bindControl(new p(C,this._linetool.properties().italic,!0,this.model(),"Change Text Font Italic")),this.bindControl(new p(x,this._linetool.properties().showPrices,!0,this.model(),"Change Disjoint Angle Show Prices")),this.bindControl(new p(f,this._linetool.properties().extendLeft,!0,this.model(),"Change Disjoint Angle Extending Left")),this.bindControl(new p(v,this._linetool.properties().extendRight,!0,this.model(),"Change Disjoint Angle Extending Right")),this.bindControl(new l(i,this._linetool.properties().linecolor,!0,this.model(),"Change Disjoint Angle Color")),this.bindControl(new r(o,this._linetool.properties().linestyle,parseInt,!0,this.model(),"Change Disjoint Angle Style")),this.bindControl(new s(t,this._linetool.properties().linewidth,!0,this.model(),"Change Disjoint Angle Width")),this.bindControl(new r(k,this._linetool.properties().leftEnd,parseInt,!0,this.model(),"Change Disjoint Angle Left End")),this.bindControl(new r(S,this._linetool.properties().rightEnd,parseInt,!0,this.model(),"Change Disjoint Angle Right End")),this.bindControl(new p(g,this._linetool.properties().fillBackground,!0,this.model(),"Change Disjoint Angle Filling")),this.bindControl(new l(T,this._linetool.properties().backgroundColor,!0,this.model(),"Change Disjoint Angle Background Color",this._linetool.properties().transparency)),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1107:function(e,t,o){"use strict" -;function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.LessTransformer,l=a.GreateTransformer,p=a.ToFloatTransformer,s=a.BooleanBinder,d=a.SliderBinder,h=a.ColorBinding,c=a.SimpleComboBinder,b=a.SimpleStringBinder,u=o(373).addColorPicker,C=o(1197).createLineWidthEditor,y=o(1199).createTransparencyEditor;o(242),inherit(i,n),i.prototype.addOneColorPropertyWidget=function(e){var t=this.createOneColorForAllLinesWidget(),o=$("
")).append($("")).append(t.editor).append($("").append(t.label)),o.appendTo(e)},i.prototype.prepareLayout=function(){var e,t,o,i,n,a,g,T,w,_,m,f,L,v,k,S,P,x,B,R,E,F,I,D,A,W,V,O,z,M,j,H,G,N,U,q,Y,K,Q,J,Z;this._table=$(document.createElement("table")),this._table.addClass("property-page property-page-unpadded"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),this._table.css({width:"100%"}),e=$("
"),$(""),$("").appendTo(a),a.appendTo(n);for(g in i.levels._childs)T=i.levels[g],w=$(""),w.appendTo(n),$("").appendTo(w),_=$(""),$("
").append(n).appendTo(e),a=$("
"+$.t("Levels")+"
"+g+"").append(_).appendTo(w),m=$(""),m.appendTo(w),f=u(m),L=$(""),L.appendTo(w),v=C(),v.appendTo(L),this.bindControl(new s(_,T.visible,!0,t,"Change Gann Line Visibility")),this.bindControl(new h(f,T.color,!0,t,"Change Gann Line Color",0)),this.bindControl(new d(v,T.width,!0,t,"Change Gann Line Width"));k=$(""),$(""),$("").appendTo(S),S.appendTo(k);for(g in i.fanlines._childs)P=i.fanlines[g],x=$(""),x.appendTo(k),_=$(""),$("").appendTo(x),m=$("
").append(k).appendTo(e),S=$("
"+$.t("Fans")+"
").append(_).appendTo(x),B=P.x.value()+"x"+P.y.value(),$(""+B+""),m.appendTo(x),f=u(m),L=$(""),L.appendTo(x),v=C(),v.appendTo(L),this.bindControl(new s(_,P.visible,!0,t,"Change Gann Line Visibility")),this.bindControl(new h(f,P.color,!0,t,"Change Gann Fan Color",0)),this.bindControl(new d(v,P.width,!0,t,"Change Gann Line Width"));R=$(""),$(""),$("").appendTo(E),E.appendTo(R);for(g in i.arcs._childs)F=i.arcs[g],I=$(""),I.appendTo(R),_=$(""),$("").appendTo(I),m=$("").appendTo(this._table), -A=$(''),W=y(),V=$("").appendTo(D),O=$("
").append(R).appendTo(e),E=$("
"+$.t("Arcs")+"
").append(_).appendTo(I),B=F.x.value()+"x"+F.y.value(),$(""+B+""),m.appendTo(I),f=u(m),L=$(""),L.appendTo(I),v=C(),v.appendTo(L),this.bindControl(new s(_,F.visible,!0,t,"Change Gann Line Visibility")),this.bindControl(new h(f,F.color,!0,t,"Change Gann Arc Color",0)),this.bindControl(new d(v,F.width,!0,t,"Change Gann Line Width"));this.addOneColorPropertyWidget(R),D=$("
"),$('").appendTo(O),$("").appendTo(V),$("");o.append($(""),e.appendTo(this._table),t=this._linetool.properties(),o=$("
').append(O).appendTo(V),V=$("
").append(A).appendTo(V),$(""+$.t("Background")+"").append(W).appendTo(V),i.reverse&&(z=$(""),V=this.addLabeledRow(O,$.t("Reverse"),z,!0),$("").append(z).prependTo(V),M="Change Gann Square Reverse",this.bindControl(new s(z,i.reverse,!0,t,M))),this.bindControl(new s(A,i.arcsBackground.fillBackground,!0,t,"Change Gann Square Filling")),this.bindControl(new d(W,i.arcsBackground.transparency,!0,t,"Change Gann Square Background Transparency")),j=$(''),V=this.addLabeledRow(O,$.t("Price/Bar Ratio"),j,!0),$("").append(j).appendTo(V),j.TVTicker({step:o.getScaleRatioStep()}),M="Change Gann Square Scale Ratio",H=this._getPropertySetter(i.scaleRatio,M),G=[p(i.scaleRatio.value()),l(1e-7),r(1e8)],N=new b(j,i.scaleRatio,G,!1,t,M,H),N.addFormatter(function(e){return o.getScaleRatioFormatter().format(e)}),this.bindControl(N),U=$(''),V=this.addLabeledRow(O,$.t("Ranges And Ratio"),U,!1),$("").append(U).prependTo(V),this.bindControl(new s(U,i.showLabels,!0,t,"Change Gann Square Lables Visibility")),v=C(),f=this.createColorPicker(),q=$(''),Y=$(''),K=this.createFontSizeEditor(),Q=this.createFontEditor(),J=i.labelsStyle,this.bindControl(new c(K,J.fontSize,parseInt,!0,t,"Change Text Font Size")),this.bindControl(new c(Q,J.font,null,!0,t,"Change Text Font")),this.bindControl(new s(q,J.bold,!0,t,"Change Text Font Bold")),this.bindControl(new s(Y,J.italic,!0,t,"Change Text Font Italic")),Z=$('').append($(document.createElement("td")).attr({width:1}).append(Q)).append($(document.createElement("td")).attr({width:1}).append(K)).append($(document.createElement("td")).css("vertical-align","top").attr({width:1}).append(q)).append($(document.createElement("td")).css("vertical-align","top").append(Y)).append($("
")),$('
').append(Z).appendTo(V)},i.prototype.widget=function(){return this._table},i.prototype._getPropertySetter=function(e,t){var o=this.model(),i=this._linetool;return function(n){o.beginUndoMacro(t),o.saveLineToolState(i,"Save Gann Square State"),o.setProperty(e,n,t),o.saveLineToolState(i,"Save Gann Square State"),o.endUndoMacro()}},e.exports.LineToolGannComplexStylesPropertyPage=i},1108:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.BooleanBinder,l=a.SliderBinder,p=a.ColorBinding,s=o(373).addColorPicker,d=o(1197).createLineWidthEditor,h=o(1199).createTransparencyEditor;inherit(i,n),i.prototype.addOneColorPropertyWidget=function(e){ -var t=this.createOneColorForAllLinesWidget(),o=$("
")).append($("")).append(t.editor).append($("").append(t.label)),o.appendTo(e)},i.prototype.prepareLayout=function(){var e,t,o,i,n,a,c,b,u,C,y,g,T,w,_,m,f,L,v,k,S,P,x,B,R,E,F;this._table=$(document.createElement("table")),this._table.addClass("property-page property-page-unpadded"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),this._table.css({width:"100%"}),e=$("
"),$(""),$("").appendTo(i),i.appendTo(o);for(n in t.levels._childs)a=t.levels[n],c=$(""),c.appendTo(o),$("").appendTo(c),b=$(""),$("
").append(o).appendTo(e),i=$("
"+$.t("Levels")+"
"+n+"").append(b).appendTo(c),u=$(""),u.appendTo(c),C=s(u),y=$(""),y.appendTo(c),g=d(),g.appendTo(y),this.bindControl(new r(b,a.visible,!0,this.model(),"Change Gann Line Visibility")),this.bindControl(new p(C,a.color,!0,this.model(),"Change Gann Line Color",0)),this.bindControl(new l(g,a.width,!0,this.model(),"Change Gann Line Width"));T=$(""),$(""),$("").appendTo(w),w.appendTo(T);for(n in t.fanlines._childs)_=t.fanlines[n],m=$(""),m.appendTo(T),b=$(""),$("").appendTo(m),u=$("
").append(T).appendTo(e),w=$("
"+$.t("Fans")+"
").append(b).appendTo(m),f=_.x.value()+"x"+_.y.value(),$(""+f+""),u.appendTo(m),C=s(u),y=$(""),y.appendTo(m),g=d(),g.appendTo(y),this.bindControl(new r(b,_.visible,!0,this.model(),"Change Gann Line Visibility")),this.bindControl(new p(C,_.color,!0,this.model(),"Change Gann Fan Color",0)),this.bindControl(new l(g,_.width,!0,this.model(),"Change Gann Line Width"));L=$(""),$(""),$("").appendTo(v),v.appendTo(L);for(n in t.arcs._childs)k=t.arcs[n],S=$(""),S.appendTo(L),b=$(""),$("").appendTo(S),u=$("").appendTo(this._table),x=$(''),B=h(),R=$("").appendTo(P),E=$("
").append(L).appendTo(e),v=$("
"+$.t("Arcs")+"
").append(b).appendTo(S),f=k.x.value()+"x"+k.y.value(),$(""+f+""),u.appendTo(S),C=s(u),y=$(""),y.appendTo(S),g=d(),g.appendTo(y),this.bindControl(new r(b,k.visible,!0,this.model(),"Change Gann Line Visibility")),this.bindControl(new p(C,k.color,!0,this.model(),"Change Gann Arc Color",0)),this.bindControl(new l(g,k.width,!0,this.model(),"Change Gann Line Width"));this.addOneColorPropertyWidget(L),P=$("
"),$('").appendTo(E),$("").appendTo(R),$("");m.appendTo(this._tbody),n="control-level-"+o+"-"+i,a=$("
').append(E).appendTo(R),R=$("
").append(x).appendTo(R),$(""+$.t("Background")+"").append(B).appendTo(R),t.reverse&&(F=$(""),R=this.addLabeledRow(E,$.t("Reverse"),F,!0), -$("").append(F).prependTo(R),this.bindControl(new r(F,t.reverse,!0,this.model(),"Change Gann Square Reverse"))),this.bindControl(new r(x,t.arcsBackground.fillBackground,!0,this.model(),"Change Gann Square Filling")),this.bindControl(new l(B,t.arcsBackground.transparency,!0,this.model(),"Change Gann Square Background Transparency"))},i.prototype.widget=function(){return this._table},e.exports.LineToolGannFixedStylesPropertyPage=i},1109:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.BooleanBinder,l=a.ColorBinding,p=a.SimpleComboBinder,s=a.SliderBinder,d=o(373).addColorPicker,h=o(1198).createLineStyleEditor,c=o(1197).createLineWidthEditor,b=o(1199).createTransparencyEditor;inherit(i,n),i.prototype.addLevelEditor=function(e,t,o,i){var n,a,b,u,C,y,g,T,w,_,m=$("
"),a.appendTo(m),b=$(""),b.appendTo(a),u=this.createLabeledCell(e).appendTo(m),u.find("label").attr("for",n),C=$(""),C.appendTo(m),y=d(C),g=$(""),g.appendTo(m),T=c(),T.appendTo(g),w=$(""),w.appendTo(m),_=h(),_.render().appendTo(w),this.bindControl(new r(b,t.visible,!0,this.model(),"Change Gann Fan Line Visibility")),this.bindControl(new l(y,t.color,!0,this.model(),"Change Gann Fan Line Color",0)),this.bindControl(new p(_,t.linestyle,parseInt,!0,this.model(),"Change Gann Fan Line Style")),this.bindControl(new s(T,t.linewidth,!0,this.model(),"Change Gann Fan Line Width"))},i.prototype.prepareLayout=function(){var e,t,o,i,n,a,l,p,d,h,c=$(''),u=$('
');for(this._tbody=$("").appendTo(c),e=1;e<=9;e++)t="level"+e,o=this._linetool.properties()[t],i=o.coeff1.value(),n=o.coeff2.value(),a=""+i+""+n+"",this.addLevelEditor(a,o,i,n);this.addOneColorPropertyWidget(this._tbody),l=$(""),p=this.addLabeledRow(u,$.t("Labels"),l),$(""),p.appendTo(this._table),d=$(""),$("");b.appendTo(e),i=$("").appendTo(e),n=$("");n.appendTo($("").appendTo(i),t=$("").appendTo(this._table),t=$(""),t.appendTo(e),o=$('
").append(l).prependTo(p),this.bindControl(new r(l,this._linetool.properties().showLabels,!0,this.model(),"Change Gann Fan Labels Visibility")),this._table=c.add(u),p=$("
").append(d).appendTo(p),this.createLabeledCell($.t("Background"),d).appendTo(p),h=b(),$('').append(h).appendTo(p),this.bindControl(new r(d,this._linetool.properties().fillBackground,!0,this.model(),"Change Pitchfan Background Visibility")),this.bindControl(new s(h,this._linetool.properties().transparency,!0,this.model(),"Change Pitchfan Background Transparency")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1110:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()} -var n=o(1196),a=o(239),r=a.BooleanBinder,l=a.FloatBinder,p=a.ColorBinding,s=a.SliderBinder,d=o(373).addColorPicker,h=o(1199).createTransparencyEditor;inherit(i,n),i.prototype.addLevelEditor=function(e,t,o){var i,n,a,s,h,c,b=$("
"),i.appendTo(b),n=$(""),n.appendTo(i),a=$(""),a.appendTo(b),s=$(""),s.appendTo(a),s.css("width","70px"),this.bindControl(new r(n,o.visible,!0,this.model(),"Change Gann Square Line Visibility")),this.bindControl(new l(s,o.coeff,!1,this.model(),"Change Pitchfork Line Coeff")),h=$(""),h.appendTo(b),c=d(h),this.bindControl(new p(c,o.color,!0,this.model(),"Change Gann Square Line Color",0))},i.prototype.addFannEditor=function(e){var t,o,i=$("
").appendTo(i)),$(""+$.t("Angles")+"").appendTo(i),o=d(t),this.bindControl(new r(n,this._linetool.properties().fans.visible,!0,this.model(),"Change Gann Square Angles Visibility")),this.bindControl(new p(o,this._linetool.properties().fans.color,!0,this.model(),"Change Gann Square Angles Color",0))},i.prototype.prepareLayout=function(){var e,t,o,i,n,a,l,p,d,c,b,u,C,y,g,T,w,_,m,f;for(this._table=$(document.createElement("table")),this._table.addClass("property-page property-page-unpadded"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),this._table.css({width:"100%"}),e=$("
'),o.appendTo(t),i=$(''),i.appendTo(t),n=$(''),n.appendTo(o),n.addClass("property-page"),a=$('
'),a.appendTo(i),a.addClass("property-page"),$("").appendTo(n),$("").appendTo(a),l=1;l<=7;l++)p="hlevel"+l,this.addLevelEditor(n,$.t("Level {0}").format(l),this._linetool.properties()[p]);for(l=1;l<=7;l++)p="vlevel"+l,this.addLevelEditor(a,$.t("Level {0}").format(l),this._linetool.properties()[p]);this.addFannEditor(n),this.addOneColorPropertyWidget(a),i.css({"vertical-align":"top"}),o.css({"vertical-align":"top"}),d=$(""),c=$(""),b=$(""),u=$(""),C=$('
"+$.t("Price Levels")+"
"+$.t("Time Levels")+"
').css({width:"100%"}),y=$("").appendTo(C),g=$('
').appendTo($("
").css({width:"50%","vertical-align":"top"}).appendTo(y)),T=$('').appendTo($(""),w.appendTo(g),_=$(""),$(""),w.appendTo(T),_=$(""),$("
").css({width:"50%","vertical-align":"top"}).appendTo(y)),w=this.addLabeledRow(g,$.t("Left Labels"),d), -$("").append(d).prependTo(w),w=this.addLabeledRow(T,$.t("Right Labels"),c),$("").append(c).prependTo(w),w=this.addLabeledRow(g,$.t("Top Labels"),b),$("").append(b).prependTo(w),w=this.addLabeledRow(T,$.t("Bottom Labels"),u),$("").append(u).prependTo(w),this.bindControl(new r(d,this._linetool.properties().showLeftLabels,!0,this.model(),"Change Gann Square Left Labels Visibility")),this.bindControl(new r(c,this._linetool.properties().showRightLabels,!0,this.model(),"Change Gann Square Right Labels Visibility")),this.bindControl(new r(b,this._linetool.properties().showTopLabels,!0,this.model(),"Change Gann Square Top Labels Visibility")),this.bindControl(new r(u,this._linetool.properties().showBottomLabels,!0,this.model(),"Change Gann Square Bottom Labels Visibility")),this._table=this._table.add(C),w=$("
").append(_).appendTo(w),m=h(),$("").append(m).appendTo(w),this.bindControl(new r(_,this._linetool.properties().fillHorzBackground,!0,this.model(),"Change Gann Square Background Visibility")),this.bindControl(new s(m,this._linetool.properties().horzTransparency,!0,this.model(),"Change Gann Square Background Transparency")),w=$("
").append(_).appendTo(w),m=h(),$("").append(m).appendTo(w),this.bindControl(new r(_,this._linetool.properties().fillVertBackground,!0,this.model(),"Change Gann Square Background Visibility")),this.bindControl(new s(m,this._linetool.properties().vertTransparency,!0,this.model(),"Change Gann Square Background Transparency")),this._linetool.properties().reverse&&(f=$(""),w=this.addLabeledRow(g,$.t("Reverse"),f),$("").append(f).prependTo(w),this.bindControl(new r(f,this._linetool.properties().reverse,!0,this.model(),"Change Gann Box Reverse"))),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1111:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239).ColorBinding;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i;this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),e=this.createColorPicker(),t=$.t("Color")+":",o=this.addLabeledRow(this._table,t),$("").append(e).appendTo(o),i=this._linetool.properties(),this._div=$("
").append(this._table),this.bindControl(new a(e,i.color,!0,this.model(),"Change Icon Color")),this.loadData()},i.prototype.widget=function(){return this._div},e.exports=i},1112:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.BooleanBinder,l=a.ColorBinding,p=a.SliderBinder,s=a.SimpleComboBinder,d=o(1197).createLineWidthEditor;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n,a,h,c,b,u,C;this._table=$(document.createElement("table")), -this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),e=d(),t=this.createColorPicker(),o=this.createColorPicker(),i=$(''),n=$(''),a=this.createFontSizeEditor(),h=this.createFontEditor(),c=this.addLabeledRow(this._table,"Border"),c.prepend("
"),$("").append(t).appendTo(c),$("").append(e).appendTo(c),b=$(''),u=this.createColorPicker(),h=this.createFontEditor(),c=this.addLabeledRow(this._table,"Background",b),$("").append(b).prependTo(c),$("").append(u).appendTo(c),this.bindControl(new r(b,this._linetool.properties().fillBackground,!0,this.model(),"Change Pattern Filling")),this.bindControl(new l(t,this._linetool.properties().color,!0,this.model(),"Change Pattern Line Color")),this.bindControl(new l(o,this._linetool.properties().textcolor,!0,this.model(),"Change Pattern Text Color")),this.bindControl(new l(u,this._linetool.properties().backgroundColor,!0,this.model(),"Change Pattern Background Color",this._linetool.properties().transparency)),this.bindControl(new p(e,this._linetool.properties().linewidth,!0,this.model(),"Change Pattern Border Width")),this.bindControl(new s(a,this._linetool.properties().fontsize,parseInt,!0,this.model(),"Change Text Font Size")),this.bindControl(new s(h,this._linetool.properties().font,null,!0,this.model(),"Change Text Font")),this.bindControl(new r(i,this._linetool.properties().bold,!0,this.model(),"Change Text Font Bold")),this.bindControl(new r(n,this._linetool.properties().italic,!0,this.model(),"Change Text Font Italic")),C=$('').append($(document.createElement("td")).attr({width:1}).append(o)).append($(document.createElement("td")).attr({width:1}).append(h)).append($(document.createElement("td")).attr({width:1}).append(a)).append($(document.createElement("td")).css("vertical-align","top").attr({width:1}).append(i)).append($(document.createElement("td")).css("vertical-align","top").append(n)).append($("
")),c=this.addLabeledRow(this._table,""),$('
').append(C).appendTo(c),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1113:function(e,t,o){"use strict";function i(e,t,o){a.call(this,e,t,o),this.prepareLayout()}var n=o(8).Point,a=o(1196),r=o(239),l=r.ColorBinding,p=r.SimpleComboBinder,s=r.SimpleStringBinder,d=r.BooleanBinder,h=o(76);inherit(i,a),i.prototype.prepareLayout=function(){ -var e,t,o,i,n=this.createColorPicker(),a=this.createFontSizeEditor(),r=this.createFontEditor(),h=this.createTextEditor(350,200),c=this.createColorPicker(),b=this.createColorPicker(),u=$(''),C=$('');this.bindControl(new l(n,this._linetool.properties().textColor,!0,this.model(),"Change Text Color")),this.bindControl(new p(a,this._linetool.properties().fontSize,parseInt,!0,this.model(),"Change Text Font Size")),this.bindControl(new p(r,this._linetool.properties().font,null,!0,this.model(),"Change Text Font")),this.bindControl(new s(h,this._linetool.properties().text,null,!0,this.model(),"Change Text")),this.bindControl(new l(c,this._linetool.properties().markerColor,!0,this.model(),"Change Marker and Border Color")),this.bindControl(new l(b,this._linetool.properties().backgroundColor,!0,this.model(),"Change Background Color",this._linetool.properties().backgroundTransparency)),this.bindControl(new d(u,this._linetool.properties().bold,!0,this.model(),"Change Text Font Bold")),this.bindControl(new d(C,this._linetool.properties().italic,!0,this.model(),"Change Text Font Italic")),e=$(''),t=$('
'),o=$('
'),this._table=e.add(o).add(t),$(document.createElement("tr")).append($(document.createElement("td")).attr({width:1}).append(n)).append($(document.createElement("td")).attr({width:1}).append(r)).append($(document.createElement("td")).attr({width:1}).append(a)).append($(document.createElement("td")).attr({width:1}).append(u)).append($(document.createElement("td")).append(C)).appendTo(e),$(document.createElement("tr")).append($(document.createElement("td")).attr({colspan:5}).append(h)).appendTo(e),i=this.addLabeledRow(o,$.t("Label")),$("").appendTo(e),$("").appendTo(n),$("").appendTo(e),a=$("").appendTo(e),y=$("").appendTo(this._table),_=this.addEditorRow(w,"Extend Left",$(""),2),m=this.addEditorRow(w,"Extend Right",$(""),2),f=this._linetool.properties(),this.bindControl(new r(g,f.fillBackground,!0,this.model(),"Change Parallel Channel Fill Background")),this.bindControl(new r(c,f.showMidline,!0,this.model(),"Change Parallel Channel Show Center Line")),this.bindControl(new r(_,f.extendLeft,!0,this.model(),"Change Parallel Channel Extending Left")),this.bindControl(new r(m,f.extendRight,!0,this.model(),"Change Parallel Channel Extending Right")),this.bindControl(new l(i,f.linecolor,!0,this.model(),"Change Parallel Channel Color")),this.bindControl(new p(o,f.linestyle,parseInt,!0,this.model(),"Change Parallel Channel Style")),this.bindControl(new s(t,f.linewidth,!0,this.model(),"Change Parallel Channel Width")),this.bindControl(new l(C,f.midlinecolor,!0,this.model(),"Change Parallel Channel Middle Color")),this.bindControl(new p(u,f.midlinestyle,parseInt,!0,this.model(),"Change Parallel Channel Middle Style")),this.bindControl(new s(b,f.midlinewidth,!0,this.model(),"Change Parallel Channel Middle Width")),this.bindControl(new l(T,f.backgroundColor,!0,this.model(),"Change Parallel Channel Back Color",f.transparency)),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1115:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.BooleanBinder,l=a.FloatBinder,p=a.ColorBinding,s=a.SimpleComboBinder,d=a.SliderBinder,h=o(373).addColorPicker,c=o(1198).createLineStyleEditor,b=o(1197).createLineWidthEditor,u=o(1199).createTransparencyEditor;inherit(i,n),i.prototype.addLevelEditor=function(e,t,o){var i,n,a,u,C,y,g,T,w,_,m=$("");m.appendTo(this._table),e?(i=$("").appendTo(m),C=$(""),o.appendTo(this._table),i=$(""),$("");m.appendTo(this._table),e?(i=$("").appendTo(m),$("").appendTo(m)),C=$(""),o.appendTo(this._table),i=$(""),$(""),o.appendTo(this._table),$("").appendTo(o),$("
").attr("colspan",2).append(c).appendTo(i),i=this.addLabeledRow(o,$.t("Background")),$("").append(b).appendTo(i),this.loadData(),setTimeout(function(){h.select(),h.focus()},20)},i.prototype.widget=function(){return this._table},i.prototype.dialogPosition=function(e,t){var o,i,a,r,l,p,s,d,c,b;if(e&&t){for(o=0,i=this._linetool._model.paneForSource(this._linetool),a=h.getChartWidget();oc?(e.left-=e.left+b+10-c,e):e.left>c&&e.left").appendTo(this._table),t=h(),o=d(),i=this.createColorPicker(),n=$("
"+$.t("Channel")+"").append(i).appendTo(n),$("").append(t).appendTo(n),$("").append(o.render()).appendTo(n),n=$("
").appendTo(n),c=$(""),c.appendTo(a),this.createLabeledCell("Middle",c).appendTo(n),b=h(),u=d(),C=this.createColorPicker(),$("").append(C).appendTo(n),$("").append(b).appendTo(n),$("").append(u.render()).appendTo(n),n=$("
").appendTo(n),g=$(""),g.appendTo(y),this.createLabeledCell("Background",g).appendTo(n),T=this.createColorPicker(),$("").append(T).appendTo(n),w=$("
"),i.appendTo(m), -n=$(""),n.appendTo(i),a=$(""),a.appendTo(m),u=$(""),u.appendTo(a),u.css("width","70px"),this.bindControl(new r(n,t.visible,!0,this.model(),"Change Pitchfork Line Visibility")),this.bindControl(new l(u,t.coeff,!1,this.model(),"Change Pitchfork Line Coeff"))):$(""+$.t("Median")+""),C.appendTo(m),y=h(C),g=$(""),g.appendTo(m),T=b(),T.appendTo(g),w=$(""),w.appendTo(m),_=c(),_.render().appendTo(w),this.bindControl(new p(y,t.color,!0,this.model(),"Change Pitchfork Line Color"),0),this.bindControl(new s(_,t.linestyle,parseInt,!0,this.model(),"Change Pitchfan Line Style")),this.bindControl(new d(T,t.linewidth,!0,this.model(),"Change Pitchfan Line Width"))},i.prototype.prepareLayout=function(){var e,t,o,i,n;for(this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),this.addLevelEditor(null,this._linetool.properties().median,!1),e=0;e<=8;e++)t="level"+e,this.addLevelEditor($.t("Level {0}").format(e+1),this._linetool.properties()[t],!1);this.addOneColorPropertyWidget(this._table),o=$("
").append(i).appendTo(o),this.createLabeledCell($.t("Background"),i).appendTo(o),n=u(),$('').append(n).appendTo(o),this.bindControl(new r(i,this._linetool.properties().fillBackground,!0,this.model(),"Change Pitchfan Background Visibility")),this.bindControl(new d(n,this._linetool.properties().transparency,!0,this.model(),"Change Pitchfan Background Transparency")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1116:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.BooleanBinder,l=a.FloatBinder,p=a.ColorBinding,s=a.SimpleComboBinder,d=a.SliderBinder,h=o(373).addColorPicker,c=o(1198).createLineStyleEditor,b=o(1197).createLineWidthEditor,u=o(1199).createTransparencyEditor;inherit(i,n),i.prototype.onResoreDefaults=function(){this._linetool.properties().style.listeners().fire(this._linetool.properties().style)},i.prototype.addLevelEditor=function(e,t,o){var i,n,a,u,C,y,g,T,w,_,m=$("
"),i.appendTo(m),n=$(""),n.appendTo(i),a=$(""),a.appendTo(m),u=$(""),u.appendTo(a),u.css("width","70px"),this.bindControl(new r(n,t.visible,!0,this.model(),"Change Pitchfork Line Visibility")),this.bindControl(new l(u,t.coeff,!1,this.model(),"Change Pitchfork Line Coeff"))):($(""+$.t("Median")+""),C.appendTo(m),y=h(C),g=$(""),g.appendTo(m),T=b(),T.appendTo(g),w=$(""),w.appendTo(m),_=c(),_.render().appendTo(w),this.bindControl(new p(y,t.color,!0,this.model(),"Change Pitchfork Line Color",0)), -this.bindControl(new s(_,t.linestyle,parseInt,!0,this.model(),"Change Pitchfork Line Style")),this.bindControl(new d(T,t.linewidth,!0,this.model(),"Change Pitchfork Line Width"))},i.prototype.prepareLayout=function(){var e,t,o,i,n,a;for(this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),this.addLevelEditor(null,this._linetool.properties().median,!1),e=0;e<=8;e++)t="level"+e,this.addLevelEditor($.t("Level {0}").format(e+1),this._linetool.properties()[t],!1);this.addOneColorPropertyWidget(this._table),o=$("
").append(i).appendTo(o),this.createLabeledCell("Background",i).appendTo(o),n=u(),$('').append(n).appendTo(o),a=$(""),o=$("
"+$.t("Style")+"").append(a).appendTo(o),this.bindControl(new s(a,this._linetool.properties().style,parseInt,!0,this.model(),"Change Pitchfork Style")),this.bindControl(new r(i,this._linetool.properties().fillBackground,!0,this.model(),"Change Pitchfork Background Visibility")),this.bindControl(new d(n,this._linetool.properties().transparency,!0,this.model(),"Change Pitchfork Background Transparency")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1117:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.BooleanBinder,l=a.ColorBinding,p=a.SliderBinder,s=o(1197).createLineWidthEditor;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n;this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),e=s(),t=this.createColorPicker(),o=this.addLabeledRow(this._table,"Border"),o.prepend(""),$("").append(t).appendTo(o),$("").append(e).appendTo(o),i=$(''),n=this.createColorPicker(),o=this.addLabeledRow(this._table,"Background",i),$("").append(i).prependTo(o),$("").append(n).appendTo(o),this.bindControl(new r(i,this._linetool.properties().fillBackground,!0,this.model(),"Change Polyline Filling")),this.bindControl(new l(t,this._linetool.properties().linecolor,!0,this.model(),"Change Polyline Line Color")),this.bindControl(new l(n,this._linetool.properties().backgroundColor,!0,this.model(),"Change Polyline Background Color",this._linetool.properties().transparency)),this.bindControl(new p(e,this._linetool.properties().linewidth,!0,this.model(),"Change Polyline Border Width")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1118:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()} -var n=o(1196),a=o(239),r=a.ColorBinding,l=a.SliderBinder,p=o(1197).createLineWidthEditor;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n,a,s,d,h,c,b,u,C,y,g,T,w,_,m=$(''),f=$('
').css({width:"100%"}),L=$('
');this._table=m.add(f).add(L),e=this.createColorPicker(),t=p(),o=this.addLabeledRow(m,"Line"),$("").appendTo(f),n=$("
").append(e).appendTo(o),$("").append(t).appendTo(o),i=$("
").appendTo(i).css({"vertical-align":"top",width:"50%"}),a=$("").appendTo(i).css({"vertical-align":"top",width:"50%"}),s=$('').appendTo(n),d=$('
').appendTo(a),h=this.addColorPickerRow(s,$.t("Source back color")),c=this.addColorPickerRow(s,$.t("Source text color")),b=this.addColorPickerRow(s,$.t("Source border color")),u=this.addColorPickerRow(s,$.t("Success back color")),C=this.addColorPickerRow(s,$.t("Success text color")),y=this.addColorPickerRow(d,$.t("Target back color")),g=this.addColorPickerRow(d,$.t("Target text color")),T=this.addColorPickerRow(d,$.t("Target border color")),w=this.addColorPickerRow(d,$.t("Failure back color")),_=this.addColorPickerRow(d,$.t("Failure text color")),this.bindControl(new r(e,this._linetool.properties().linecolor,!0,this.model(),"Forecast Line Color")),this.bindControl(new l(t,this._linetool.properties().linewidth,!0,this.model(),"Forecast Line Width")),this.bindControl(new r(e,this._linetool.properties().linecolor,!0,this.model(),"Forecast Line Color")),this.bindControl(new l(t,this._linetool.properties().linewidth,!0,this.model(),"Forecast Line Width")),this.bindControl(new r(h,this._linetool.properties().sourceBackColor,!0,this.model(),"Forecast Source Background Color",this._linetool.properties().transparency)),this.bindControl(new r(b,this._linetool.properties().sourceStrokeColor,!0,this.model(),"Forecast Source Border Color")),this.bindControl(new r(c,this._linetool.properties().sourceTextColor,!0,this.model(),"Forecast Source Text Color")),this.bindControl(new r(y,this._linetool.properties().targetBackColor,!0,this.model(),"Forecast Target Background Color")),this.bindControl(new r(T,this._linetool.properties().targetStrokeColor,!0,this.model(),"Forecast Target Border Color")),this.bindControl(new r(g,this._linetool.properties().targetTextColor,!0,this.model(),"Forecast Target Text Color")),this.bindControl(new r(u,this._linetool.properties().successBackground,!0,this.model(),"Forecast Success Back Color")),this.bindControl(new r(C,this._linetool.properties().successTextColor,!0,this.model(),"Forecast Success Text Color")),this.bindControl(new r(w,this._linetool.properties().failureBackground,!0,this.model(),"Forecast Failure Back Color")), -this.bindControl(new r(_,this._linetool.properties().failureTextColor,!0,this.model(),"Forecast Failure Text Color")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1119:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.SimpleComboBinder,l=a.ColorBinding;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n;this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),e=this.createColorPicker(),t=this.createFontSizeEditor(),o=this.createColorPicker(),i=this.createColorPicker(),n=this.addLabeledRow(this._table,$.t("Text")),$("{{#columns}}{{/columns}}',tvDataTableCell:''}},function(t,e,i){"use strict";function o(t){ -var e=t.split(":");return{name:e[0],type:2===e.length?e[1]:null}}function n(t,e,i,n){var r,s,a,l,c,p,_,f,m,g,v,y,b,S,w,T=i.split(".");if(0!==T.length&&0!==T[0].length){if(r=o(T[0]),s=r.name,a=r.type,l=null!==a,c=!l||"plot"===a,p=!l||"band"===a,_=!l||"area"===a,f=!l||"input"===a,m=c?d.getPlotIdByTitle(t,s):null,g=p?d.getBandIndexByName(t,s):null,v=_?d.getFilledAreaIdByTitle(t,s):null,y=f?d.getInputByName(t,s):null,b=e.hasOwnProperty(s),(null!==m?1:0)+(null!==g?1:0)+(null!==v?1:0)+(null!==y?1:0)+(b?1:0)>1)return void h.logWarn("Study '"+t.description+"' has ambiguous identifier '"+s+"'");if(S=T[1],null!==m){if(1===T.length)return void h.logWarn("Path of sub-property of '"+s+"' plot for study '"+t.description+"' must be not empty");w=T.slice(1),u.applyPlotProperty(t,e,m,w,n)}else if(null!==y)u.applyInputValue(e,y,n);else if(null!==g){if(void 0===S)return void h.logWarn("Property name of '"+s+"' band for study '"+t.description+"' must be set");u.applyBandProperty(e,g,S,n)}else if(null!==v){if(void 0===S)return void h.logWarn("Property name of '"+s+"' area for study '"+t.description+"' must be set");u.applyFilledAreaProperty(e,v,S,n)}else b?u.setRootProperty(e,T,n):h.logWarn("Study '"+t.description+"' has no plot or input '"+s+"'")}}function r(t,e){var i,o,r=t.properties(),s=r.state();for(i in e)e.hasOwnProperty(i)&&n(t.metaInfo(),s,i,e[i]);r.merge(s),o=r.precision,void 0!==o?o.listeners().fire(o):r.listeners().fire(r)}function s(t,e,i){var o,r,s,a,l;for(o in t)t.hasOwnProperty(o)&&-1!==(r=o.indexOf("."))&&(s=o.substr(0,r),a=d.getMetaInfoByDescription(e,s),null!==a?(l=i(a.id),null!==l?n(a,l,o.substr(r+1),t[o]):h.logWarn("Cannot apply overrides for study "+s)):h.logWarn("There is no such study "+s))}var a,l,c,h,u,d;Object.defineProperty(e,"__esModule",{value:!0}),a=i(111),l=i(9),c=i(7),h=c.getLogger("Chart.Model.StudyPropertiesOverrider"),function(t){function e(t){return"colorer"===t.type}function i(t,i,o){var n,r,s,a;if(void 0===t.plots)return null;for(n=0,r=t.plots;n0?void h.logWarn("Study plot does not have color #"+o):((0===o||isNaN(o))&&(l.ensureDefined(t.styles[i]).color=n+"",o=0),void(null!==e&&(l.ensureDefined(e.colors[o]).color=n+"")))}function n(t,e,n,r,s){var a,l,c,u,p;if(void 0===e.styles)return void h.logWarn("Study does not have styles");if("color"===(a=r[0]))return l=i(t,e,n),c=r.length>1?parseInt(r[1]):NaN,void o(e,l,n,c,s);if(void 0===(u=e.styles[n])||!u.hasOwnProperty(a))return void h.logWarn("Study plot does not have property '"+a+"'");if("plottype"===a){if(void 0===(p=d[s+""]))return void h.logWarn("Unsupported plot type for plot: "+s);s=p}u[a]=s}function r(t,e,i,o){var n,r;if(void 0===t.bands)return void h.logWarn("Study does not have bands");if(void 0===(n=t.bands[e])||!n.hasOwnProperty(i))return void h.logWarn("Study band does not have property '"+i+"'") -;if("plottype"===i){if(void 0===(r=d[o+""]))return void h.logWarn("Unsupported plot type for band: "+o);o=r}n[i]=o}function s(t,e,i,o){if(void 0===t.filledAreasStyle)return void h.logWarn("Study does not have areas");var n=t.filledAreasStyle[e];if(void 0===n||!n.hasOwnProperty(i))return void h.logWarn("Study area does not have property '"+i+"'");n[i]=o}function c(t,e,i){if(void 0===t.inputs||!t.inputs.hasOwnProperty(e))return void h.logWarn("Study does not have input '"+e+"'");t.inputs[e]=i}function u(t,e,i){var o,n,r,s,a;if(0!==e.length){for(o=t,n=0,r=e.slice(0,-1);ne?(a&&(clearTimeout(a),a=null),l=h,r=t.apply(o,n),a||(o=n=null)):a||!1===i.trailing||(a=setTimeout(s,c)),r}}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o,t.exports=e.default},function(t,e,i){"use strict";var o,n,r,s,a,l,c,h,u;Object.defineProperty(e,"__esModule",{value:!0}),o=i(0),i(43),n=i(2),r=i(14),s=i(59),a=i(85),l=i(151),c=i(723),h=i(393),u=function(t){function e(e){var i=t.call(this,e)||this;return i._toggleDropdown=function(t){i.setState({isOpened:void 0!==t?t:!i.state.isOpened})},i._handleClose=function(){i._toggleDropdown(!1)},i._getDropdownPosition=function(){ -if(!i._control)return{x:0,y:0};var t=i._control.getBoundingClientRect();return{x:t.left+t.width+1,y:t.top-6}},i._handleClickArrow=function(){i._toggleDropdown()},i._handleTouchStart=function(){i.props.onClickButton(),i._toggleDropdown()},i._handlePressStart=function(){if(Modernizr.touch)i._longPressDelay||i.props.onClickButton();else{if(i._doubleClickDelay)return clearTimeout(i._doubleClickDelay),delete i._doubleClickDelay,void i._toggleDropdown(!0);i._doubleClickDelay=setTimeout(function(){delete i._doubleClickDelay,i._longPressDelay||i.props.onClickButton()},175)}i._longPressDelay=setTimeout(function(){delete i._longPressDelay,i._toggleDropdown(!0)},300)},i._handlePressEnd=function(){i._longPressDelay&&(clearTimeout(i._longPressDelay),delete i._longPressDelay,i.state.isOpened?i._toggleDropdown(!1):i.state.isOpened||!i.props.isActive||Modernizr.touch||i._toggleDropdown(!0))},i.state={isOpened:!1},i}return o.__extends(e,t),e.prototype.render=function(){var t,e=this,i=this.props,o=i.buttonActiveClass,u=i.buttonClass,d=i.buttonIcon,p=i.buttonTitle,_=i.children,f=i.isActive,m=i.isGrayed,g=i.onClickWhenGrayed,v=this.state.isOpened;return n.createElement("div",{className:r(c.dropdown,"apply-common-tooltip common-tooltip-vertical",(t={},t[c.isGrayed]=m,t[c.isActive]=f,t[c.isOpened]=v,t)),onClick:m?g:void 0,title:p,"data-tooltip-delay":1500},n.createElement("div",{ref:function(t){return e._control=t},className:c.control},n.createElement("div",{className:c.buttonWrap,onMouseDown:m||Modernizr.touch?void 0:this._handlePressStart,onMouseUp:m||Modernizr.touch?void 0:this._handlePressEnd,onClick:!m&&Modernizr.touch?this._handleTouchStart:void 0},n.createElement(l.ToolButton,{activeClass:o,className:u,icon:d,isActive:f,isGrayed:m,isTransparent:!0})),!m&&!Modernizr.touch&&n.createElement("div",{className:c.arrow,onClick:this._handleClickArrow},n.createElement(s.Icon,{className:c.arrowIcon,icon:h}))),!m&&n.createElement(a.PopupMenu,{doNotCloseOn:this,isOpened:v,onClose:this._handleClose,position:this._getDropdownPosition},_))},e}(n.PureComponent),e.ToolDropdown=u},function(t,e){t.exports=''},function(t,e){ -t.exports=''},function(t,e,i){"use strict";function o(t){return n.createDialog(Object.assign({},a,t))}var n,r,s,a;Object.defineProperty(e,"__esModule",{value:!0}),i(12),n=i(65),r={key:13,name:"yes",text:$.t("Yes"),type:"success"},s={method:"close",name:"no",text:$.t("No"),type:"default"},a={actions:[r,s],actionsWrapTemplate:'
',content:$.t("Are you sure?"),contentWrapTemplate:'

',destroyOnClose:!0,title:$.t("Confirmation"),width:400},e.createConfirmDialog=o},function(t,e,i){"use strict";var o,n,r,s;Object.defineProperty(e,"__esModule",{value:!0}),o=i(9),n=i(19),function(t){t[t.FromLeft=-1]="FromLeft",t[t.FromRight=1]="FromRight"}(r=e.TimePointIndexSearchMode||(e.TimePointIndexSearchMode={})),s=function(){function t(t){this.m_bars=new n.PlotList(t),this.m_nsBars=new n.PlotList(t)}return t.prototype.bars=function(){return this.m_bars},t.prototype.nsBars=function(){return this.m_nsBars},t.prototype.size=function(){return this.m_bars.size()+this.m_nsBars.size()},t.prototype.each=function(t){this.m_bars.each(t),this.m_nsBars.each(t)},t.prototype.clear=function(){this.m_bars.clear(),this.m_nsBars.clear(),this.lastProjectionPrice=void 0},t.prototype.isEmpty=function(){return this.m_bars.isEmpty()&&this.m_nsBars.isEmpty()},t.prototype.first=function(){return this.m_bars.isEmpty()?this.m_nsBars.first():this.m_bars.first()},t.prototype.last=function(){return this.m_nsBars.isEmpty()?this.m_bars.last():this.m_nsBars.last()},t.prototype.search=function(t,e){return this.nsBars().isEmpty()?this.bars().search(t,e):this.bars().isEmpty()?this.nsBars().search(t,e):o.ensureNotNull(this.nsBars().firstIndex())<=t?this.nsBars().search(t,e):this.bars().search(t,e)},t.prototype.valueAt=function(t){var e=this.search(t);return null!==e?e.value:null},t.prototype.plotValueToTimePointIndex=function(t,e,i){var o,n,s,a;if(i===r.FromRight)return o=function(i,o){var n=o[e];return void 0!==n&&null!==n&&t>=n},null!==(n=this.m_bars.findLast(o))?n.index:(s=this.m_nsBars.findLast(o), -null!==s?s.index:this.m_bars.firstIndex());if(i===r.FromLeft)return a=function(i,o){var n=o[e];return void 0!==n&&null!==n&&t<=n},null!==(n=this.m_bars.findFirst(a))?n.index:(s=this.m_nsBars.findFirst(a),null!==s?s.index:this.m_bars.lastIndex());throw Error("plotValueToTimePointIndex: unsupported search mode")},t}(),e.SeriesData=s},function(t,e,i){"use strict";var o,n;Object.defineProperty(e,"__esModule",{value:!0}),o=i(15),n=function(){function t(t){void 0===t&&(t=1),this._precision=t}return t.prototype.format=function(t){var e,i;return o.isNumber(t)||(t=parseFloat(t)),e=t.toFixed(this._precision),i=Math.pow(10,-this._precision),Math.max(parseFloat(e),i)+""},t}(),e.LimitedPrecisionNumericFormatter=n},function(t,e){t.exports=''},function(t,e,i){"use strict";var o,n,r;Object.defineProperty(e,"__esModule",{value:!0}),o=i(9),n=i(17),i(13),r=function(){function t(t){var e=this;this._alive=new n,this._body=new n,this._width=new n,this._height=new n,this._fullscreen=new n,this._detachable=new n,this._visible=new n,this._availWidth=new n,this._availHeight=new n,this._owner=new n,this._ownersStack=[],this.owner=this._owner.readonly(),this._bridge={alive:this._alive.readonly(),body:this._body.readonly(),width:this._width.readonly(),height:this._height.readonly(),fullscreen:this._fullscreen.readonly(),detachable:this._detachable.readonly(),visible:this._visible.readonly(),availWidth:this._availWidth.readonly(),availHeight:this._availHeight.readonly(),remove:function(){var t=e._owner.value();t&&t.remove&&t.remove()},negotiateWidth:function(t){var i=e._owner.value();i&&i.negotiateWidth&&i.negotiateWidth(t)},negotiateHeight:function(t){var i=e._owner.value();i&&i.negotiateHeight&&i.negotiateHeight(t)},requestFullscreen:function(){var t=e._owner.value();t&&t.requestFullscreen&&t.requestFullscreen()},exitFullscreen:function(){var t=e._owner.value();t&&t.exitFullscreen&&t.exitFullscreen()},detach:function(t){var i=e._owner.value();i&&i.detach&&i.detach(t)},attach:function(){var t=e._owner.value();t&&t.attach&&t.attach()}},t&&this.pushOwner(t)}return t.prototype.bridge=function(){return this._bridge},t.prototype.pushOwner=function(t){var e,i,o,n;if(t.alive.value()){for(e=0,i=this._ownersStack;e=i;e--)this._unsubscribeOwner(this._ownersStack[e],!0);this._ownersStack.length=i,i>0?this._subscribeOwner(this._ownersStack[i-1]):(this._alive.setValue(!1),this._owner.deleteValue())},t}(),e.ResizerDetacherState=r},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.layouts={s:{title:"1 chart",count:1,sizer:function(t,e,i,o){return{width:e.width-o-o,height:e.height-o-o,top:o,left:o}}}}},function(t,e,i){"use strict";function o(){this.backColorers=[]}function n(t){o.call(this),this._series=t}function r(t,e){o.call(this),this._study=t,this._plotIndex=e}var s=i(19).PlotRowSearchMode;o.prototype.barStyle=function(t,e,i){var o,n={};for(o=this.backColorers.length-1;o>=0;o--)this.backColorers[o].applyBarStyle(t,e,n,i);return this.applyBarStyle(t,e,n,i),n},o.prototype.pushBackBarColorer=function(t){this.backColorers.push(t)},o.prototype.applyBarStyle=function(t,e,i){throw Error("This function is supposed to be reimplemented in a subclass")},inherit(n,o),n.prototype.applyBarStyle=function(t,e,i,o){var n,r,s,a,l,c,h,u,d,p,_,f,m,g,v;switch(i||(i={}),i.barColor=null,i.barBorderColor=null,i.barWickColor=null,i.isBarHollow=null,i.isBarUp=null,i.upColor=null,i.downColor=null,i.isTwoColorBar=null,n=this._series.properties(),n.style.value()){case TradingView.Series.STYLE_LINE:i.barColor=n.lineStyle.color.value();break;case TradingView.Series.STYLE_AREA:i.barColor=n.areaStyle.linecolor.value();break;case TradingView.Series.STYLE_BARS:r=n.barStyle.upColor.value(),s=n.barStyle.downColor.value(),a=r,l=s,c=this.findBar(t,!1,o),n.barStyle.barColorsOnPrevClose.value()?(h=this.findPrevBar(t,!1,o),i.barColor=h[TradingView.CLOSE_PLOT]<=c[TradingView.CLOSE_PLOT]?r:s,i.barBorderColor=h[TradingView.CLOSE_PLOT]<=c[TradingView.CLOSE_PLOT]?a:l):(i.barColor=c[TradingView.OPEN_PLOT]<=c[TradingView.CLOSE_PLOT]?r:s,i.barBorderColor=c[TradingView.OPEN_PLOT]<=c[TradingView.CLOSE_PLOT]?a:l);break;case TradingView.Series.STYLE_CANDLES:r=n.candleStyle.upColor.value(),s=n.candleStyle.downColor.value(),a=n.candleStyle.borderUpColor?n.candleStyle.borderUpColor.value():n.candleStyle.borderColor.value(),l=n.candleStyle.borderDownColor?n.candleStyle.borderDownColor.value():n.candleStyle.borderColor.value(),u=n.candleStyle.wickUpColor?n.candleStyle.wickUpColor.value():n.candleStyle.wickColor.value(),d=n.candleStyle.wickDownColor?n.candleStyle.wickDownColor.value():n.candleStyle.wickColor.value(),c=this.findBar(t,!1,o),n.candleStyle.barColorsOnPrevClose.value()?(h=this.findPrevBar(t,!1,o), -p=h[TradingView.CLOSE_PLOT]<=c[TradingView.CLOSE_PLOT]):p=c[TradingView.OPEN_PLOT]<=c[TradingView.CLOSE_PLOT],i.barColor=p?r:s,i.barBorderColor=p?a:l,i.barWickColor=p?u:d;break;case TradingView.Series.STYLE_HOLLOW_CANDLES:r=n.hollowCandleStyle.upColor.value(),s=n.hollowCandleStyle.downColor.value(),a=n.hollowCandleStyle.borderUpColor?n.hollowCandleStyle.borderUpColor.value():n.hollowCandleStyle.borderColor.value(),l=n.hollowCandleStyle.borderDownColor?n.hollowCandleStyle.borderDownColor.value():n.hollowCandleStyle.borderColor.value(),u=n.hollowCandleStyle.wickUpColor?n.hollowCandleStyle.wickUpColor.value():n.hollowCandleStyle.wickColor.value(),d=n.hollowCandleStyle.wickDownColor?n.hollowCandleStyle.wickDownColor.value():n.hollowCandleStyle.wickColor.value(),c=this.findBar(t,!1,o),h=this.findPrevBar(t,!1,o),h[TradingView.CLOSE_PLOT]<=c[TradingView.CLOSE_PLOT]?(i.barColor=r,i.barBorderColor=a,i.barWickColor=u):(i.barColor=s,i.barBorderColor=l,i.barWickColor=d),c[TradingView.OPEN_PLOT]<=c[TradingView.CLOSE_PLOT]?i.isBarHollow=!0:i.isBarHollow=!1;break;case TradingView.Series.STYLE_HEIKEN_ASHI:r=n.haStyle.upColor.value(),s=n.haStyle.downColor.value(),a=n.haStyle.borderUpColor.value(),l=n.haStyle.borderDownColor.value(),u=n.haStyle.wickUpColor.value(),d=n.haStyle.wickDownColor.value(),c=this.findBar(t,e,o),n.haStyle.barColorsOnPrevClose.value()?(h=this.findPrevBar(t,e,o),p=h[TradingView.CLOSE_PLOT]<=c[TradingView.CLOSE_PLOT]):p=c[TradingView.OPEN_PLOT]<=c[TradingView.CLOSE_PLOT],i.barColor=p?r:s,i.barBorderColor=p?a:l,i.barWickColor=p?u:d;break;case TradingView.Series.STYLE_RENKO:c=this.findBar(t,e,o),p=c[TradingView.OPEN_PLOT]<=c[TradingView.CLOSE_PLOT],r=e?n.renkoStyle.upColorProjection.value():n.renkoStyle.upColor.value(),s=e?n.renkoStyle.downColorProjection.value():n.renkoStyle.downColor.value(),a=e?n.renkoStyle.borderUpColorProjection.value():n.renkoStyle.borderUpColor.value(),l=e?n.renkoStyle.borderDownColorProjection.value():n.renkoStyle.borderDownColor.value(),u=n.renkoStyle.wickUpColor.value(),d=n.renkoStyle.wickDownColor.value(),i.barColor=p?r:s,i.barBorderColor=p?a:l,i.barWickColor=p?u:d,i.isBarUp=p;break;case TradingView.Series.STYLE_PB:c=this.findBar(t,e,o),p=c[TradingView.OPEN_PLOT]<=c[TradingView.CLOSE_PLOT],r=e?n.pbStyle.upColorProjection.value():n.pbStyle.upColor.value(),s=e?n.pbStyle.downColorProjection.value():n.pbStyle.downColor.value(),a=e?n.pbStyle.borderUpColorProjection.value():n.pbStyle.borderUpColor.value(),l=e?n.pbStyle.borderDownColorProjection.value():n.pbStyle.borderDownColor.value(),i.barColor=p?r:s,i.barBorderColor=p?a:l,i.isBarUp=p;break;case TradingView.Series.STYLE_KAGI:i.upColor=e?n.kagiStyle.upColorProjection.value():n.kagiStyle.upColor.value(),i.downColor=e?n.kagiStyle.downColorProjection.value():n.kagiStyle.downColor.value(),_=null,c=this.findBar(t,e,o),c[TradingView.LOW_PLOT]0,r=e?n.pnfStyle.upColorProjection.value():n.pnfStyle.upColor.value(),s=e?n.pnfStyle.downColorProjection.value():n.pnfStyle.downColor.value(),i.isBarUp=p,i.barColor=p?r:s;break;case TradingView.Series.STYLE_BASELINE:c=this.findBar(t,e,o),f=n.baselineStyle,m=this._series.priceScale(),g=Math.round(m.height()*(Math.abs(100-f.baseLevelPercentage.value())/100)),v=m.coordinateToPrice(g),c[TradingView.CLOSE_PLOT]>v?i.barColor=n.baselineStyle.topLineColor.value():i.barColor=n.baselineStyle.bottomLineColor.value()}return i},n.prototype.getSeriesBars=function(t){return t?this._series.nsBars():this._series.bars()},n.prototype._findBarFieldValue=function(t,e,i){var o=this.getSeriesBars(i).valueAt(t);if(null!==o)return o[e]},n.prototype.findBar=function(t,e,i){return i?i.value:this.getSeriesBars(e).valueAt(t)||[]},n.prototype.findPrevBar=function(t,e,i){var o,n;return i&&i.previousValue?i.previousValue:(o=this._series.bars(),n=o._search(t,s.Exact),null!==n&&n>0?this._series.bars()._valueAt(n-1):[])},inherit(r,o),r.prototype.applyBarStyle=function(t,e,i){var o,n,r,s,a,l,c,h,u,d,p,_,f;return i||(i={}),e?i:(o=this._study.properties(),o.visible.value()?(n=this._study.metaInfo(),(r=this._study.data())&&0!==r.size()?(s=n.plots[this._plotIndex],this._study.getMinFirstBarIndexForPlot(s.id)>t?i:(a=o.styles[s.id],a.visible&&!a.visible.value()?i:(l=this._study.offset(s.id),null===(c=r.valueAt(t-l))?i:null==(h=c[this._plotIndex+1])?i:(h=Math.round(h),u=n.plots[this._plotIndex].palette,d=o.palettes,p=d[u],_=n.palettes[u].valToIndex?n.palettes[u].valToIndex[h]:h,f=p.colors[_].color.value(),i.barColor=f,i.upColor=f.color,i.downColor=f.color,i)))):i):i)},e.SeriesBarColorer=n,e.StudyBarColorer=r},function(t,e,i){"use strict";function o(t){this.items=t.items,this.barSpacing=t.barSpacing,this.colorUp=t.colorup,this.colorDn=t.colordown,this.colorBorderUp=t.colorBorderUp,this.colorBorderDown=t.colorBorderDown,this.width=this._calculateWidth(t.barSpacing),this.minHeight=t.minHeight,this.vertOffset=this._calculateVerticalOffset(t.barSpacing)}function n(t,e,i,o){this.x=t,this.y=e,this.height=i,this.isUp=o}var r=i(8).Point,s=i(11);o.prototype._calculateVerticalOffset=function(t){return Math.round((t||0)/4)},o.prototype._calculateMinHeight=function(t){return this.width||this._calculateWidth(t)},o.prototype._calculateWidth=function(t){var t=t||this.barSpacing;return Math.round(t/2)},o.prototype.draw=function(t){var e,i,o,n,r,s,a,l=this.width,c=l<4,h=Math.max(parseInt(l/2),1),u=Math.round(this.width/2),d=Math.round(this.width);for(t.translate(1,1),e=0,i=this.items.length;e1;return 0===this._graphics.indexes.length&&!t},o.prototype.graphics=function(){return this._graphics},o.prototype.setGraphics=function(t){this._graphics=t,this._postProcessGraphicsData()},o.prototype.process=function(t){if(""!==t.d)return t.d.indexes_replace?void this.replaceIndexes(t):void(t.d.graphicsCmds&&(this.processEraseCmds(t.d.graphicsCmds.erase),this.processCreateCmds(t.d.graphicsCmds.create,t.indexes)))},o.prototype.replaceIndexes=function(t){""!==t.d&&(n(!!t.d.indexes_replace),this._graphics.indexes=t.indexes)},o.prototype.processEraseCmds=function(t){var e,i,r,s,a;if(t)for(n(!!this._graphics,"_graphics object doesn't exist in the study!"),n(!!this._graphics.indexes,"_graphics.indexes array doesn't exist in the study!"),e=0;e=0&&s.data.splice(a,1)}},o._findGraphicsObjIndexById=function(t,e){for(var i=0;i=c.priceHigh||d.priceLow>=c.priceLow)&&(d.priceHigh<=h.priceHigh||d.priceLow<=h.priceLow)&&(d.va=!0);n.shortDataObj||(n.shortDataObj={}),n.shortDataObj[s]=a.slice()}}},o._sortHHistItemsByPrice=function(t){t.sort(function(t,e){return t.priceLow-e.priceLow})},o._splitHHistItemsBySession=function(t,e){var i,o,n,s={};for(i=0;i=0?new c(e,i,a):new c(e,i)},t.exports=o},function(t,e,i){"use strict";var o,n,r,s,a;Object.defineProperty(e,"__esModule",{value:!0}),o=i(0),n=i(9),r=i(67),s=i(15),a=function(t){function e(e,i){var o=t.call(this)||this;return o._activeBackground="#0F6DBF",o._background="#5592C9",o._active=!1,o._source=e,o._data=i,o}return o.__extends(e,t),e.prototype.setActive=function(t){this._active=t},e.prototype.setBackground=function(t){this._background=t},e.prototype._updateRendererData=function(t){var e,i,o,r,a,l,c,h;if(t.visible=!1,e=this._source.model(),e.timeScale()&&!e.timeScale().isEmpty()&&null!==(i=this._source.priceScale())&&!i.isEmpty()&&(e.selectedSource()===this._source||this._source.isForcedDrawPriceAxisLabel())&&null!==e.timeScale().visibleBars()&&(o=this._source.axisPoints(),r=this._data.pointIndex,!(o.length<=r)&&(a=o[r], -isFinite(a.price)))){if(i.isPercent()){if(!(l=this._source.ownerSource()))return;if(c=l.firstValue(),!s.isNumber(c))return;a.price=n.ensureNotNull(i.priceRange()).convertToPercent(a.price,c)}h=this._active?this._activeBackground:this._background,this._data.backgroundProperty&&(h=this._data.backgroundProperty.value()),t.background=h,t.borderColor="#2E84A6",t.color=this.generateTextColor(h),t.coordinate=i.priceToCoordinate(a.price),t.text=i.formatter().format(a.price),t.visible=!0}},e}(r.PriceAxisView),e.LineToolPriceAxisView=a},function(t,e,i){"use strict";var o,n;Object.defineProperty(e,"__esModule",{value:!0}),o=i(32),n=function(){function t(){this._text="",this._background="#585858",this._coordinate=0}return t.prototype.text=function(){return this._text},t.prototype.background=function(){return this._background},t.prototype.color=function(){return"black"===o.rgbToBlackWhiteString(o.parseRgb(this._background),150)?"white":"black"},t.prototype.coordinate=function(){return this._coordinate},t}(),e.TimeAxisView=n},function(t,e,i){"use strict";function o(){this._data=null}var n=/[1-9]/g;o.prototype.setData=function(t){this._data=t},o.prototype.draw=function(t,e){var i,o,r,s,a,l,c,h,u,d,p,_,f,m,g,v,y,b,S;null!=this._data&&!1!==this._data.visible&&0!==this._data.text.length&&(t.font=e.font,(i=Math.round(e.widthCache.measureText(t,this._data.text,n)))<=0||(o=e.paddingHorizontal,r=i+2*o,s=r/2,a=this._data.width,l=this._data.coordinate,c=Math.floor(l-s)+.5,c<0?(l+=Math.abs(0-c),c=Math.floor(l-s)+.5):c+r>a&&(l-=Math.abs(a-(c+r)),c=Math.floor(l-s)+.5),h=c,u=h+r,d=u,p=Math.round(this._data.coordinate+1),_=p,f=.5,m=f+e.borderSize+e.tickLength+e.paddingTop+e.fontSize+e.paddingBottom,g=m,v=f,y=v,b=y+e.borderSize+e.tickLength,S=m-e.baselineOffset-e.paddingBottom,t.fillStyle=this._data.background,t.lineWidth=1,t.beginPath(),t.strokeStyle=this._data.color,t.moveTo(c,f),t.lineTo(h,m),t.lineTo(u,g),t.lineTo(d,v),t.fill(),t.beginPath(),t.moveTo(p,y),t.lineTo(_,b),t.stroke(),t.textAlign="left",t.fillStyle=this._data.color,t.fillText(this._data.text,c+o,S)))},t.exports=o},function(t,e,i){"use strict";function o(t,e){this.customization={forcePriceAxisLabel:!0,disableSelection:!0,disableErasing:!0},n.call(this,t,e)}var n=i(1).LineDataSource;inherit(o,n),o.POINTS_COUNT=1,o.prototype.pointsCount=function(){return o.POINTS_COUNT},o.prototype.hasContextMenu=function(){return!1},o.prototype.state=function(){return null},o.prototype.startMoving=function(){n.prototype.startMoving.apply(this,arguments),this._cursorMoved=!1},o.prototype.endMoving=function(){n.prototype.endMoving.apply(this,arguments),this._cursorMoved=!1},o.prototype.correctPoints=function(t){var e,i,o,n,r;for(this._currentMovingPoint&&this._startMovingPoint?this._currentMovingPoint.price-this._startMovingPoint.price&&(this._cursorMoved=!0):this._cursorMoved=!1,e=this.priceScale(),i=e.mainSource().base(),o=1/i,n=0;n100&&y.riskDisplayMode.setValueSilently("money"),this._syncStateExclusions=["entryPrice","stopPrice","targetPrice","riskSize","qty","amountTarget","amountStop","risk","accountSize"],this.version=o.version,this._entryPriceAxisView=new l(this,{colorProperty:y.linecolor,priceProperty:y.entryPrice}),this._stopPriceAxisView=new l(this,{colorProperty:y.stopBackground,priceProperty:y.stopPrice}),this._profitPriceAxisView=new l(this,{colorProperty:y.profitBackground,priceProperty:y.targetPrice}),i.e(1).then(function(t){var e=i(1171).RiskRewardPaneView;this._setPaneViews([new e(this,this._model)])}.bind(this).bind(null,i)).catch(i.oe)}function n(t,e){var i,n;this._constructor="LineToolRiskRewardShort",i=e||new h("linetoolriskrewardshort"),o.call(this,t,i),n=this.properties(), -n.entryPrice.subscribe(this,this._recalculateQty),n.stopPrice.subscribe(this,this._recalculateQty),n.riskSize.subscribe(this,this._recalculateQty),n.entryPrice.subscribe(this,this._recalculateAmount),n.profitLevel.subscribe(this,this._recalculateAmount),n.stopLevel.subscribe(this,this._recalculateAmount),n.accountSize.subscribe(this,this._recalculateAmount),n.riskSize.subscribe(this,this._recalculateAmount),n.qty.subscribe(this,this._recalculateAmount)}function r(t,e){var i,n;this._constructor="LineToolRiskRewardLong",i=e||new h("linetoolriskrewardlong"),o.call(this,t,i),n=this.properties(),n.entryPrice.subscribe(this,this._recalculateQty),n.stopPrice.subscribe(this,this._recalculateQty),n.riskSize.subscribe(this,this._recalculateQty),n.entryPrice.subscribe(this,this._recalculateAmount),n.profitLevel.subscribe(this,this._recalculateAmount),n.stopLevel.subscribe(this,this._recalculateAmount),n.accountSize.subscribe(this,this._recalculateAmount),n.riskSize.subscribe(this,this._recalculateAmount),n.qty.subscribe(this,this._recalculateAmount)}var s=i(9).ensureNotNull,a=i(1).LineDataSource,l=i(844).LineToolRiskRewardPriceAxisView,c=i(26),h=i(6).DefaultProperty,u=i(89).NumericFormatter,d=i(3).propertyPages,p=i(409).RiskRewardPointIndex;inherit(o,a),o.prototype.riskFormatter=function(t){return"percents"===t?this._riskInPercentsFormatter:this._riskInMoneyFormatter},o.prototype.getRiskStep=function(t){return"percents"===t?.01:1},o.prototype._roundValue=function(t){return parseFloat(t.toFixed(2))},o.prototype._recalculateRisk=function(){var t=this.properties(),e=t.riskDisplayMode.value(),i=t.riskSize.value(),o=t.accountSize.value(),n=t.risk.value();n="percents"===e?this._roundValue(i/o*100):this._roundValue(o/100*n),this._riskInChange=!0,t.risk.setValue(this.riskFormatter(e).format(n)),this._riskInChange=!1},o.prototype._recalculateRiskSize=function(){var t,e,i,o;this._riskInChange||(t=this.properties(),e=t.risk.value(),i=t.riskDisplayMode.value(),o=t.accountSize.value(),"percents"===i?t.riskSize.setValue(e/100*o):e>o?(t.risk.setValue(o),t.riskSize.setValue(o)):t.riskSize.setValue(e))},o.version=2,o.prototype.i18nCache={title:$.t("Risk/Reward")},o.prototype.lastBarData=function(){var t,e,i,o,n,r=this._model.mainSeries().bars().firstIndex(),a=this._model.mainSeries().bars().lastIndex();return null===r||null===a||isNaN(r)||isNaN(a)?null:(t=this.points(),4===t.length?(e=t[p.ActualClose],e.index=1&&(o=[],o.push(this._points[0]),n=this._points[0],n={price:n.price,index:n.index+50},o.push(n),this._points[1]&&o.push(this._points[1]),this._points[2]&&o.push(this._points[2]),this._points=o,this._timePoint.length>=1&&(r=[],n=this._timePoint[0],r.push(n),s={price:n.price,time_t:n.time_t,offset:n.offset+50},r.push(s), -this._timePoint[1]&&o.push(this._points[1]),this._timePoint[2]&&o.push(this._points[2]),this._timePoint=r))},o.prototype.checkAlert=function(){this.recalculate()},o.prototype.priceAxisViews=function(t,e){return this.isSourceHidden()?null:e!==this.priceScale()||this._model.paneForSource(this)!==t?null:[this._entryPriceAxisView,this._stopPriceAxisView,this._profitPriceAxisView]},o.prototype.updateAllViews=function(){this.isActualSymbol()&&this._properties.visible.value()&&(c.hideAllDrawings().value()&&this.userEditEnabled()||(a.prototype.updateAllViews.call(this),this._entryPriceAxisView.update(),this._stopPriceAxisView.update(),this._profitPriceAxisView.update()))},o.prototype.setPoint=function(t,e){var i,o=this.priceScale();switch(o.isPercent()&&(i=this.ownerSource().firstValue(),e.price=o.priceRange().convertFromPercent(e.price,i)),t){case 0:e.price=this._roundPrice(e.price),o.isPercent()&&(e.price=o.priceRange().convertToPercent(e.price,i)),a.prototype.setPoint.call(this,t,e),this.recalculate();break;case 1:this.isActualSymbol()&&this.properties().stopPrice.setValue(this.preparseStopPrice(e.price));break;case 2:this.isActualSymbol()&&this.properties().targetPrice.setValue(this.preparseProfitPrice(e.price));break;case 3:e.price=this._roundPrice(e.price),o.isPercent()&&(e.price=o.priceRange().convertToPercent(e.price,i)),a.prototype.setPoint.call(this,1,e),this.recalculate()}},o.PriceProperty=function(t,e){a.PointPriceProperty.call(this,t,e)},inherit(o.PriceProperty,a.PointPriceProperty),o.PriceProperty.prototype.setValue=function(t){var e=this._lineSource.points()[this._pointIndex];e.price=parseFloat(t),this._lineSource.setPoint(this._pointIndex,e),this._lineSource.recalculate(),this._lineSource._model.updateSource(this._lineSource),this._listeners.fire(this),this._lineSource.endChanging(),this._lineSource._syncMultichartState()},o.StopPriceProperty=function(t){o.PriceProperty.call(this,t,1)},inherit(o.StopPriceProperty,o.PriceProperty),o.StopPriceProperty.prototype.value=function(){var t=this._lineSource.stopPrice(),e=this._lineSource.ownerSource().formatter(),i=e.parse(e.format(t));return i.price?i.price:i.value},o.StopPriceProperty.prototype.setValue=function(t){var e=Math.round(Math.abs(t-this._lineSource.entryPrice())*this._lineSource._model.mainSeries().base());this._lineSource.properties().stopLevel.setValue(e),this._lineSource.properties().stopLevel.listeners().fire(this._lineSource.properties().stopLevel)},o.TargetPriceProperty=function(t){o.PriceProperty.call(this,t,2)},inherit(o.TargetPriceProperty,o.PriceProperty),o.TargetPriceProperty.prototype.value=function(){var t=this._lineSource.profitPrice(),e=this._lineSource.ownerSource().formatter(),i=e.parse(e.format(t));return i.price?i.price:i.value},o.TargetPriceProperty.prototype.setValue=function(t){var e=Math.round(Math.abs(t-this._lineSource.entryPrice())*this._lineSource._model.mainSeries().base());this._lineSource.properties().profitLevel.setValue(e),this._lineSource.properties().profitLevel.listeners().fire(this._lineSource.properties().profitLevel) -},o.prototype.pointsCount=function(){return 1},o.prototype.title=function(){return this.i18nCache.title},o.prototype.addPoint=function(t){var e,i;return t.price=this._roundPrice(t.price),a.prototype.addPoint.call(this,t,null,!0),e={price:t.price,index:t.index+50},a.prototype._addPointIntenal.call(this,e,null,!0),i=this.calculateActualEntry(t,e),i&&(a.prototype._addPointIntenal.call(this,i,null,!0),(e=this.findClosePoint(i,e))&&a.prototype._addPointIntenal.call(this,e,null,!0)),this._lastPoint=null,this.normalizePoints(),this.createServerPoints(),!0},o.prototype._roundPrice=function(t){var e=this._model.mainSeries().base();return Math.round(t*e)/e},o.prototype.recalculate=function(){var t,e,i,o,n;this.properties().interval.value()===this._model.mainSeries().interval()&&0!==this.points().length&&(t=this.properties().targetPrice.value(),e=this.properties().stopPrice.value(),i=[this._points[0],this._points[1]],o=this.calculateActualEntry(this.points()[0],this.points()[1]),o&&(i.push(o),(n=this.findClosePoint(o,this.points()[1]))&&i.push(n)),this._points=i,t!==this.properties().targetPrice.value()&&this.properties().targetPrice._listeners.fire(this.properties().targetPrice),e!==this.properties().stopPrice.value()&&this.properties().stopPrice._listeners.fire(this.properties().stopPrice))},o.prototype.start=function(){a.prototype.start.call(this),this.recalculate()},o.prototype.startMoving=function(t){t.price=this._roundPrice(t.price),a.prototype.startMoving.call(this,t)},o.prototype.move=function(t){t.price=this._roundPrice(t.price),a.prototype.move.call(this,t),this.recalculate(),this._entryPriceAxisView.update()},o.prototype.correctPoints=function(t){return!!this.isActualSymbol()&&a.prototype.correctPoints.call(this,[t[0],t[1]])},o.prototype.entryPrice=function(){return this.points()[0].price},o.prototype.findClosePoint=function(t,e){var i,o,n,r=this._model.mainSeries().bars(),a=s(r.firstIndex()),l=Math.max(t.index,a),c=s(r.lastIndex());for(i=l;i<=Math.min(c,e.index);i++)if(o=s(r.valueAt(i)),null!=(n=this.checkStopPrice(o)))return{index:i,price:n};return null},o.prototype.calculateActualEntry=function(t,e){var i,o,n=this._model.mainSeries().bars(),r=s(n.firstIndex()),a=Math.max(t.index,r),l=t.price,c=s(n.lastIndex());for(i=a;i<=Math.min(c,e.index);i++)if(o=s(n.valueAt(i)),o[TradingView.HIGH_PLOT]>=l&&o[TradingView.LOW_PLOT]<=l)return{index:i,price:l};return null},o.prototype.axisPoints=function(){var t,e,i;if(!this._points[p.ActualEntry])return[];if(t=this._points[p.ActualEntry],e=null,4===this._points.length)e=this._points[p.ActualClose];else{if(!(i=this.lastBarData()))return[];e={index:i.index,price:i.closePrice}}return[t,e]},o.prototype.getInputsPropertyPage=function(){return d.LineToolRiskRewardInputsPropertyPage},o.prototype.getStylesPropertyPage=function(){return d.LineToolRiskRewardStylesPropertyPage},inherit(n,o),n.prototype.i18nCache={title:$.t("Risk/Reward short")},n.prototype._recalculateQty=function(){var t,e,i,o,n;0!==this.points().length&&(t=this.properties(),e=t.entryPrice.value(),i=t.stopPrice.value(), -o=t.riskSize.value(),n=Math.floor(o/Math.abs(i-e)),t.qty.setValue(n))},n.prototype._recalculateAmount=function(){var t,e,i,o,n,r,s,a;0!==this.points().length&&(t=this.properties(),e=t.accountSize.value(),i=t.entryPrice.value(),o=t.qty.value(),n=t.stopPrice.value(),r=t.targetPrice.value(),s=this._roundValue(e+(i-r)*o),a=this._roundValue(e-(n-i)*o),t.amountTarget.setValue(s),t.amountStop.setValue(a))},n.prototype.title=function(){return this.i18nCache.title},n.prototype.stopPrice=function(){return this.entryPrice()+this.properties().stopLevel.value()/this._model.mainSeries().base()},n.prototype.profitPrice=function(){return this.entryPrice()-this.properties().profitLevel.value()/this._model.mainSeries().base()},n.prototype.calculatePL=function(t){return this.entryPrice()-t},n.prototype.preparseStopPrice=function(t){t=this._roundPrice(t);var e=this.entryPrice()+1/this._model.mainSeries().base();return Math.max(t,e)},n.prototype.preparseProfitPrice=function(t){t=this._roundPrice(t);var e=this.entryPrice()-1/this._model.mainSeries().base();return Math.min(t,e)},n.prototype.checkStopPrice=function(t){var e=this.stopPrice(),i=this.profitPrice();return t[TradingView.HIGH_PLOT]>=e?this.stopPrice():t[TradingView.LOW_PLOT]<=i?this.profitPrice():null},r.prototype.i18nCache={title:$.t("Risk/Reward long")},inherit(r,o),r.prototype._recalculateQty=function(){var t,e,i,o,n;0!==this.points().length&&(t=this.properties(),e=t.entryPrice.value(),i=t.stopPrice.value(),o=t.riskSize.value(),n=Math.floor(o/Math.abs(e-i)),t.qty.setValue(n))},r.prototype._recalculateAmount=function(){var t,e,i,o,n,r,s,a;0!==this.points().length&&(t=this.properties(),e=t.accountSize.value(),i=t.entryPrice.value(),o=t.qty.value(),n=t.stopPrice.value(),r=t.targetPrice.value(),s=this._roundValue(e+(r-i)*o),a=this._roundValue(e-(i-n)*o),t.amountTarget.setValue(s),t.amountStop.setValue(a))},r.prototype.stopPrice=function(){return this.entryPrice()-this.properties().stopLevel.value()/this._model.mainSeries().base()},r.prototype.profitPrice=function(){return this.entryPrice()+this.properties().profitLevel.value()/this._model.mainSeries().base()},r.prototype.calculatePL=function(t){return t-this.entryPrice()},r.prototype.preparseStopPrice=function(t){t=this._roundPrice(t);var e=this.entryPrice()-1/this._model.mainSeries().base();return Math.min(t,e)},r.prototype.preparseProfitPrice=function(t){t=this._roundPrice(t);var e=this.entryPrice()+1/this._model.mainSeries().base();return Math.max(t,e)},r.prototype.checkStopPrice=function(t){var e=this.stopPrice(),i=this.profitPrice();return t[TradingView.LOW_PLOT]<=e?this.stopPrice():t[TradingView.HIGH_PLOT]>=i?this.profitPrice():null},r.prototype.title=function(){return this.i18nCache.title},e.LineToolRiskReward=o,e.LineToolRiskRewardLong=r,e.LineToolRiskRewardShort=n}).call(e,i(73))},function(t,e,i){"use strict";function o(t,e){this._formatter=t,this._maxSize=e||50,this._actualSize=0,this._cache={},this._usageTick=1,this._oldestTick=1,this._tick2Labels={}}o.prototype.format=function(t){var e,i -;return this._cache[t]?this._cache[t].string:(this._actualSize===this._maxSize&&(e=this._tick2Labels[this._oldestTick],delete this._tick2Labels[this._oldestTick],delete this._cache[e],this._oldestTick++,this._actualSize--),i=this._formatter(t),this._cache[t]={string:i,tick:this._usageTick},this._tick2Labels[this._usageTick]=t,this._actualSize++,this._usageTick++,i)},t.exports=o},function(t,e,i){"use strict";function o(t,e,i){a.call(this,t,e,i)}function n(t,e,i){o.call(this,t,e,i)}function r(t,e,i){o.call(this,t,e,i)}function s(t,e,i){o.call(this,t,e,i)}var a=i(105).LineStudyMtp;inherit(o,a),o.prototype.pointsCount=function(){return 1},o.prototype._studyInputs=function(){var t,e,i=this.points();return i.length0?1/0:i<0?-1/0:t.zorder(),[t,i,e]}).sort(function(t,e){return t[1]-e[1]||t[2]-e[2]}).map(function(t){return t[0]})},o.prototype._updateMargins=function(){var t,e,i=.01*this._properties.topMargin.value(),o=.01*this._properties.bottomMargin.value();for(this.m_leftPriceScale.setTopMargin(i),this.m_leftPriceScale.setBottomMargin(o),this.m_rightPriceScale.setTopMargin(i),this.m_rightPriceScale.setBottomMargin(o),t=0;to)&&(o=i));return null===o&&(o=this.getZOrderMinMax().minZOrder-1),this.m_dataSources.forEach(function(t){t.zorder()>o&&t.setZorder(t.zorder()+1)}),o+1},o.prototype.beginInsertManyLineDataSources=function(){this._isInInsertManyDataSourcesState=!0,this._lastLineDataSourceZOrder=null},o.prototype.endInsertManyLineDataSources=function(){this._isInInsertManyDataSourcesState=!1,this._lastLineDataSourceZOrder=null},o.prototype.addDataSource=function(t,e,i){var o;t instanceof r&&!i?(o=null!==this._lastLineDataSourceZOrder?this._lastLineDataSourceZOrder:this._newZOrderForLineTool(),this._isInInsertManyDataSourcesState&&(this._lastLineDataSourceZOrder=o)):o=this.getZOrderMinMax().minZOrder-1,this.insertDataSource(t,e,o)},o.prototype.insertDataSource=function(t,e,i){var n,r,s;this.m_dataSources.push(t),n=!1,t===this._model.mainSeries()?(this.m_mainDataSource=t,n=!0):null===this.m_mainDataSource&&(this.m_mainDataSource=t,n=!0),t._isOverlay=!1, -null!==e||this.canHaveMoreNoScaleSources()||(e=this.rightPriceScale()),null===e&&(r=this.m_rightPriceScale.topMargin(),s=this.m_rightPriceScale.bottomMargin(),t.metaInfo&&"Volume@tv-basicstudies"===t.metaInfo().id&&(r=.75,s=0),e=new c(this._model.properties().scalesProperties),e.setHeight(this.m_height),e.setTopMargin(r),e.setBottomMargin(s),t._isOverlay=!0),e.addDataSource(t,this._isInInsertManyDataSourcesState),t.setPriceScale(e),t.onTagsChanged&&t.onTagsChanged().subscribe(this,o.prototype.onSourceTagsChanged),t.setZorder(i),n&&this._processMainSourceChange(),this._tagsChanged.fire(),TradingView.isInherited(t.constructor,a)&&this.recalculatePriceScale(e),this.invalidateSourcesCache()},o.prototype.removeDataSource=function(t,e){var i,n=this.m_dataSources.indexOf(t);if(-1===n)return void l.logDebug("removeDataSource: invalid data source");t._isOverlay=!1,this.m_dataSources.splice(n,1),t!==this.m_mainDataSource||e||(this.m_mainDataSource=null),i=null,-1!==this.m_leftPriceScale.dataSources().indexOf(t)?(this.m_leftPriceScale.removeDataSource(t),i=this.m_leftPriceScale):-1!==this.m_rightPriceScale.dataSources().indexOf(t)&&(this.m_rightPriceScale.removeDataSource(t),i=this.m_rightPriceScale),t.onTagsChanged&&t.onTagsChanged().unsubscribe(this,o.prototype.onSourceTagsChanged),TradingView.isInherited(t.constructor,a)&&this._processMainSourceChange(),this._tagsChanged.fire(),i&&TradingView.isInherited(t.constructor,a)&&this.recalculatePriceScale(i),this.invalidateSourcesCache()},o.prototype.startScalePrice=function(t,e){t.startScale(e)},o.prototype.scalePriceTo=function(t,e){t.scaleTo(e),this.updateAllViews()},o.prototype.endScalePrice=function(t){t.endScale()},o.prototype.startScrollPrice=function(t,e){t.startScroll(e)},o.prototype.scrollPriceTo=function(t,e){t.scrollTo(e),this.updateAllViews()},o.prototype.endScrollPrice=function(t){t.endScroll()},o.prototype.setPriceAutoScale=function(t,e){if(t.setAutoScale(e),this.timeScale().isEmpty())return void t.setPriceRange(null);this.recalculatePriceScale(t)},o.prototype.restorePriceScaleState=function(t,e){t.restoreState(e),this.updateAllViews()},o.prototype.updateAllViews=function(){for(var t=0;t0&&!this.timeScale().isEmpty()&&(i=this.timeScale().visibleBars(),t.recalculatePriceRange(i)),t.updatePaneViews())},o.prototype.resetPriceScale=function(t){var e=this.timeScale().visibleBars();t.isLockScale()||t.setAutoScale(!0),t.recalculatePriceRange(e),this.updateAllViews()},o.prototype.recalculate=function(){var t,e;for(this.recalculatePriceScale(this.m_rightPriceScale),this.recalculatePriceScale(this.m_leftPriceScale),t=0;te&&(e=o.zorder());return{minZOrder:t,maxZOrder:e}},o.prototype.isZOrderAvailable=function(t){var e,i;for(e=0;e0&&e<0?(n=a[l-1].zorder(),r=t.zorder(),a[l-1].setZorder(r),t.setZorder(n)):l0&&(s=a[l+1].zorder(),r=t.zorder(),a[l+1].setZorder(r),t.setZorder(s)),this.invalidateSourcesCache()},o.prototype.onSourceTagsChanged=function(){this._tagsChanged.fire()},o.prototype.onTagsChanged=function(){return this._tagsChanged},o.prototype.dumpPriceScale=function(t){var e,i,o,n=t.dataSources(),r=[];for(e=0;e=0;t--)TradingView.isInherited(this.m_dataSources[t].constructor,TradingView.Series)&&this.m_dataSources.splice(t,1)},o.prototype.nonOverlayPricesSourcesCount=function(){return this.m_dataSources.filter(function(t){return(!t.properties().linkedToSeries||!t.properties().linkedToSeries.value())&&(TradingView.isInherited(t.constructor,a)&&t.showInObjectTree()&&!t.isNoScale())}).length},o.prototype.canHaveMoreNoScaleSources=function(){return this.nonOverlayPricesSourcesCount()>1},o.prototype.actionNoScaleIsEnabled=function(t){return!(!this.isOverlay(t)&&TradingView.isInherited(t.constructor,a))||this.canHaveMoreNoScaleSources()},o.prototype.executionsPositionController=function(){return this._executionsPositionController||(this._executionsPositionController=new n(this,this._model.timeScale())),this._executionsPositionController},o.prototype.isLast=function(){var t=this._model.panes();return t[t.length-1]===this}, -o.prototype.setMaximized=function(t){this._maximized=t},o.prototype.isMaximized=function(){return this._maximized},o.prototype.isMainPane=function(){var t=this._model.mainSeries(),e=!1;return this.m_dataSources.forEach(function(i){e||(e=i===t)}),this._isMainPane=e,e},o.prototype.properties=function(){return this._properties},o.prototype._mainSourceVisiblePriceRange=function(t){var e=this.m_timeScale.visibleBars();return null!==e?t.mainSource().priceRange(e.firstBar(),e.lastBar()):new s(-.5,.5)},o.prototype.applyLeftPriceScaleRatio=function(t){this._lastLeftPriceScaleRatio!==t&&(this._setNewPriceRangeByScaleRatio(this.m_leftPriceScale,t,this._mainSourceVisiblePriceRange(this.m_leftPriceScale),!0,!0),this._tryToApplyNewLeftPriceScaleRatio(h(this.m_timeScale,this.m_leftPriceScale)))},o.prototype.applyRightPriceScaleRatio=function(t){this._lastRightPriceScaleRatio!==t&&(this._setNewPriceRangeByScaleRatio(this.m_rightPriceScale,t,this._mainSourceVisiblePriceRange(this.m_rightPriceScale),!0,!0),this._tryToApplyNewRightPriceScaleRatio(h(this.m_timeScale,this.m_rightPriceScale)))},o.prototype.isLeftPriceScaleLocked=function(){return!this.m_leftPriceScale.isLog()&&this.m_leftPriceScale.isLockScale()},o.prototype.isRightPriceScaleLocked=function(){return!this.m_rightPriceScale.isLog()&&this.m_rightPriceScale.isLockScale()},o.prototype.leftPriceScaleRatio=function(){return null===this._lastLeftPriceScaleRatio&&(this._lastLeftPriceScaleRatio=h(this.m_timeScale,this.m_leftPriceScale)),this._lastLeftPriceScaleRatio},o.prototype.rightPriceScaleRatio=function(){return null===this._lastRightPriceScaleRatio&&(this._lastRightPriceScaleRatio=h(this.m_timeScale,this.m_rightPriceScale)),this._lastRightPriceScaleRatio},o.prototype._mainSeriesPaneScaleRatioOnChange=function(){this.isMainPane()&&(this._lastLeftPriceScaleRatio=null,this._lastRightPriceScaleRatio=null,this._model.mainSeriesScaleRatioPropertyOnChanged())},o.prototype._applyOldScaleRatioToPriceScale=function(t,e){if(this._isRecalculatingScales||null===e||void 0===e)return!1;this._isRecalculatingScales=!0,this._setNewPriceRangeByScaleRatio(t,e,this._mainSourceVisiblePriceRange(t)),this._isRecalculatingScales=!1},o.prototype._applyOldScaleRatioToTimeScale=function(t,e){if(this._isRecalculatingScales||null===e||void 0===e)return!1;this._isRecalculatingScales=!0,this._setNewBarSpacingByScaleRatio(t,e),this._isRecalculatingScales=!1},o.prototype._tryToApplyNewLeftPriceScaleRatio=function(t){if(this._lastLeftPriceScaleRatio===t)return!1;this._leftPriceScaleRatioChanged.fire(this._lastLeftPriceScaleRatio,t),this._lastLeftPriceScaleRatio=t},o.prototype._tryToApplyNewRightPriceScaleRatio=function(t){if(this._lastRightPriceScaleRatio===t)return!1;this._rightPriceScaleRatioChanged.fire(this._lastRightPriceScaleRatio,t),this._lastRightPriceScaleRatio=t},o.prototype._recalculatePriceScaleByScaleRatio=function(){ -this.isMainPane()&&(this.m_leftPriceScale.mainSource()&&(this.isLeftPriceScaleLocked()&&null!==this._lastLeftPriceScaleRatio?this._applyOldScaleRatioToPriceScale(this.m_leftPriceScale,this._lastLeftPriceScaleRatio):this._tryToApplyNewLeftPriceScaleRatio(h(this.m_timeScale,this.m_leftPriceScale))),this.m_rightPriceScale.mainSource()&&(this.isRightPriceScaleLocked()&&null!==this._lastRightPriceScaleRatio?this._applyOldScaleRatioToPriceScale(this.m_rightPriceScale,this._lastRightPriceScaleRatio):this._tryToApplyNewRightPriceScaleRatio(h(this.m_timeScale,this.m_rightPriceScale))))},o.prototype._recalculateTimeScaleByLeftScaleRatio=function(){this.isLeftPriceScaleLocked()&&null!==this._lastLeftPriceScaleRatio?this._applyOldScaleRatioToTimeScale(this.m_leftPriceScale,this._lastLeftPriceScaleRatio):this._tryToApplyNewLeftPriceScaleRatio(h(this.m_timeScale,this.m_leftPriceScale))},o.prototype._recalculateTimeScaleByRightScaleRatio=function(){this.isRightPriceScaleLocked()&&null!==this._lastRightPriceScaleRatio?this._applyOldScaleRatioToTimeScale(this.m_rightPriceScale,this._lastRightPriceScaleRatio):this._tryToApplyNewRightPriceScaleRatio(h(this.m_timeScale,this.m_rightPriceScale))},o.prototype._setNewPriceRangeByScaleRatio=function(t,e,i,o,n){var r=u(t,this.m_timeScale.barSpacing(),e);t.setPriceRange(null!==r?r:i,o,n)},o.prototype._setMinMaxPriceRange=function(t,e){var i=u(t,this.m_timeScale.maxBarSpacing(),e),o=u(t,this.m_timeScale.minBarSpacing(),e);null!==i&&t.setMaxPriceRange(i),null!==o&&t.setMinPriceRange(o)},o.prototype._onLeftPriceScaleSetMinMaxPriceRange=function(){this._setMinMaxPriceRange(this.m_leftPriceScale,this._lastLeftPriceScaleRatio)},o.prototype._onRightPriceScaleSetMinMaxPriceRange=function(){this._setMinMaxPriceRange(this.m_rightPriceScale,this._lastRightPriceScaleRatio)},o.prototype._setNewBarSpacingByScaleRatio=function(t,e){var i=this.m_timeScale.getValidBarSpacing(d(t,e));this.m_timeScale.isValidBarSpacing(i)&&this.m_timeScale.setBarSpacing(i)},t.exports=o}).call(e,i(10))},function(t,e,i){"use strict";(function(e,o){function n(t,e){if(this.m_base=t,this.m_integralDividers=e,this.m_fractionalDividers=[],c.isBaseDecimal(this.m_base))this.m_fractionalDividers=[2,2.5,2];else for(var i=this.m_base;1!==i;){if(i%2==0)this.m_fractionalDividers.push(2),i/=2;else{if(i%5!=0)throw new RangeError("unexpected base");this.m_fractionalDividers.push(2),this.m_fractionalDividers.push(2.5),i/=5}if(this.m_fractionalDividers.length>100)throw Error("something wrong with base")}}function r(t,e,i){this.m_marks=[],this.m_base=e,this.m_priceScale=t,this._formatter=i,i&&(this._cache=new h(function(t){return i.format(t)})),this._currentFormatBase=0}function s(t){for(var e=1;t*e!==Math.round(t*e);)e*=10;return e}function a(t,i){function n(){var t,e,i=s.m_dataSources;for(t=0;tn+r&&c.greaterOrEqual(s,n,r)&&c.greaterOrEqual(s,i*o,r)&&c.greaterOrEqual(s,1,r);++a,o=this.m_integralDividers[a%this.m_integralDividers.length])s/=o;if(s<=n+r&&(s=n),s=Math.max(1,s),this.m_fractionalDividers.length>0&&c.equal(s,1,r))for(a=0,o=this.m_fractionalDividers[0];s>n+r&&c.greaterOrEqual(s,i*o,r);++a,o=this.m_fractionalDividers[a%this.m_fractionalDividers.length])s/=o;return s},r.prototype.TICK_DENSITY=2.5,r.prototype.base=function(){return this.m_base},r.prototype.setBase=function(t){if(t<0)throw new RangeError("base < 0");this.m_base=t}, -r.prototype.fontHeight=function(){return this.m_priceScale.fontSize()},r.prototype.tickSpan=function(t,e){var i,o,r,s,a,l,h;if(t=e?1:-1,n=Math.max(i,e),r=Math.min(i,e),i=n,e=r,i!==e)for(a=this.tickSpan(i,e),l=i%a,l+=l<0?a:0,this.m_marks=[],this._formatter||(c=s(a),this._cache&&this._currentFormatBase===c||(u=new f(c),this._cache=new h(function(t){return u.format(t)}))),d=null,p=i-l;p>e;p-=a)_=this.m_priceScale.priceToCoordinate(p),null!==d&&Math.abs(_-d)30)throw new RangeError("invalid margin");this.m_topMargin!==t&&(this.m_topMargin=t,this._invalidateInternalHeightCache(),this._marksCache=null)},a.prototype.bottomMargin=function(){return Math.max(this.m_bottomMargin,this._studyBottomMargin)},a.prototype.setBottomMargin=function(t){if(!isNumber(t))throw new TypeError("invalid margin");if(t<0||t>30)throw new RangeError("invalid margin");this.m_bottomMargin!==t&&(this.m_bottomMargin=t,this._invalidateInternalHeightCache(),this._marksCache=null)},a.prototype.internalHeight=function(){if(this._internalHeightCache)return this._internalHeightCache;var t=this.height()*(1-this.topMargin()-this.bottomMargin());return this._internalHeightCache=t,t},a.prototype._invalidateInternalHeightCache=function(){this._internalHeightCache=null,this._internalHeightChanged.fire()}, -a.prototype.internalHeightChanged=function(){return this._internalHeightChanged},a.prototype.priceRange=function(){return this.makeSureItIsValid(),this.m_priceRange},a.prototype.priceRangeChanged=function(){return this._priceRangeChanged},a.prototype.setPriceRange=function(t,e,i){var o,n,r;if(!(t instanceof g))throw new TypeError("incorrect price range");return o=this.m_priceRange,!!(e||null===o&&null!==t||null!==o&&!o.equals(t))&&(n=null!==this.m_maxPriceRange&&this.m_maxPriceRange.containsStrictly(t),r=null!==this.m_minPriceRange&&t.containsStrictly(this.m_minPriceRange),!(this.isLockScale()&&!e&&(n||r))&&(this._marksCache=null,this.m_priceRange=t,void(i||this._priceRangeChanged.fire(o,t))))},a.prototype.isEmpty=function(){return this.makeSureItIsValid(),0===this.m_height||!this.m_priceRange||this.m_priceRange.isEmpty()},a.prototype.invertedCoordinate=function(t){return this.height()-1-t},a._logicalOffset=4,a._coordOffset=1e-4,a.prototype.log10=function(t){return Math.log(t)/Math.log(10)},a.prototype._toLog=function(t){var e,i=Math.abs(t);return i<1e-8?0:(e=this.log10(i+a._coordOffset)+a._logicalOffset,t<0?-e:e)},a.prototype.priceToLogical=function(t){return this.isLog()&&t?this._toLog(t):t},a.prototype._fromLog=function(t){var e,i=Math.abs(t);return i<1e-8?0:(e=Math.pow(10,i-a._logicalOffset)-a._coordOffset,t<0?-e:e)},a.prototype.logicalToPrice=function(t){return this.isLog()?this._fromLog(t):t},a.prototype.priceToCoordinate=function(t,e){var i,o;return this.makeSureItIsValid(),this.isEmpty()?0:(t=this.priceToLogical(t),i=this.bottomMargin()*this.height()+(this.internalHeight()-1)*(t-this.priceRange().minValue())/(this.priceRange().maxValue()-this.priceRange().minValue()),o=this.invertedCoordinate(i),e?o:Math.round(o))},a.prototype.pricesToCoordinates=function(t){this.pricesToCoordinatesEx(t,function(t){return t.y},function(t,e){t.y=e})},a.prototype.pricesToCoordinatesEx=function(t,e,i){var o,n,r,s,a,l,c,h,u;if(this.makeSureItIsValid(),o=this.bottomMargin()*this.height(),n=this.priceRange().minValue(),r=this.priceRange().maxValue(),s=this.internalHeight()-1,a=s/(r-n),this.isLog())for(l=0;l.01||Math.abs(i-this._studyTopMargin)>.01)&&(this._studyBottomMargin=o,this._studyTopMargin=i,this._marksCache=null,this._invalidateInternalHeightCache()),t?(t.minValue()===t.maxValue()&&(t=new g(t.minValue()-.5,t.maxValue()+.5)),this.setPriceRange(t)):this.m_priceRange||this.setPriceRange(new g(-.5,.5)),this._invalidatedForRange.isValid=!0}},a.prototype.sourcesToUpdateViews=function(){var t,e;if(!this._sourcesToUpdateViews)for(this._sourcesToUpdateViews=[],t=0;t6&&(t.textAlign="center",t.textBaseline="middle",t.font="bold "+e.labelFontSize+"px Arial",t.fillStyle=e.labelFontColor,t.fillText(e.label,e.x,e.y))},n.prototype.hitTest=function(t){var e,i;for(i=this._plates.length-1;i>=0;--i)if(e=this._hitTestDot(this._plates[i],t))return e;return null},n.prototype._hitTestDot=function(t,e){var i=this._dotTransform(t),o=new s(i.x,i.y);return a(e,o,Math.max(i.radius,8))?new l(l.REGULAR,t):null},r.prototype._createLayout=function(){throw Error("Child class must override this member")},r.prototype._updatePlate=function(t){throw Error("Child class must override this member")},r.prototype._getContainer=function(t){return this._container&&this._context===t||(this._context=t,this._container=$(t.canvas).parent()),this._container},r.prototype._plateArrowSize=14,r.prototype.showPlate=function(t,e){var i,o,n,r,s,a,l,c;this._currentId===t.id&&this._layout&&0!==this._layout.length&&null!=this._layout[0].parentNode||(this._currentId=t.id,this._createLayout(),this._getContainer(e).append(this._layout),i=this,this._layout.hover(function(){i.tooltipHovered=!0,$(this).stop(!0).fadeTo(0,1)},function(){i.tooltipHovered=!1})),o=Math.round(t.barWidth/2),o>15&&(o=15),o<10&&(o=10),this._updatePlate(t),n=e.canvas.getBoundingClientRect(),r=t.x-this._layout.outerWidth()=o.Std.max(l,c),a-.5*l+.25*h,o.Std.iff(l>=o.Std.max(a,c),l-.5*a+.25*h,c+.25*h));return o.Std.iff(0===d,0,(s-s.get(1)+.5*(s-i)+.25*(s.get(1)-i.get(1)))/d*u/t*50)},this.f_1=function(t,e){var i=this.f_0(t,e);return o.Std.cum(i,e)},this.main=function(t,e){var i,o;return this._context=t,this._input=e,i=this._input(0),o=this.f_1(i,this._context),[o]}}},{name:"Advance/Decline",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,inputs:{in_0:10}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Advance/Decline",shortDescription:"AD", -is_price_study:!1,inputs:[{id:"in_0",name:"length",defval:10,type:"integer",min:1,max:2e3}],id:"Advance/Decline@tv-basicstudies-1",scriptIdPart:"",name:"Advance/Decline"},constructor:function(){this.f_0=function(t,e){return o.Std.gt(t,e)},this.f_1=function(t,e){return o.Std.lt(t,e)},this.f_2=function(t,e){return 0===e?t:t/e},this.main=function(t,e){var i,n,r,s,a,l,c,h,u;return this._context=t,this._input=e,i=this._input(0),n=this.f_0(o.Std.close(this._context),o.Std.open(this._context)),r=this._context.new_var(n),s=o.Std.sum(r,i,this._context),a=this.f_1(o.Std.close(this._context),o.Std.open(this._context)),l=this._context.new_var(a),c=o.Std.sum(l,i,this._context),h=this.f_2(s,c),u=h,[u]}}},{name:"Arnaud Legoux Moving Average",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#000080"}},precision:4,inputs:{in_0:9,in_1:.85,in_2:6}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Arnaud Legoux Moving Average",shortDescription:"ALMA",is_price_study:!0,inputs:[{id:"in_0",name:"Window Size",defval:9,type:"integer",min:0,max:5e3},{id:"in_1",name:"Offset",defval:.85,type:"float",min:-1e12,max:1e12},{id:"in_2",name:"Sigma",defval:6,type:"float",min:-1e12,max:1e12}],id:"Arnaud Legoux Moving Average@tv-basicstudies-1",scriptIdPart:"",name:"Arnaud Legoux Moving Average"},constructor:function(){this.main=function(t,e){var i,n,r,s,a,l;return this._context=t,this._input=e,i=o.Std.close(this._context),n=this._input(0),r=this._input(1),s=this._input(2),a=this._context.new_var(i),l=o.Std.alma(a,n,r,s),[l]}}},{name:"Aroon",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF6A00"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0094FF"}},precision:4,inputs:{in_0:14}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"}],styles:{plot_0:{title:"Upper",histogramBase:0,joinPoints:!1},plot_1:{title:"Lower",histogramBase:0,joinPoints:!1}},description:"Aroon",shortDescription:"Aroon",is_price_study:!1,inputs:[{id:"in_0",name:"length",defval:14,type:"integer",min:1,max:2e3}],id:"Aroon@tv-basicstudies-1",scriptIdPart:"",name:"Aroon"},constructor:function(){this.f_0=function(t,e){return 100*(t+e)/e},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_;return this._context=t,this._input=e,i=this._input(0),n=o.Std.high(this._context),r=i+1,s=this._context.new_var(n),a=o.Std.highestbars(s,r,this._context),l=this.f_0(a,i),c=o.Std.low(this._context),h=this._context.new_var(c),u=o.Std.lowestbars(h,r,this._context),d=this.f_0(u,i),p=l,_=d,[p,_]}}},{name:"Average Directional Index",metainfo:{_metainfoVersion:41,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0, -color:"#FF0000"}},precision:4,inputs:{in_0:14,in_1:14}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"ADX",histogramBase:0,joinPoints:!1,isHidden:!1}},description:"Average Directional Index",shortDescription:"ADX",is_price_study:!1,inputs:[{id:"in_0",name:"ADX Smoothing",defval:14,type:"integer",min:-1e12,max:1e12},{id:"in_1",name:"DI Length",defval:14,type:"integer",min:-1e12,max:1e12}],id:"average_directional_Index@tv-basicstudies-1",scriptIdPart:"",name:"Average Directional Index"},constructor:function(){this.f_0=function(t){var e=this._context.new_var(o.Std.high(this._context)),i=o.Std.change(e),n=this._context.new_var(o.Std.low(this._context)),r=-o.Std.change(n),s=this._context.new_var(o.Std.tr(void 0,this._context)),a=o.Std.rma(s,t,this._context),l=this._context.new_var(o.Std.and(o.Std.gt(i,r),o.Std.gt(i,0))?i:0),c=o.Std.fixnan(100*o.Std.rma(l,t,this._context)/a,this._context),h=this._context.new_var(o.Std.and(o.Std.gt(r,i),o.Std.gt(r,0))?r:0);return[c,o.Std.fixnan(100*o.Std.rma(h,t,this._context)/a,this._context)]},this.f_1=function(t,e){var i=this.f_0(t),n=i[0],r=i[1],s=n+r,a=this._context.new_var(o.Std.abs(n-r)/(o.Std.eq(s,0)?1:s));return[100*o.Std.rma(a,e,this._context)]},this.main=function(t,e){return this._context=t,this._input=e,this.f_1(this._input(0),this._input(1))}}},{name:"Average True Range",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,inputs:{in_0:14}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Average True Range",shortDescription:"ATR",is_price_study:!1,inputs:[{id:"in_0",name:"length",defval:14,type:"integer",min:1,max:2e3}],id:"Average True Range@tv-basicstudies-1",scriptIdPart:"",name:"Average True Range"},constructor:function(){this.main=function(t,e){var i,n,r,s;return this._context=t,this._input=e,i=this._input(0),n=o.Std.tr(this._context),r=this._context.new_var(n),s=o.Std.rma(r,i,this._context),[s]}}},{name:"Awesome Oscillator",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:1,trackPrice:!1,transparency:35,visible:!0,color:"#000080"}},precision:4,palettes:{palette_0:{colors:{0:{color:"#FF0000",width:1,style:0},1:{color:"#008000",width:1,style:0}}}},inputs:{}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",palette:"palette_0",target:"plot_0",type:"colorer"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Awesome Oscillator",shortDescription:"AO",is_price_study:!1,palettes:{palette_0:{colors:{0:{name:"Color 0"},1:{name:"Color 1"}}}},inputs:[],id:"Awesome Oscillator@tv-basicstudies-1",scriptIdPart:"",name:"Awesome Oscillator"},constructor:function(){this.f_0=function(t,e){return t-e},this.f_1=function(t){return o.Std.le(t,0)?0:1},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d;return this._context=t,this._input=e, -i=o.Std.hl2(this._context),n=this._context.new_var(i),r=o.Std.sma(n,5,this._context),s=this._context.new_var(i),a=o.Std.sma(s,34,this._context),l=this.f_0(r,a),c=l,h=this._context.new_var(l),u=o.Std.change(h),d=this.f_1(u),[c,d]}}},{name:"Balance of Power",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,inputs:{}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Balance of Power",shortDescription:"Balance of Power",is_price_study:!1,inputs:[],id:"Balance of Power@tv-basicstudies-1",scriptIdPart:"",name:"Balance of Power"},constructor:function(){this.f_0=function(t,e,i,o){return(t-e)/(i-o)},this.main=function(t,e){return this._context=t,this._input=e,[this.f_0(o.Std.close(this._context),o.Std.open(this._context),o.Std.high(this._context),o.Std.low(this._context))]}}},{name:"Bollinger Bands",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"},plot_2:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}},precision:4,filledAreasStyle:{fill_0:{color:"#000080",transparency:90,visible:!0}},inputs:{in_0:20,in_1:2}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"},{id:"plot_2",type:"line"}],styles:{plot_0:{title:"Median",histogramBase:0,joinPoints:!1},plot_1:{title:"Upper",histogramBase:0,joinPoints:!1},plot_2:{title:"Lower",histogramBase:0,joinPoints:!1}},description:"Bollinger Bands",shortDescription:"BB",is_price_study:!0,filledAreas:[{id:"fill_0",objAId:"plot_1",objBId:"plot_2",type:"plot_plot",title:"Plots Background"}],inputs:[{id:"in_0",name:"length",defval:20,type:"integer",min:1,max:1e4},{id:"in_1",name:"mult",defval:2,type:"float",min:.001,max:50}],id:"Bollinger Bands@tv-basicstudies-1",scriptIdPart:"",name:"Bollinger Bands"},constructor:function(){this.f_0=function(t,e){return t*e},this.f_1=function(t,e){return t+e},this.f_2=function(t,e){return t-e},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_,f;return this._context=t,this._input=e,i=o.Std.close(this._context),n=this._input(0),r=this._input(1),s=this._context.new_var(i),a=o.Std.sma(s,n,this._context),l=this._context.new_var(i),c=o.Std.stdev(l,n,this._context),h=this.f_0(r,c),u=this.f_1(a,h),d=this.f_2(a,h),p=a,_=u,f=d,[p,_,f]}}},{name:"Bollinger Bands %B",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#008080"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:1},{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:0}],filledAreasStyle:{fill_0:{color:"#008080", -transparency:90,visible:!0}},inputs:{in_0:20,in_1:2}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Bollinger Bands %B",shortDescription:"BB %B",is_price_study:!1,bands:[{id:"hline_0",name:"UpperLimit"},{id:"hline_1",name:"LowerLimit"}],filledAreas:[{id:"fill_0",objAId:"hline_0",objBId:"hline_1",type:"hline_hline",title:"Hlines Background"}],inputs:[{id:"in_0",name:"length",defval:20,type:"integer",min:1,max:1e4},{id:"in_1",name:"mult",defval:2,type:"float",min:.001,max:50}],id:"Bollinger Bands %B@tv-basicstudies-1",scriptIdPart:"",name:"Bollinger Bands %B"},constructor:function(){this.f_0=function(t,e){return t*e},this.f_1=function(t,e){return t+e},this.f_2=function(t,e){return t-e},this.f_3=function(t,e,i){return(t-e)/(i-e)},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_;return this._context=t,this._input=e,i=o.Std.close(this._context),n=this._input(0),r=this._input(1),s=this._context.new_var(i),a=o.Std.sma(s,n,this._context),l=this._context.new_var(i),c=o.Std.stdev(l,n,this._context),h=this.f_0(r,c),u=this.f_1(a,h),d=this.f_2(a,h),p=this.f_3(i,d,u),_=p,[_]}}},{name:"Bollinger Bands Width",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}},precision:4,inputs:{in_0:20,in_1:2}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Bollinger Bands Width",shortDescription:"BBW",is_price_study:!1,inputs:[{id:"in_0",name:"length",defval:20,type:"integer",min:1,max:1e4},{id:"in_1",name:"mult",defval:2,type:"float",min:.001,max:50}],id:"Bollinger Bands Width@tv-basicstudies-1",scriptIdPart:"",name:"Bollinger Bands Width"},constructor:function(){this.f_0=function(t,e){return t*e},this.f_1=function(t,e){return t+e},this.f_2=function(t,e){return t-e},this.f_3=function(t,e,i){return(t-e)/i},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_;return this._context=t,this._input=e,i=o.Std.close(this._context),n=this._input(0),r=this._input(1),s=this._context.new_var(i),a=o.Std.sma(s,n,this._context),l=this._context.new_var(i),c=o.Std.stdev(l,n,this._context),h=this.f_0(r,c),u=this.f_1(a,h),d=this.f_2(a,h),p=this.f_3(u,d,a),_=p,[_]}}},{name:"Chaikin Money Flow",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#008000"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:0}],inputs:{in_0:20}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Chaikin Money Flow",shortDescription:"CMF",is_price_study:!1,bands:[{id:"hline_0",name:"Zero"}],inputs:[{id:"in_0",name:"length",defval:20,type:"integer",min:1,max:2e3}],id:"Chaikin Money Flow@tv-basicstudies-1",scriptIdPart:"",name:"Chaikin Money Flow"},constructor:function(){this.f_0=function(t,e,i,n){ -return o.Std.or(o.Std.and(o.Std.eq(t,e),o.Std.eq(t,i)),o.Std.eq(e,i))?0:(2*t-i-e)/(e-i)*n},this.f_1=function(t,e){return t/e},this.main=function(t,e){var i,n,r,s,a,l,c,h,u;return this._context=t,this._input=e,i=this._input(0),n=this.f_0(o.Std.close(this._context),o.Std.high(this._context),o.Std.low(this._context),o.Std.volume(this._context)),r=this._context.new_var(n),s=o.Std.sum(r,i,this._context),a=o.Std.volume(this._context),l=this._context.new_var(a),c=o.Std.sum(l,i,this._context),h=this.f_1(s,c),u=h,[u]}}},{name:"Chaikin Oscillator",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:0}],inputs:{in_0:3,in_1:10}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Chaikin Oscillator",shortDescription:"Chaikin Osc",is_price_study:!1,bands:[{id:"hline_0",name:"Zero"}],inputs:[{id:"in_0",name:"short",defval:3,type:"integer",min:1,max:2e3},{id:"in_1",name:"long",defval:10,type:"integer",min:1,max:2e3}],id:"Chaikin Oscillator@tv-basicstudies-1",scriptIdPart:"",name:"Chaikin Oscillator"},constructor:function(){this.f_0=function(t,e){return t-e},this.main=function(t,e){var i,n,r,s,a,l,c,h,u;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=o.Std.accdist(this._context),s=this._context.new_var(r),a=o.Std.ema(s,i,this._context),l=this._context.new_var(r),c=o.Std.ema(l,n,this._context),h=this.f_0(a,c),u=h,[u]}}},{name:"Chande Kroll Stop",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#008000"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,inputs:{in_0:10,in_1:1,in_2:9}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"}],styles:{plot_0:{title:"Long",histogramBase:0,joinPoints:!1},plot_1:{title:"Short",histogramBase:0,joinPoints:!1}},description:"Chande Kroll Stop",shortDescription:"Chande Kroll Stop",is_price_study:!0,inputs:[{id:"in_0",name:"p",defval:10,type:"integer",min:1,max:4999},{id:"in_1",name:"x",defval:1,type:"integer",min:1,max:1e12},{id:"in_2",name:"q",defval:9,type:"integer",min:1,max:1e12}],id:"Chande Kroll Stop@tv-basicstudies-1",scriptIdPart:"",name:"Chande Kroll Stop"},constructor:function(){this.f_0=function(t,e,i){return t-e*i},this.f_1=function(t,e,i){return t+e*i},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_,f,m,g,v,y;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=this._input(2),s=o.Std.high(this._context),a=this._context.new_var(s),l=o.Std.highest(a,i,this._context),c=o.Std.atr(i,this._context),h=this.f_0(l,n,c),u=this._context.new_var(s),d=o.Std.lowest(u,i,this._context),p=this.f_1(d,n,c),_=this._context.new_var(h),f=o.Std.highest(_,r,this._context), -m=this._context.new_var(p),g=o.Std.lowest(m,r,this._context),v=g,y=f,[v,y]}}},{name:"Chande Momentum Oscillator",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#008080"}},precision:4,inputs:{in_0:9}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Chande Momentum Oscillator",shortDescription:"ChandeMO",is_price_study:!1,inputs:[{id:"in_0",name:"length",defval:9,type:"integer",min:1,max:2e3}],id:"Chande Momentum Oscillator@tv-basicstudies-1",scriptIdPart:"",name:"Chande Momentum Oscillator"},constructor:function(){this.f_0=function(t){return o.Std.ge(t,0)?t:0},this.f_1=function(t){return o.Std.ge(t,0)?0:-t},this.f_2=function(t,e){return 100*t/e},this.f_3=function(t,e){return this.f_2(t-e,t+e)},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_;return this._context=t,this._input=e,i=this._input(0),n=o.Std.close(this._context),r=this._context.new_var(n),s=o.Std.change(r),a=this.f_0(s),l=this.f_1(s),c=this._context.new_var(a),h=o.Std.sum(c,i,this._context),u=this._context.new_var(l),d=o.Std.sum(u,i,this._context),p=this.f_3(h,d),_=p,[_]}}},{name:"Chop Zone",metainfo:{_metainfoVersion:41,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:5,trackPrice:!1,transparency:35,visible:!0,color:"#000080"}},precision:4,palettes:{palette_0:{colors:{0:{color:"#34dddd",width:1,style:0},1:{color:"#006400",width:1,style:0},2:{color:"#98fb98",width:1,style:0},3:{color:"#00FF00",width:1,style:0},4:{color:"#8B0000",width:1,style:0},5:{color:"#FF0000",width:1,style:0},6:{color:"#FF7F00",width:1,style:0},7:{color:"#ffc04c",width:1,style:0},8:{color:"#FFFF00",width:1,style:0}}}},inputs:{}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",palette:"palette_0",target:"plot_0",type:"colorer"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1,isHidden:!1}},description:"Chop Zone",shortDescription:"Chop Zone",is_price_study:!1,palettes:{palette_0:{colors:{0:{name:"Color 0"},1:{name:"Color 1"},2:{name:"Color 2"},3:{name:"Color 3"},4:{name:"Color 4"},5:{name:"Color 5"},6:{name:"Color 6"},7:{name:"Color 7"},8:{name:"Color 8"}},valToIndex:{0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8}}},inputs:[],id:"chop_zone@tv-basicstudies-1",scriptIdPart:"",name:"Chop Zone"},constructor:function(){this.f_0=function(){ -var t=o.Std.close(this._context),e=o.Std.hlc3(this._context),i=this._context.new_var(o.Std.high(this._context)),n=o.Std.highest(i,30,this._context),r=o.Std.lowest(i,30,this._context),s=25/(n-r)*r,a=this._context.new_var(t),l=this._context.new_var(o.Std.ema(a,34,this._context)),c=(l.get(1)-l.get(0))/e*s,h=o.Std.sqrt(1+c*c),u=o.Std.round(180*o.Std.acos(1/h)/3.141592653589793),d=o.Std.iff(o.Std.gt(c,0),-u,u),p=o.Std.and(o.Std.gt(d,-2.14),o.Std.le(d,-.71))?7:8,_=o.Std.and(o.Std.gt(d,-3.57),o.Std.le(d,-2.14))?6:p,f=o.Std.and(o.Std.gt(d,-5),o.Std.le(d,-3.57))?5:_,m=o.Std.le(d,-5)?4:f,g=o.Std.and(o.Std.lt(d,2.14),o.Std.ge(d,.71))?3:m,v=o.Std.and(o.Std.lt(d,3.57),o.Std.ge(d,2.14))?2:g,y=o.Std.and(o.Std.lt(d,5),o.Std.ge(d,3.57))?1:v;return[1,o.Std.ge(d,5)?0:y]},this.main=function(t,e){return this._context=t,this._input=e,this.f_0()}}},{name:"Choppiness Index",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:61.8},{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:38.2}],filledAreasStyle:{fill_0:{color:"#008000",transparency:90,visible:!0}},inputs:{in_0:14}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Choppiness Index",shortDescription:"CHOP",is_price_study:!1,bands:[{id:"hline_0",name:"UpperLimit"},{id:"hline_1",name:"LowerLimit"}],filledAreas:[{id:"fill_0",objAId:"hline_0",objBId:"hline_1",type:"hline_hline",title:"Hlines Background"}],inputs:[{id:"in_0",name:"length",defval:14,type:"integer",min:1,max:2e3}],id:"Choppiness Index@tv-basicstudies-1",scriptIdPart:"",name:"Choppiness Index"},constructor:function(){this.f_0=function(t,e,i,n){return 100*o.Std.log10(t/(e-i))/n},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_,f;return this._context=t,this._input=e,i=this._input(0),n=o.Std.atr(1,this._context),r=this._context.new_var(n),s=o.Std.sum(r,i,this._context),a=o.Std.high(this._context),l=this._context.new_var(a),c=o.Std.highest(l,i,this._context),h=o.Std.low(this._context),u=this._context.new_var(h),d=o.Std.lowest(u,i,this._context),p=o.Std.log10(i),_=this.f_0(s,c,d,p),f=_,[f]}}},{name:"Commodity Channel Index",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#808000"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:100},{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:-100}],filledAreasStyle:{fill_0:{color:"#808000",transparency:90,visible:!0}},inputs:{in_0:20}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Commodity Channel Index",shortDescription:"CCI",is_price_study:!1,bands:[{id:"hline_0",name:"UpperLimit"},{id:"hline_1",name:"LowerLimit"}],filledAreas:[{id:"fill_0",objAId:"hline_0", -objBId:"hline_1",type:"hline_hline",title:"Hlines Background"}],inputs:[{id:"in_0",name:"length",defval:20,type:"integer",min:1,max:2e3}],id:"Commodity Channel Index@tv-basicstudies-1",scriptIdPart:"",name:"Commodity Channel Index"},constructor:function(){this.f_0=function(t,e,i){return(t-e)/(.015*i)},this.main=function(t,e){var i,n,r,s,a,l,c,h;return this._context=t,this._input=e,i=o.Std.hlc3(this._context),n=this._input(0),r=this._context.new_var(i),s=o.Std.sma(r,n,this._context),a=this._context.new_var(i),l=o.Std.dev(a,n,this._context),c=this.f_0(i,s,l),h=c,[h]}}},{name:"Connors RSI",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#800080"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:70},{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:30}],filledAreasStyle:{fill_0:{color:"#800080",transparency:90,visible:!0}},inputs:{in_0:3,in_1:2,in_2:100}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"CRSI",histogramBase:0,joinPoints:!1}},description:"Connors RSI",shortDescription:"CRSI",is_price_study:!1,bands:[{id:"hline_0",name:"UpperLimit"},{id:"hline_1",name:"LowerLimit"}],filledAreas:[{id:"fill_0",objAId:"hline_0",objBId:"hline_1",type:"hline_hline",title:"Hlines Background"}],inputs:[{id:"in_0",name:"RSI Length",defval:3,type:"integer",min:1},{id:"in_1",name:"UpDown Length",defval:2,type:"integer",min:1},{id:"in_2",name:"ROC Length",defval:100,type:"integer",min:1}],id:"Connors RSI@tv-basicstudies-1",scriptIdPart:"",name:"Connors RSI"},constructor:function(){this.f_1=function(t,e,i){var n=i.new_var(o.Std.max(o.Std.change(t),0));return o.Std.rma(n,e,i)},this.f_2=function(t,e,i){var n=i.new_var(-o.Std.min(o.Std.change(t),0));return o.Std.rma(n,e,i)},this.f_3=function(){var t=0;return function(e){var i=e.get(0),n=e.get(1);return t=i===n?0:i>n?o.Std.nz(t)<=0?1:o.Std.nz(t)+1:o.Std.nz(t)>=0?-1:o.Std.nz(t)-1,this._context.new_var(t)}}(),this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p;return this._context=t,this._input=e,i=o.Std.close(this._context),n=this._context.new_var(i),r=this._input(0),s=this._input(1),a=this._input(2),l=o.Std.rsi(this.f_1(n,r,this._context),this.f_2(n,r,this._context)),c=this.f_3(n),h=o.Std.rsi(this.f_1(c,s,this._context),this.f_2(c,s,this._context)),u=this._context.new_var(o.Std.roc(n,1)),d=o.Std.percentrank(u,a),p=o.Std.avg(l,h,d),[p]}}},{name:"Coppock Curve",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#000080"}},precision:4,inputs:{in_0:10,in_1:14,in_2:11}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Coppock Curve",shortDescription:"Coppock Curve",is_price_study:!1,inputs:[{id:"in_0",name:"WMA Length",defval:10,type:"integer",min:-1e12,max:5e3},{id:"in_1",name:"Long RoC Length",defval:14, -type:"integer",min:1,max:4999},{id:"in_2",name:"Short RoC Length",defval:11,type:"integer",min:1,max:4999}],id:"Coppock Curve@tv-basicstudies-1",scriptIdPart:"",name:"Coppock Curve"},constructor:function(){this.f_0=function(t,e){return t+e},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=this._input(2),s=o.Std.close(this._context),a=this._context.new_var(s),l=o.Std.roc(a,n),c=this._context.new_var(s),h=o.Std.roc(c,r),u=this.f_0(l,h),d=this._context.new_var(u),p=o.Std.wma(d,i,this._context),_=p,[_]}}},{name:"Correlation Coeff",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:4,trackPrice:!1,transparency:40,visible:!0,color:"#800080"}},precision:4,inputs:{in_0:"AAPL",in_1:20}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Correlation Coefficient",shortDescription:"CC",is_price_study:!1,inputs:[{id:"in_0",name:"sym",defval:"AAPL",type:"symbol"},{id:"in_1",name:"length",defval:20,type:"integer",min:1,max:2e3}],id:"Correlation Coeff@tv-basicstudies-1",scriptIdPart:"",name:"Correlation Coeff"},constructor:function(){this.init=function(t,e){this._context=t,this._input=e,this._context.new_sym(this._input(0),o.Std.period(this._context),o.Std.period(this._context))},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d;return this._context=t,this._input=e,i=this._context.new_var(this._context.symbol.time),this._input(0),o.Std.period(this._context),n=o.Std.close(this._context),r=this._input(1),this._context.select_sym(1),s=this._context.new_var(this._context.symbol.time),a=o.Std.close(this._context),l=this._context.new_var(a),this._context.select_sym(0),c=l.adopt(s,i,0),h=this._context.new_var(n),u=this._context.new_var(c),d=o.Std.correlation(h,u,r,this._context),[d]}}},{name:"Detrended Price Oscillator",metainfo:{_metainfoVersion:42,isTVScript:!1,isTVScriptStub:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#808000"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:0}],inputs:{in_0:21,in_1:!1}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"DPO",histogramBase:0,joinPoints:!1,isHidden:!1}},description:"Detrended Price Oscillator",shortDescription:"DPO",is_price_study:!1,is_hidden_study:!1,id:"detrended_price_oscillator@tv-basicstudies-1",bands:[{id:"hline_0",name:"Zero",isHidden:!1}],inputs:[{id:"in_0",name:"Period",defval:21,type:"integer",min:1,max:1e12},{id:"in_1",name:"isCentered",defval:!1,type:"bool"}],scriptIdPart:"",name:"Detrended Price Oscillator"},constructor:function(){this.f_0=function(){var t=this._input(0),e=this._input(1),i=Math.floor(t/2+1),n=this._context.new_var(o.Std.close(this._context)),r=this._context.new_var(o.Std.sma(n,t,this._context)),s=this._context.new_var(o.Std.close(this._context)),a=s.get(i)-r,l=o.Std.close(this._context)-r.get(i),c=e?a:l,h=-i;return[c,e?h:0]}, -this.main=function(t,e){this._context=t,this._input=e;var i=this.f_0();return[{value:i[0],offset:i[1]}]}}},{name:"Directional Movement Index",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF7F00"},plot_2:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,inputs:{in_0:14,in_1:14}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"},{id:"plot_2",type:"line"}],styles:{plot_0:{title:"+DI",histogramBase:0,joinPoints:!1},plot_1:{title:"-DI",histogramBase:0,joinPoints:!1},plot_2:{title:"ADX",histogramBase:0,joinPoints:!1}},description:"Directional Movement",shortDescription:"DMI",is_price_study:!1,inputs:[{id:"in_0",name:"DI Length",defval:14,type:"integer",min:1,max:2e3},{id:"in_1",name:"ADX Smoothing",defval:14,type:"integer",min:1,max:50}],id:"Directional Movement Index@tv-basicstudies-1",scriptIdPart:"",name:"Directional Movement Index"},constructor:function(){this.f_0=function(t){return-t},this.f_1=function(t,e){return o.Std.and(o.Std.gt(t,e),o.Std.gt(t,0))?t:0},this.f_2=function(t,e){return 100*t/e},this.f_3=function(t,e){return t+e},this.f_4=function(t,e,i){return o.Std.abs(t-e)/(o.Std.eq(i,0)?1:i)},this.f_5=function(t){return 100*t},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_,f,m,g,v,y,b,S,w,T,C,x,P,L,I,k,A,M,E;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=o.Std.high(this._context),s=this._context.new_var(r),a=o.Std.change(s),l=o.Std.low(this._context),c=this._context.new_var(l),h=o.Std.change(c),u=this.f_0(h),d=o.Std.tr(this._context),p=this._context.new_var(d),_=o.Std.rma(p,i,this._context),f=this.f_1(a,u),m=this._context.new_var(f),g=o.Std.rma(m,i,this._context),v=this.f_2(g,_),y=o.Std.fixnan(v,this._context),b=this.f_1(u,a),S=this._context.new_var(b),w=o.Std.rma(S,i,this._context),T=this.f_2(w,_),C=o.Std.fixnan(T,this._context),x=this.f_3(y,C),P=this.f_4(y,C,x),L=this._context.new_var(P),I=o.Std.rma(L,n,this._context),k=this.f_5(I),A=y,M=C,E=k,[A,M,E]}}},{name:"Donchian Channels",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"},plot_2:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF7F00"}},precision:4,filledAreasStyle:{fill_0:{color:"#0000FF",transparency:90,visible:!0}},inputs:{in_0:20}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"},{id:"plot_2",type:"line"}],styles:{plot_0:{title:"Lower",histogramBase:0,joinPoints:!1},plot_1:{title:"Upper",histogramBase:0,joinPoints:!1},plot_2:{title:"Basis",histogramBase:0,joinPoints:!1}},description:"Donchian Channels", -shortDescription:"DC",is_price_study:!0,filledAreas:[{id:"fill_0",objAId:"plot_1",objBId:"plot_0",type:"plot_plot",title:"Plots Background"}],inputs:[{id:"in_0",name:"length",defval:20,type:"integer",min:1,max:2e3}],id:"Donchian Channels@tv-basicstudies-1",scriptIdPart:"",name:"Donchian Channels"},constructor:function(){this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p;return this._context=t,this._input=e,i=this._input(0),n=o.Std.low(this._context),r=this._context.new_var(n),s=o.Std.lowest(r,i,this._context),a=o.Std.high(this._context),l=this._context.new_var(a),c=o.Std.highest(l,i,this._context),h=o.Std.avg(c,s),u=s,d=c,p=h,[u,d,p]}}},{name:"Double Exponential Moving Average",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#008000"}},precision:4,inputs:{in_0:9}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Double EMA",shortDescription:"DEMA",is_price_study:!0,inputs:[{id:"in_0",name:"length",defval:9,type:"integer",min:1,max:1e4}],id:"Double Exponential Moving Average@tv-basicstudies-1",scriptIdPart:"",name:"Double Exponential Moving Average"},constructor:function(){this.f_0=function(t,e){return 2*t-e},this.main=function(t,e){var i,n,r,s,a,l,c,h;return this._context=t,this._input=e,i=this._input(0),n=o.Std.close(this._context),r=this._context.new_var(n),s=o.Std.ema(r,i,this._context),a=this._context.new_var(s),l=o.Std.ema(a,i,this._context),c=this.f_0(s,l),h=c,[h]}}},{name:"Ease of Movement",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#808000"}},precision:4,inputs:{in_0:1e4,in_1:14}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Ease Of Movement",shortDescription:"EOM",is_price_study:!1,inputs:[{id:"in_0",name:"Divisor",defval:1e4,type:"integer",min:1,max:1e9},{id:"in_1",name:"length",defval:14,type:"integer",min:1,max:2e3}],id:"Ease of Movement@tv-basicstudies-1",scriptIdPart:"",name:"Ease of Movement"},constructor:function(){this.f_0=function(t,e,i,o,n){return t*e*(i-o)/n},this.main=function(t,e){var i,n,r,s,a,l,c,h,u;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=o.Std.hl2(this._context),s=this._context.new_var(r),a=o.Std.change(s),l=this.f_0(i,a,o.Std.high(this._context),o.Std.low(this._context),o.Std.volume(this._context)),c=this._context.new_var(l),h=o.Std.sma(c,n,this._context),u=h,[u]}}},{name:"Elders Force Index",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#800000"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:0}],inputs:{in_0:13}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot", -histogramBase:0,joinPoints:!1}},description:"Elder's Force Index",shortDescription:"EFI",is_price_study:!1,bands:[{id:"hline_0",name:"Zero"}],inputs:[{id:"in_0",name:"length",defval:13,type:"integer",min:1,max:2e3}],id:"Elders Force Index@tv-basicstudies-1",scriptIdPart:"",name:"Elders Force Index"},constructor:function(){this.f_0=function(t,e){return t*e},this.main=function(t,e){var i,n,r,s,a,l,c,h;return this._context=t,this._input=e,i=this._input(0),n=o.Std.close(this._context),r=this._context.new_var(n),s=o.Std.change(r),a=this.f_0(s,o.Std.volume(this._context)),l=this._context.new_var(a),c=o.Std.ema(l,i,this._context),h=c,[h]}}},{name:"EMA Cross",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#008000"},plot_2:{linestyle:0,linewidth:4,plottype:3,trackPrice:!1,transparency:35,visible:!0,color:"#000080"}},precision:4,inputs:{in_0:9,in_1:26}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"},{id:"plot_2",type:"line"}],styles:{plot_0:{title:"Short",histogramBase:0,joinPoints:!1},plot_1:{title:"Long",histogramBase:0,joinPoints:!1},plot_2:{title:"Crosses",histogramBase:0,joinPoints:!1}},description:"EMA Cross",shortDescription:"EMA Cross",is_price_study:!0,inputs:[{id:"in_0",name:"Short",defval:9,type:"integer",min:1,max:2e3},{id:"in_1",name:"Long",defval:26,type:"integer",min:1,max:2e3}],id:"EMA Cross@tv-basicstudies-1",scriptIdPart:"",name:"EMA Cross"},constructor:function(){this.f_0=function(t,e){return t?e:o.Std.na()},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=o.Std.close(this._context),s=this._context.new_var(r),a=o.Std.ema(s,i,this._context),l=this._context.new_var(r),c=o.Std.ema(l,n,this._context),h=a,u=c,d=o.Std.cross(a,c,this._context),p=this.f_0(d,a),[h,u,p]}}},{name:"Envelope",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF7F00"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"},plot_2:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}},precision:4,filledAreasStyle:{fill_0:{color:"#0000FF",transparency:90,visible:!0}},inputs:{in_0:20,in_1:10,in_2:!1}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"},{id:"plot_2",type:"line"}],styles:{plot_0:{title:"Median",histogramBase:0,joinPoints:!1},plot_1:{title:"Upper",histogramBase:0,joinPoints:!1},plot_2:{title:"Lower",histogramBase:0,joinPoints:!1}},description:"Envelope",shortDescription:"Env",is_price_study:!0,filledAreas:[{id:"fill_0",objAId:"plot_1",objBId:"plot_2",type:"plot_plot",title:"Plots Background"}],inputs:[{id:"in_0",name:"Length",defval:20,type:"integer",min:1,max:2e3},{ -id:"in_1",name:"percent",defval:10,type:"float",min:-1e12,max:1e12},{id:"in_2",name:"exponential",defval:!1,type:"bool"}],id:"Envelope@tv-basicstudies-1",scriptIdPart:"",name:"Envelope"},constructor:function(){this.f_0=function(t,e,i){return t?e:i},this.f_1=function(t,e){return t*(1+e)},this.f_2=function(t,e){return t*(1-e)},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_,f,m,g;return this._context=t,this._input=e,i=o.Std.close(this._context),n=this._input(0),r=this._input(1),s=this._input(2),a=this._context.new_var(i),l=o.Std.ema(a,n,this._context),c=this._context.new_var(i),h=o.Std.sma(c,n,this._context),u=this.f_0(s,l,h),d=r/100,p=this.f_1(u,d),_=this.f_2(u,d),f=u,m=p,g=_,[f,m,g]}}},{name:"Fisher Transform",metainfo:{_metainfoVersion:41,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF7F00"}},precision:4,bands:[{color:"#FF7F00",linestyle:2,linewidth:1,visible:!0,value:1.5},{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:.75},{color:"#FF7F00",linestyle:2,linewidth:1,visible:!0,value:0},{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:-.75},{color:"#FF7F00",linestyle:2,linewidth:1,visible:!0,value:-1.5}],inputs:{in_0:9}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"}],styles:{plot_0:{title:"Fisher",histogramBase:0,joinPoints:!1,isHidden:!1},plot_1:{title:"Trigger",histogramBase:0,joinPoints:!1,isHidden:!1}},description:"Fisher Transform",shortDescription:"Fisher",is_price_study:!1,bands:[{id:"hline_0",name:"Level",isHidden:!1},{id:"hline_1",name:"Level",isHidden:!1},{id:"hline_2",name:"Level",isHidden:!1},{id:"hline_3",name:"Level",isHidden:!1},{id:"hline_4",name:"Level",isHidden:!1}],inputs:[{id:"in_0",name:"Length",defval:9,type:"integer",min:1,max:1e12}],id:"fisher_transform@tv-basicstudies-1",scriptIdPart:"",name:"Fisher Transform"},constructor:function(){this.f_0=function(t){var e=o.Std.lt(t,-.99)?-.999:t;return[o.Std.gt(t,.99)?.999:e]},this.f_1=function(){var t,e,i,n=this._input(0),r=this._context.new_var(o.Std.hl2(this._context)),s=o.Std.highest(r,n,this._context),a=this._context.new_var(o.Std.hl2(this._context)),l=o.Std.lowest(a,n,this._context),c=this._context.new_var(),h=this.f_0(.66*((o.Std.hl2(this._context)-l)/o.Std.max(s-l,.001)-.5)+.67*o.Std.nz(c.get(1)));return c.set(h[0]),t=this._context.new_var(),t.set(.5*o.Std.log((1+c.get(0))/o.Std.max(1-c.get(0),.001))+.5*o.Std.nz(t.get(1))),e=t.get(1),i=t.get(0),[i,e]},this.main=function(t,e){return this._context=t,this._input=e,this.f_1()}}},{name:"Historical Volatility",metainfo:{_metainfoVersion:41,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}},precision:4,inputs:{in_0:10}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1,isHidden:!1}}, -description:"Historical Volatility",shortDescription:"HV",is_price_study:!1,inputs:[{id:"in_0",name:"length",defval:10,type:"integer",min:1,max:1e12}],id:"historical_volatility@tv-basicstudies-1",scriptIdPart:"",name:"Historical Volatility"},constructor:function(){this.f_0=function(){var t=this._input(0),e=o.Std.or(o.Std.isintraday(this._context),o.Std.and(o.Std.isdaily(this._context),o.Std.eq(o.Std.interval(this._context),1)))?1:7,i=this._context.new_var(o.Std.close(this._context)),n=this._context.new_var(o.Std.log(o.Std.close(this._context)/i.get(1)));return[100*o.Std.stdev(n,t,this._context)*o.Std.sqrt(365/e)]},this.main=function(t,e){return this._context=t,this._input=e,this.f_0()}}},{name:"Hull MA",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#000080"}},precision:4,inputs:{in_0:9}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Hull Moving Average",shortDescription:"HMA",is_price_study:!0,inputs:[{id:"in_0",name:"length",defval:9,type:"integer",min:1,max:1e4}],id:"Hull MA@tv-basicstudies-1",scriptIdPart:"",name:"Hull MA"},constructor:function(){this.f_0=function(t,e){return 2*t-e},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_,f;return this._context=t,this._input=e,i=o.Std.close(this._context),n=this._input(0),r=n/2,s=this._context.new_var(i),a=o.Std.wma(s,r,this._context),l=this._context.new_var(i),c=o.Std.wma(l,n,this._context),h=this.f_0(a,c),u=o.Std.sqrt(n),d=o.Std.round(u),p=this._context.new_var(h),_=o.Std.wma(p,d,this._context),f=_,[f]}}},{name:"Ichimoku Cloud",metainfo:{_metainfoVersion:42,isTVScript:!1,isTVScriptStub:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0496ff"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#991515"},plot_2:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#459915"},plot_3:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#008000"},plot_4:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,palettes:{palette_0:{colors:{0:{color:"#008000",width:1,style:0},1:{color:"#FF0000",width:1,style:0}}}},filledAreasStyle:{fill_0:{color:"#000080",transparency:90,visible:!0}},inputs:{in_0:9,in_1:26,in_2:52,in_3:26}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"},{id:"plot_2",type:"line"},{id:"plot_3",type:"line"},{id:"plot_4",type:"line"},{id:"plot_5",palette:"palette_0",target:"fill_0",type:"colorer"}],styles:{plot_0:{title:"Conversion Line",histogramBase:0,joinPoints:!1,isHidden:!1},plot_1:{title:"Base Line",histogramBase:0,joinPoints:!1,isHidden:!1},plot_2:{title:"Lagging Span",histogramBase:0,joinPoints:!1,isHidden:!1},plot_3:{title:"Lead 1",histogramBase:0,joinPoints:!1,isHidden:!1},plot_4:{title:"Lead 2",histogramBase:0,joinPoints:!1, -isHidden:!1}},description:"Ichimoku Cloud",shortDescription:"Ichimoku",is_price_study:!0,is_hidden_study:!1,id:"Ichimoku Cloud@tv-basicstudies-1",palettes:{palette_0:{colors:{0:{name:"Color 0"},1:{name:"Color 1"}},valToIndex:{0:0,1:1}}},filledAreas:[{id:"fill_0",objAId:"plot_3",objBId:"plot_4",type:"plot_plot",title:"Plots Background",isHidden:!1,palette:"palette_0"}],inputs:[{id:"in_0",name:"Conversion Line Periods",defval:9,type:"integer",min:1,max:1e12},{id:"in_1",name:"Base Line Periods",defval:26,type:"integer",min:1,max:1e12},{id:"in_2",name:"Lagging Span 2 Periods",defval:52,type:"integer",min:1,max:1e12},{id:"in_3",name:"Displacement",defval:26,type:"integer",min:1,max:1e12}],scriptIdPart:"",name:"Ichimoku Cloud"},constructor:function(){this.donchian=function(t){var e=this._context.new_var(o.Std.low(this._context)),i=this._context.new_var(o.Std.high(this._context));return o.Std.avg(o.Std.lowest(e,t,this._context),o.Std.highest(i,t,this._context))},this.f_1=function(){var t=this._input(0),e=this._input(1),i=this._input(2),n=this._input(3),r=this.donchian(t),s=this.donchian(e),a=o.Std.avg(r,s),l=this.donchian(i);return[r,s,o.Std.close(this._context),a,l,-n,n,n,o.Std.gt(a,l)?0:1]},this.main=function(t,e){this._context=t,this._input=e;var i=this.f_1();return[i[0],i[1],{value:i[2],offset:i[5]},{value:i[3],offset:i[6]},{value:i[4],offset:i[7]},i[8]]}}},{name:"Keltner Channels",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"},plot_2:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}},precision:4,filledAreasStyle:{fill_0:{color:"#0000FF",transparency:90,visible:!0}},inputs:{in_0:!0,in_1:20,in_2:1}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"},{id:"plot_2",type:"line"}],styles:{plot_0:{title:"Upper",histogramBase:0,joinPoints:!1},plot_1:{title:"Middle",histogramBase:0,joinPoints:!1},plot_2:{title:"Lower",histogramBase:0,joinPoints:!1}},description:"Keltner Channels",shortDescription:"KC",is_price_study:!0,filledAreas:[{id:"fill_0",objAId:"plot_0",objBId:"plot_2",type:"plot_plot",title:"Plots Background"}],inputs:[{id:"in_0",name:"useTrueRange",defval:!0,type:"bool"},{id:"in_1",name:"length",defval:20,type:"integer",min:1,max:2e3},{id:"in_2",name:"mult",defval:1,type:"float",min:-1e12,max:1e12}],id:"Keltner Channels@tv-basicstudies-1",scriptIdPart:"",name:"Keltner Channels"},constructor:function(){this.f_0=function(t,e,i,o){return t?e:i-o},this.f_1=function(t,e,i){return t+e*i},this.f_2=function(t,e,i){return t-e*i},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_,f,m;return this._context=t,this._input=e,i=o.Std.close(this._context),n=this._input(0),r=this._input(1),s=this._input(2),a=this._context.new_var(i),l=o.Std.ema(a,r,this._context), -c=this.f_0(n,o.Std.tr(this._context),o.Std.high(this._context),o.Std.low(this._context)),h=this._context.new_var(c),u=o.Std.ema(h,r,this._context),d=this.f_1(l,u,s),p=this.f_2(l,u,s),_=d,f=l,m=p,[_,f,m]}}},{name:"Klinger Oscillator",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#000080"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#008000"}},precision:4,inputs:{}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1},plot_1:{title:"Signal",histogramBase:0,joinPoints:!1}},description:"Klinger Oscillator",shortDescription:"Klinger Oscillator",is_price_study:!1,inputs:[],id:"Klinger Oscillator@tv-basicstudies-1",scriptIdPart:"",name:"Klinger Oscillator"},constructor:function(){this.f_0=function(t,e){return o.Std.ge(t,0)?e:-e},this.f_1=function(t,e){return t-e},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_,f;return this._context=t,this._input=e,i=o.Std.hlc3(this._context),n=this._context.new_var(i),r=o.Std.change(n),s=this.f_0(r,o.Std.volume(this._context)),a=this._context.new_var(s),l=o.Std.ema(a,34,this._context),c=this._context.new_var(s),h=o.Std.ema(c,55,this._context),u=this.f_1(l,h),d=this._context.new_var(u),p=o.Std.ema(d,13,this._context),_=u,f=p,[_,f]}}},{name:"Know Sure Thing",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#008000"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:0}],inputs:{in_0:10,in_1:15,in_2:20,in_3:30,in_4:10,in_5:10,in_6:10,in_7:15,in_8:9}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"}],styles:{plot_0:{title:"KST",histogramBase:0,joinPoints:!1},plot_1:{title:"Signal",histogramBase:0,joinPoints:!1}},description:"Know Sure Thing",shortDescription:"KST",is_price_study:!1,bands:[{id:"hline_0",name:"Zero"}],inputs:[{id:"in_0",name:"roclen1",defval:10,type:"integer",min:1,max:2e3},{id:"in_1",name:"roclen2",defval:15,type:"integer",min:1,max:2e3},{id:"in_2",name:"roclen3",defval:20,type:"integer",min:1,max:2e3},{id:"in_3",name:"roclen4",defval:30,type:"integer",min:1,max:2e3},{id:"in_4",name:"smalen1",defval:10,type:"integer",min:1,max:2e3},{id:"in_5",name:"smalen2",defval:10,type:"integer",min:1,max:2e3},{id:"in_6",name:"smalen3",defval:10,type:"integer",min:1,max:2e3},{id:"in_7",name:"smalen4",defval:15,type:"integer",min:1,max:2e3},{id:"in_8",name:"siglen",defval:9,type:"integer",min:1,max:2e3}],id:"Know Sure Thing@tv-basicstudies-1",scriptIdPart:"",name:"Know Sure Thing"},constructor:function(){this.f_0=function(t,e,i,o){return t+2*e+3*i+4*o},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_,f,m,g,v,y,b,S,w,T,C,x,P,L,I,k,A,M,E,D,V,O,R,B,z,F,N,W -;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=this._input(2),s=this._input(3),a=this._input(4),l=this._input(5),c=this._input(6),h=this._input(7),u=this._input(8),d=o.Std.close(this._context),p=i,_=this._context.new_var(d),f=o.Std.roc(_,p),m=a,g=this._context.new_var(f),v=o.Std.sma(g,m,this._context),y=n,b=this._context.new_var(d),S=o.Std.roc(b,y),w=l,T=this._context.new_var(S),C=o.Std.sma(T,w,this._context),x=r,P=this._context.new_var(d),L=o.Std.roc(P,x),I=c,k=this._context.new_var(L),A=o.Std.sma(k,I,this._context),M=s,E=this._context.new_var(d),D=o.Std.roc(E,M),V=h,O=this._context.new_var(D),R=o.Std.sma(O,V,this._context),B=this.f_0(v,C,A,R),z=this._context.new_var(B),F=o.Std.sma(z,u,this._context),N=B,W=F,[N,W]}}},{name:"Least Squares Moving Average",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#000080"}},precision:4,inputs:{in_0:25,in_1:0}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Least Squares Moving Average",shortDescription:"LSMA",is_price_study:!0,inputs:[{id:"in_0",name:"Length",defval:25,type:"integer",min:1,max:1e12},{id:"in_1",name:"Offset",defval:0,type:"integer",min:-1e12,max:1e12}],id:"Least Squares Moving Average@tv-basicstudies-1",scriptIdPart:"",name:"Least Squares Moving Average"},constructor:function(){this.main=function(t,e){var i,n,r,s,a,l;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=o.Std.close(this._context),s=this._context.new_var(r),a=o.Std.linreg(s,i,n),l=a,[l]}}},{name:"Linear Regression Curve",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#000080"}},precision:4,inputs:{in_0:9}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Linear Regression Curve",shortDescription:"LRC",is_price_study:!0,inputs:[{id:"in_0",name:"Length",defval:9,type:"integer",min:1,max:2e3}],id:"Linear Regression Curve@tv-basicstudies-1",scriptIdPart:"",name:"Linear Regression Curve"},constructor:function(){this.main=function(t,e){var i,n,r,s,a;return this._context=t,this._input=e,i=o.Std.close(this._context),n=this._input(0),r=this._context.new_var(i),s=o.Std.linreg(r,n,0),a=s,[a]}}},{name:"MA Cross",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#008000"},plot_2:{linestyle:0,linewidth:4,plottype:3,trackPrice:!1,transparency:35,visible:!0,color:"#000080"}},precision:4,inputs:{in_0:9,in_1:26}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"},{id:"plot_2",type:"line"}],styles:{plot_0:{title:"Short", -histogramBase:0,joinPoints:!1},plot_1:{title:"Long",histogramBase:0,joinPoints:!1},plot_2:{title:"Crosses",histogramBase:0,joinPoints:!1}},description:"MA Cross",shortDescription:"MA Cross",is_price_study:!0,inputs:[{id:"in_0",name:"Short",defval:9,type:"integer",min:1,max:2e3},{id:"in_1",name:"Long",defval:26,type:"integer",min:1,max:2e3}],id:"MA Cross@tv-basicstudies-1",scriptIdPart:"",name:"MA Cross"},constructor:function(){this.f_0=function(t,e){return t?e:o.Std.na()},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=o.Std.close(this._context),s=this._context.new_var(r),a=o.Std.sma(s,i,this._context),l=this._context.new_var(r),c=o.Std.sma(l,n,this._context),h=a,u=c,d=o.Std.cross(a,c,this._context),p=this.f_0(d,a),[h,u,p]}}},{name:"MA with EMA Cross",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#008000"},plot_2:{linestyle:0,linewidth:4,plottype:3,trackPrice:!1,transparency:35,visible:!0,color:"#000080"}},precision:4,inputs:{in_0:10,in_1:10}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"},{id:"plot_2",type:"line"}],styles:{plot_0:{title:"MA",histogramBase:0,joinPoints:!1},plot_1:{title:"EMA",histogramBase:0,joinPoints:!1},plot_2:{title:"Crosses",histogramBase:0,joinPoints:!1}},description:"MA with EMA Cross",shortDescription:"MA/EMA Cross",is_price_study:!0,inputs:[{id:"in_0",name:"Length MA",defval:10,type:"integer",min:1,max:2e3},{id:"in_1",name:"Length EMA",defval:10,type:"integer",min:1,max:2e3}],id:"MA with EMA Cross@tv-basicstudies-1",scriptIdPart:"",name:"MA with EMA Cross"},constructor:function(){this.f_0=function(t,e){return t?e:o.Std.na()},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=o.Std.close(this._context),s=this._context.new_var(r),a=o.Std.sma(s,i,this._context),l=this._context.new_var(r),c=o.Std.ema(l,n,this._context),h=a,u=c,d=o.Std.cross(a,c,this._context),p=this.f_0(d,a),[h,u,p]}}},{name:"Mass Index",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#000080"}},precision:4,inputs:{in_0:10}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Mass Index",shortDescription:"Mass Index",is_price_study:!1,inputs:[{id:"in_0",name:"length",defval:10,type:"integer",min:1,max:2e3}],id:"Mass Index@tv-basicstudies-1",scriptIdPart:"",name:"Mass Index"},constructor:function(){this.f_0=function(t,e){return t-e},this.f_1=function(t,e){return t/e},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d;return this._context=t,this._input=e,i=this._input(0),n=this.f_0(o.Std.high(this._context),o.Std.low(this._context)), -r=this._context.new_var(n),s=o.Std.ema(r,9,this._context),a=this._context.new_var(s),l=o.Std.ema(a,9,this._context),c=this.f_1(s,l),h=this._context.new_var(c),u=o.Std.sum(h,i,this._context),d=u,[d]}}},{name:"McGinley Dynamic",metainfo:{_metainfoVersion:42,isTVScript:!1,isTVScriptStub:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#000080"}},precision:4,inputs:{in_0:14}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1,isHidden:!1}},description:"McGinley Dynamic",shortDescription:"McGinley Dynamic",is_price_study:!0,is_hidden_study:!1,id:"mcginley_dynamic@tv-basicstudies-1",inputs:[{id:"in_0",name:"length",defval:14,type:"integer",min:1,max:1e12}],scriptIdPart:"",name:"McGinley Dynamic"},constructor:function(){this.f_0=function(){var t,e=this._input(0),i=o.Std.close(this._context),n=this._context.new_var(i),r=o.Std.ema(n,e,this._context),s=this._context.new_var(),a=s.get(1)+(i-s.get(1))/(e*o.Std.pow(i/s.get(1),4));return s.set(o.Std.na(s.get(1))?r:a),t=s.get(0),[t]},this.main=function(t,e){return this._context=t,this._input=e,this.f_0()}}},{name:"Momentum",metainfo:{_metainfoVersion:30,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#808000"}},precision:4,inputs:{in_0:10,in_1:"close"}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Mom",histogramBase:0,joinPoints:!1,isHidden:!1}},description:"Momentum",shortDescription:"Mom",is_price_study:!1,inputs:[{id:"in_0",name:"Length",defval:10,type:"integer",min:1,max:2e3},{id:"in_1",name:"Source",defval:"close",type:"source",options:["open","high","low","close","hl2","hlc3","ohlc4"]}],id:"Momentum@tv-basicstudies-1",scriptIdPart:"",name:"Momentum"},constructor:function(){this.main=function(t,e){var i,n,r,s,a;return this._context=t,this._input=e,i=this._input(0),n=o.Std[this._input(1)](this._context),r=this._context.new_var(n),s=r.get(i),a=s?n-s:null,[a]}}},{name:"Money Flow",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#459915"}},precision:4,bands:[{color:"#c0c0c0",linestyle:2,linewidth:1,visible:!0,value:80},{color:"#c0c0c0",linestyle:2,linewidth:1,visible:!0,value:20}],filledAreasStyle:{fill_0:{color:"#9915ff",transparency:90,visible:!0}},inputs:{in_0:14}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Money Flow",shortDescription:"MFI",is_price_study:!1,bands:[{id:"hline_0",name:"UpperLimit"},{id:"hline_1",name:"LowerLimit"}],filledAreas:[{id:"fill_0",objAId:"hline_0",objBId:"hline_1",type:"hline_hline",title:"Hlines Background"}],inputs:[{id:"in_0",name:"Length",defval:14,type:"integer",min:1,max:2e3}],id:"Money Flow@tv-basicstudies-1",scriptIdPart:"",name:"Money Flow"},constructor:function(){this.f_0=function(t,e,i){ -return t*(o.Std.le(e,0)?0:i)},this.f_1=function(t,e,i){return t*(o.Std.ge(e,0)?0:i)},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_;return this._context=t,this._input=e,i=this._input(0),n=o.Std.hlc3(this._context),r=this._context.new_var(n),s=o.Std.change(r),a=this.f_0(o.Std.volume(this._context),s,n),l=this._context.new_var(a),c=o.Std.sum(l,i,this._context),h=this.f_1(o.Std.volume(this._context),s,n),u=this._context.new_var(h),d=o.Std.sum(u,i,this._context),p=o.Std.rsi(c,d),_=p,[_]}}},{name:"Moving Average",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}},precision:4,inputs:{in_0:9,in_1:"close",in_2:0}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Moving Average",shortDescription:"MA",is_price_study:!0,inputs:[{id:"in_0",name:"Length",defval:9,type:"integer",min:1,max:1e4},{id:"in_1",name:"Source",defval:"close",type:"source",options:["open","high","low","close","hl2","hlc3","ohlc4"]},{id:"in_2",name:"Offset",defval:0,type:"integer",min:-1e4,max:1e4}],id:"Moving Average@tv-basicstudies-1",scriptIdPart:"",name:"Moving Average"},constructor:function(){this.main=function(t,e){var i,n,r,s,a,l;return this._context=t,this._input=e,i=o.Std[this._input(1)](this._context),n=this._input(0),r=this._input(2),s=this._context.new_var(i),a=o.Std.sma(s,n,this._context),l=a,[{value:l,offset:r}]}}},{name:"Moving Average Channel",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#CC0000"}},precision:4,filledAreasStyle:{fill_0:{color:"#A2C4C9",transparency:90,visible:!0}},inputs:{in_0:20,in_1:20,in_2:0,in_3:0}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"}],styles:{plot_0:{title:"Upper",histogramBase:0,joinPoints:!1},plot_1:{title:"Lower",histogramBase:0,joinPoints:!1}},filledAreas:[{id:"fill_0",objAId:"plot_0",objBId:"plot_1",type:"plot_plot",title:"Plots Background"}],description:"Moving Average Channel",shortDescription:"MAC",is_price_study:!0,inputs:[{id:"in_0",name:"Upper Length",defval:20,type:"integer",min:1,max:1e4},{id:"in_1",name:"Lower Length",defval:20,type:"integer",min:1,max:1e4},{id:"in_2",name:"Upper Offset",defval:0,type:"integer",min:-1e4,max:1e4},{id:"in_3",name:"Lower Offset",defval:0,type:"integer",min:-1e4,max:1e4}],id:"Moving Average Channel@tv-basicstudies-1",scriptIdPart:"",name:"Moving Average Channel"},constructor:function(){this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d;return this._context=t,this._input=e,i=o.Std.high(this._context),n=o.Std.low(this._context),r=this._input(0),s=this._input(1),a=this._input(2),l=this._input(3),c=this._context.new_var(i),h=this._context.new_var(n),u=o.Std.sma(c,r,this._context),d=o.Std.sma(h,s,this._context), -[{value:u,offset:a},{value:d,offset:l}]}}},{name:"Moving Average Convergence/Divergence",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:1,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"},plot_2:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,inputs:{in_0:12,in_1:26,in_3:"close",in_2:9}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"},{id:"plot_2",type:"line"}],styles:{plot_0:{title:"Histogram",histogramBase:0,joinPoints:!1},plot_1:{title:"MACD",histogramBase:0,joinPoints:!1},plot_2:{title:"Signal",histogramBase:0,joinPoints:!1}},description:"MACD",shortDescription:"MACD",is_price_study:!1,inputs:[{id:"in_0",name:"fastLength",defval:12,type:"integer",min:1,max:2e3},{id:"in_1",name:"slowLength",defval:26,type:"integer",min:1,max:2e3},{id:"in_3",name:"Source",defval:"close",type:"source",options:["open","high","low","close","hl2","hlc3","ohlc4"]},{id:"in_2",name:"signalLength",defval:9,type:"integer",min:1,max:50}],id:"Moving Average Convergence/Divergence@tv-basicstudies-1",scriptIdPart:"",name:"MACD"},constructor:function(){this.f_0=function(t,e){return t-e},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_,f,m,g;return this._context=t,this._input=e,i=o.Std[this._input(2)](this._context),n=this._input(0),r=this._input(1),s=this._input(3),a=this._context.new_var(i),l=o.Std.ema(a,n,this._context),c=this._context.new_var(i),h=o.Std.ema(c,r,this._context),u=this.f_0(l,h),d=this._context.new_var(u),p=o.Std.ema(d,s,this._context),_=this.f_0(u,p),f=_,m=u,g=p,[f,m,g]}}},{name:"Moving Average Exponential",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}},precision:4,inputs:{in_0:9,in_1:"close",in_2:0}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Moving Average Exponential",shortDescription:"EMA",is_price_study:!0,inputs:[{id:"in_0",name:"Length",defval:9,type:"integer",min:1,max:1e4},{id:"in_1",name:"Source",defval:"close",type:"source",options:["open","high","low","close","hl2","hlc3","ohlc4"]},{id:"in_2",name:"Offset",defval:0,type:"integer",min:-1e4,max:1e4}],id:"Moving Average Exponential@tv-basicstudies-1",scriptIdPart:"",name:"Moving Average Exponential"},constructor:function(){this.main=function(t,e){var i,n,r,s,a,l;return this._context=t,this._input=e,i=o.Std[this._input(1)](this._context),n=this._input(0),r=this._input(2),s=this._context.new_var(i),a=o.Std.ema(s,n,this._context),l=a,[{value:l,offset:r}]}}},{name:"Moving Average Weighted",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}}, -precision:4,inputs:{in_0:9,in_1:"close",in_2:0}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Moving Average Weighted",shortDescription:"WMA",is_price_study:!0,inputs:[{id:"in_0",name:"Length",defval:9,type:"integer",min:1,max:2e3},{id:"in_1",name:"Source",defval:"close",type:"source",options:["open","high","low","close","hl2","hlc3","ohlc4"]},{id:"in_2",name:"Offset",defval:0,type:"integer",min:-1e4,max:1e4}],id:"Moving Average Weighted@tv-basicstudies-1",scriptIdPart:"",name:"Moving Average Weighted"},constructor:function(){this.main=function(t,e){var i,n,r,s,a,l;return this._context=t,this._input=e,i=o.Std[this._input(1)](this._context),n=this._input(0),r=this._input(2),s=this._context.new_var(i),a=o.Std.wma(s,n,this._context),l=a,[{value:l,offset:r}]}}},{name:"Net Volume",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}},precision:4,inputs:{}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Net Volume",shortDescription:"Net Volume",is_price_study:!1,inputs:[],id:"Net Volume@tv-basicstudies-1",scriptIdPart:"",name:"Net Volume"},constructor:function(){this.f_0=function(t,e,i){return o.Std.gt(t,0)?e:o.Std.lt(i,0)?-e:0*e},this.main=function(t,e){var i,n,r,s,a;return this._context=t,this._input=e,i=o.Std.close(this._context),n=this._context.new_var(i),r=o.Std.change(n),s=this.f_0(r,o.Std.volume(this._context),r),a=s,[a]}}},{name:"On Balance Volume",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}},precision:4,inputs:{}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"On Balance Volume",shortDescription:"OBV",is_price_study:!1,inputs:[],id:"On Balance Volume@tv-basicstudies-1",scriptIdPart:"",name:"On Balance Volume"},constructor:function(){this.f_0=function(t,e,i){return o.Std.gt(t,0)?e:o.Std.lt(i,0)?-e:0*e},this.main=function(t,e){var i,n,r,s,a,l;return this._context=t,this._input=e,i=o.Std.close(this._context),n=this._context.new_var(i),r=o.Std.change(n),s=this.f_0(r,o.Std.volume(this._context),r),a=o.Std.cum(s,this._context),l=a,[l]}}},{name:"Parabolic SAR",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:3,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}},precision:4,inputs:{in_0:.02,in_1:.02,in_2:.2}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Parabolic SAR",shortDescription:"SAR",is_price_study:!0,inputs:[{id:"in_0",name:"start",defval:.02,type:"float",min:-1e12,max:1e12},{id:"in_1",name:"increment",defval:.02,type:"float",min:-1e12,max:1e12},{id:"in_2",name:"maximum", -defval:.2,type:"float",min:-1e12,max:1e12}],id:"Parabolic SAR@tv-basicstudies-1",scriptIdPart:"",name:"Parabolic SAR"},constructor:function(){this.main=function(t,e){var i,n,r,s,a;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=this._input(2),s=o.Std.sar(i,n,r,this._context),a=s,[a]}}},{name:"Price Channel",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0080"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0080"},plot_2:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0496FF"}},precision:4,inputs:{in_0:20,in_1:0}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"},{id:"plot_2",type:"line"}],styles:{plot_0:{title:"Highprice Line",histogramBase:0,joinPoints:!1},plot_1:{title:"Lowprice Line",histogramBase:0,joinPoints:!1},plot_2:{title:"Centerprice Line",histogramBase:0,joinPoints:!1}},description:"Price Channel",shortDescription:"PC",is_price_study:!1,inputs:[{id:"in_0",name:"Length",defval:20,type:"integer",min:1,max:2e3},{id:"in_1",name:"Offset Length",defval:0,type:"integer",min:1,max:2e3}],id:"Price Channel@tv-basicstudies-1",scriptIdPart:"",name:"Price Channel"},constructor:function(){this.main=function(t,e){var i,n,r,s,a,l,c,h,u;return this._context=t,this._input=e,i=o.Std.high(this._context),n=this._context.new_var(i),r=o.Std.low(this._context),s=this._context.new_var(r),a=this._input(0),l=this._input(1),c=o.Std.highest(n,a,this._context),h=o.Std.lowest(s,a,this._context),u=o.Std.avg(c,h),[{value:c,offset:l},{value:h,offset:l},{value:u,offset:l}]}}},{name:"Price Oscillator",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}},precision:4,inputs:{in_0:10,in_1:21}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Price Oscillator",shortDescription:"PPO",is_price_study:!1,inputs:[{id:"in_0",name:"shortlen",defval:10,type:"integer",min:1,max:2e3},{id:"in_1",name:"longlen",defval:21,type:"integer",min:1,max:2e3}],id:"Price Oscillator@tv-basicstudies-1",scriptIdPart:"",name:"Price Oscillator"},constructor:function(){this.f_0=function(t,e){return(t-e)/e*100},this.main=function(t,e){var i,n,r,s,a,l,c,h,u;return this._context=t,this._input=e,i=o.Std.close(this._context),n=this._input(0),r=this._input(1),s=this._context.new_var(i),a=o.Std.sma(s,n,this._context),l=this._context.new_var(i),c=o.Std.sma(l,r,this._context),h=this.f_0(a,c),u=h,[u]}}},{name:"Price Volume Trend",metainfo:{_metainfoVersion:42,isTVScript:!1,isTVScriptStub:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}},precision:4,inputs:{}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"PVT",histogramBase:0, -joinPoints:!1,isHidden:!1}},description:"Price Volume Trend",shortDescription:"PVT",is_price_study:!1,is_hidden_study:!1,id:"price_volume_trend@tv-basicstudies-1",inputs:[],scriptIdPart:"",name:"Price Volume Trend"},constructor:function(){this.f_0=function(){var t=this._context.new_var(o.Std.close(this._context));return[o.Std.cum(o.Std.change(t)/t.get(1)*o.Std.volume(this._context),this._context)]},this.main=function(t,e){return this._context=t,this._input=e,[this.f_0()[0]]}}},{name:"Rate Of Change",metainfo:{_metainfoVersion:41,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:0}],inputs:{in_0:9}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"ROC",histogramBase:0,joinPoints:!1,isHidden:!1}},description:"Rate Of Change",shortDescription:"ROC",is_price_study:!1,bands:[{id:"hline_0",name:"Zero Line",isHidden:!1}],inputs:[{id:"in_0",name:"length",defval:9,type:"integer",min:1,max:1e12}],id:"rate_of_change@tv-basicstudies-1",scriptIdPart:"",name:"Rate Of Change"},constructor:function(){this.main=function(t,e){var i,n,r;return this._context=t,this._input=e,i=this._context.new_var(o.Std.close(this._context)),n=this._input(0),r=100*(i.get(0)-i.get(n))/i.get(n),[r]}}},{name:"Relative Strength Index",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#800080"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:70},{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:30}],filledAreasStyle:{fill_0:{color:"#800080",transparency:90,visible:!0}},inputs:{in_0:14}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Relative Strength Index",shortDescription:"RSI",is_price_study:!1,bands:[{id:"hline_0",name:"UpperLimit"},{id:"hline_1",name:"LowerLimit"}],filledAreas:[{id:"fill_0",objAId:"hline_0",objBId:"hline_1",type:"hline_hline",title:"Hlines Background"}],inputs:[{id:"in_0",name:"Length",defval:14,type:"integer",min:1,max:2e3}],id:"Relative Strength Index@tv-basicstudies-1",scriptIdPart:"",name:"Relative Strength Index"},constructor:function(){this.f_0=function(t){return o.Std.max(t,0)},this.f_1=function(t){return-o.Std.min(t,0)},this.f_2=function(t,e){return o.Std.eq(t,0)?100:o.Std.eq(e,0)?0:100-100/(1+e/t)},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_;return this._context=t,this._input=e,i=o.Std.close(this._context),n=this._input(0),r=this._context.new_var(i),s=o.Std.change(r),a=this.f_0(s),l=this._context.new_var(a),c=o.Std.rma(l,n,this._context),h=this.f_1(s),u=this._context.new_var(h),d=o.Std.rma(u,n,this._context),p=this.f_2(d,c),_=p,[_]}}},{name:"Relative Vigor Index",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0, -linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#008000"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,inputs:{in_0:10}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"}],styles:{plot_0:{title:"RVGI",histogramBase:0,joinPoints:!1},plot_1:{title:"Signal",histogramBase:0,joinPoints:!1}},description:"Relative Vigor Index",shortDescription:"RVGI",is_price_study:!1,inputs:[{id:"in_0",name:"Length",defval:10,type:"integer",min:1,max:2e3}],id:"Relative Vigor Index@tv-basicstudies-1",scriptIdPart:"",name:"Relative Vigor Index"},constructor:function(){this.f_0=function(t,e){return t-e},this.f_1=function(t,e){return t/e},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_,f,m,g,v;return this._context=t,this._input=e,i=this._input(0),n=this.f_0(o.Std.close(this._context),o.Std.open(this._context)),r=this._context.new_var(n),s=o.Std.swma(r,this._context),a=this._context.new_var(s),l=o.Std.sum(a,i,this._context),c=this.f_0(o.Std.high(this._context),o.Std.low(this._context)),h=this._context.new_var(c),u=o.Std.swma(h,this._context),d=this._context.new_var(u),p=o.Std.sum(d,i,this._context),_=this.f_1(l,p),f=this._context.new_var(_),m=o.Std.swma(f,this._context),g=_,v=m,[g,v]}}},{name:"Relative Volatility Index",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#000080"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:80},{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:20}],filledAreasStyle:{fill_0:{color:"#808000",transparency:90,visible:!0}},inputs:{in_0:10}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Relative Volatility Index",shortDescription:"RVI",is_price_study:!1,bands:[{id:"hline_0",name:"UpperLimit"},{id:"hline_1",name:"LowerLimit"}],filledAreas:[{id:"fill_0",objAId:"hline_0",objBId:"hline_1",type:"hline_hline",title:"Hlines Background"}],inputs:[{id:"in_0",name:"length",defval:10,type:"integer",min:1,max:2e3}],id:"Relative Volatility Index@tv-basicstudies-1",scriptIdPart:"",name:"Relative Volatility Index"},constructor:function(){this.f_0=function(t,e){return o.Std.le(t,0)?0:e},this.f_1=function(t,e){return o.Std.gt(t,0)?0:e},this.f_2=function(t,e){return t/(t+e)*100},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_,f,m;return this._context=t,this._input=e,i=this._input(0),n=o.Std.close(this._context),r=this._context.new_var(n),s=o.Std.stdev(r,i,this._context),a=this._context.new_var(n),l=o.Std.change(a),c=this.f_0(l,s),h=this._context.new_var(c),u=o.Std.ema(h,14,this._context),d=this.f_1(l,s),p=this._context.new_var(d),_=o.Std.ema(p,14,this._context),f=this.f_2(u,_),m=f,[m]}}},{name:"SMI Ergodic Indicator/Oscillator",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1, -transparency:35,visible:!0,color:"#0000FF"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF7F00"},plot_2:{linestyle:0,linewidth:1,plottype:1,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,inputs:{in_0:5,in_1:20,in_2:5}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"},{id:"plot_2",type:"line"}],styles:{plot_0:{title:"Indicator",histogramBase:0,joinPoints:!1},plot_1:{title:"Signal",histogramBase:0,joinPoints:!1},plot_2:{title:"Oscillator",histogramBase:0,joinPoints:!1}},description:"SMI Ergodic Indicator/Oscillator",shortDescription:"SMIIO",is_price_study:!1,inputs:[{id:"in_0",name:"shortlen",defval:5,type:"integer",min:1,max:2e3},{id:"in_1",name:"longlen",defval:20,type:"integer",min:1,max:2e3},{id:"in_2",name:"siglen",defval:5,type:"integer",min:1,max:2e3}],id:"SMI Ergodic Indicator/Oscillator@tv-basicstudies-1",scriptIdPart:"",name:"SMI Ergodic Indicator/Oscillator"},constructor:function(){this.f_0=function(t,e){return t-e},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=this._input(2),s=o.Std.close(this._context),a=this._context.new_var(s),l=o.Std.tsi(a,i,n,this._context),c=this._context.new_var(l),h=o.Std.ema(c,r,this._context),u=this.f_0(l,h),d=l,p=h,_=u,[d,p,_]}}},{name:"Smoothed Moving Average",metainfo:{_metainfoVersion:41,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,inputs:{in_0:7,in_1:"close"}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1,isHidden:!1}},description:"Smoothed Moving Average",shortDescription:"SMMA",is_price_study:!0,inputs:[{id:"in_0",name:"Length",defval:7,type:"integer",min:1,max:1e12},{id:"in_1",name:"Source",defval:"close",type:"source",options:["open","high","low","close","hl2","hlc3","ohlc4"]}],id:"smoothed_moving_average@tv-basicstudies-1",scriptIdPart:"",name:"Smoothed Moving Average"},constructor:function(){this.f_0=function(){var t,e=this._input(0),i=o.Std[this._input(1)](this._context),n=this._context.new_var(i),r=o.Std.sma(n,e,this._context),s=this._context.new_var(),a=(s.get(1)*(e-1)+i)/e;return s.set(o.Std.na(s.get(1))?r:a),t=s.get(0),[t]},this.main=function(t,e){return this._context=t,this._input=e,this.f_0()}}},{name:"Stochastic",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:80},{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:20}],filledAreasStyle:{fill_0:{color:"#800080",transparency:75,visible:!0}},inputs:{in_0:14,in_1:1,in_2:3}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"}],styles:{ -plot_0:{title:"%K",histogramBase:0,joinPoints:!1},plot_1:{title:"%D",histogramBase:0,joinPoints:!1}},description:"Stochastic",shortDescription:"Stoch",is_price_study:!1,bands:[{id:"hline_0",name:"UpperLimit"},{id:"hline_1",name:"LowerLimit"}],filledAreas:[{id:"fill_0",objAId:"hline_0",objBId:"hline_1",type:"hline_hline",title:"Hlines Background"}],inputs:[{id:"in_0",name:"length",defval:14,type:"integer",min:1,max:1e4},{id:"in_1",name:"smoothK",defval:1,type:"integer",min:1,max:1e4},{id:"in_2",name:"smoothD",defval:3,type:"integer",min:1,max:1e4}],id:"Stochastic@tv-basicstudies-1",scriptIdPart:"",name:"Stochastic"},constructor:function(){this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_,f,m,g,v;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=this._input(2),s=o.Std.close(this._context),a=o.Std.high(this._context),l=o.Std.low(this._context),c=this._context.new_var(s),h=this._context.new_var(a),u=this._context.new_var(l),d=o.Std.stoch(c,h,u,i,this._context),p=this._context.new_var(d),_=o.Std.sma(p,n,this._context),f=this._context.new_var(_),m=o.Std.sma(f,r,this._context),g=_,v=m,[g,v]}}},{name:"Stochastic RSI",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:80},{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:20}],filledAreasStyle:{fill_0:{color:"#800080",transparency:80,visible:!0}},inputs:{in_0:14,in_1:14,in_2:3,in_3:3}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"}],styles:{plot_0:{title:"%K",histogramBase:0,joinPoints:!1},plot_1:{title:"%D",histogramBase:0,joinPoints:!1}},description:"Stochastic RSI",shortDescription:"Stoch RSI",is_price_study:!1,bands:[{id:"hline_0",name:"UpperLimit"},{id:"hline_1",name:"LowerLimit"}],filledAreas:[{id:"fill_0",objAId:"hline_0",objBId:"hline_1",type:"hline_hline",title:"Hlines Background"}],inputs:[{id:"in_0",name:"lengthRSI",defval:14,type:"integer",min:1,max:1e4},{id:"in_1",name:"lengthStoch",defval:14,type:"integer",min:1,max:1e4},{id:"in_2",name:"smoothK",defval:3,type:"integer",min:1,max:1e4},{id:"in_3",name:"smoothD",defval:3,type:"integer",min:1,max:1e4}],id:"Stochastic RSI@tv-basicstudies-1",scriptIdPart:"",name:"Stochastic RSI"},constructor:function(){this.f_1=function(t,e,i){var n=i.new_var(o.Std.max(o.Std.change(t),0));return o.Std.rma(n,e,i)},this.f_2=function(t,e,i){var n=i.new_var(-o.Std.min(o.Std.change(t),0));return o.Std.rma(n,e,i)},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_,f,m,g,v,y;return this._context=t,this._input=e,i=o.Std.close(this._context),n=this._input(0),r=this._input(1),s=this._input(2),a=this._input(3),l=this._context.new_var(i),c=o.Std.rsi(this.f_1(l,n,this._context),this.f_2(l,n,this._context)),h=this._context.new_var(c),u=this._context.new_var(c), -d=this._context.new_var(c),p=o.Std.stoch(h,u,d,r,this._context),_=this._context.new_var(p),f=o.Std.sma(_,s,this._context),m=this._context.new_var(f),g=o.Std.sma(m,a,this._context),v=f,y=g,[v,y]}}},{name:"TRIX",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#800000"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:0}],inputs:{in_0:18}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"TRIX",histogramBase:0,joinPoints:!1}},description:"TRIX",shortDescription:"TRIX",is_price_study:!1,bands:[{id:"hline_0",name:"Zero"}],inputs:[{id:"in_0",name:"length",defval:18,type:"integer",min:1,max:2e3}],id:"TRIX@tv-basicstudies-1",scriptIdPart:"",name:"TRIX"},constructor:function(){this.f_0=function(t){return o.Std.log(t)},this.f_1=function(t){return 1e4*t},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_;return this._context=t,this._input=e,i=this._input(0),n=this.f_0(o.Std.close(this._context)),r=this._context.new_var(n),s=o.Std.ema(r,i,this._context),a=this._context.new_var(s),l=o.Std.ema(a,i,this._context),c=this._context.new_var(l),h=o.Std.ema(c,i,this._context),u=this._context.new_var(h),d=o.Std.change(u),p=this.f_1(d),_=p,[_]}}},{name:"Triple EMA",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#008000"}},precision:4,inputs:{in_0:9}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Triple EMA",shortDescription:"TEMA",is_price_study:!0,inputs:[{id:"in_0",name:"length",defval:9,type:"integer",min:1,max:1e4}],id:"Triple EMA@tv-basicstudies-1",scriptIdPart:"",name:"Triple EMA"},constructor:function(){this.f_0=function(t,e,i){return 3*(t-e)+i},this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d;return this._context=t,this._input=e,i=this._input(0),n=o.Std.close(this._context),r=this._context.new_var(n),s=o.Std.ema(r,i,this._context),a=this._context.new_var(s),l=o.Std.ema(a,i,this._context),c=this._context.new_var(l),h=o.Std.ema(c,i,this._context),u=this.f_0(s,l,h),d=u,[d]}}},{name:"True Strength Indicator",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#000080"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:0}],inputs:{in_0:25,in_1:13,in_2:13}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1},plot_1:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"True Strength Indicator",shortDescription:"True Strength Indicator",is_price_study:!1,bands:[{id:"hline_0",name:"Zero"}],inputs:[{id:"in_0",name:"long",defval:25, -type:"integer",min:1,max:4999},{id:"in_1",name:"short",defval:13,type:"integer",min:1,max:4999},{id:"in_2",name:"siglen",defval:13,type:"integer",min:1,max:4999}],id:"True Strength Indicator@tv-basicstudies-1",scriptIdPart:"",name:"True Strength Indicator"},constructor:function(){this.main=function(t,e){var i,n,r,s,a,l,c,h;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=this._input(2),s=o.Std.close(this._context),a=this._context.new_var(s),l=o.Std.tsi(a,n,i,this._context),c=l,h=this._context.new_var(c),[c,o.Std.ema(h,r,this._context)]}}},{name:"Ultimate Oscillator",metainfo:{_metainfoVersion:41,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,inputs:{in_0:7,in_1:14,in_2:28}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"UO",histogramBase:0,joinPoints:!1,isHidden:!1}},description:"Ultimate Oscillator",shortDescription:"UO",is_price_study:!1,inputs:[{id:"in_0",name:"length7",defval:7,type:"integer",min:1,max:1e12},{id:"in_1",name:"length14",defval:14,type:"integer",min:1,max:1e12},{id:"in_2",name:"length28",defval:28,type:"integer",min:1,max:1e12}],id:"ultimate_oscillator@tv-basicstudies-1",scriptIdPart:"",name:"Ultimate Oscillator"},constructor:function(){this.f_0=function(t,e,i){var n=this._context.new_var(t),r=this._context.new_var(e);return[o.Std.sum(n,i,this._context)/o.Std.sum(r,i,this._context)]},this.f_1=function(){var t=this._input(0),e=this._input(1),i=this._input(2),n=this._context.new_var(o.Std.close(this._context)),r=o.Std.max(o.Std.high(this._context),n.get(1)),s=this._context.new_var(o.Std.close(this._context)),a=o.Std.min(o.Std.low(this._context),s.get(1)),l=o.Std.close(this._context)-a,c=r-a,h=this.f_0(l,c,t),u=this.f_0(l,c,e),d=this.f_0(l,c,i);return[100*(4*h[0]+2*u[0]+d[0])/7]},this.main=function(t,e){return this._context=t,this._input=e,this.f_1()}}},{name:"VWAP",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:0,transparency:0,visible:!0,color:"#3A6CA8"}},precision:4},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"VWAP",histogramBase:0,joinPoints:!1,isHidden:!1}},description:"VWAP",shortDescription:"VWAP",is_price_study:!0,inputs:[],id:"VWAP@tv-basicstudies-1",scriptIdPart:"",name:"VWAP"},constructor:function(){this.f_1=function(t){t.hist=null,t.add_hist()},this.init=function(t,e){this._isNewSession=o.Std.createNewSessionCheck(t)},this.main=function(t,e){var i,n,r,s;return this._context=t,this._input=e,i=t.new_var(),n=t.new_var(),this._context.symbol.time&&(r=this._context.symbol.time,this._isNewSession(r)&&(this.f_1(i),this.f_1(n))),i.set(o.Std.nz(i.get(1))+o.Std.hlc3(this._context)*o.Std.volume(this._context)),n.set(o.Std.nz(n.get(1))+o.Std.volume(this._context)),s=i.get(0)/n.get(0),[s]}}},{name:"VWMA",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{ -linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"}},precision:4,inputs:{in_0:20}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"VWMA",shortDescription:"VWMA",is_price_study:!0,inputs:[{id:"in_0",name:"len",defval:20,type:"integer",min:1,max:1e4}],id:"VWMA@tv-basicstudies-1",scriptIdPart:"",name:"VWMA"},constructor:function(){this.main=function(t,e){var i,n,r,s,a;return this._context=t,this._input=e,i=o.Std.close(this._context),n=this._input(0),r=this._context.new_var(i),s=o.Std.vwma(r,n,this._context),a=s,[a]}}},{name:"Volume Oscillator",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#000080"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:0}],inputs:{in_0:5,in_1:10}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Volume Oscillator",shortDescription:"Volume Osc",is_price_study:!1,bands:[{id:"hline_0",name:"Zero"}],inputs:[{id:"in_0",name:"shortlen",defval:5,type:"integer",min:1,max:4999},{id:"in_1",name:"longlen",defval:10,type:"integer",min:1,max:4999}],id:"Volume Oscillator@tv-basicstudies-1",scriptIdPart:"",name:"Volume Oscillator"},constructor:function(){this.f_0=function(t,e){return 100*(t-e)/e},this.main=function(t,e){var i,n,r,s,a,l,c,h,u;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=o.Std.volume(this._context),s=this._context.new_var(r),a=o.Std.ema(s,i,this._context),l=this._context.new_var(r),c=o.Std.ema(l,n,this._context),h=this.f_0(a,c),u=h,[u]}}},{name:"Vortex Indicator",metainfo:{_metainfoVersion:42,isTVScript:!1,isTVScriptStub:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"}},precision:4,inputs:{in_0:14}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"}],styles:{plot_0:{title:"VI +",histogramBase:0,joinPoints:!1,isHidden:!1},plot_1:{title:"VI -",histogramBase:0,joinPoints:!1,isHidden:!1}},description:"Vortex Indicator",shortDescription:"VI",is_price_study:!1,is_hidden_study:!1,id:"vortex_indicator@tv-basicstudies-1",inputs:[{id:"in_0",name:"Period",defval:14,type:"integer",min:2,max:1e12}],scriptIdPart:"",name:"Vortex Indicator"},constructor:function(){this.f_0=function(){var t=this._input(0),e=this._context.new_var(o.Std.low(this._context)),i=this._context.new_var(o.Std.abs(o.Std.high(this._context)-e.get(1))),n=o.Std.sum(i,t,this._context),r=this._context.new_var(o.Std.high(this._context)),s=this._context.new_var(o.Std.abs(o.Std.low(this._context)-r.get(1))),a=o.Std.sum(s,t,this._context),l=this._context.new_var(o.Std.atr(1,this._context)),c=o.Std.sum(l,t,this._context);return[n/c,a/c]},this.main=function(t,e){return this._context=t,this._input=e,this.f_0()}}},{ -name:"Willams %R",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#000080"}},precision:4,bands:[{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:-20},{color:"#808080",linestyle:2,linewidth:1,visible:!0,value:-80}],filledAreasStyle:{fill_0:{color:"#000080",transparency:90,visible:!0}},inputs:{in_0:14}},plots:[{id:"plot_0",type:"line"}],styles:{plot_0:{title:"Plot",histogramBase:0,joinPoints:!1}},description:"Williams %R",shortDescription:"%R",is_price_study:!1,bands:[{id:"hline_0",name:"UpperLimit"},{id:"hline_1",name:"LowerLimit"}],filledAreas:[{id:"fill_0",objAId:"hline_0",objBId:"hline_1",type:"hline_hline",title:"Hlines Background"}],inputs:[{id:"in_0",name:"length",defval:14,type:"integer",min:1,max:2e3}],id:"Willams %R@tv-basicstudies-1",scriptIdPart:"",name:"Willams %R"},constructor:function(){this.f_0=function(t,e,i){return 100*(t-e)/(e-i)},this.main=function(t,e){var i,n,r,s,a,l,c,h,u;return this._context=t,this._input=e,i=this._input(0),n=o.Std.high(this._context),r=this._context.new_var(n),s=o.Std.highest(r,i,this._context),a=o.Std.low(this._context),l=this._context.new_var(a),c=o.Std.lowest(l,i,this._context),h=this.f_0(o.Std.close(this._context),s,c),u=h,[u]}}},{name:"Williams Alligator",metainfo:{_metainfoVersion:27,isTVScript:!1,isTVScriptStub:!1,is_hidden_study:!1,defaults:{styles:{plot_0:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#0000FF"},plot_1:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#FF0000"},plot_2:{linestyle:0,linewidth:1,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#008000"}},precision:4,inputs:{in_0:21,in_1:13,in_2:8}},plots:[{id:"plot_0",type:"line"},{id:"plot_1",type:"line"},{id:"plot_2",type:"line"}],styles:{plot_0:{title:"Jaw",histogramBase:0,joinPoints:!1},plot_1:{title:"Teeth",histogramBase:0,joinPoints:!1},plot_2:{title:"Lips",histogramBase:0,joinPoints:!1}},description:"Williams Alligator",shortDescription:"Alligator",is_price_study:!0,inputs:[{id:"in_0",name:"jawLength",defval:21,type:"integer",min:1,max:2e3},{id:"in_1",name:"teethLength",defval:13,type:"integer",min:1,max:2e3},{id:"in_2",name:"lipsLength",defval:8,type:"integer",min:1,max:2e3}],id:"Williams Alligator@tv-basicstudies-1",scriptIdPart:"",name:"Williams Alligator"},constructor:function(){this.main=function(t,e){var i,n,r,s,a,l,c,h,u,d,p,_,f;return this._context=t,this._input=e,i=this._input(0),n=this._input(1),r=this._input(2),s=o.Std.hl2(this._context),a=this._context.new_var(s),l=o.Std.ema(a,i,this._context),c=this._context.new_var(s),h=o.Std.ema(c,n,this._context),u=this._context.new_var(s),d=o.Std.ema(u,r,this._context),p=l,_=h,f=d,[{value:p,offset:8},{value:_,offset:5},{value:f,offset:3}]}}},{name:"Williams Fractals",metainfo:{_metainfoVersion:42,isTVScript:!1,isTVScriptStub:!1,defaults:{styles:{plot_0:{plottype:"shape_triangle_down",visible:!0,location:"BelowBar", -transparency:0,color:"#800000"},plot_1:{plottype:"shape_triangle_up",visible:!0,location:"AboveBar",transparency:0,color:"#808000"}},precision:4,inputs:{in_0:2}},plots:[{id:"plot_0",type:"shapes"},{id:"plot_1",type:"shapes"}],styles:{plot_0:{title:"Down fractals",isHidden:!1},plot_1:{title:"Up fractals",isHidden:!1}},description:"Williams Fractal",shortDescription:"Fractals",is_price_study:!0,is_hidden_study:!1,id:"Williams Fractals@tv-basicstudies-1",inputs:[{id:"in_0",name:"Periods",defval:2,type:"integer",min:2,max:1e12}],scriptIdPart:"",name:"Williams Fractals",isCustomIndicator:!0},constructor:function(){this.f_0=function(){var t=this._input(0),e=this._context.new_var(o.Std.high(this._context)),i=o.Std.or(o.Std.and(o.Std.and(o.Std.lt(e.get(t+2),e.get(t)),o.Std.lt(e.get(t+1),e.get(t))),o.Std.and(o.Std.lt(e.get(t-1),e.get(t)),o.Std.lt(e.get(t-2),e.get(t)))),o.Std.or(o.Std.or(o.Std.and(o.Std.lt(e.get(t+3),e.get(t)),o.Std.and(o.Std.and(o.Std.lt(e.get(t+2),e.get(t)),o.Std.eq(e.get(t+1),e.get(t))),o.Std.and(o.Std.lt(e.get(t-1),e.get(t)),o.Std.lt(e.get(t-2),e.get(t))))),o.Std.and(o.Std.and(o.Std.lt(e.get(t+4),e.get(t)),o.Std.lt(e.get(t+3),e.get(t))),o.Std.and(o.Std.and(o.Std.eq(e.get(t+2),e.get(t)),o.Std.le(e.get(t+1),e.get(t))),o.Std.and(o.Std.lt(e.get(t-1),e.get(t)),o.Std.lt(e.get(t-2),e.get(t)))))),o.Std.or(o.Std.and(o.Std.and(o.Std.lt(e.get(t+5),e.get(t)),o.Std.and(o.Std.lt(e.get(t+4),e.get(t)),o.Std.eq(e.get(t+3),e.get(t)))),o.Std.and(o.Std.and(o.Std.eq(e.get(t+2),e.get(t)),o.Std.le(e.get(t+1),e.get(t))),o.Std.and(o.Std.lt(e.get(t-1),e.get(t)),o.Std.lt(e.get(t-2),e.get(t))))),o.Std.and(o.Std.and(o.Std.and(o.Std.lt(e.get(t+6),e.get(t)),o.Std.lt(e.get(t+5),e.get(t))),o.Std.and(o.Std.eq(e.get(t+4),e.get(t)),o.Std.le(e.get(t+3),e.get(t)))),o.Std.and(o.Std.and(o.Std.eq(e.get(t+2),e.get(t)),o.Std.le(e.get(t+1),e.get(t))),o.Std.and(o.Std.lt(e.get(t-1),e.get(t)),o.Std.lt(e.get(t-2),e.get(t)))))))),n=this._context.new_var(o.Std.low(this._context)) -;return[o.Std.or(o.Std.and(o.Std.and(o.Std.gt(n.get(t+2),n.get(t)),o.Std.gt(n.get(t+1),n.get(t))),o.Std.and(o.Std.gt(n.get(t-1),n.get(t)),o.Std.gt(n.get(t-2),n.get(t)))),o.Std.or(o.Std.or(o.Std.and(o.Std.gt(n.get(t+3),n.get(t)),o.Std.and(o.Std.and(o.Std.gt(n.get(t+2),n.get(t)),o.Std.eq(n.get(t+1),n.get(t))),o.Std.and(o.Std.gt(n.get(t-1),n.get(t)),o.Std.gt(n.get(t-2),n.get(t))))),o.Std.and(o.Std.and(o.Std.gt(n.get(t+4),n.get(t)),o.Std.gt(n.get(t+3),n.get(t))),o.Std.and(o.Std.and(o.Std.eq(n.get(t+2),n.get(t)),o.Std.ge(n.get(t+1),n.get(t))),o.Std.and(o.Std.gt(n.get(t-1),n.get(t)),o.Std.gt(n.get(t-2),n.get(t)))))),o.Std.or(o.Std.and(o.Std.and(o.Std.gt(n.get(t+5),n.get(t)),o.Std.and(o.Std.gt(n.get(t+4),n.get(t)),o.Std.eq(n.get(t+3),n.get(t)))),o.Std.and(o.Std.and(o.Std.eq(n.get(t+2),n.get(t)),o.Std.ge(n.get(t+1),n.get(t))),o.Std.and(o.Std.gt(n.get(t-1),n.get(t)),o.Std.gt(n.get(t-2),n.get(t))))),o.Std.and(o.Std.and(o.Std.and(o.Std.gt(n.get(t+6),n.get(t)),o.Std.gt(n.get(t+5),n.get(t))),o.Std.and(o.Std.eq(n.get(t+4),n.get(t)),o.Std.ge(n.get(t+3),n.get(t)))),o.Std.and(o.Std.and(o.Std.eq(n.get(t+2),n.get(t)),o.Std.ge(n.get(t+1),n.get(t))),o.Std.and(o.Std.gt(n.get(t-1),n.get(t)),o.Std.gt(n.get(t-2),n.get(t)))))))),i]},this.main=function(t,e){this._context=t,this._input=e;var i=this.f_0();return[{value:i[0],offset:-2},{value:i[1],offset:-2}]}}}]},function(t,e,i){"use strict";var o,n,r,s,a,l,c,h;Object.defineProperty(e,"__esModule",{value:!0}),o=i(0),n=i(2),r=i(39),s=i(14),a=i(85),l=i(369),c=i(1026),h=function(t){function e(e){var i=t.call(this,e)||this;return i._handleClick=function(){i._handleToggleDropdown()},i._handleToggleDropdown=function(t){var e=i.state.isOpened,o="boolean"==typeof t?t:!e;i.setState({isOpened:o})},i._handleClose=function(){i._handleToggleDropdown(!1)},i._getDropdownPosition=function(){var t=r.findDOMNode(i).getBoundingClientRect();return{x:t.left+(i.props.directionHorz===a.DirectionHorz.ToLeft?t.width:0),y:t.bottom+2}},i.state={isOpened:!1},i}return o.__extends(e,t),e.prototype.render=function(){var t,e=this.props,i=e.id,o=e.arrow,r=e.children,h=e.content,u=e.directionHorz,d=e.isDisabled,p=e.minWidth,_=e.title,f=e.className,m=this.state.isOpened,g=s(f,c.button,"apply-common-tooltip",(t={},t[c.isDisabled]=d,t[c.isOpened]=m,t));return n.createElement("div",{id:i,className:g,onClick:d?void 0:this._handleClick,title:_},h,o&&n.createElement("div",{className:c.arrow},n.createElement("div",{className:c.arrowWrap},n.createElement(l.ToolWidgetCaret,{dropped:m}))),n.createElement(a.PopupMenu,{closeOnClickOutside:this.props.closeOnClickOutside,directionHorz:u,doNotCloseOn:this,isOpened:m,minWidth:p,onClose:this._handleClose,position:this._getDropdownPosition},r))},e.defaultProps={arrow:!0,closeOnClickOutside:!0},e}(n.PureComponent),e.ToolWidgetMenu=h},function(t,e,i){"use strict";function o(t){var e=t.className,i=n.__rest(t,["className"]);return r.createElement(a.ToolWidgetButton,n.__assign({},i,{className:s(e,l.button)}))}var n,r,s,a,l;Object.defineProperty(e,"__esModule",{value:!0}),n=i(0),r=i(2),s=i(14),a=i(103), -l=i(1034),e.ToolWidgetIconButton=o},function(t,e,i){"use strict";function o(t,e,i){var o,n,r,s,a;for(void 0===i&&(i={}),o=Object.assign({},e),n=0,r=Object.keys(e);nt?t:e}}function a(t){return function(e){var i=parseInt(e,10);return M(i)?t:i}}function l(t){var e=new B;return function(i){var o=e.parse(i);return M(o)?t:o}}function c(t){var e=new B;return function(i){var o=e.parse(i);return M(o)?t():o}}function h(t,e){var i=new z(e);return function(e){var o=i.format(e);return M(o)?t:o}}function u(){return function(t){for(var e=t,i=t.replace(/[^\u0000-\u007F]/,"");i.length!==e.length;)e=i,i=e.replace(/[^\u0000-\u007F]/,"");return i}}function d(t){return function(e){return 0===e.length?t:e}}function p(t,e,i,o,n,r,s){W.call(this,t,e,o,n,r),this._transformFunction=i,this._setter=s,this._attachToControl(t,o)}function _(t,e,i,o,n){p.call(this,t,e,l(e.value()),i,o,n),this.addFormatter(function(t){return(new B).format(t)})}function f(t,e,i,o,n,r){this._subControlIds=e,W.call(this,t,i,o,n,r),this._forEachSubControl(function(t){this._attachToControl(t,o)})}function m(t,e,i,o,n,r,s){this._model=o,this._mainSeries=r,this._toIntTransformer=a(s),this._disabled=!1,W.call(this,t,e,i,o,n);var l=this;i&&t.change(function(){l.setValueToProperty(l.value())}),this._mainSeries.onBarReceived().subscribe(this,function(){l.setValue(this.property().value())})}function g(t,e,i,o,n){W.call(this,t,e,i,o,n),i&&t.on("accept-symbol",function(t,e){this.setValueToProperty(e)}.bind(this))}function v(t,e,i,o,n,r,s,a){W.call(this,t,e,o,n,r),this._transformFunction=i,this._propertyChangedHook=a,this._setter=s;var l=this;o&&t.change(function(){l._setter?l._setter.call(l,l.value()):l.setValueToProperty(l.value())})}function y(t,e){W.call(this,t,e)}function b(t,e,i,o,n,r){if(!t.is(":checkbox, :radio"))return new w(t,e,i,o,n);W.call(this,t,e,i,o,n),this._setter=r;var s=this;i&&t.change(function(){s._setter?s._setter.call(s,s.value()):s.setValueToProperty(s.value())})}function S(t,e,i,o,n,r){W.call(this,t,e,i,o,n),this._inverted=!0===r}function w(t,e,i,o,n){W.call(this,t,e,i,o,n);var r=this;i&&t.click(function(){var t=$(this).toggleClass("active").hasClass("active");r.setValueToProperty(t)})}function T(t,e,i,o,n,r){var s,a;s=t.is("input")?t:t.find("input"),W.call(this,s,e,i,o,n),this._transparencyProperty=r,this.applyOldTransparency(),a=this,i&&s.change(function(){a.setValueToProperty(a.value())})}function C(e,i,o,n,r,s){function a(t,e){var i=c.control().slider("option","min"),o=c.control().slider("option","max"),n=c._property.value();(i<=n&&n<=o||il._transformers[1]&&$(r[1]).val(l._transformers[1]),-1!==$.inArray(t.keyCode,[46,8,9,27,13,110,190])||65===t.keyCode&&!0===t.ctrlKey||67===t.keyCode&&!0===t.ctrlKey||88===t.keyCode&&!0===t.ctrlKey||t.keyCode>=35&&t.keyCode<=39||(t.shiftKey||t.keyCode<48||t.keyCode>57)&&(t.keyCode<96||t.keyCode>105)&&t.preventDefault()})}),$(r[0]).on("keyup",function(t){parseInt($(this).val())l._transformers[1]&&$(this).val(l._transformers[1]),parseInt($(this).val())>parseInt($(r[1]).val())&&$(this).val(r[1].val()),l._control.slider("values",0,$(this).val()),I.prototype.setValueToProperty.call(l,l._control.slider("values"),"from")}),$(r[1]).on("keyup",function(t){parseInt($(this).val())l._transformers[1]&&$(this).val(l._transformers[1]), -parseInt($(this).val())<$(r[0]).val()&&$(this).val(r[0].val()),l._control.slider("values",1,$(this).val()),I.prototype.setValueToProperty.call(l,l._control.slider("values"),"to")})),this._propFrom.listeners().subscribe(this,I.prototype.propertyChanged),this._propTo.listeners().subscribe(this,I.prototype.propertyChanged),o&&t.on("slide",function(t,e){l.setValueToProperty(l._control.slider("values"),e.handle)}),t.slider({stop:function(t,e){r&&($(r[0]).val(l._control.slider("values",0)),$(r[1]).val(l._control.slider("values",1))),l.setValueToProperty(l._control.slider("values"),e.handle)},start:function(t,e){r&&($(r[0]).val(l._control.slider("values",0)),$(r[1]).val(l._control.slider("values",1))),l.setValueToProperty(l._control.slider("values"),e.handle)}})}function k(t,e,i,o,n,r){W.call(this,t,e,i,o,n),this._separator=r||" ";var s=this;i&&t.change(function(){s.setValueToProperty(s.value())})}var A,M,E,D,V,O,R,B,z,F,N,W,H;i(385),A=i(9).ensureNotNull,M=i(198).isNaN,E=i(32),D=E.rgba,V=E.rgbaToString,O=E.parseRgb,R=i(213).TimePointIndexSearchMode,B=i(89).NumericFormatter,z=i(214).LimitedPrecisionNumericFormatter,F=i(30),N=i(373).addColorPicker,W=i(321).Binding,H=i(7).getLogger("Chart.PropertyPage"),o.prototype.model=function(){return this._model},o.prototype.bindControl=function(t){return this._bindings.push(t),t},o.prototype.unbindControl=function(t){var e=this._bindings.indexOf(t);-1!==e&&this._bindings.splice(e,1)},o.prototype.loadData=function(){var t,e,i;for(t=0;t",r=[{priceScale:1,minMove:1,frac:!1},{priceScale:10,minMove:1,frac:!1},{priceScale:100, -minMove:1,frac:!1},{priceScale:1e3,minMove:1,frac:!1},{priceScale:1e4,minMove:1,frac:!1},{priceScale:1e5,minMove:1,frac:!1},{priceScale:1e6,minMove:1,frac:!1},{priceScale:1e7,minMove:1,frac:!1},{priceScale:1e8,minMove:1,frac:!1},{priceScale:2,minMove:1,frac:!0},{priceScale:4,minMove:1,frac:!0},{priceScale:8,minMove:1,frac:!0},{priceScale:16,minMove:1,frac:!0},{priceScale:32,minMove:1,frac:!0},{priceScale:64,minMove:1,frac:!0},{priceScale:128,minMove:1,frac:!0},{priceScale:320,minMove:1,frac:!0}];for(t in r)e=r[t],i=e.priceScale+","+e.minMove+","+e.frac,o=e.minMove+"/"+e.priceScale,n+="";return n+="",$(n)},o.prototype.createPrecisionEditor=function(){var t,e="",$(e)},o.prototype.createLabeledCell=function(t,e,i){var o,n,r,s,a=null;return"number"==typeof t.valueOf()?(a=t,o=e,n=i):(o=t,n=e),o+="",r=this._labelToId(o),s=$("
").appendTo(t),i=$("
").append(e).appendTo(n),$("").append(t).appendTo(n),n=this.addLabeledRow(this._table,$.t("Background")),$("").append(o).appendTo(n),n=this.addLabeledRow(this._table,$.t("Border")),$("").append(i).appendTo(n),this.bindControl(new l(e,this._linetool.properties().color,!0,this.model(),"Change Price Text Color")),this.bindControl(new r(t,this._linetool.properties().fontsize,parseInt,!0,this.model(),"Change Price Text Font Size")),this.bindControl(new l(o,this._linetool.properties().backgroundColor,!0,this.model(),"Change Background Color",this._linetool.properties().transparency)),this.bindControl(new l(i,this._linetool.properties().borderColor,!0,this.model(),"Change Border Color")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1120:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.SliderBinder,l=a.ColorBinding,p=o(1197).createLineWidthEditor;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n;this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),e=this.createColorPicker(),t=this.createColorPicker(),o=this.addLabeledRow(this._table,"Background"),$("").append(e).appendTo(o),$("").append(t).appendTo(o),i=p(),n=this.createColorPicker(),o=this.addLabeledRow(this._table,"Border"),$("").append(n).appendTo(o),$("").appendTo(o),$("").append(i).appendTo(o),this.bindControl(new l(n,this._linetool.properties().trendline.color,!0,this.model(),"Change Projection Line Color")),this.bindControl(new l(e,this._linetool.properties().color1,!0,this.model(),"Change Projection Background Color",this._linetool.properties().transparency)),this.bindControl(new l(t,this._linetool.properties().color2,!0,this.model(),"Change Projection Background Color",this._linetool.properties().transparency)),this.bindControl(new r(i,this._linetool.properties().linewidth,!0,this.model(),"Change Projection Border Width")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1121:function(e,t,o){"use strict";function i(e,t,o){n.call(this,e,t,o),this.prepareLayout()}var n=o(1196),a=o(239),r=a.ColorBinding,l=a.BooleanBinder,p=a.SliderBinder,s=o(1197).createLineWidthEditor -;inherit(i,n),i.prototype.prepareLayout=function(){var e,t,o,i,n;this._table=$(document.createElement("table")),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2"),e=s(),t=this.createColorPicker(),o=this.addLabeledRow(this._table,"Border"),o.prepend(""),$("").append(t).appendTo(o),$("").append(e).appendTo(o),i=$(''),n=this.createColorPicker(),o=this.addLabeledRow(this._table,"Background",i),$("").append(i).prependTo(o),$("").append(n).appendTo(o),this.bindControl(new l(i,this._linetool.properties().fillBackground,!0,this.model(),"Change Rectangle Filling")),this.bindControl(new r(t,this._linetool.properties().color,!0,this.model(),"Change Rectangle Line Color")),this.bindControl(new r(n,this._linetool.properties().backgroundColor,!0,this.model(),"Change Rectangle Background Color",this._linetool.properties().transparency)),this.bindControl(new p(e,this._linetool.properties().linewidth,!0,this.model(),"Change Rectangle Border Width")),this.loadData()},i.prototype.widget=function(){return this._table},e.exports=i},1122:function(e,t,o){"use strict";function i(e,t){this._chartWidget=e,this._undoModel=t}function n(e,t,o){a.call(this,e,t,o),this.prepareLayout()}var a=o(1196),r=o(239),l=r.SimpleStringBinder,p=r.SimpleComboBinder,s=r.ColorBinding,d=r.BooleanBinder;i.prototype.attachSource=function(e,t){this._source=e,this._edit=$("',textNotesWidgetItem:'
{{title}}
{{#symbol}}
'+i(599)+'{{symbol}}
{{/symbol}}
{{description}}
',tvDataTable:'{{#columns}}{{/columns}}{{#bodies}}{{#strokes}}{{#cells}}{{/cells}}{{/strokes}}{{/bodies}}
{{{label}}}
{{#contain}}{{{contain}}}{{/contain}}
',tvDataTableRow:'
{{#contain}}{{{contain}}}{{/contain}}
{{#contain}}{{{contain}}}{{/contain}}"),$("
").appendTo(e);return $('').appendTo(i)},o.prototype._labelToId=function(t){return"control"+t.replace(/(^| )\w/g,function(t){return"-"+t.trim().toLowerCase()})+Math.floor(1e3*Math.random())},o.prototype.addRow=function(t){return $(document.createElement("tr")).appendTo(t)},o.prototype.addLabeledRow=function(t,e,i,o){var n,r=e&&e.length>0?$.t(e):"",s=$(document.createElement("tr")),a=$(document.createElement("td")).html(r);return o&&a.attr("colspan",2),i&&(n=this._labelToId(e),i.attr("id",n),a.html('")),s.append(a).appendTo(t)},o.prototype.addEditorRow=function(t,e,i,o){var n=$(document.createElement("td"));return i.row=this.addLabeledRow(t,e,i,o),i.appendTo(n.appendTo(i.row)),i},o.prototype.addColorPickerRow=function(t,e){return this.addEditorRow(t,e,this.createColorPicker())},o.prototype.addOffsetEditorRow=function(t,e){var i=$("");return i.attr("type","text"),i.css("width","100px"),i.addClass("ticker"),this.addEditorRow(t,e,i)},o.prototype.addFontEditorRow=function(t,e){return this.addEditorRow(t,e,this.createFontEditor())},o.prototype.refreshStateControls=function(t,e,i){var o,n,r;for(o=0;o0&&(i=e[0],this._control.selectbox("change",i.value,i.text))}catch(t){}},v.prototype.propertyChanged=function(t){var e=t.value();"function"==typeof this._propertyChangedHook&&(e=this._propertyChangedHook(e)),this.setValue(e)},inherit(y,W),y.prototype.value=function(){return this._property.value()},y.prototype.setValue=function(t){return this._control.html(t)},inherit(b,W),b.prototype.value=function(){return this.control().is(":checked")},b.prototype.setValue=function(t){var e,i,o,n -;return this.control().is(".visibility-checker")&&(t?(this.control().closest("tr").find(".slider-range").slider("enable"),this.control().closest("tr").find('input[type="text"]').each(function(){$(this).prop("disabled",!1)})):(this.control().closest("tr").find(".slider-range").slider("disable"),this.control().closest("tr").find('input[type="text"]').each(function(){$(this).prop("disabled",!0)}))),this.control().is(".visibility-switch")&&(e={opacity:t?1:.5},i=t?"enable":"disable",o=this.control().data("hides"),o?o.closest("td").css(e):(n=this.control(),n.parent().parent().data("visible",t).find("td").filter(function(){var t=$(this);return!t.find("label").length&&t.find(":checkbox").attr("id")!==n.attr("id")}).each(function(){var o=$(this);o.children().each(function(){var n=$(this);n.is(".ui-slider")?n.slider(i):n.is("select")?(n.selectbox(i),o.css(e)):n.is(".custom-select")?(n.data(i)(),o.css(e)):n.is(".tvcolorpicker-container")?(n.find("input").prop("disabled",!t),o.css(e)):(n.prop("disabled",!t),o.css(e))})}))),this.control().attr("checked",!!t)},inherit(S,W),S.prototype.value=function(){return this.control().is(":disabled")},S.prototype.setValue=function(t){return t=!!t,this._inverted&&(t=!t),this.control().parents("label").toggleClass("disabled",t),this.control().attr("disabled",t)},inherit(w,W),w.prototype.value=function(){return this.control().hasClass("active")},w.prototype.setValue=function(t){return this.control().toggleClass("active",!!t)},inherit(T,W),T.prototype.applyOldTransparency=function(){var t,e,i;this.transparencyProperty()&&(F.isHexColor(this.property().value())?(t=this.transparencyProperty().value?this.transparencyProperty().value():this.transparencyProperty(),e=O(this.property().value()),i=(100-t)/100,this.control().val(V(D(e,i)))):this.control().val(this.property().value()),this.control().change())},T.prototype.transparencyProperty=function(){return this._transparencyProperty},T.prototype.value=function(){return this._control.val()},T.prototype.setValue=function(t){this._control.val(t),this._control.change(),this._control.color&&this._control.color.fromString(t)},inherit(C,W),C.prototype.value=function(){return this._control.slider("option","value")},C.prototype.setValue=function(t){this._control.slider("option","value",t)},inherit(x,b),x.prototype.onIntervalChanged=function(){+this._intervalProperty.value()<1440?this._control.attr({disabled:!1,checked:!!this._property.value()}):this._control.attr({disabled:!0,checked:!1})},x.prototype.value=function(){return this._control.is(":disabled")?this._property.value():b.prototype.value.call(this)},x.prototype.setValue=function(t){if(!this._control.is(":disabled"))return b.prototype.setValue.call(this,t)},x.prototype.destroy=function(){this._intervalProperty.listeners().unsubscribe(this,this.onIntervalChanged),delete this._intervalProperty,b.prototype.destroy.call(this,arguments)},P.prototype._attachToControl=function(t){var e=this;this._wv.subscribe(this._setValueBinded,{callWithLast:!0}),$(this._control).on("change",function(){ -e.setValueToProperty(e.value())})},P.prototype.control=function(){return this._control},P.prototype.value=function(){var t=$(this._control).val();return this._transformFunction&&(t=this._transformFunction(t)),t},P.prototype.setValue=function(t){$(this._control).val(t)},P.prototype.setValueToProperty=function(t){this._undoModel.undoHistory.setWatchedValue(this._wv,t,this._undoText)},P.prototype.watchedValue=function(){return this._wv},P.prototype.destroy=function(){this._wv.unsubscribe(this._setValueBinded)},inherit(L,P),L.prototype._attachToControl=function(t){var e=this;this._wv.subscribe(this.setValue.bind(this),{callWithLast:!0}),$(this._control).on("click",function(){e.setValueToProperty(e.value())})},L.prototype.value=function(){var t=$(this._control).attr("checked");return this._not&&(t=!t),this._transformFunction&&(t=this._transformFunction(t)),t},L.prototype.setValue=function(t){this._not&&(t=!t),$(this._control).attr("checked",!!t)},I.prototype.properties=function(){return this._properties},I.prototype.value=function(t){return this._control.slider("values",t)},I.prototype.setValue=function(t,e){this._control.slider("values",e,t.value()),this._inputsText&&$(this._inputsText[e]).val(t.value())},I.prototype.propertyChanged=function(t){this.setValue(t)},I.prototype.setValueToProperty=function(t,e){($(e).hasClass("from")||"from"===e)&&(this._undoModel.beginUndoMacro(this._undoText[0]),this._undoModel.setProperty(this._propFrom,t[0],this._undoText[0]),this._propFrom.setValue(t[0],0),this._undoModel.endUndoMacro()),($(e).hasClass("to")||"to"===e)&&(this._undoModel.beginUndoMacro(this._undoText[1]),this._undoModel.setProperty(this._propTo,t[1],this._undoText[1]),this._propTo.setValue(t[1],1),this._undoModel.endUndoMacro())},I.prototype.destroy=function(){this._propFrom&&this._propTo&&(this._propFrom.listeners().unsubscribe(this,W.prototype.propertyChanged),this._propTo.listeners().unsubscribe(this,W.prototype.propertyChanged))},inherit(k,W),k.prototype.value=function(){var t=[];return this._control.each(function(){var e=$(this);e.is(":checked")&&t.push(e.attr("value"))}),t.join(this._separator)},k.prototype.setValue=function(t){var e=t.split(this._separator).filter(Boolean);this._control.each(function(){var t=$(this),i=-1!==e.indexOf(t.attr("value"));t.attr("checked",i),t.parents("label").toggleClass("active",i)})},e.PropertyPage=o,e.UppercaseTransformer=n,e.GreateTransformer=r,e.LessTransformer=s,e.ToIntTransformer=a,e.ToFloatTransformer=l,e.ToFloatTransformerWithDynamicDefaultValue=c,e.ToFloatLimitedPrecisionTransformer=h,e.ToAsciiTransformer=u,e.ReplaceEmptyTransformer=d,e.SimpleStringBinder=p,e.FloatBinder=_,e.SessionBinder=f,e.BarTimeBinder=m,e.SymbolBinder=g,e.SimpleComboBinder=v,e.StaticContentBinder=y,e.BooleanBinder=b,e.DisabledBinder=S,e.ColorBinding=T,e.SliderBinder=C,e.CheckboxWVBinding=L,e.RangeBinder=I}).call(e,i(25))},,function(t,e,i){(function(t){var e={};e.LINESTYLE_SOLID=0,e.LINESTYLE_DOTTED=1,e.LINESTYLE_DASHED=2,e.LINESTYLE_LARGE_DASHED=3,e.LINESTYLE_SPARSE_DOTTED=4,e.TEXTPOS_TOPLEFT=0, -e.TEXTPOS_TOPCENTER=1,e.TEXTPOS_TOPRIGHT=2,e.TEXTPOS_MIDDLELEFT=3,e.TEXTPOS_MIDDLECENTER=4,e.TEXTPOS_MIDDLERIGHT=5,e.TEXTPOS_BOTTOMLEFT=6,e.TEXTPOS_BOTTOMCENTER=7,e.TEXTPOS_BOTTOMRIGHT=8,e.SIZE_AUTO="auto",e.SIZE_TINY="tiny",e.SIZE_SMALL="small",e.SIZE_NORMAL="normal",e.SIZE_LARGE="large",e.SIZE_HUGE="huge",e.MARKLOC_ABOVEBAR="AboveBar",e.MARKLOC_BELOWBAR="BelowBar",e.MARKLOC_TOP="Top",e.MARKLOC_BOTTOM="Bottom",e.MARKLOC_RIGHT="Right",e.MARKLOC_LEFT="Left",e.MARKLOC_ABSOLUTE="Absolute",e.MARKLOC_ABSOLUTEUP="AbsoluteUp",e.MARKLOC_ABSOLUTEDOWN="AbsoluteDown",e.HHISTLOC_RELATIVE="relative",e.HHISTLOC_ABSOLUTE="absolute",e.HHISTDIR_LEFTTORIGHT="left_to_right",e.HHISTDIR_RIGHTTOLEFT="right_to_left",void 0!==t&&t&&t.exports&&(t.exports=e)}).call(e,i(42)(t))},function(t,e,i){"use strict";function o(t){var e,i,o=(t+"").match(/(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/);return null===o?0:(e=o[1]?o[1].length:0,i=o[2]?parseInt(o[2],0):0,Math.max(0,e-i))}function n(t){return t=Math.abs(t),!l.isInteger(t)&&t>1&&(t=parseFloat((""+t).replace(/^.+\./,"0."))),0').appendTo(r.parent()),i=$('
').html(c).appendTo(e),o=$('
').html(c).appendTo(e),e.on("mousedown",function(t){t.preventDefault(),r.focus()}),i.click(function(){r.is(":disabled")||s(r)}),o.click(function(){r.is(":disabled")||a(r)}),r.keydown(function(t){r.is(":disabled")||(38===t.keyCode?i.addClass("i-active"):40===t.keyCode&&o.addClass("i-active"))}),r.keyup(function(t){r.is(":disabled")||(38===t.keyCode?(s(r),i.removeClass("i-active")):40===t.keyCode&&(a(r),o.removeClass("i-active")))}),r.mousewheel(function(t,e){e>0?i.click():o.click()}))})}},,,function(t,e,i){var o,n;!function(r,s){"object"==typeof t&&t.exports?t.exports=s():(o=s,void 0!==(n="function"==typeof o?o.call(e,i,e,t):o)&&(t.exports=n))}(0,function(){"use strict";function t(t,e){var i,o=document.createElement(t||"div");for(i in e)o[i]=e[i] -;return o}function e(t){for(var e=1,i=arguments.length;e',i)}h.addRule(".spin-vml","behavior:url(#default#VML)"),a.prototype.lines=function(t,o){function r(){return n(i("group",{coordsize:h+" "+h,coordorigin:-c+" "+-c}),{width:h,height:h})}function a(t,a,l){e(d,e(n(r(),{rotation:360/o.lines*t+"deg",left:~~a}),e(n(i("roundrect",{arcsize:o.corners}),{width:c,height:o.scale*o.width,left:o.scale*o.radius,top:-o.scale*o.width>>1,filter:l}),i("fill",{color:s(o.color,t),opacity:o.opacity}),i("stroke",{opacity:0}))))}var l,c=o.scale*(o.length+o.width),h=2*o.scale*c,u=-(o.width+o.length)*o.scale*2+"px",d=n(r(),{position:"absolute",top:u,left:u});if(o.shadow)for(l=1;l<=o.lines;l++)a(l,-2,"progid:DXImageTransform.Microsoft.Blur(pixelradius=2,makeshadow=1,shadowopacity=.3)");for(l=1;l<=o.lines;l++)a(l);return e(t,d)},a.prototype.opacity=function(t,e,i,o){var n=t.firstChild;o=o.shadow&&o.lines||0,n&&e+o>1)+"px"})}for(var l,h=0,u=(r.lines-1)*(1-r.direction)/2;h");o.appendTo(t),o.css("padding-left","0px"),o.css("padding-right","0px"),i=$(""),i.attr("type","text"),i.addClass("ticker"),i.css("width","40px"),i.attr("id",e),i.appendTo(o)},r=function(t,e,i){var o,n=$("
");n.css("padding-left",i),n.css("padding-right",i),n.appendTo(t),o=$("
"),o.appendTo(n),o.append(e),o.css("font-size","150%")},s=$(""),s.appendTo(t),a=$(""),a.appendTo(s),c=["start_hours","start_minutes","end_hours","end_minutes"],n.call(this,a,c[0]),r.call(this,a,":",0),n.call(this,a,c[1]),r.call(this,a,"-",4),n.call(this,a,c[2]),r.call(this,a,":",0),n.call(this,a,c[3]),h=!1,this.bindControl(new l(a,c,e,h,this.model(),o))},o.prototype.prepareLayoutImpl=function(e,i){function o(t){return(new v).format(t)}function n(t){return function(e){var i,o,n,r=this,s=null;if(0===e.indexOf("#")){if(i=e.slice(1,e.indexOf("$")),null===(o=it._model.model().getStudyById(i)))return void b.logError("Can not get Study by id "+i);if(o.isStarted()||o.start(null,!0), -!(n=o.sourceId()))return void b.logError("Can not get source id for "+o.metaInfo().id);s=e.replace(/^[^\$]+/,n)}!~e.indexOf("$")&&!~e.indexOf("#")||it._study.isStarted()||it._study.start(null,!0),it._study.testInputValue(t,e)?r.setValueToProperty(s||r.value()):r.setValue(it._property.inputs[t.id].value())}}function l(t){return function(e){var i,o,n,r;if(t.hasOwnProperty(e)||0===e.indexOf("#")||!~e.indexOf("$"))return e;for(i=e.slice(0,e.indexOf("$")),o=it._model.model().allStudies(),n=0;n"),x.appendTo(i),P=$("]","i"),be=/checked\s*(?:[^=]|=\s*.checked.)/i,_e=/\/(java|ecma)script/i,we=/^\s*",""],legend:[1,"
","
"],thead:[1,"
"),P.appendTo(x),P.addClass("propertypage-name-label"),P.text($.t(T,{context:"input"})),L=$(""),L.appendTo(x),I=null,k=null,A=null,"resolution"===S.type)I=$('");else if("symbol"===S.type)I=$(''),g.bindToInput(I,{onPopupOpen:function(t){this._$symbolSearchPopup=t,this._symbolSearchZindex&&t.css("z-index",this._symbolSearchZindex)}.bind(this),onPopupClose:function(){this._$symbolSearchPopup=null}.bind(this)});else if("session"===S.type)this._addSessionEditor(L,this._property.inputs[w],S,C);else if("source"===S.type){for(M={},E={open:window.t("open"),high:window.t("high"),low:window.t("low"),close:window.t("close"),hl2:window.t("hl2"),hlc3:window.t("hlc3"),ohlc4:window.t("ohlc4")},D=Object.keys(E),V=0;V").attr("value",X).text(J).appendTo(I);L.addClass("js-value-cell")}else if(S.options)for(I=$(""),"bool"===S.type?I.attr("type","checkbox"):I.attr("type","text");I&&(I.appendTo(L),I.is(":checkbox")||I.css("width","100px")),S.options?this.bindControl(new _(I,this._property.inputs[w],null,!0,this.model(),C,k,A)):"bar_time"===S.type?(Q=10,this.bindControl(new a(I,this._property.inputs[w],!0,this.model(),C,this.model().mainSeries(),Q)),I.addClass("ticker")):"integer"===S.type?(tt=[d(S.defval)],(0===S.min||S.min)&&tt.push(h(S.min)),(0===S.max||S.max)&&tt.push(u(S.max)),this.bindControl(new m(I,this._property.inputs[w],tt,!1,this.model(),C)),I.addClass("ticker"),isFinite(S.step)&&S.step>0&&I.attr("data-step",S.step)):"float"===S.type?(tt=[p(S.defval)],(0===S.min||S.min)&&tt.push(h(S.min)),(0===S.max||S.max)&&tt.push(u(S.max)),et=new m(I,this._property.inputs[w],tt,!1,this.model(),C),et.addFormatter(o),this.bindControl(et),I.addClass("ticker"),isFinite(S.step)&&S.step>0&&I.attr("data-step",S.step)):"text"===S.type?this.bindControl(new m(I,this._property.inputs[w],null,!1,this.model(),C)):"bool"===S.type?this.bindControl(new f(I,this._property.inputs[w],!0,this.model(),C)):"resolution"===S.type?this.bindControl(new _(I,this._property.inputs[w],r,!0,this.model(),"Change Interval")):"symbol"===S.type&&this.bindControl(new s(I,this._property.inputs[w],!0,this.model(),"Change Symbol"))}this._property.offset&&(T=this._property.offset.title?this._property.offset.title.value():$.t("Offset"),I=this.addOffsetEditorRow(i,T),tt=[d(this._property.offset.val)],tt.push(h(this._property.offset.min)),tt.push(u(this._property.offset.max)),this.bindControl(new m(I,this._property.offset.val,tt,!1,this.model(),"Undo "+T))),this._property.offsets&&$.each(e.plots,function(t,e){var o,n,r,s;this._property.offsets[e.id]&&(o=this._property.offsets[e.id],void 0!==o.isHidden&&o.isHidden.value()||(n=o.title.value(),r=this.addOffsetEditorRow(i,n),s=[d(o.val)],s.push(h(o.min)),s.push(u(o.max)),this.bindControl(new m(r,o.val,s,!1,this.model(),"Undo "+n))))}.bind(this))},o.prototype.prepareLayout=function(){this._table=$(""),this._table.addClass("property-page"),this._table.attr("cellspacing","0"),this._table.attr("cellpadding","2");var t=this._study.metaInfo();this.prepareLayoutImpl(t,this._table),this.loadData()},o.prototype.symbolSearchPopup=function(){return this._$symbolSearchPopup},o.prototype.widget=function(){return this._table},e.StudyInputsPropertyPage=o}).call(e,i(5))},function(t,e,i){"use strict";function o(t){this._data=t,this.bars=t.bars,this._barWidth=n.optimalBarWidth(t.barSpacing),this._barBorderWidth=1}var n=i(45),r=i(11);o.prototype.draw=function(t){ -var e,i,o,n,r,s,a,l,c,h,u,d,p,_,f=this.bars,m=this._data.barSpacing,g=this._data.drawWick,v=this._data.drawBorder,y=this._data.wickColor,b=this._barBorderWidth,S=this._barWidth;if(t.lineCap="square",t.lineStyle=this._data.lineStyle,m<1){if(g){for(t.strokeStyle=y,t.lineWidth=1,t.beginPath(),h=f.length;h-- >0;)u=f[h],t.moveTo(u.time,u.low),t.lineTo(u.time,u.high);t.stroke()}for(t.lineWidth=1,d="",p=!1,t.beginPath(),h=f.length;h-- >0;)u=f[h],c=u.time,d!==u.color&&(p&&(t.stroke(),t.beginPath(),p=!1),t.strokeStyle=u.color,d=u.color),t.moveTo(u.time,u.open),t.lineTo(u.time,u.close),p=!0;p&&t.stroke()}else{if(f=f.slice().sort(function(t,e){return t.color>e.color?-1:t.colora[a.length-1].time+l)return null;for(e=null,i=0;i5&&("width"in t&&(n[3]=Math.min(t.width,Math.max(1,n[3]))),"height"in t&&(n[4]=Math.min(t.height,Math.max(1,n[4])))),i.apply(this,n)},o(n,function(i,o){var n=t[o];t[o]=function(){var t,o;if("all"===i)for(o=[],t=arguments.length;0]+)>)/gi,""):t},TradingView.encodeSpread=function(t){return encodeURIComponent(t)},TradingView.clean=function(t,e,i){var o,n,r,s=[["&","&"],["<","<"],[">",">"],['"',"""],["'","'"],["'","'"]],a=t -;if(!t||!t.replace)return a;for(o=0;o'},function(t,e,i){"use strict";function o(t,e,i,o,n){function r(t){return e&&e[t]?e[t]:t}function s(t,e,i,o){var n=r(e[0]);return!!t.hasOwnProperty(n)&&(e.length>1?s(t[n],e.slice(1),i):(t[n]&&t[n].setValue?t[n].setValue(i):t[n]=i,!0))}function a(t){i||f.logWarn("Path `"+t+"` does not exist.")}var l,c,h,u;if(o)for(l in o)c=l.split("."),h=r(c[0]),u=void 0!==n&&n===c[0],0!==c.length&&u&&(c=c.slice(1),h=r(c[0])),0!==c.length&&t.hasOwnProperty(h)?s(t,c,o[l])||a(l):u&&a(l)}function n(t,e,i,n){window.__defaultsOverrides&&o(t,e,i,window.__defaultsOverrides,n)}function r(){var t=/^linetool.+/;Object.keys(TradingView.defaultProperties).forEach(function(e){t.test(e)&&n(TradingView.defaultProperties[e],null,!1,e)})}function s(t,e){return e?l(t,e):a(t)}function a(t){var e,i=m(t);return window._UNIT_TESTS||(e=TradingView.clone(TVSettings.getJSON(t,null)))&&TradingView.merge(i,e),i}function l(t,e){var i,o,n=m(t);return window._UNIT_TESTS||(i=TradingView.clone(TVSettings.getJSON(t,null)),t.startsWith("study_")&&i&&d.isVersionHead(i.version)&&(o=e.updateStudyState(i,i),i=o),TradingView.merge(n,i)),n}var c=i(49),h=i(300).LineToolPitchforkStyle,u=i(246).LineToolBarsPatternMode,d=i(84),p=i(111).PlotType,_=i(74).LineEnd,f=i(7).getLogger("Chart.Defaults"),m=function(t){var e,i,o,s,a,l,d,f,m={a:function(t,e){return{color:t,visible:e}},b:function(t,e,i){return{coeff:t,color:e,visible:i}},c:function(t,e,i,o,n){return{coeff:t,color:e,visible:i,linestyle:void 0===o?CanvasEx.LINESTYLE_SOLID:o,linewidth:void 0===n?1:n}},d:function(t,e,i){return{color:t,width:i,visible:e}},e:function(t,e,i,o,n){return{color:t,visible:e,width:i,x:o,y:n}},f:function(t,e,i,o,n,r){return{coeff1:t,coeff2:e,color:i,visible:o,linestyle:void 0===n?CanvasEx.LINESTYLE_SOLID:n,linewidth:void 0===r?1:r}}};if(void 0===TradingView.defaultProperties){switch(window.locale){case"ar_AE":e="Asia/Dubai";break;case"au":e="Australia/Sydney";break;case"br":e="America/Sao_Paulo";break;case"ca":e="America/Toronto";break;case"de_DE":case"it":e="Europe/Berlin";break;case"es":e="Europe/Madrid";break;case"fa_IR":e="Asia/Tehran";break;case"fr":case"sv_SE":e="Europe/Paris";break;case"he_IL":case"tr":e="Europe/Athens";break;case"hu_HU":case"pl":e="Europe/Warsaw";break;case"id":case"th_TH":case"vi_VN":e="Asia/Bangkok";break;case"in":e="Asia/Kolkata";break;case"ja":case"kr":e="Asia/Tokyo";break;case"ms_MY":e="Asia/Singapore";break;case"ru":e="Europe/Moscow";break;case"uk":e="Europe/London";break;case"zh_CN":case"zh_TW":e="Asia/Shanghai" -;break;default:e="Etc/UTC"}TradingView.defaultProperties={chartproperties:{timezone:e,dataWindowProperties:{background:"rgba( 255, 254, 206, 0.2)",border:"rgba( 96, 96, 144, 1)",font:"Verdana",fontBold:!1,fontItalic:!1,fontSize:10,transparency:80,visible:!0},paneProperties:{background:"#ffffff",gridProperties:{color:"#e1ecf2",style:CanvasEx.LINESTYLE_SOLID},vertGridProperties:{color:"#e1ecf2",style:CanvasEx.LINESTYLE_SOLID},horzGridProperties:{color:"#e1ecf2",style:CanvasEx.LINESTYLE_SOLID},crossHairProperties:{color:"rgba( 152, 152, 152, 1)",style:CanvasEx.LINESTYLE_DASHED,transparency:0,width:1},topMargin:5,bottomMargin:5,leftAxisProperties:{autoScale:!0,autoScaleDisabled:!1,lockScale:!1,percentage:!1,percentageDisabled:!1,log:!1,logDisabled:!1,alignLabels:!0},rightAxisProperties:{autoScale:!0,autoScaleDisabled:!1,lockScale:!1,percentage:!1,percentageDisabled:!1,log:!1,logDisabled:!1,alignLabels:!0},legendProperties:{showStudyArguments:!0,showStudyTitles:!0,showStudyValues:!0,showSeriesTitle:!0,showSeriesOHLC:!0,showLegend:!0}},scalesProperties:{showLeftScale:!1,showRightScale:!0,backgroundColor:"#ffffff",lineColor:"#555",textColor:"#555",fontSize:11,scaleSeriesOnly:!1,showSeriesLastValue:!0,showSeriesPrevCloseValue:!1,showStudyLastValue:!1,showSymbolLabels:!1,showStudyPlotLabels:!1},mainSeriesProperties:{style:c.STYLE_CANDLES,esdShowDividends:!0,esdShowSplits:!0,esdShowEarnings:!0,esdShowBreaks:!1,esdBreaksStyle:{color:"rgba( 235, 77, 92, 1)",style:CanvasEx.LINESTYLE_DASHED,width:1},esdFlagSize:2,showCountdown:!0,showInDataWindow:!0,visible:!0,silentIntervalChange:!1,showPriceLine:!0,priceLineWidth:1,priceLineColor:"",showPrevClosePriceLine:!1,prevClosePriceLineWidth:1,prevClosePriceLineColor:"rgba( 85, 85, 85, 1)",minTick:"default",extendedHours:!1,sessVis:!1,statusViewStyle:{fontSize:17,showExchange:!0,showInterval:!0,showSymbolAsDescription:!1},candleStyle:{upColor:"#53b987",downColor:"#eb4d5c",drawWick:!0,drawBorder:!0,borderColor:"#378658",borderUpColor:"#53b987",borderDownColor:"#eb4d5c",wickColor:"#737375",wickUpColor:"#a9cdd3",wickDownColor:"#f5a6ae",barColorsOnPrevClose:!1},hollowCandleStyle:{upColor:"rgba( 83, 185, 135, 1)",downColor:"rgba( 255, 77, 92, 1)",drawWick:!0,drawBorder:!0,borderColor:"rgba( 55, 134, 88, 1)",borderUpColor:"rgba( 83, 185, 135, 1)",borderDownColor:"rgba( 255, 77, 92, 1)",wickColor:"rgba( 115, 115, 117, 1)",wickUpColor:"rgba( 169, 220, 195, 1)",wickDownColor:"rgba( 245, 166, 174, 1)"},haStyle:{upColor:"rgba( 83, 185, 135, 1)",downColor:"rgba( 255, 77, 92, 1)",drawWick:!0,drawBorder:!0,borderColor:"rgba( 55, 134, 88, 1)",borderUpColor:"rgba( 83, 185, 135, 1)",borderDownColor:"rgba( 255, 77, 92, 1)",wickColor:"rgba( 115, 115, 117, 1)",wickUpColor:"rgba( 83, 185, 135, 1)",wickDownColor:"rgba( 255, 77, 92, 1)",showRealLastPrice:!1,barColorsOnPrevClose:!1,inputs:{},inputInfo:{}},barStyle:{upColor:"rgba( 83, 185, 135, 1)",downColor:"rgba( 255, 77, 92, 1)",barColorsOnPrevClose:!1,dontDrawOpen:!1},lineStyle:{color:"rgba( 60, 120, 216, 1)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1, -priceSource:"close",styleType:c.STYLE_LINE_TYPE_SIMPLE},areaStyle:{color1:"rgba( 96, 96, 144, 0.5)",color2:"rgba( 1, 246, 245, 0.5)",linecolor:"rgba( 0, 148, 255, 1)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1,priceSource:"close",transparency:50},priceAxisProperties:{autoScale:!0,autoScaleDisabled:!1,lockScale:!1,percentage:!1,percentageDisabled:!1,log:!1,logDisabled:!1},renkoStyle:{upColor:"rgba( 83, 185, 135, 1)",downColor:"rgba( 255, 77, 92, 1)",borderUpColor:"rgba( 83, 185, 135, 1)",borderDownColor:"rgba( 255, 77, 92, 1)",upColorProjection:"rgba( 169, 220, 195, 1)",downColorProjection:"rgba( 245, 166, 174, 1)",borderUpColorProjection:"rgba( 169, 220, 195, 1)",borderDownColorProjection:"rgba( 245, 166, 174, 1)",wickUpColor:"rgba( 83, 185, 135, 1)",wickDownColor:"rgba( 255, 77, 92, 1)",inputs:{source:"close",boxSize:3,style:"ATR",atrLength:14,wicks:!0},inputInfo:{source:{name:"Source"},boxSize:{name:"Box size"},style:{name:"Style"},atrLength:{name:"ATR Length"},wicks:{name:"Wicks"}}},pbStyle:{upColor:"rgba( 83, 185, 135, 1)",downColor:"rgba( 255, 77, 92, 1)",borderUpColor:"rgba( 83, 185, 135, 1)",borderDownColor:"rgba( 255, 77, 92, 1)",upColorProjection:"rgba( 169, 220, 195, 1)",downColorProjection:"rgba( 245, 166, 174, 1)",borderUpColorProjection:"rgba( 169, 220, 195, 1)",borderDownColorProjection:"rgba( 245, 166, 174, 1)",inputs:{source:"close",lb:3},inputInfo:{source:{name:"Source"},lb:{name:"Number of line"}}},kagiStyle:{upColor:"rgba( 83, 185, 135, 1)",downColor:"rgba( 255, 77, 92, 1)",upColorProjection:"rgba( 169, 220, 195, 1)",downColorProjection:"rgba( 245, 166, 174, 1)",inputs:{source:"close",style:"ATR",atrLength:14,reversalAmount:1},inputInfo:{source:{name:"Source"},style:{name:"Style"},atrLength:{name:"ATR Length"},reversalAmount:{name:"Reversal amount"}}},pnfStyle:{upColor:"rgba( 83, 185, 135, 1)",downColor:"rgba( 255, 77, 92, 1)",upColorProjection:"rgba( 169, 220, 195, 1)",downColorProjection:"rgba( 245, 166, 174, 1)",inputs:{sources:"Close",reversalAmount:3,boxSize:1,style:"ATR",atrLength:14},inputInfo:{sources:{name:"Source"},boxSize:{name:"Box size"},reversalAmount:{name:"Reversal amount"},style:{name:"Style"},atrLength:{name:"ATR Length"}}},baselineStyle:{baselineColor:"rgba( 117, 134, 150, 1)",topFillColor1:"rgba( 83, 185, 135, 0.1)",topFillColor2:"rgba( 83, 185, 135, 0.1)",bottomFillColor1:"rgba( 235, 77, 92, 0.1)",bottomFillColor2:"rgba( 235, 77, 92, 0.1)",topLineColor:"rgba( 83, 185, 135, 1)",bottomLineColor:"rgba( 235, 77, 92, 1)",topLineWidth:1,bottomLineWidth:1,priceSource:"close",transparency:50,baseLevelPercentage:50}},symbolWatermarkProperties:{color:"rgba( 85, 85, 85, 0)",transparency:100},chartEventsSourceProperties:{visible:!0,futureOnly:!0,breaks:{color:"rgba(85, 85, 85, 1)",visible:!1,style:CanvasEx.LINESTYLE_DASHED,width:1}},tradingProperties:{showPositions:!0,showOrders:!0,showExecutions:!0,extendLeft:!0,lineLength:5,lineWidth:1,lineStyle:CanvasEx.LINESTYLE_DASHED},alertsProperties:{labels:{visible:!0,color:"rgba( 215, 84, 66, 1)",highlightColor:"rgba( 255, 255, 51, 1)", -hoverColor:"rgba( 245, 227, 135, 1)",line:{visible:!0,style:CanvasEx.LINESTYLE_DASHED,width:1}},fakeLabels:{visible:!0,color:"rgba( 119, 119, 119, 1)",line:{visible:!0,style:CanvasEx.LINESTYLE_DASHED,width:1}},drawingIcon:{color:"rgba( 170, 170, 170, 1)"}},editorFontsList:["Verdana","Courier New","Times New Roman","Arial"],volumePaneSize:"large"},drawings:{magnet:!1,stayInDrawingMode:!1,drawOnAllCharts:!0,crossHairColor:"rgba( 183, 183, 183, 1)",crossHairStyle:CanvasEx.LINESTYLE_DASHED,crossHairWidth:1},linetoolorder:{singleChartOnly:!0,extendLeft:"inherit",lineLength:"inherit",lineColor:"rgba( 255, 0, 0, 1)",lineTransparency:0,lineStyle:"inherit",lineWidth:"inherit",bodyBorderColor:"rgba( 255, 0, 0, 0)",bodyBorderTransparency:0,bodyBackgroundColor:"rgba( 255, 255, 255, 0.75)",bodyBackgroundTransparency:25,bodyTextColor:"rgba( 255, 0, 0, 0)",bodyTextTransparency:0,bodyFontFamily:"Verdana",bodyFontSize:7,bodyFontBold:!0,bodyFontItalic:!1,quantityBorderColor:"rgba( 255, 0, 0, 0)",quantityBorderTransparency:0,quantityBackgroundColor:"rgba( 255, 0, 0, 0.75)",quantityBackgroundTransparency:25,quantityTextColor:"rgba( 255, 255, 255, 1)",quantityTextTransparency:0,quantityFontFamily:"Verdana",quantityFontSize:7,quantityFontBold:!0,quantityFontItalic:!1,cancelButtonBorderColor:"rgba( 255, 0, 0, 1)",cancelButtonBorderTransparency:0,cancelButtonBackgroundColor:"rgba( 255, 255, 255, 0.75)",cancelButtonBackgroundTransparency:25,cancelButtonIconColor:"rgba( 255, 0, 0, 1)",cancelButtonIconTransparency:0,tooltip:""},linetoolposition:{singleChartOnly:!0,extendLeft:"inherit",lineLength:"inherit",lineColor:"rgba( 0, 113, 224, 1)",lineTransparency:0,lineStyle:"inherit",lineWidth:"inherit",bodyBorderColor:"rgba( 0, 113, 224, 1)",bodyBorderTransparency:0,bodyBackgroundColor:"rgba( 255, 255, 255, 0.75)",bodyBackgroundTransparency:25,bodyTextColor:"rgba( 0, 113, 224, 1)",bodyTextTransparency:0,bodyFontFamily:"Verdana",bodyFontSize:7,bodyFontBold:!0,bodyFontItalic:!1,quantityBorderColor:"rgba( 0, 113, 224, 1)",quantityBorderTransparency:0,quantityBackgroundColor:"rgba( 0, 113, 224, 0.75)",quantityBackgroundTransparency:25,quantityTextColor:"rgba( 255, 255, 255, 1)",quantityTextTransparency:0,quantityFontFamily:"Verdana",quantityFontSize:7,quantityFontBold:!0,quantityFontItalic:!1,reverseButtonBorderColor:"rgba( 0, 113, 224, 1)",reverseButtonBorderTransparency:0,reverseButtonBackgroundColor:"rgba( 255, 255, 255, 0.75)",reverseButtonBackgroundTransparency:25,reverseButtonIconColor:"rgba( 0, 113, 224, 1)",reverseButtonIconTransparency:0,closeButtonBorderColor:"rgba( 0, 113, 224, 1)",closeButtonBorderTransparency:0,closeButtonBackgroundColor:"rgba( 255, 255, 255, 0.75)",closeButtonBackgroundTransparency:25,closeButtonIconColor:"rgba( 0, 113, 224, 1)",closeButtonIconTransparency:0,tooltip:""},linetoolexecution:{singleChartOnly:!0,direction:"buy",arrowHeight:8,arrowSpacing:1,arrowColor:"rgba( 0, 0, 255, 1)",arrowTransparency:0,text:"",textColor:"rgba( 0, 0, 0, 1)",textTransparency:0,fontFamily:"Verdana",fontSize:8,fontBold:!1,fontItalic:!1, -tooltip:""},linetoolicon:{singleChartOnly:!0,clonable:!0,color:"rgba( 61, 133, 198, 1)",size:40,icon:61536,angle:.5*Math.PI,scale:1},linetoolbezierquadro:{clonable:!0,linecolor:"rgba( 21, 153, 128, 1)",linewidth:1,fillBackground:!1,backgroundColor:"rgba( 21, 56, 153, 0.5)",transparency:50,linestyle:CanvasEx.LINESTYLE_SOLID,extendLeft:!1,extendRight:!1,leftEnd:_.Normal,rightEnd:_.Normal},linetoolbeziercubic:{clonable:!0,linecolor:"rgba( 21, 153, 128, 1)",linewidth:1,fillBackground:!1,backgroundColor:"rgba( 21, 56, 153, 0.5)",transparency:50,linestyle:CanvasEx.LINESTYLE_SOLID,extendLeft:!1,extendRight:!1,leftEnd:_.Normal,rightEnd:_.Normal},linetooltrendline:{clonable:!0,linecolor:"rgba( 21, 153, 128, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID,extendLeft:!1,extendRight:!1,leftEnd:_.Normal,rightEnd:_.Normal,font:"Verdana",textcolor:"rgba( 21, 119, 96, 1)",fontsize:12,bold:!1,italic:!1,snapTo45Degrees:!0,alwaysShowStats:!1,showMiddlePoint:!1,showPriceRange:!1,showBarsRange:!1,showDateTimeRange:!1,showDistance:!1,showAngle:!1},linetooltimecycles:{clonable:!0,linecolor:"rgba(21, 153, 128, 1)",linewidth:1,fillBackground:!0,backgroundColor:"rgba(106, 168, 79, 0.5)",transparency:50,linestyle:CanvasEx.LINESTYLE_SOLID},linetoolsineline:{clonable:!0,linecolor:"rgba( 21, 153, 128, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID},linetooltrendangle:{singleChartOnly:!0,clonable:!0,linecolor:"rgba( 21, 153, 128, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID,snapTo45Degrees:!0,font:"Verdana",textcolor:"rgba( 21, 119, 96, 1)",fontsize:12,bold:!0,italic:!1,alwaysShowStats:!1,showMiddlePoint:!1,showPriceRange:!1,showBarsRange:!1,extendRight:!1,extendLeft:!1},linetooldisjointangle:{clonable:!0,linecolor:"rgba( 18, 159, 92, 1)",linewidth:2,linestyle:CanvasEx.LINESTYLE_SOLID,fillBackground:!0,backgroundColor:"rgba( 106, 168, 79, 0.5)",transparency:50,extendLeft:!1,extendRight:!1,leftEnd:_.Normal,rightEnd:_.Normal,font:"Verdana",textcolor:"rgba( 18, 159, 92, 1)",fontsize:12,bold:!1,italic:!1,showPrices:!1,showPriceRange:!1,showDateTimeRange:!1,showBarsRange:!1},linetoolflatbottom:{clonable:!0,linecolor:"rgba( 73, 133, 231, 1)",linewidth:2,linestyle:CanvasEx.LINESTYLE_SOLID,fillBackground:!0,backgroundColor:"rgba( 21, 56, 153, 0.5)",transparency:50,extendLeft:!1,extendRight:!1,leftEnd:_.Normal,rightEnd:_.Normal,font:"Verdana",textcolor:"rgba( 73, 133, 231, 1)",fontsize:12,bold:!1,italic:!1,showPrices:!1,showPriceRange:!1,showDateTimeRange:!1,showBarsRange:!1},linetoolfibspiral:{clonable:!0,linecolor:"rgba( 21, 153, 128, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID},linetooldaterange:{clonable:!0,linecolor:"rgba( 88, 88, 88, 1)",linewidth:1,font:"Verdana",textcolor:"rgba( 255, 255, 255, 1)",fontsize:12,fillLabelBackground:!0,labelBackgroundColor:"rgba( 91, 133, 191, 0.9)",labelBackgroundTransparency:30,fillBackground:!0,backgroundColor:"rgba( 186, 218, 255, 0.4)",backgroundTransparency:60,drawBorder:!1,borderColor:"rgba( 102, 123, 139, 1)",extendTop:!1,extendBottom:!1},linetoolpricerange:{clonable:!0, -linecolor:"rgba( 88, 88, 88, 1)",linewidth:1,font:"Verdana",textcolor:"rgba( 255, 255, 255, 1)",fontsize:12,fillLabelBackground:!0,labelBackgroundColor:"rgba( 91, 133, 191, 0.9)",labelBackgroundTransparency:30,fillBackground:!0,backgroundColor:"rgba( 186, 218, 255, 0.4)",backgroundTransparency:60,drawBorder:!1,borderColor:"rgba( 102, 123, 139, 1)",extendLeft:!1,extendRight:!1},linetooldateandpricerange:{clonable:!0,linecolor:"rgba( 88, 88, 88, 1)",linewidth:1,font:"Verdana",textcolor:"rgba( 255, 255, 255, 1)",fontsize:12,fillLabelBackground:!0,labelBackgroundColor:"rgba( 91, 133, 191, 0.9)",labelBackgroundTransparency:30,fillBackground:!0,backgroundColor:"rgba( 186, 218, 255, 0.4)",backgroundTransparency:60,drawBorder:!1,borderColor:"rgba( 102, 123, 139, 1)"},linetoolriskrewardshort:{isShort:!0,clonable:!0,linecolor:"rgba( 88, 88, 88, 1)",linewidth:1,font:"Verdana",textcolor:"rgba(255, 255, 255, 1)",fontsize:12,fillLabelBackground:!0,labelBackgroundColor:"rgba( 88, 88, 88, 1)",labelBackgroundTransparency:0,fillBackground:!0,stopBackground:"rgba( 255, 0, 0, 0.2)",profitBackground:"rgba( 0, 160, 0, 0.2)",stopBackgroundTransparency:80,profitBackgroundTransparency:80,drawBorder:!1,borderColor:"rgba( 102, 123, 139, 1)",compact:!1,riskDisplayMode:"percents",accountSize:1e3,risk:25},linetoolriskrewardlong:{isShort:!1,clonable:!0,linecolor:"rgba( 88, 88, 88, 1)",linewidth:1,font:"Verdana",textcolor:"rgba(255, 255, 255, 1)",fontsize:12,fillLabelBackground:!0,labelBackgroundColor:"rgba( 88, 88, 88, 1)",labelBackgroundTransparency:0,fillBackground:!0,stopBackground:"rgba( 255, 0, 0, 0.2)",profitBackground:"rgba( 0, 160, 0, 0.2)",stopBackgroundTransparency:80,profitBackgroundTransparency:80,drawBorder:!1,borderColor:"rgba( 102, 123, 139, 1)",compact:!1,riskDisplayMode:"percents",accountSize:1e3,risk:25},linetoolarrow:{clonable:!0,linecolor:"rgba( 111, 136, 198, 1)",linewidth:2,linestyle:CanvasEx.LINESTYLE_SOLID,extendLeft:!1,extendRight:!1,leftEnd:_.Normal,rightEnd:_.Arrow,font:"Verdana",textcolor:"rgba( 21, 119, 96, 1)",fontsize:12,bold:!1,italic:!1,alwaysShowStats:!1,showMiddlePoint:!1,showPriceRange:!1,showBarsRange:!1,showDateTimeRange:!1,showDistance:!1,showAngle:!1},linetoolray:{clonable:!0,linecolor:"rgba( 21, 153, 128, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID,extendLeft:!1,extendRight:!0,leftEnd:_.Normal,rightEnd:_.Normal,font:"Verdana",textcolor:"rgba( 21, 119, 96, 1)",fontsize:12,bold:!1,italic:!1,alwaysShowStats:!1,showMiddlePoint:!1,showPriceRange:!1,showBarsRange:!1,showDateTimeRange:!1,showDistance:!1,showAngle:!1},linetoolextended:{clonable:!0,linecolor:"rgba( 21, 153, 128, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID,extendLeft:!0,extendRight:!0,leftEnd:_.Normal,rightEnd:_.Normal,font:"Verdana",textcolor:"rgba( 21, 119, 96, 1)",fontsize:12,bold:!1,italic:!1,alwaysShowStats:!1,showMiddlePoint:!1,showPriceRange:!1,showBarsRange:!1,showDateTimeRange:!1,showDistance:!1,showAngle:!1},linetoolhorzline:{clonable:!0,linecolor:"rgba( 128, 204, 219, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID, -showPrice:!0,showLabel:!1,text:"",font:"Verdana",textcolor:"rgba( 21, 119, 96, 1)",fontsize:12,bold:!1,italic:!1,horzLabelsAlign:"center",vertLabelsAlign:"top"},linetoolhorzray:{clonable:!0,linecolor:"rgba( 128, 204, 219, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID,showPrice:!0,showLabel:!1,text:"",font:"Verdana",textcolor:"rgba( 21, 119, 96, 1)",fontsize:12,bold:!1,italic:!1,horzLabelsAlign:"center",vertLabelsAlign:"top"},linetoolvertline:{clonable:!0,linecolor:"rgba( 128, 204, 219, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID,showTime:!0},linetoolcirclelines:{clonable:!0,trendline:{visible:!0,color:"rgba( 128, 128, 128, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_DASHED},linecolor:"rgba( 128, 204, 219, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID},linetoolfibtimezone:{horzLabelsAlign:"right",vertLabelsAlign:"bottom",clonable:!0,baselinecolor:"rgba( 128, 128, 128, 1)",linecolor:"rgba( 0, 85, 219, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID,showLabels:!0,font:"Verdana",fillBackground:!1,transparency:80,trendline:{visible:!0,color:"rgba( 128, 128, 128, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_DASHED},level1:m.c(0,"rgba( 128, 128, 128, 1)",!0),level2:m.c(1,"rgba( 0, 85, 219, 1)",!0),level3:m.c(2,"rgba( 0, 85, 219, 1)",!0),level4:m.c(3,"rgba( 0, 85, 219, 1)",!0),level5:m.c(5,"rgba( 0, 85, 219, 1)",!0),level6:m.c(8,"rgba( 0, 85, 219, 1)",!0),level7:m.c(13,"rgba( 0, 85, 219, 1)",!0),level8:m.c(21,"rgba( 0, 85, 219, 1)",!0),level9:m.c(34,"rgba( 0, 85, 219, 1)",!0),level10:m.c(55,"rgba( 0, 85, 219, 1)",!0),level11:m.c(89,"rgba( 0, 85, 219, 1)",!0),__collectibleLines:["trendline","level1","level2","level3","level4","level5","level6","level7","level8","level9","level10","level11"]},linetooltext:{clonable:!0,color:"rgba( 102, 123, 139, 1)",text:$.t("Text"),font:"Verdana",fontsize:20,fillBackground:!1,backgroundColor:"rgba( 91, 133, 191, 0.9)",backgroundTransparency:70,drawBorder:!1,borderColor:"rgba( 102, 123, 139, 1)",bold:!1,italic:!1,locked:!1,fixedSize:!0,wordWrap:!1,wordWrapWidth:400},linetooltextabsolute:{singleChartOnly:!0,clonable:!0,color:"rgba( 102, 123, 139, 1)",text:$.t("Text"),font:"Verdana",fontsize:20,fillBackground:!1,backgroundColor:"rgba( 155, 190, 213, 0.3)",backgroundTransparency:70,drawBorder:!1,borderColor:"rgba( 102, 123, 139, 1)",bold:!1,italic:!1,locked:!0,wordWrap:!1,wordWrapWidth:400},linetoolballoon:{clonable:!0,color:"rgba( 102, 123, 139, 1)",backgroundColor:"rgba( 255, 254, 206, 0.7)",borderColor:"rgba( 140, 140, 140, 1)",fontWeight:"bold",fontsize:12,font:"Arial",transparency:30,text:$.t("Comment")},linetoolbrush:{clonable:!0,linecolor:"rgba( 53, 53, 53, 1)",linewidth:2,linestyle:CanvasEx.LINESTYLE_SOLID,smooth:5,fillBackground:!1,backgroundColor:"rgba( 21, 56, 153, 0.5)",transparency:50,leftEnd:_.Normal,rightEnd:_.Normal},linetoolpolyline:{clonable:!0,linecolor:"rgba( 53, 53, 53, 1)",linewidth:2,linestyle:CanvasEx.LINESTYLE_SOLID,fillBackground:!0,backgroundColor:"rgba( 21, 56, 153, 0.5)",transparency:50,filled:!1},linetoolarrowmark:{clonable:!0, -color:"rgba( 120, 120, 120, 1)",text:"",fontsize:20,font:"Verdana"},linetoolarrowmarkleft:{clonable:!0,color:"rgba( 120, 120, 120, 1)",text:"",fontsize:20,font:"Verdana"},linetoolarrowmarkup:{clonable:!0,color:"rgba( 120, 120, 120, 1)",text:"",fontsize:20,font:"Verdana"},linetoolarrowmarkright:{clonable:!0,color:"rgba( 120, 120, 120, 1)",text:"",fontsize:20,font:"Verdana"},linetoolarrowmarkdown:{clonable:!0,color:"rgba( 120, 120, 120, 1)",text:"",fontsize:20,font:"Verdana"},linetoolflagmark:{clonable:!0,color:"rgba( 255, 0, 0, 1)"},linetoolnote:{clonable:!0,markerColor:"rgba( 46, 102, 255, 1)",textColor:"rgba( 0, 0, 0, 1)",backgroundColor:"rgba( 255, 255, 255, 1)",backgroundTransparency:0,text:$.t("Text"),font:"Arial",fontSize:12,bold:!1,italic:!1,locked:!1,fixedSize:!0},linetoolnoteabsolute:{singleChartOnly:!0,clonable:!0,markerColor:"rgba( 46, 102, 255, 1)",textColor:"rgba( 0, 0, 0, 1)",backgroundColor:"rgba( 255, 255, 255, 1)",backgroundTransparency:0,text:$.t("Text"),font:"Arial",fontSize:12,bold:!1,italic:!1,locked:!0,fixedSize:!0},linetoolthumbup:{clonable:!0,color:"rgba( 0, 128, 0, 1)"},linetoolthumbdown:{clonable:!0,color:"rgba( 255, 0, 0, 1)"},linetoolpricelabel:{clonable:!0,color:"rgba( 102, 123, 139, 1)",backgroundColor:"rgba( 255, 255, 255, 0.7)",borderColor:"rgba( 140, 140, 140, 1)",fontWeight:"bold",fontsize:11,font:"Arial",transparency:30},linetoolrectangle:{clonable:!0,color:"rgba( 21, 56, 153, 1)",fillBackground:!0,backgroundColor:"rgba( 21, 56, 153, 0.5)",linewidth:1,snapTo45Degrees:!0,transparency:50},linetoolrotatedrectangle:{clonable:!0,color:"rgba( 152, 0, 255, 1)",fillBackground:!0,backgroundColor:"rgba( 142, 124, 195, 0.5)",transparency:50,linewidth:1,snapTo45Degrees:!0},linetoolellipse:{clonable:!0,color:"rgba( 153, 153, 21, 1)",fillBackground:!0,backgroundColor:"rgba( 153, 153, 21, 0.5)",transparency:50,linewidth:1},linetoolarc:{clonable:!0,color:"rgba( 153, 153, 21, 1)",fillBackground:!0,backgroundColor:"rgba( 153, 153, 21, 0.5)",transparency:50,linewidth:1},linetoolprediction:{singleChartOnly:!0,linecolor:"rgba( 28, 115, 219, 1)",linewidth:2,sourceBackColor:"rgba( 241, 241, 241, 1)",sourceTextColor:"rgba( 110, 110, 110, 1)",sourceStrokeColor:"rgba( 110, 110, 110, 1)",targetStrokeColor:"rgba( 47, 168, 255, 1)",targetBackColor:"rgba( 11, 111, 222, 1)",targetTextColor:"rgba( 255, 255, 255, 1)",successBackground:"rgba( 54, 160, 42, 0.9)",successTextColor:"rgba( 255, 255, 255, 1)",failureBackground:"rgba( 231, 69, 69, 0.5)",failureTextColor:"rgba( 255, 255, 255, 1)",intermediateBackColor:"rgba( 234, 210, 137, 1)",intermediateTextColor:"rgba( 109, 77, 34, 1)",transparency:10,centersColor:"rgba( 32, 32, 32, 1)"},linetooltriangle:{clonable:!0,color:"rgba( 153, 21, 21, 1)",fillBackground:!0,backgroundColor:"rgba( 153, 21, 21, 0.5)",transparency:50,linewidth:1},linetoolcallout:{clonable:!0,color:"rgba( 255, 255, 255, 1)",backgroundColor:"rgba( 153, 21, 21, 0.5)",transparency:50,linewidth:2,fontsize:12,font:"Verdana",text:$.t("Text"),bordercolor:"rgba( 153, 21, 21, 1)",bold:!1,italic:!1,wordWrap:!1, -wordWrapWidth:400},linetoolparallelchannel:{clonable:!0,linecolor:"rgba( 119, 52, 153, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID,extendLeft:!1,extendRight:!1,fillBackground:!0,backgroundColor:"rgba( 180, 167, 214, 0.5)",transparency:50,showMidline:!1,midlinecolor:"rgba( 119, 52, 153, 1)",midlinewidth:1,midlinestyle:CanvasEx.LINESTYLE_DASHED},linetoolelliottimpulse:{degree:7,clonable:!0,showWave:!0,color:"rgba( 61, 133, 198, 1)",linewidth:1},linetoolelliotttriangle:{degree:7,clonable:!0,showWave:!0,color:"rgba( 255, 152, 0, 1)",linewidth:1},linetoolelliotttriplecombo:{degree:7,clonable:!0,showWave:!0,color:"rgba( 106, 168, 79, 1)",linewidth:1},linetoolelliottcorrection:{degree:7,clonable:!0,showWave:!0,color:"rgba( 61, 133, 198, 1)",linewidth:1},linetoolelliottdoublecombo:{degree:7,clonable:!0,showWave:!0,color:"rgba( 106, 168, 79, 1)",linewidth:1},linetoolbarspattern:{singleChartOnly:!0,color:"rgba( 80, 145, 204, 1)",clonable:!0,mode:u.Bars,mirrored:!1,flipped:!1},linetoolghostfeed:{singleChartOnly:!0,clonable:!0,averageHL:20,variance:50,candleStyle:{upColor:"#6ba583",downColor:"#d75442",drawWick:!0,drawBorder:!0,borderColor:"#378658",borderUpColor:"#225437",borderDownColor:"#5b1a13",wickColor:"#737375"},transparency:50},study:{inputs:{},styles:{},palettes:{},bands:{},area:{},graphics:{},showInDataWindow:!0,visible:!0,showStudyArguments:!0,precision:"default"},linetoolpitchfork:{clonable:!0,fillBackground:!0,transparency:80,style:h.Original,median:{visible:!0,color:"rgba( 165, 0, 0, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID},level0:m.c(.25,"rgba( 160, 107, 0, 1)",!1),level1:m.c(.382,"rgba( 105, 158, 0, 1)",!1),level2:m.c(.5,"rgba( 0, 155, 0, 1)",!0),level3:m.c(.618,"rgba( 0, 153, 101, 1)",!1),level4:m.c(.75,"rgba( 0, 101, 153, 1)",!1),level5:m.c(1,"rgba( 0, 0, 153, 1)",!0),level6:m.c(1.5,"rgba( 102, 0, 153, 1)",!1),level7:m.c(1.75,"rgba( 153, 0, 102, 1)",!1),level8:m.c(2,"rgba( 165, 0, 0, 1)",!1),__collectibleLines:["median","level0","level1","level2","level3","level4","level5","level6","level7","level8"]},linetoolpitchfan:{clonable:!0,fillBackground:!0,transparency:80,median:{visible:!0,color:"rgba( 165, 0, 0, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID},level0:m.c(.25,"rgba( 160, 107, 0, 1)",!1),level1:m.c(.382,"rgba( 105, 158, 0, 1)",!1),level2:m.c(.5,"rgba( 0, 155, 0, 1)",!0),level3:m.c(.618,"rgba( 0, 153, 101, 1)",!1),level4:m.c(.75,"rgba( 0, 101, 153, 1)",!1),level5:m.c(1,"rgba( 0, 0, 153, 1)",!0),level6:m.c(1.5,"rgba( 102, 0, 153, 1)",!1),level7:m.c(1.75,"rgba( 153, 0, 102, 1)",!1),level8:m.c(2,"rgba( 165, 0, 0, 1)",!1),__collectibleLines:["median","level0","level1","level2","level3","level4","level5","level6","level7","level8"]},linetoolgannfan:{clonable:!0,showLabels:!0,font:"Verdana",fillBackground:!0,transparency:80,level1:m.f(1,8,"rgba( 160, 107, 0, 1)",!0),level2:m.f(1,4,"rgba( 105, 158, 0, 1)",!0),level3:m.f(1,3,"rgba( 0, 155, 0, 1)",!0),level4:m.f(1,2,"rgba( 0, 153, 101, 1)",!0),level5:m.f(1,1,"rgba( 128, 128, 128, 1)",!0),level6:m.f(2,1,"rgba( 0, 101, 153, 1)",!0), -level7:m.f(3,1,"rgba( 0, 0, 153, 1)",!0),level8:m.f(4,1,"rgba( 102, 0, 153, 1)",!0),level9:m.f(8,1,"rgba( 165, 0, 0, 1)",!0),__collectibleLines:["level1","level2","level3","level4","level5","level6","level7","level8","level9","level10","level11"]},linetoolganncomplex:{clonable:!0,fillBackground:!1,arcsBackground:{fillBackground:!0,transparency:80},reverse:!1,scaleRatio:"",showLabels:!0,labelsStyle:{font:"Verdana",fontSize:12,bold:!1,italic:!1},levels:[m.d("rgba( 128, 128, 128, 1)",!0,1),m.d("rgba( 160, 107, 0, 1)",!0,1),m.d("rgba( 105, 158, 0, 1)",!0,1),m.d("rgba( 0, 155, 0, 1)",!0,1),m.d("rgba( 0, 153, 101, 1)",!0,1),m.d("rgba( 128, 128, 128, 1)",!0,1)],fanlines:[m.e("rgba( 165, 0, 255, 1)",!1,1,8,1),m.e("rgba( 165, 0, 0, 1)",!1,1,5,1),m.e("rgba( 128, 128, 128, 1)",!1,1,4,1),m.e("rgba( 160, 107, 0, 1)",!1,1,3,1),m.e("rgba( 105, 158, 0, 1)",!0,1,2,1),m.e("rgba( 0, 155, 0, 1)",!0,1,1,1),m.e("rgba( 0, 153, 101, 1)",!0,1,1,2),m.e("rgba( 0, 153, 101, 1)",!1,1,1,3),m.e("rgba( 0, 0, 153, 1)",!1,1,1,4),m.e("rgba( 102, 0, 153, 1)",!1,1,1,5),m.e("rgba( 165, 0, 255, 1)",!1,1,1,8)],arcs:[m.e("rgba( 160, 107, 0, 1)",!0,1,1,0),m.e("rgba( 160, 107, 0, 1)",!0,1,1,1),m.e("rgba( 160, 107, 0, 1)",!0,1,1.5,0),m.e("rgba( 105, 158, 0, 1)",!0,1,2,0),m.e("rgba( 105, 158, 0, 1)",!0,1,2,1),m.e("rgba( 0, 155, 0, 1)",!0,1,3,0),m.e("rgba( 0, 155, 0, 1)",!0,1,3,1),m.e("rgba( 0, 153, 101, 1)",!0,1,4,0),m.e("rgba( 0, 153, 101, 1)",!0,1,4,1),m.e("rgba( 0, 0, 153, 1)",!0,1,5,0),m.e("rgba( 0, 0, 153, 1)",!0,1,5,1)],__collectibleLines:["trendline","levels.0","levels.1","levels.2","levels.3","levels.4","levels.5","fanlines.0","fanlines.1","fanlines.2","fanlines.3","fanlines.4","fanlines.5","fanlines.6","fanlines.7","fanlines.8","fanlines.9","fanlines.10","arcs.0","arcs.1","arcs.2","arcs.3","arcs.4","arcs.5","arcs.6","arcs.7","arcs.8","arcs.9","arcs.10"]},linetoolgannfixed:{clonable:!0,fillBackground:!1,arcsBackground:{fillBackground:!0,transparency:80},reverse:!1,levels:[m.d("rgba( 128, 128, 128, 1)",!0,1),m.d("rgba( 160, 107, 0, 1)",!0,1),m.d("rgba( 105, 158, 0, 1)",!0,1),m.d("rgba( 0, 155, 0, 1)",!0,1),m.d("rgba( 0, 153, 101, 1)",!0,1),m.d("rgba( 128, 128, 128, 1)",!0,1)],fanlines:[m.e("rgba( 165, 0, 255, 1)",!1,1,8,1),m.e("rgba( 165, 0, 0, 1)",!1,1,5,1),m.e("rgba( 128, 128, 128, 1)",!1,1,4,1),m.e("rgba( 160, 107, 0, 1)",!1,1,3,1),m.e("rgba( 105, 158, 0, 1)",!0,1,2,1),m.e("rgba( 0, 155, 0, 1)",!0,1,1,1),m.e("rgba( 0, 153, 101, 1)",!0,1,1,2),m.e("rgba( 0, 153, 101, 1)",!1,1,1,3),m.e("rgba( 0, 0, 153, 1)",!1,1,1,4),m.e("rgba( 102, 0, 153, 1)",!1,1,1,5),m.e("rgba( 165, 0, 255, 1)",!1,1,1,8)],arcs:[m.e("rgba( 160, 107, 0, 1)",!0,1,1,0),m.e("rgba( 160, 107, 0, 1)",!0,1,1,1),m.e("rgba( 160, 107, 0, 1)",!0,1,1.5,0),m.e("rgba( 105, 158, 0, 1)",!0,1,2,0),m.e("rgba( 105, 158, 0, 1)",!0,1,2,1),m.e("rgba( 0, 155, 0, 1)",!0,1,3,0),m.e("rgba( 0, 155, 0, 1)",!0,1,3,1),m.e("rgba( 0, 153, 101, 1)",!0,1,4,0),m.e("rgba( 0, 153, 101, 1)",!0,1,4,1),m.e("rgba( 0, 0, 153, 1)",!0,1,5,0),m.e("rgba( 0, 0, 153, 1)",!0,1,5,1)], -__collectibleLines:["trendline","levels.0","levels.1","levels.2","levels.3","levels.4","levels.5","fanlines.0","fanlines.1","fanlines.2","fanlines.3","fanlines.4","fanlines.5","fanlines.6","fanlines.7","fanlines.8","fanlines.9","fanlines.10","arcs.0","arcs.1","arcs.2","arcs.3","arcs.4","arcs.5","arcs.6","arcs.7","arcs.8","arcs.9","arcs.10"]},linetoolgannsquare:{clonable:!0,color:"rgba( 21, 56, 153, 0.8)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID,font:"Verdana",showTopLabels:!0,showBottomLabels:!0,showLeftLabels:!0,showRightLabels:!0,fillHorzBackground:!0,horzTransparency:80,fillVertBackground:!0,vertTransparency:80,reverse:!1,fans:m.a("rgba( 128, 128, 128, 1)",!1),hlevel1:m.b(0,"rgba( 128, 128, 128, 1)",!0),hlevel2:m.b(.25,"rgba( 160, 107, 0, 1)",!0),hlevel3:m.b(.382,"rgba( 105, 158, 0, 1)",!0),hlevel4:m.b(.5,"rgba( 0, 155, 0, 1)",!0),hlevel5:m.b(.618,"rgba( 0, 153, 101, 1)",!0),hlevel6:m.b(.75,"rgba( 0, 101, 153, 1)",!0),hlevel7:m.b(1,"rgba( 128, 128, 128, 1)",!0),vlevel1:m.b(0,"rgba( 128, 128, 128, 1)",!0),vlevel2:m.b(.25,"rgba( 160, 107, 0, 1)",!0),vlevel3:m.b(.382,"rgba( 105, 158, 0, 1)",!0),vlevel4:m.b(.5,"rgba( 0, 155, 0, 1)",!0),vlevel5:m.b(.618,"rgba( 0, 153, 101, 1)",!0),vlevel6:m.b(.75,"rgba( 0, 101, 153, 1)",!0),vlevel7:m.b(1,"rgba( 128, 128, 128, 1)",!0),__collectibleLines:["fans","hlevel1","hlevel2","hlevel3","hlevel4","hlevel5","hlevel6","hlevel7","vlevel1","vlevel2","vlevel3","vlevel4","vlevel5","vlevel6","vlevel7"]},linetoolfibspeedresistancefan:{clonable:!0,fillBackground:!0,transparency:80,grid:{color:"rgba( 128, 128, 128, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID,visible:!0},linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID,font:"Verdana",showTopLabels:!0,showBottomLabels:!0,showLeftLabels:!0,showRightLabels:!0,snapTo45Degrees:!0,hlevel1:m.b(0,"rgba( 128, 128, 128, 1)",!0),hlevel2:m.b(.25,"rgba( 160, 107, 0, 1)",!0),hlevel3:m.b(.382,"rgba( 105, 158, 0, 1)",!0),hlevel4:m.b(.5,"rgba( 0, 155, 0, 1)",!0),hlevel5:m.b(.618,"rgba( 0, 153, 101, 1)",!0),hlevel6:m.b(.75,"rgba( 0, 101, 153, 1)",!0),hlevel7:m.b(1,"rgba( 128, 128, 128, 1)",!0),vlevel1:m.b(0,"rgba( 128, 128, 128, 1)",!0),vlevel2:m.b(.25,"rgba( 160, 107, 0, 1)",!0),vlevel3:m.b(.382,"rgba( 105, 158, 0, 1)",!0),vlevel4:m.b(.5,"rgba( 0, 155, 0, 1)",!0),vlevel5:m.b(.618,"rgba( 0, 153, 101, 1)",!0),vlevel6:m.b(.75,"rgba( 0, 101, 153, 1)",!0),vlevel7:m.b(1,"rgba( 128, 128, 128, 1)",!0),__collectibleLines:["trendline","hlevel1","hlevel2","hlevel3","hlevel4","hlevel5","hlevel6","hlevel7","vlevel1","vlevel2","vlevel3","vlevel4","vlevel5","vlevel6","vlevel7"]},linetoolfibretracement:{clonable:!0,showCoeffs:!0,showPrices:!0,font:"Verdana",fillBackground:!0,transparency:80,extendLines:!1,horzLabelsAlign:"left",vertLabelsAlign:"middle",reverse:!1,coeffsAsPercents:!1,trendline:{visible:!0,color:"rgba( 128, 128, 128, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_DASHED},levelsStyle:{linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID},level1:m.b(0,"rgba( 128, 128, 128, 1)",!0),level2:m.b(.236,"rgba( 204, 40, 40, 1)",!0), -level3:m.b(.382,"rgba( 149, 204, 40, 1)",!0),level4:m.b(.5,"rgba( 40, 204, 40, 1)",!0),level5:m.b(.618,"rgba( 40, 204, 149, 1)",!0),level6:m.b(.786,"rgba( 40, 149, 204, 1)",!0),level7:m.b(1,"rgba( 128, 128, 128, 1)",!0),level8:m.b(1.618,"rgba( 40, 40, 204, 1)",!0),level9:m.b(2.618,"rgba( 204, 40, 40, 1)",!0),level10:m.b(3.618,"rgba( 149, 40, 204, 1)",!0),level11:m.b(4.236,"rgba( 204, 40, 149, 1)",!0),level12:m.b(1.272,"rgba( 149, 204, 40, 1)",!1),level13:m.b(1.414,"rgba( 204, 40, 40, 1)",!1),level16:m.b(2,"rgba( 40, 204, 149, 1)",!1),level14:m.b(2.272,"rgba( 149, 204, 40, 1)",!1),level15:m.b(2.414,"rgba( 40, 204, 40, 1)",!1),level17:m.b(3,"rgba( 40, 149, 204, 1)",!1),level18:m.b(3.272,"rgba( 128, 128, 128, 1)",!1),level19:m.b(3.414,"rgba( 40, 40, 204, 1)",!1),level20:m.b(4,"rgba( 204, 40, 40, 1)",!1),level21:m.b(4.272,"rgba( 149, 40, 204, 1)",!1),level22:m.b(4.414,"rgba( 204, 40, 149, 1)",!1),level23:m.b(4.618,"rgba( 149, 204, 40, 1)",!1),level24:m.b(4.764,"rgba( 40, 204, 149, 1)",!1),__collectibleLines:["trendline","level1","level2","level3","level4","level5","level6","level7","level8","level9","level10","level11","level12","level13","level14","level15","level16","level17","level18","level19","level20","level21","level22","level23","level24"]},linetoolfibchannel:{clonable:!0,showCoeffs:!0,showPrices:!0,font:"Verdana",fillBackground:!0,transparency:80,extendLeft:!1,extendRight:!1,horzLabelsAlign:"left",vertLabelsAlign:"middle",coeffsAsPercents:!1,levelsStyle:{linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID},level1:m.b(0,"rgba( 128, 128, 128, 1)",!0),level2:m.b(.236,"rgba( 204, 40, 40, 1)",!0),level3:m.b(.382,"rgba( 149, 204, 40, 1)",!0),level4:m.b(.5,"rgba( 40, 204, 40, 1)",!0),level5:m.b(.618,"rgba( 40, 204, 149, 1)",!0),level6:m.b(.786,"rgba( 40, 149, 204, 1)",!0),level7:m.b(1,"rgba( 128, 128, 128, 1)",!0),level8:m.b(1.618,"rgba( 40, 40, 204, 1)",!0),level9:m.b(2.618,"rgba( 204, 40, 40, 1)",!0),level10:m.b(3.618,"rgba( 149, 40, 204, 1)",!0),level11:m.b(4.236,"rgba( 204, 40, 149, 1)",!0),level12:m.b(1.272,"rgba( 149, 204, 40, 1)",!1),level13:m.b(1.414,"rgba( 204, 40, 40, 1)",!1),level16:m.b(2,"rgba( 40, 204, 149, 1)",!1),level14:m.b(2.272,"rgba( 149, 204, 40, 1)",!1),level15:m.b(2.414,"rgba( 40, 204, 40, 1)",!1),level17:m.b(3,"rgba( 40, 149, 204, 1)",!1),level18:m.b(3.272,"rgba( 128, 128, 128, 1)",!1),level19:m.b(3.414,"rgba( 40, 40, 204, 1)",!1),level20:m.b(4,"rgba( 204, 40, 40, 1)",!1),level21:m.b(4.272,"rgba( 149, 40, 204, 1)",!1),level22:m.b(4.414,"rgba( 204, 40, 149, 1)",!1),level23:m.b(4.618,"rgba( 149, 204, 40, 1)",!1),level24:m.b(4.764,"rgba( 40, 204, 149, 1)",!1),__collectibleLines:["level1","level2","level3","level4","level5","level6","level7","level8","level9","level10","level11","level12","level13","level14","level15","level16","level17","level18","level19","level20","level21","level22","level23","level24"]},linetoolprojection:{clonable:!0,showCoeffs:!0,font:"Verdana",fillBackground:!0,transparency:80,color1:"rgba( 0, 128, 0, 0.2)",color2:"rgba( 255, 0, 0, 0.2)",linewidth:1,trendline:{visible:!0, -color:"rgba( 128, 128, 128, 1)",linestyle:CanvasEx.LINESTYLE_SOLID},level1:m.c(1,"rgba( 128, 128, 128, 1)",!0)},linetool5pointspattern:{clonable:!0,color:"rgba( 204, 40, 149, 1)",textcolor:"rgba( 255, 255, 255, 1)",fillBackground:!0,backgroundColor:"rgba( 204, 40, 149, 0.5)",font:"Verdana",fontsize:12,bold:!1,italic:!1,transparency:50,linewidth:1},linetoolcypherpattern:{clonable:!0,color:"#CC2895",textcolor:"#FFFFFF",fillBackground:!0,backgroundColor:"#CC2895",font:"Verdana",fontsize:12,bold:!1,italic:!1,transparency:50,linewidth:1},linetooltrianglepattern:{clonable:!0,color:"rgba( 149, 40, 255, 1)",textcolor:"rgba( 255, 255, 255, 1)",fillBackground:!0,backgroundColor:"rgba( 149, 40, 204, 0.5)",font:"Verdana",fontsize:12,bold:!1,italic:!1,transparency:50,linewidth:1},linetoolabcd:{clonable:!0,color:"rgba( 0, 155, 0, 1)",textcolor:"rgba( 255, 255, 255, 1)",font:"Verdana",fontsize:12,bold:!1,italic:!1,linewidth:2},linetoolthreedrivers:{clonable:!0,color:"rgba( 149, 40, 255, 1)",textcolor:"rgba( 255, 255, 255, 1)",fillBackground:!0,backgroundColor:"rgba( 149, 40, 204, 0.5)",font:"Verdana",fontsize:12,bold:!1,italic:!1,transparency:50,linewidth:2},linetoolheadandshoulders:{clonable:!0,color:"rgba( 69, 104, 47, 1)",textcolor:"rgba( 255, 255, 255, 1)",fillBackground:!0,backgroundColor:"rgba( 69, 168, 47, 0.5)",font:"Verdana",fontsize:12,bold:!1,italic:!1,transparency:50,linewidth:2},linetoolfibwedge:{singleChartOnly:!0,clonable:!0,showCoeffs:!0,font:"Verdana",fillBackground:!0,transparency:80,trendline:{visible:!0,color:"rgba( 128, 128, 128, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID},level1:m.c(.236,"rgba( 204, 40, 40, 1)",!0),level2:m.c(.382,"rgba( 149, 204, 40, 1)",!0),level3:m.c(.5,"rgba( 40, 204, 40, 1)",!0),level4:m.c(.618,"rgba( 40, 204, 149, 1)",!0),level5:m.c(.786,"rgba( 40, 149, 204, 1)",!0),level6:m.c(1,"rgba( 128, 128, 128, 1)",!0),level7:m.c(1.618,"rgba( 40, 40, 204, 1)",!1),level8:m.c(2.618,"rgba( 204, 40, 40, 1)",!1),level9:m.c(3.618,"rgba( 149, 40, 204, 1)",!1),level10:m.c(4.236,"rgba( 204, 40, 149, 1)",!1),level11:m.c(4.618,"rgba( 204, 40, 149, 1)",!1),__collectibleLines:["trendline","level1","level2","level3","level4","level5","level6","level7","level8","level9","level10","level11"]},linetoolfibcircles:{clonable:!0,showCoeffs:!0,font:"Verdana",fillBackground:!0,transparency:80,snapTo45Degrees:!0,coeffsAsPercents:!1,trendline:{visible:!0,color:"rgba( 128, 128, 128, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_DASHED},level1:m.c(.236,"rgba( 204, 40, 40, 1)",!0),level2:m.c(.382,"rgba( 149, 204, 40, 1)",!0),level3:m.c(.5,"rgba( 40, 204, 40, 1)",!0),level4:m.c(.618,"rgba( 40, 204, 149, 1)",!0),level5:m.c(.786,"rgba( 40, 149, 204, 1)",!0),level6:m.c(1,"rgba( 128, 128, 128, 1)",!0),level7:m.c(1.618,"rgba( 40, 40, 204, 1)",!0),level8:m.c(2.618,"rgba( 204, 40, 40, 1)",!0),level9:m.c(3.618,"rgba( 149, 40, 204, 1)",!0),level10:m.c(4.236,"rgba( 204, 40, 149, 1)",!0),level11:m.c(4.618,"rgba( 204, 40, 149, 1)",!0), -__collectibleLines:["trendline","level1","level2","level3","level4","level5","level6","level7","level8","level9","level10","level11"]},linetoolfibspeedresistancearcs:{clonable:!0,showCoeffs:!0,font:"Verdana",fillBackground:!0,transparency:80,fullCircles:!1,trendline:{visible:!0,color:"rgba( 128, 128, 128, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_DASHED},level1:m.c(.236,"rgba( 204, 40, 40, 1)",!0),level2:m.c(.382,"rgba( 149, 204, 40, 1)",!0),level3:m.c(.5,"rgba( 40, 204, 40, 1)",!0),level4:m.c(.618,"rgba( 40, 204, 149, 1)",!0),level5:m.c(.786,"rgba( 40, 149, 204, 1)",!0),level6:m.c(1,"rgba( 128, 128, 128, 1)",!0),level7:m.c(1.618,"rgba( 40, 40, 204, 1)",!0),level8:m.c(2.618,"rgba( 204, 40, 40, 1)",!0),level9:m.c(3.618,"rgba( 149, 40, 204, 1)",!0),level10:m.c(4.236,"rgba( 204, 40, 149, 1)",!0),level11:m.c(4.618,"rgba( 204, 40, 149, 1)",!0),__collectibleLines:["trendline","level1","level2","level3","level4","level5","level6","level7","level8","level9","level10","level11"]},linetooltrendbasedfibextension:{clonable:!0,showCoeffs:!0,showPrices:!0,font:"Verdana",fillBackground:!0,transparency:80,extendLines:!1,horzLabelsAlign:"left",vertLabelsAlign:"middle",reverse:!1,coeffsAsPercents:!1,trendline:{visible:!0,color:"rgba( 128, 128, 128, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_DASHED},levelsStyle:{linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID},level1:m.b(0,"rgba( 128, 128, 128, 1)",!0),level2:m.b(.236,"rgba( 204, 40, 40, 1)",!0),level3:m.b(.382,"rgba( 149, 204, 40, 1)",!0),level4:m.b(.5,"rgba( 40, 204, 40, 1)",!0),level5:m.b(.618,"rgba( 40, 204, 149, 1)",!0),level6:m.b(.786,"rgba( 40, 149, 204, 1)",!0),level7:m.b(1,"rgba( 128, 128, 128, 1)",!0),level8:m.b(1.618,"rgba( 40, 40, 204, 1)",!0),level9:m.b(2.618,"rgba( 204, 40, 40, 1)",!0),level10:m.b(3.618,"rgba( 149, 40, 204, 1)",!0),level11:m.b(4.236,"rgba( 204, 40, 149, 1)",!0),level12:m.b(1.272,"rgba( 149, 204, 40, 1)",!1),level13:m.b(1.414,"rgba( 204, 40, 40, 1)",!1),level16:m.b(2,"rgba( 40, 204, 149, 1)",!1),level14:m.b(2.272,"rgba( 149, 204, 40, 1)",!1),level15:m.b(2.414,"rgba( 40, 204, 40, 1)",!1),level17:m.b(3,"rgba( 40, 149, 204, 1)",!1),level18:m.b(3.272,"rgba( 128, 128, 128, 1)",!1),level19:m.b(3.414,"rgba( 40, 40, 204, 1)",!1),level20:m.b(4,"rgba( 204, 40, 40, 1)",!1),level21:m.b(4.272,"rgba( 149, 40, 204, 1)",!1),level22:m.b(4.414,"rgba( 204, 40, 149, 1)",!1),level23:m.b(4.618,"rgba( 149, 204, 40, 1)",!1),level24:m.b(4.764,"rgba( 40, 204, 149, 1)",!1),__collectibleLines:["trendline","level1","level2","level3","level4","level5","level6","level7","level8","level9","level10","level11","level12","level13","level14","level15","level16","level17","level18","level19","level20","level21","level22","level23","level24"]},linetooltrendbasedfibtime:{clonable:!0,showCoeffs:!0,font:"Verdana",fillBackground:!0,transparency:80,horzLabelsAlign:"right",vertLabelsAlign:"bottom",trendline:{visible:!0,color:"rgba( 128, 128, 128, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_DASHED},level1:m.c(0,"rgba( 128, 128, 128, 1)",!0),level2:m.c(.382,"rgba( 204, 40, 40, 1)",!0), -level3:m.c(.5,"rgba( 149, 204, 40, 1)",!1),level4:m.c(.618,"rgba( 40, 204, 40, 1)",!0),level5:m.c(1,"rgba( 40, 204, 149, 1)",!0),level6:m.c(1.382,"rgba( 40, 149, 204, 1)",!0),level7:m.c(1.618,"rgba( 128, 128, 128, 1)",!0),level8:m.c(2,"rgba( 40, 40, 204, 1)",!0),level9:m.c(2.382,"rgba( 204, 40, 40, 1)",!0),level10:m.c(2.618,"rgba( 149, 40, 204, 1)",!0),level11:m.c(3,"rgba( 204, 40, 149, 1)",!0),__collectibleLines:["trendline","level1","level2","level3","level4","level5","level6","level7","level8","level9","level10","level11"]},linetoolschiffpitchfork:{clonable:!0,fillBackground:!0,transparency:80,style:h.Schiff,median:{visible:!0,color:"rgba( 165, 0, 0, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID},level0:m.c(.25,"rgba( 160, 107, 0, 1)",!1),level1:m.c(.382,"rgba( 105, 158, 0, 1)",!1),level2:m.c(.5,"rgba( 0, 155, 0, 1)",!0),level3:m.c(.618,"rgba( 0, 153, 101, 1)",!1),level4:m.c(.75,"rgba( 0, 101, 153, 1)",!1),level5:m.c(1,"rgba( 0, 0, 153, 1)",!0),level6:m.c(1.5,"rgba( 102, 0, 153, 1)",!1),level7:m.c(1.75,"rgba( 153, 0, 102, 1)",!1),level8:m.c(2,"rgba( 165, 0, 0, 1)",!1),__collectibleLines:["median","level0","level1","level2","level3","level4","level5","level6","level7","level8"]},linetoolschiffpitchfork2:{clonable:!0,fillBackground:!0,transparency:80,style:h.Schiff2,median:{visible:!0,color:"rgba( 165, 0, 0, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID},level0:m.c(.25,"rgba( 160, 107, 0, 1)",!1),level1:m.c(.382,"rgba( 105, 158, 0, 1)",!1),level2:m.c(.5,"rgba( 0, 155, 0, 1)",!0),level3:m.c(.618,"rgba( 0, 153, 101, 1)",!1),level4:m.c(.75,"rgba( 0, 101, 153, 1)",!1),level5:m.c(1,"rgba( 0, 0, 153, 1)",!0),level6:m.c(1.5,"rgba( 102, 0, 153, 1)",!1),level7:m.c(1.75,"rgba( 153, 0, 102, 1)",!1),level8:m.c(2,"rgba( 165, 0, 0, 1)",!1),__collectibleLines:["median","level0","level1","level2","level3","level4","level5","level6","level7","level8"]},linetoolinsidepitchfork:{clonable:!0,fillBackground:!0,transparency:80,style:h.Inside,median:{visible:!0,color:"rgba( 165, 0, 0, 1)",linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID},level0:m.c(.25,"rgba( 160, 107, 0, 1)",!1),level1:m.c(.382,"rgba( 105, 158, 0, 1)",!1),level2:m.c(.5,"rgba( 0, 155, 0, 1)",!0),level3:m.c(.618,"rgba( 0, 153, 101, 1)",!1),level4:m.c(.75,"rgba( 0, 101, 153, 1)",!1),level5:m.c(1,"rgba( 0, 0, 153, 1)",!0),level6:m.c(1.5,"rgba( 102, 0, 153, 1)",!1),level7:m.c(1.75,"rgba( 153, 0, 102, 1)",!1),level8:m.c(2,"rgba( 165, 0, 0, 1)",!1),__collectibleLines:["median","level0","level1","level2","level3","level4","level5","level6","level7","level8"]},linetool:{frozen:!1,visible:!0},linetoolvisibilities:{intervalsVisibilities:{seconds:!0,secondsFrom:1,secondsTo:59,minutes:!0,minutesFrom:1,minutesTo:59,hours:!0,hoursFrom:1,hoursTo:24,days:!0,daysFrom:1,daysTo:366,weeks:!0,months:!0}}},n(TradingView.defaultProperties.chartproperties),r()}for(void 0===TradingView.defaultProperties["study_MA@tv-basicstudies"]&&(TradingView.defaultProperties["study_MA@tv-basicstudies"]={description:"Moving Average",shortDescription:"MA",inputs:{length:9,source:"close"},styles:{ -MovAvg:{visible:!0,color:"rgba( 4, 150, 255, 1)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1,plottype:p.Line,histogramBase:0,title:"MA"}}}),void 0===TradingView.defaultProperties["study_ErrorOnUpdate@tv-basicstudies"]&&(TradingView.defaultProperties["study_ErrorOnUpdate@tv-basicstudies"]={description:"Error On Update",styles:{ErrorOnUpdate:{visible:!0,color:"rgba( 255, 0, 0, 1)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1,plottype:p.Line,histogramBase:0}}}),void 0===TradingView.defaultProperties["study_ErrorOnCreate@tv-basicstudies"]&&(TradingView.defaultProperties["study_ErrorOnCreate@tv-basicstudies"]={description:"Error On Create",styles:{ErrorOnUpdate:{visible:!0,color:"rgba( 0, 255, 0, 1)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1,plottype:p.Line,histogramBase:0}}}),void 0===TradingView.defaultProperties["study_ErrorOnNewBar@tv-basicstudies"]&&(TradingView.defaultProperties["study_ErrorOnNewBar@tv-basicstudies"]={description:"Error On New Bar",styles:{ErrorOnUpdate:{visible:!0,color:"rgba( 0, 0, 255, 1)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1,plottype:p.Line,histogramBase:0}}}),void 0===TradingView.defaultProperties["study_PivotPointsHighLow@tv-basicstudies"]&&(TradingView.defaultProperties["study_PivotPointsHighLow@tv-basicstudies"]={font:"Arial",fontsize:10,borderColor:"rgba( 83, 143, 31, 1)",backColor:"rgba( 240, 255, 204, 1)",textColor:"rgba( 0, 0, 0, 1)"}),void 0===TradingView.defaultProperties["study_PivotPointsStandard@tv-basicstudies"]&&(i="rgba( 212, 121, 40, 1)",o=!0,s=1,TradingView.defaultProperties["study_PivotPointsStandard@tv-basicstudies"]={_hardCodedDefaultsVersion:1,font:"Arial",fontsize:11,levelsStyle:{showLabels:!0,visibility:{P:o,"S1/R1":o,"S2/R2":o,"S3/R3":o,"S4/R4":o,"S5/R5":o},colors:{P:i,"S1/R1":i,"S2/R2":i,"S3/R3":i,"S4/R4":i,"S5/R5":i},widths:{P:s,"S1/R1":s,"S2/R2":s,"S3/R3":s,"S4/R4":s,"S5/R5":s}}}),void 0===TradingView.defaultProperties["study_ZigZag@tv-basicstudies"]&&(TradingView.defaultProperties["study_ZigZag@tv-basicstudies"]={color:"rgba( 86, 135, 29, 1)",linewidth:2}),void 0===TradingView.defaultProperties["study_ElliottWave@tv-basicstudies"]&&(TradingView.defaultProperties["study_ElliottWave@tv-basicstudies"]={inputs:{},level0:m.a("rgba( 255, 0, 0, 1)",!1),level1:m.a("rgba( 0, 128, 0, 1)",!1),level2:m.a("rgba( 0, 0, 255, 1)",!1),level3:m.a("rgba( 255, 0, 255, 1)",!1),level4:m.a("rgba( 0, 128, 255, 1)",!0),level5:m.a("rgba( 255, 0, 0, 1)",!0),level6:m.a("rgba( 0, 128, 0, 1)",!0),level7:m.a("rgba( 0, 0, 255, 1)",!0),level8:m.a("rgba( 255, 0, 255, 1)",!0)}),void 0===TradingView.defaultProperties["study_LinearRegression@tv-basicstudies"]&&(TradingView.defaultProperties["study_LinearRegression@tv-basicstudies"]={styles:{upLine:{visible:!0,color:"rgba( 0, 0, 255, 0.3)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1},downLine:{visible:!0,color:"rgba( 0, 0, 255, 0.3)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1},baseLine:{visible:!0,color:"rgba( 255, 0, 0, 0.3)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1},extendLines:!0,showPearsons:!0, -backgroundColor:"rgba( 153, 21, 21, 0.3)",transparency:70}}),void 0===TradingView.defaultProperties["study_RegressionTrend@tv-basicstudies"]&&(TradingView.defaultProperties["study_RegressionTrend@tv-basicstudies"]={linewidth:1,linestyle:CanvasEx.LINESTYLE_SOLID,styles:{upLine:{visible:!0,color:"rgba( 0, 0, 255, 0.3)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1},downLine:{visible:!0,color:"rgba( 0, 0, 255, 0.3)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1},baseLine:{visible:!0,color:"rgba( 255, 0, 0, 0.3)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1},extendLines:!1,showPearsons:!0,transparency:70}}),void 0===TradingView.defaultProperties["study_Compare@tv-basicstudies"]&&(TradingView.defaultProperties["study_Compare@tv-basicstudies"]={minTick:"default"}),void 0===TradingView.defaultProperties["study_Overlay@tv-basicstudies"]&&(a="study_Overlay@tv-basicstudies",TradingView.defaultProperties[a]={style:c.STYLE_BARS,showPriceLine:!1,minTick:"default",candleStyle:{upColor:"rgba( 107, 165, 131, 1)",downColor:"rgba( 215, 84, 66, 1)",drawWick:!0,drawBorder:!0,borderColor:"rgba( 55, 134, 88, 1)",borderUpColor:"rgba( 34, 84, 55, 1)",borderDownColor:"rgba( 91, 26, 19, 1)",wickColor:"rgba( 115, 115, 117, 1)",wickUpColor:"rgba( 115, 115, 117, 1)",wickDownColor:"rgba( 115, 115, 117, 1)",barColorsOnPrevClose:!1},hollowCandleStyle:{upColor:"rgba( 107, 165, 131, 1)",downColor:"rgba( 215, 84, 66, 1)",drawWick:!0,drawBorder:!0,borderColor:"rgba( 55, 134, 88, 1)",borderUpColor:"rgba( 34, 84, 55, 1)",borderDownColor:"rgba( 91, 26, 19, 1)",wickColor:"rgba( 115, 115, 117, 1)",wickUpColor:"rgba( 115, 115, 117, 1)",wickDownColor:"rgba( 115, 115, 117, 1)",barColorsOnPrevClose:!1},barStyle:{upColor:"rgba( 107, 165, 131, 1)",downColor:"rgba( 215, 84, 66, 1)",barColorsOnPrevClose:!1,dontDrawOpen:!1},lineStyle:{color:"rgba( 3, 3, 247, 1)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1,priceSource:"close",styleType:c.STYLE_LINE_TYPE_SIMPLE},areaStyle:{color1:"rgba( 96, 96, 144, 0.5)",color2:"rgba( 1, 246, 245, 0.5)",linecolor:"rgba( 0, 148, 255, 1)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1,priceSource:"close",transparency:50},baselineStyle:{baselineColor:"rgba( 117, 134, 150, 1)",topFillColor1:"rgba( 83, 185, 135, 0.1)",topFillColor2:"rgba( 83, 185, 135, 0.1)",bottomFillColor1:"rgba( 235, 77, 92, 0.1)",bottomFillColor2:"rgba( 235, 77, 92, 0.1)",topLineColor:"rgba( 83, 185, 135, 1)",bottomLineColor:"rgba( 235, 77, 92, 1)",topLineWidth:1,bottomLineWidth:1,priceSource:"close",transparency:50,baseLevelPercentage:50},styles:{open:{visible:!0,color:"rgba( 255, 0, 0, 1)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1,plottype:p.Line,histogramBase:0},high:{visible:!0,color:"rgba( 255, 0, 0, 1)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1,plottype:p.Line,histogramBase:0},low:{visible:!0,color:"rgba( 255, 0, 0, 1)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1,plottype:p.Line,histogramBase:0},close:{visible:!0,color:"rgba( 255, 0, 0, 1)",linestyle:CanvasEx.LINESTYLE_SOLID,linewidth:1,plottype:p.Line,histogramBase:0}}}),l=t.split("."), -d=TradingView.defaultProperties,f=0;ft._major?1:this._minort._minor?1:0},t.prototype.isLess=function(t){return this.compareTo(t)<0},t.prototype.isLessOrEqual=function(t){return this.compareTo(t)<=0},t.prototype.isEqual=function(t){return 0===this.compareTo(t)},t.prototype.isGreater=function(t){return this.compareTo(t)>0},t.prototype.isGreaterOrEqual=function(t){return this.compareTo(t)>=0},t.parse=function(e){var i,n,r;if(e instanceof t)return new t(e.major(),e.minor());if("number"==typeof e)return o.assert(Math.floor(e)===e,"Version should not be a float number"),new t(e,0);if("string"==typeof e){if(i=e.split("."),1===i.length)return n=parseInt(i[0],10),o.assert(!isNaN(n),"Bad version string: "+e),new t(n,0);if(2===i.length)return n=parseInt(i[0],10),o.assert(!isNaN(n),"Bad version string: "+e),r=parseInt(i[1],10),o.assert(!isNaN(r),"Bad version string: "+e),new t(n,r);throw Error("Bad version string (one dot expected): "+e)}throw Error("Bad version: "+e)},t.ZERO=new t(0,0),t}(),e.Version=n},function(t,e,i){"use strict";function o(t){this._studyId=t,this._maxToVers=n.ZERO,this._maxFromVers=n.ZERO,this._migrs=[]}var n=i(301).Version,r=i(7).getLogger("Chart.StudyMigration");o.prototype.addMigration=function(t,e,i){var o=n.parse(t),r=n.parse(e);o.isGreater(this._maxFromVers)&&(this._maxFromVers=o),r.isGreater(this._maxToVers)&&(this._maxToVers=r),this._migrs.push({fromVers:o,toVers:r,rules:i})},o.prototype.updateInputs=function(t,e,i){var o,n,s;if(!i)return i;for(o=TradingView.clone(i),n=t;n.isLess(e)&&null!=(s=this._findMigration(n));){ -if(r.logNormal("Migrating study inputs from "+s.fromVers+" to "+s.toVers+" version, studyId: "+this._studyId+", migration: "+JSON.stringify(s)+", inputs: "+JSON.stringify(i)),o=this._applyMigration(o,s),!n.isLess(s.toVers))throw Error("Problems in study migration process... Possible infinite cycle has been detected and stopped.");n=s.toVers}return n>t&&r.logNormal("Study inputs migration is done, studyId: "+this._studyId+", inputs: "+JSON.stringify(o)),o},o.prototype._findMigration=function(t){var e,i,o=-1,n=this._maxFromVers;for(e=0;e=0||e.indexOf(t)>=0},o._applyInputChangedMinMaxRule=function(t,e){if("adjustValIfNeeded"!==e.action)throw Error("Unknown action "+e.action+" for rule with type "+e.type);var i=t[e.inputId];return ie.maxVal&&(t[e.inputId]=e.maxVal),r.logNormal("Input "+e.inputId+"="+i+" adjusted to value "+t[e.inputId]),t},o._applyInputChangedOptionsRule=function(t,e){if(!(["text"].indexOf(e.inputType)>=0&&"resetToDefValIfNeeded"===e.action))throw Error("Unexpected rule.inputType="+e.inputType+" in rule.action="+e.action);var i=t[e.inputId];return e.options.indexOf(i)<0&&(t[e.inputId]=e.defVal,r.logNormal("Input "+e.inputId+"="+i+" reset to default value "+e.defVal)),t},t.exports=o},function(t,e){ -t.exports=''},function(t,e){t.exports=''},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t){return t.reduce(function(t,e,i){return~t.indexOf(e)||t.push(e),t},[])},t.exports=e.default},function(t,e){t.exports=''},function(t,e,i){"use strict";var o,n,r,s,a;Object.defineProperty(e,"__esModule",{value:!0}),o=i(24),n=i(5),r=i(17),s=!n.enabled("hide_left_toolbar_by_default"),a=o.getBool("ChartDrawingToolbarWidget.visible",s),e.isDrawingToolbarVisible=new r(a)},function(t,e,i){"use strict";function o(t){var e=t.action,i=t.isActive,o=t.isBgFull,a=t.isHidden,l=t.isTransparent,c=t.toolName;return n.createElement(s.ToolButton,{icon:r.lineToolsInfo[c].icon,isActive:i,isBgFull:o,isHidden:a,isTransparent:l,onClick:e,title:r.lineToolsInfo[c].localizedName})}var n,r,s;Object.defineProperty(e,"__esModule",{value:!0}),n=i(2),r=i(66),s=i(151),e.ToolButtonAction=o},function(t,e,i){"use strict";function o(){var t,e,i=[];for(i=i.concat([61536,61537,61538,61539]),i=i.concat([61725,61726]),i=i.concat([61575,61576,61796,61797]),i=i.concat([61779,61780,61781,61782,61783,61784,61785,61786]),t=i.slice(0),e=61440;e<=61846;e++)-1===i.indexOf(e)&&(e%16==15&&61487!==e||e>=61620&&e<=61630||61718!==e&&61719!==e&&61472!==e&&61619!==e&&t.push(e));return t}Object.defineProperty(e,"__esModule",{value:!0}), -e.availableIcons=o()},function(t,e,i){"use strict";var o,n,r;Object.defineProperty(e,"__esModule",{value:!0}),o=i(10),n=i(24),function(t){function e(e){return t.favorites.indexOf(e)}function i(){t.favorites=[],n.getJSON("chart.favoriteDrawings",[]).forEach(function(e){t.favorites.push(e.tool||e)}),t.favoritesSynced.fire()}function r(){n.setJSON("chart.favoriteDrawings",t.favorites)}t.favorites=[],t.favoritesSynced=new o,t.favoriteIndex=e,t.saveFavorites=r,i(),n.onSync.subscribe(null,i)}(r||(r={})),function(t){function e(){return r.favorites.slice()}function i(){return r.favorites.length}function n(t){return t<0||t>=i()?"":r.favorites[t]}function s(e){return!l(e)&&(r.favorites.push(e),r.saveFavorites(),t.favoriteAdded.fire(e),!0)}function a(e){var i=r.favoriteIndex(e);return-1!==i&&(r.favorites.splice(i,1),r.saveFavorites(),t.favoriteRemoved.fire(e),!0)}function l(t){return-1!==r.favoriteIndex(t)}function c(e,o){if(o<0||o>=i())return!1;var n=r.favoriteIndex(e);return-1!==n&&o!==n&&(r.favorites.splice(n,1),r.favorites.splice(o,0,e),r.saveFavorites(),t.favoriteMoved.fire(e,n,o),!0)}t.favoriteAdded=new o,t.favoriteRemoved=new o,t.favoriteMoved=new o,t.favoritesSynced=r.favoritesSynced,t.favorites=e,t.favoritesCount=i,t.favorite=n,t.addFavorite=s,t.removeFavorite=a,t.isFavorite=l,t.moveFavorite=c}(e.LinetoolsFavoritesStore||(e.LinetoolsFavoritesStore={}))},function(t,e,i){"use strict";function o(t,e){var i=L.colorsPalette[t];if(!i)throw Error("No such color "+t);return i}function n(t){return!t.isPrivate}function r(){return e.themes[e.watchedTheme.value()]||e.themes[e.DEFAULT_THEME]}function s(t){return r().getThemedColor(t)}function a(t){e.watchedTheme.setValue(t)}function l(){a(T.getValue(I)||e.DEFAULT_THEME)}function c(){return T.getValue(I)||null}function h(){T.setValue(I,r().name,{forceFlush:!0})}function u(t){return C.loadTheme(t)}function d(){return C.loadThemes()}function p(){return x.getStdThemeNames()}function _(t){return x.getStdChartTheme(t).then(function(t){return t||{content:void 0}})}function f(){return x.getStdThemes()}function m(t,e){return C.saveTheme(t,e)}function g(t){return C.removeTheme(t)}function v(t){return C.isThemeExist(t)}function y(t){return x.translateThemeName(t)}function b(t){return x.isStdTheme(t)}function S(t){return{content:{chartProperties:{paneProperties:t.m_model.properties().paneProperties.state(),scalesProperties:t.m_model.properties().scalesProperties.state()},mainSourceProperties:t.m_model.m_mainSeries.properties().state()}}}var w,T,C,x,P,L,I,k;Object.defineProperty(e,"__esModule",{value:!0}),i(738),i(12),w=i(17),T=i(24),C=i(739),x=i(741),P=i(742),L=i(743),e.themes=(k={},k[x.StdTheme.Light]={name:x.StdTheme.Light,label:window.t("Light",{context:"colorThemeName"}),className:"theme-light",order:2,getThemedColor:function(t){return o(t)}},k[x.StdTheme.Dark]={name:x.StdTheme.Dark,label:window.t("Dark",{context:"colorThemeName"}),className:"theme-dark",order:1,getThemedColor:function(t){return o(P[t])}},k),e.DEFAULT_THEME="light",e.watchedTheme=new w,e.watchedTheme.subscribe(function(t){ -var i=document.getElementsByTagName("html")[0];Object.keys(e.themes).forEach(function(t){i.classList.remove(e.themes[t].className)}),i.classList.add(e.themes[t].className)}),e.isPublicTheme=n,e.getCurrentTheme=r,e.setThemedColor=s,e.setTheme=a,I="current_theme.name",e.restoreTheme=l,e.savedThemeName=c,e.syncTheme=h,e.getTheme=u,e.getThemeNames=d,e.getStdThemeNames=p,e.getStdTheme=_,e.getStdThemes=f,e.saveTheme=m,e.removeTheme=g,e.isThemeExist=v,e.translateStdThemeName=y,e.isStdTheme=b,e.extractThemeFromModel=S},function(t,e,i){"use strict";var o=i(23),n=i(15).parseJSONorNot,r=i(7).getLogger("Chart.SaveloadAdapter.Library"),s=function(){var t,e,i,s,a={},l=null;return a.setCustomAdapter=function(t){l=t,r.logNormal("Use custom save-load adapter")},a.initialize=function(o,n,r,a){t=o,e=n,i=r,s=a},a.updateUser=function(t){e=t},a.getCharts=function(o,a){function c(t){t=t.map(function(t){return{id:t.id,name:t.name,image_url:t.id,modified_iso:t.timestamp,short_symbol:t.symbol,interval:t.resolution}}),o(t)}return l?void l.getAllCharts().then(c).catch(a):$.ajax({url:"{0}/{1}/charts?client={2}&user={3}".format(i,encodeURIComponent(s),encodeURIComponent(t),encodeURIComponent(e)),type:"GET",crossDomain:!0}).done(function(t){var e=n(t);if("ok"!==e.status)return r.logWarn("Charts list request failed: "+e.message),void a();c(e.data)}).fail(a)},a.removeChart=function(o,a){if(l)return void l.removeChart(o).then(a);$.ajax({url:"{0}/{1}/charts?client={2}&user={3}&chart={4}".format(i,encodeURIComponent(s),encodeURIComponent(t),encodeURIComponent(e),encodeURIComponent(o)),type:"DELETE",crossDomain:!0}).done(function(t){var e=n(t);"ok"!==e.status&&r.logWarn("Chart delete request failed: "+e.message),a()})},a.saveChart=function(o,a,c,h,u,d,p){var _,f=u.id.value(),m={name:o,content:JSON.stringify(h),symbol:a,resolution:c};if(l)return m.id=f,void l.saveChart(m).then(d).catch(p);_="{0}/{1}/charts?client={2}&user={3}".format(i,encodeURIComponent(s),encodeURIComponent(t),encodeURIComponent(e)),void 0!==f&&(_+="&chart="+encodeURIComponent(f)),$.ajax({url:_,data:m,type:"POST",crossDomain:!0}).done(function(t){var e=n(t);if("ok"!==e.status)return r.logWarn("Chart save request failed: "+e.message),void p();d(e.id)}).fail(function(){p()})},a.getChartContent=function(o,a,c){function h(t){var e=JSON.parse(t);return e.uid=o.id,e}if(l)return void l.getChartContent(o.id).then(function(t){var e=h(t);a(e)}).catch(c);$.ajax({url:"{0}/{1}/charts?client={2}&user={3}&chart={4}".format(i,encodeURIComponent(s),encodeURIComponent(t),encodeURIComponent(e),encodeURIComponent(o.id)),type:"GET",crossDomain:!0}).done(function(t){var e,i=n(t);if("ok"!==i.status)return void r.logWarn("Chart load request failed: "+i.message);e=h(i.data.content),a(e)}).fail(function(){c&&c()})},a.loadChart=function(t){a.getChartContent(t,function(t){o.emit("chart_load_requested",t)},function(){r.logWarn("Error loading chart")})},a.removeStudyTemplate=function(o,a){if(l)return void l.removeStudyTemplate({name:o}).then(a);$.ajax({ -url:"{0}/{1}/study_templates?client={2}&user={3}&template={4}".format(i,encodeURIComponent(s),encodeURIComponent(t),encodeURIComponent(e),encodeURIComponent(o)),type:"DELETE",crossDomain:!0}).done(function(t){var e=n(t);"ok"!==e.status&&r.logWarn("Chart delete request failed: "+e.message),a()})},a.getStudyTemplateContent=function(o,r){if(l)return void l.getStudyTemplateContent({name:o}).then(function(t){r({content:t})});$.ajax({url:"{0}/{1}/study_templates?client={2}&user={3}&template={4}".format(i,encodeURIComponent(s),encodeURIComponent(t),encodeURIComponent(e),encodeURIComponent(o)),type:"GET",crossDomain:!0}).done(function(t){r(n(t).data)})},a.saveStudyTemplate=function(o,a){var c={name:o.name,content:o.content};if(l)return void l.saveStudyTemplate(c).then(a.bind(null,{error:""})).catch(function(t){a({error:null!=t?""+t:"error"})});$.ajax({url:"{0}/{1}/study_templates?client={2}&user={3}".format(i,encodeURIComponent(s),encodeURIComponent(t),encodeURIComponent(e)),type:"POST",crossDomain:!0,data:c}).done(function(t){var e=n(t);"ok"!==e.status&&r.logWarn("Template save request failed: "+e.message),a({error:"ok"===e.status?"":e.status})})},a._templatesCache=null,a.getStudyTemplatesList=function(o){function c(t){t=t.map(function(t){return{is_default:!1,name:t.name}}),a._templatesCache=t,o(t)}return a._templatesCache?void o(a._templatesCache):(a._templatesCache=[],l?void l.getAllStudyTemplates().then(c):void $.ajax({url:"{0}/{1}/study_templates?client={2}&user={3}".format(i,encodeURIComponent(s),encodeURIComponent(t),encodeURIComponent(e)),type:"GET",crossDomain:!0}).done(function(t){if(null!==a._templatesCache){var e=n(t);if("ok"!==e.status)return void r.logWarn("Templates list request failed: "+e.message);c(e.data)}}))},a.invalidateStudyTemplatesList=function(){a._templatesCache=null},a}();t.exports=s},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o={SELECT:"select"};e.events=o},function(t,e,i){"use strict";function o(t){return t.replace(r,s)}function n(t){return void 0===t&&(t=""),t.replace(/(<([^>]+)>)/gi,"")}var r,s;Object.defineProperty(e,"__esModule",{value:!0}),r=/[<"'&>]/g,s=function(t){return"&#"+t.charCodeAt(0)+";"},e.htmlEscape=o,e.removeTags=n},function(t,e,i){"use strict";function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var n;Object.defineProperty(e,"__esModule",{value:!0}),n=function(){function t(t,e){var i,o;for(i=0;i0&&void 0!==arguments[0]?arguments[0]:"keydown";o(this,t),this._event=e}return n(t,[{key:"regHandlers",value:function(t){this._handlers=t}},{key:"watchOn",value:function(t){this._listener=this._regListener(),this._watchingEl=t,t.addEventListener(this._event,this._listener)}},{key:"stopWatching",value:function(){ -this._watchingEl.removeEventListener(this._event,this._listener)}},{key:"_regListener",value:function(){var t=this;return function(e){var i=e.which,o=t._getHandler(i);e.stopPropagation(),o(e)}}},{key:"_getHandler",value:function(t){var e=this._handlers[t],i=function(){},o=function(t){t.preventDefault(),e(t)};return e?o:i}}]),t}()},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o={SELECT:"select",SELECT_CUSTOM:"selectCustom",AFTER_CLOSE_MENU:"afterCloseMenu",BEFORE_OPEN_MENU:"beforeOpenMenu"};e.events=o},function(t,e,i){"use strict";function o(t,e,i){e.toggleClass("i-hidden",""===t.val()),i.fire(t.val())}function n(t){var e,i,n,s=$(l);return t.addClass&&s.addClass(t.addClass),t.withoutControls&&s.addClass("tv-search-row--without-controls"),e=s.find(".js-input-control"),i=s.find(".js-reset-button"),t.placeholder&&e.attr("placeholder",t.placeholder),i[0].addEventListener("click",function(){e.val("").trigger("input").focus()}),n=new r,e.on("input propertychange",o.bind(null,e,i,n)),o(e,i,n),{$control:s,$input:e,inputChangedDelegate:n}}var r,s,a,l;Object.defineProperty(e,"__esModule",{value:!0}),r=i(10),s=i(384),a=i(763),i(764),l='
'+s+''+a+"
",e.createSearchControl=n},function(t,e,i){"use strict";function o(t){this._options=t||{},this._setInput(),this._caption=$('').html(" "),this._helpTooltipTrigger=$('').text("?").attr("title",$.t("Type the interval number for minute charts (i.e. 5 if it is going to be a five minute chart). Or number plus letter for H (Hourly), D (Daily), W (Weekly), M (Monthly) intervals (i.e. D or 2H)")),this._dialogTitle=$.t("Change Interval")}var n=i(76),r=i(71);o.prototype._setInput=function(){this._input=$(''),this._input.on("keypress",this._handleInput.bind(this)).on("input",function(){this._validate(),this._updateCaption()}.bind(this)).on("blur",function(){setTimeout(this._submit.bind(this),0)}.bind(this))},o.prototype._validate=function(){var t=this._input.val();this._parsed=r.parseIntervalValue(t),this._valid=!this._parsed.error,this._supported=!this._parsed.error&&r.intervalIsSupported(t),!this._supported||this._parsed.unit&&"H"!==this._parsed.unit||this._parsed.qty*("H"===this._parsed.unit?60:1)>1440&&(this._supported=!1)},o.prototype._updateCaption=function(){var t,e,i;this._valid&&this._supported?(e=this._parsed.qty||1,i=this._parsed.unit?{H:"hour",D:"day",W:"week",M:"month",S:"second"}[this._parsed.unit]:"minute",t=e+" "+$.t(i,{count:e}),this._input.add(this._caption).removeClass("error")):(t=this._parsed.error?" ":$.t("Not applicable"),this._input.add(this._caption).addClass("error")),this._caption.html(t)}, -o.prototype._handleInput=function(t){if(13===t.which)return void this._submit();t.ctrlKey||t.metaKey||!t.charCode||!t.which||t.which<=32||r.isIntervalChar(String.fromCharCode(t.charCode))||t.preventDefault()},o.prototype._submit=function(){var t,e;TVDialogs.isOpen(this._dialogTitle)&&(this._valid&&this._supported&&(t=r.sanitizeIntervalValue(this._input.val()),e=n.interval.value(),t&&e!==t&&"function"==typeof this._options.callback&&this._options.callback(t)),TVDialogs.destroy(this._dialogTitle))},o.prototype._setInitialValue=function(t){var e,i;t=t||this._options.initialValue,e="",i=!1,t&&","!==t?e=r.sanitizeIntervalValue(t)||"":(t=n.interval.value(),e=t,i=!0),this._input.val(e),i&&this._input.select()},o.prototype.isValid=function(){return!!this._valid},o.prototype.show=function(t){var e=TVDialogs.createDialog(this._dialogTitle,{hideCloseCross:!0,addClass:"change-interval-dialog"}),i=e.find("._tv-dialog-content");return e.css("min-width",0),i.css("min-width",0).mousedown(function(t){this._input.is(t.target)||t.preventDefault()}.bind(this)).append(this._input.add(this._caption).add(this._helpTooltipTrigger)),TVDialogs.applyHandlers(e),TVDialogs.positionDialog(e),this._setInitialValue(t),this._validate(),this._updateCaption(),e},t.exports=o},function(t,e,i){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function s(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}var a,l;Object.defineProperty(e,"__esModule",{value:!0}),e.AddSymbolCheckbox=void 0,a=i(205),l=o(a),e.AddSymbolCheckbox=function(t){function e(t){n(this,e),t.checked=TVSettings.getBool("showAddSymbolDialog.checkboxState",!0);var i=r(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return i.$checkbox.change(function(){setTimeout(function(){TVSettings.setValue("showAddSymbolDialog.checkboxState",i.checked)})}),i}return s(e,t),e}(l.default)},function(t,e,i){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}function n(t,e){var i,o,n,r,c,p,_,f,m,g,v,y=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};for(y=$.extend({},{title:$.t("Confirm Inputs"),callback:function(t){}},y),i=null,o=(0,s.createDialog)({title:y.title,contentWrapTemplate:'
',width:u,closeOnClickAtOtherDialogs:!0,destroyOnClose:!0,actionsWrapTemplate:'
',isClickOutFn:function(t){var e=i.symbolSearchPopup() -;if(e)return e[0]!==t.target&&!e[0].contains(t.target)&&void 0},actions:[{name:"apply",type:"primary",text:$.t("Apply"),key:13}]}),d=o,n=(0,l.merge)({},e.defaults.inputs),r=0;ru&&o.$el.css("max-width",v),f.find("input,select").first().focus()}function r(){return d}var s,a,l,c,h,u,d;Object.defineProperty(e,"__esModule",{value:!0}),e.show=n,e.instance=r,s=i(65),a=i(247),l=i(15),c=i(25),h=o(c),i(242),u=450,d=null},function(t,e,i){function o(t,e,i,o,r,s){if(!t)return void n.logDebug("Missing control");this._control=t,this._property=e,this._applyOnFly=i,this._undoModel=o,this._undoText=r,e&&(this._formatters=[],this._changed=!1,this.setValue(e.value()),e.listeners().subscribe(this,this.propertyChanged))}var n=i(7).getLogger("Chart.PropertyPage.Binding");o.prototype.addFormatter=function(t){this._formatters.push(t),this.setValue(this._property.value())},o.prototype._formatValue=function(t){return this._formatters.reduce(function(t,e){return e(t)},t)},o.prototype._setValueToProperty=function(t){this._setter?this._setter.call(this,t):this.setValueToProperty(t)},o.prototype._attachToControl=function(t,e){var i=this;e?t.on("keyup change input",function(t){var e=i.value();i._setValueToProperty(e),i.setValue(e)}):(t.keypress(function(t){if(this._changed=!0,13===t.which){var e=i.value();i._setValueToProperty(e),i.setValue(e)}}),t.focusout(function(t){var e=i.value();i.changed()&&(i._setValueToProperty(e),i.setValue(e))}),t.change(function(t){var e=i.value();$(t.target).is(".ticker")?(void 0!==i._changeTimerId&&clearTimeout(i._changeTimerId),i._changeTimerId=setTimeout(function(){i._setValueToProperty(e)},250)):i._setValueToProperty(e),i.setValue(e)}))},o.prototype.control=function(){return this._control},o.prototype.changed=function(){return this._changed},o.prototype.setValueToProperty=function(t){this._undoModel.setProperty(this._property,t,this._undoText),this._changed=!1},o.prototype.property=function(){return this._property},o.prototype.propertyChanged=function(t){this.setValue(t.value())},o.prototype.destroy=function(){this._property&&this._property.listeners().unsubscribe(this,this.propertyChanged)},e.Binding=o},function(t,e,i){"use strict";function o(t,e){var i;return function(){clearTimeout(i),i=setTimeout(t.bind.apply(t,[this].concat(Array.prototype.slice.call(arguments))),e)}}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o,t.exports=e.default -},function(t,e,i){"use strict";var o,n,r,s,a;Object.defineProperty(e,"__esModule",{value:!0}),i(13),i(12),o=i(17),n=i(216),r=i(777),s=i(778),a=function(){function t(t){this._window=t,this._fullscreenApi=new r.FullscreenApi(t.document),this._initFullscreen()}return t.prototype.allocate=function(){var t,e,i,r=this;return this.free(),t=this._window.document,e=$("
",t).addClass("js-rootresizer__contents").css({position:"relative",width:"100%",height:"100%"}).prependTo(t.body),this._visibilityApi=new s.VisibilityApi(this._window.document),i={alive:new o(!0),body:new o(e),width:new o,height:new o,availWidth:new o,availHeight:new o,visible:this._visibilityApi.isVisible,fullscreen:this._fullscreenApi.isFullscreen,remove:function(){i.alive.setValue(!1)},attach:function(){i.alive.setValue(!1),r._window.close()},requestFullscreen:function(){r._requestFullscreen()},exitFullscreen:function(){r._exitFullscreen()}},i.alive.subscribe(function(t){t||i!==r._area||r.free()}),this._area=i,this._resizeHandler=function(){var t=i.body.value()[0],e=t.clientWidth,o=t.clientHeight;i.availHeight.setValue(o),i.availWidth.setValue(e),i.height.setValue(o),i.width.setValue(e)},this._resizeHandler(),$(this._window).on("resize",this._resizeHandler),new n.ResizerDetacherState(i).bridge()},t.prototype.free=function(){if(this._resizeHandler&&($(this._window).off("resize",this._resizeHandler),this._resizeHandler=void 0),this._visibilityApi&&(this._visibilityApi.destroy(),this._visibilityApi=void 0),this._area){var t=this._area;this._area=void 0,t.alive.setValue(!1),t.body.value().remove()}},t.prototype._requestFullscreen=function(){this._fullscreenApi.enter()},t.prototype._exitFullscreen=function(){this._fullscreenApi.exit()},t.prototype._initFullscreen=function(){var t=this,e=this._window.document;this._fullscreenApi.isFullscreen.subscribe(function(i){i?(t._$exitFullscreenButton=$("
",e).addClass("tv-exit-fullscreen-button").text($.t("Exit Full Screen (ESC)")).on("click",function(e){e.preventDefault(),t._exitFullscreen()}).appendTo(e.body),t._onExitFullscreenEsc=function(e){27===e.keyCode&&(e.preventDefault(),t._exitFullscreen())},$(e).on("keyup",t._onExitFullscreenEsc)):(t._$exitFullscreenButton&&(t._$exitFullscreenButton.remove(),t._$exitFullscreenButton=void 0),t._onExitFullscreenEsc&&($(e).off("keyup",t._onExitFullscreenEsc),t._onExitFullscreenEsc=void 0)),t._resizeHandler&&t._resizeHandler()})},t}(),e.Root=a},function(t,e,i){"use strict";var o,n,r;Object.defineProperty(e,"__esModule",{value:!0}),o=i(0),n=i(72),r=function(t){function e(e){var i=t.call(this,e,!1)||this;return i._subcommands=[],i}return o.__extends(e,t),e.prototype.addCommand=function(t){this._subcommands.push(t)},e.prototype.isEmpty=function(){return 0===this._subcommands.length},e.prototype.redo=function(){for(var t=0;t=0;t--)this._subcommands[t].undo()},e}(n.UndoCommand),e.UndoMacroCommand=r},function(t,e,i){"use strict";var o,n,r -;Object.defineProperty(e,"__esModule",{value:!0}),o=i(0),n=i(67),r=function(t){function e(e,i){var o=t.call(this)||this;return o._source=e,o._data=i,o}return o.__extends(e,t),e.prototype._updateRendererData=function(t){t.visible=!1;var e=this._source.lastValueData(this._data.plotIndex,!1);e.noData||(t.background=e.color,t.color=this.generateTextColor(e.color),t.coordinate=e.coordinate,t.floatCoordinate=e.floatCoordinate,t.text=e.text,t.visible=!0)},e}(n.PriceAxisView),e.StudyPriceAxisView=r},function(t,e,i){"use strict";function o(t){this.bars=t.bars,this.barSpacing=t.barSpacing,this.barWidth=n.optimalBarWidth(t.barSpacing),this.barLineWidth=Math.max(1,Math.round(this.barWidth)),this.dontDrawOpen=t.dontDrawOpen}var n=i(45),r=i(11);o.prototype.draw=function(t){var e,i,o;for(t.save(),t.translate(.5,.5),i=0;ia[a.length-1].time+l)return null;for(e=null,i=0;i=0&&!n(this.items[i].y);)i--;if(!(e>=i)){for(t.translate(.5,.5),o={},s=this.items,a=e;a<=i;a++)l=s[a],c=l.style?l.style.color:this.lineColor,a"),s=r.get(0).getContext("2d"),s.font=this._font,a=0,l=0;l").attr("width",this.textImageWidth).attr("height",this.textImageHeight),i=e.get(0).getContext("2d"),i.textBaseline="top",i.font=this._font,i.textAlign="center",i.fillStyle=t,o=Math.round(this.textImageWidth/2),n=0,r=0;r0,this._precision=t}return t.prototype.state=function(){return{precision:this._precision}},t.prototype.format=function(t){if(!n.isNumber(t))return e.PLACE_HOLDER;var i="";return t<0&&(i="-",t=-t),t>=1e100?window.t("N/A"):(!this._fractionalValues||t>=995?t=Math.round(t):this._fractionalValues&&(t=+t.toFixed(this._precision)),t<995?i+this._formatNumber(t):t<999995?i+this._formatNumber(t/1e3)+"K":t<999999995?(t=1e3*Math.round(t/1e3),i+this._formatNumber(t/1e6)+"M"):(t=1e6*Math.round(t/1e6),i+this._formatNumber(t/1e9)+"B"))},t.prototype.parse=function(t){var e,i,o;return"---"===t?{error:"not a number",res:!1,value:NaN}:(e={K:1e3,M:1e6,B:1e9},i=t.slice(-1),e.hasOwnProperty(i)?(o=this._numericFormatter.parse(t.slice(0,-1)),n.isNumber(o)?{res:!0,value:o*e[i]}:{error:"not a number",res:!1,value:NaN}):(o=this._numericFormatter.parse(t),n.isNumber(o)?{res:!0,value:o}:{error:"not a number",res:!1,value:NaN}))},t.serialize=function(t){return t.state()},t.deserialize=function(e){return new t(e.precision)},t.prototype._formatNumber=function(t){return this._fractionalValues&&(t=r.fixComputationError(t)), -this._numericFormatter.format(t).replace(/(\.[1-9]*)0+$/,function(t,e){return e})},t}(),e.VolumeFormatter=s},function(t,e,i){"use strict";function o(t){var e,i=n.get_timezone(t).offset_utc(Date.now()),o="",r=i/1e3/60/60;return r%1&&(o=":"+r%1*60),e="",e=r>0?"+"+(r-r%1)+o:0===r?"":r-r%1+o+"",{offset:i,string:"UTC"+e}}Object.defineProperty(e,"__esModule",{value:!0});var n=i(50);e.parseTzOffset=o},function(t,e,i){"use strict";function o(){a.call(this)}function n(t,e){this._constructor="LineToolFibSpeedResistanceArcs";var n=e||this.createPropertiesObject("linetoolfibwedge");r.call(this,t,n),t._fibWedgeLabelsCache||(t._fibWedgeLabelsCache=new o),i.e(1).then(function(t){var e=i(1080).FibWedgePaneView;this._setPaneViews([new e(this,this._model)])}.bind(this).bind(null,i)).catch(i.oe)}var r=i(1).LineDataSource,s=i(21),a=i(88),l=i(3).propertyPages;inherit(o,a),o.prototype.levelsCount=function(){return n.LevelsCount},inherit(n,r),n.LevelsCount=11,n.prototype.getCache=function(){return this._model._fibWedgeLabelsCache||(this._model._fibWedgeLabelsCache=new o),this._model._fibWedgeLabelsCache},n.prototype.pointsCount=function(){return 3},n.prototype.title=function(){return"Fib Wedge"},n.prototype.setPoint=function(t,e){var i,o,n,s,a,l,c;r.prototype.setPoint.call(this,t,e),this._recursiveGuard||(this._recursiveGuard=!0,2===t?(i=this.pointToScreenPoint(this._points[0])[0],o=this.pointToScreenPoint(this._points[1])[0],n=this.pointToScreenPoint(this._points[2])[0],s=n.subtract(i).length(),a=o.subtract(i).normalized(),o=i.add(a.scaled(s)),l=this.screenPointToPoint(o),this._properties.points[1].price.setValue(l.price),this._properties.points[1].bar.setValue(l.index)):(i=this.pointToScreenPoint(this._points[0])[0],o=this.pointToScreenPoint(this._points[1])[0],n=this.pointToScreenPoint(this._points[2])[0],c=o.subtract(i).length(),a=n.subtract(i).normalized(),n=i.add(a.scaled(c)),l=this.screenPointToPoint(n),this._properties.points[2].price.setValue(l.price),this._properties.points[2].bar.setValue(l.index)),this._recursiveGuard=!1)},n.prototype.addPoint=function(t){var e,i,o,n,s,a,l,c;return 2===this._points.length&&(e=this.pointToScreenPoint(this._points[0])[0],i=this.pointToScreenPoint(this._points[1])[0],this.priceScale().isPercent()&&(o=this.ownerSource().firstValue(),t.price=this.priceScale().priceRange().convertFromPercent(t.price,o)),n=this.pointToScreenPoint(t)[0],s=i.subtract(e).length(),a=n.subtract(e).normalized(),n=e.add(a.scaled(s)),l=this.priceScale().coordinateToPrice(n.y),c=Math.round(this._model.timeScale().coordinateToIndex(n.x)),t={index:c,price:l}),r.prototype.addPoint.call(this,t)},n.prototype.processErase=function(t,e){var i="level"+e,o=this.properties()[i].visible;t.setProperty(o,!1,"Erase level line")},n.prototype.createPropertiesObject=function(t,e,i){return new s(t,e,i,{range:[1,11]})},n.prototype.getInputsPropertyPage=function(){return null},n.prototype.getStylesPropertyPage=function(){return l.LineToolFibWedgeStylesPropertyPage},e.LineToolFibWedge=n},function(t,e,i){"use strict";(function(t){function o(t,e){ -this._pane=t,this._timeScale=e}function n(t){this._line=t}function r(t,e){this._adapter=new n(this),this._constructor="LineToolExecution";var o=e||new l("linetoolexecution");this.customization={forcePriceAxisLabel:!1,disableSelection:!0,disableErasing:!0},s.call(this,t,o),i.e(1).then(function(t){var e=i(1153).ExecutionPaneView;this._setPaneViews([new e(this,this._model)])}.bind(this).bind(null,i)).catch(i.oe)}var s=i(1).LineDataSource,a=i(170),l=i(6).DefaultProperty,c=i(19).PlotRowSearchMode;o.prototype._cachedByBarIndexOrderedExecutions={},o.recreateOrderedByBarsSourcesCache=function(t){var e,i,n,r,s;for(o.clearOrderedByBarsSourcesCache(),e=o.prototype,i=t.orderedSources(),n=0;nh.lastBar()||i=0;--d)if((p=u[d])instanceof r&&p._adapter._index===i&&p._adapter.getDirection()===m){if(p===t._line)break;_=p._adapter._height(),f=g?f+_:f-_}return{x:e.indexToCoordinate(i),y:f}},n.prototype._height=function(){var t,e=this.getArrowHeight(),i=this.getArrowSpacing();return this.getText()&&a.fontHeight(this.getFont()),t=10,e+i+0+t},n.prototype.getIndex=function(){return this._line._model.timeScale().baseIndex()-this._line.points()[0].index},n.prototype.setIndex=function(t){var e,i=this._line._model.timeScale(),o=i.baseIndex(),n=o-Math.abs(t);return this._line.startMoving(this._line.points()[0]),e=TradingView.merge({},this._line.points()[0]),e.index=n,this._line.move(e),this._line.endMoving(),this},n.prototype.getTime=function(){return this._unixtime},n.prototype.setTime=function(t){var e=this._line._model.mainSeries();return this._unixtime=ChartApiInstance.alignTimePoint?ChartApiInstance.alignTimePoint(t,e.interval(),e.symbolInfo()):t,this._line.restorePoints([{offset:0,price:this.getPrice(),time_t:this._unixtime}],[]),this._line.createServerPoints(),this},n.prototype.getPrice=function(){return this._line.points().length>0?this._line.points()[0].price:this._line._timePoint.length>0?this._line._timePoint[0].price:void 0},n.prototype.setPrice=function(t){return this._line.points().length>0&&(this._line.points()[0].price=t),this._line._timePoint.length>0&&(this._line._timePoint[0].price=t),this},n.prototype.getText=function(){ -return this._line.properties().text.value()},n.prototype.setText=function(t){return this._line.properties().text.setValue(t||""),this._line.updateAllViewsAndRedraw(),this},n.prototype.getArrowHeight=function(){return this._line.properties().arrowHeight.value()},n.prototype.setArrowHeight=function(t){return this._line.properties().arrowHeight.setValue(t||5),this},n.prototype.getArrowSpacing=function(){return this._line.properties().arrowSpacing.value()},n.prototype.setArrowSpacing=function(t){return this._line.properties().arrowSpacing.setValue(t||1),this},n.prototype.getDirection=function(){return this._line.properties().direction.value()},n.prototype.setDirection=function(t){return this._line.properties().direction.setValue(t||"buy"),this},n.prototype.getArrowColor=function(){return a.getColorFromProperties(this._line.properties().arrowColor,this._line.properties().arrowTransparency)},n.prototype.setArrowColor=function(t){return a.setColorToProperties(t,this._line.properties().arrowColor,this._line.properties().arrowTransparency),this},n.prototype.getTextColor=function(){return a.getColorFromProperties(this._line.properties().textColor,this._line.properties().textTransparency)},n.prototype.setTextColor=function(t){return a.setColorToProperties(t,this._line.properties().textColor,this._line.properties().textTransparency),this},n.prototype.getFont=function(){return a.getFontFromProperties(this._line.properties().fontFamily,this._line.properties().fontSize,this._line.properties().fontBold,this._line.properties().fontItalic)},n.prototype.setFont=function(t){return a.setFontToProperties(t,this._line.properties().fontFamily,this._line.properties().fontSize,this._line.properties().fontBold,this._line.properties().fontItalic),this},n.prototype.setTooltip=function(t){return null==t?t="":t+="",this._line.properties().tooltip.setValue(t),this},n.prototype.getTooltip=function(){return this._line.properties().tooltip.value()},n.prototype.remove=function(){this._line._model.removeSource(this._line),delete this._line},inherit(r,s),r.POINTS_COUNT=1,r.skipMagnetting=!0,r.prototype.pointsCount=function(){return r.POINTS_COUNT},r.prototype.title=function(){return"Execution"},r.prototype.hasContextMenu=function(){return!1},r.prototype.state=function(){return null},r.prototype.updateAllViews=function(){return this._isVisible()?s.prototype.updateAllViews.call(this):null},r.prototype.priceAxisViews=function(t,e){return this._isVisible()?s.prototype.priceAxisViews.call(this,t,e):null},r.prototype._isVisible=function(){return this._model.properties().tradingProperties.showExecutions.value()},r.prototype.paneViews=function(e){return TradingView.printing&&!t.enabled("snapshot_trading_drawings")?null:this._model.properties().tradingProperties.showExecutions.value()?s.prototype.paneViews.call(this,e):null},r.prototype.userEditEnabled=function(){return!1},r.prototype.showInObjectTree=function(){return!1},r.prototype.getInputsPropertyPage=function(){return null},e.ExecutionsPositionController=o,e.LineToolExecution=r}).call(e,i(5)) -},function(t,e,i){"use strict";function o(t,e,i){return new a(t,e,i)}var n,r,s,a;Object.defineProperty(e,"__esModule",{value:!0}),n=i(0),r=i(15),s=i(21),a=function(t){function e(e,i,o){return t.call(this,e,i,o,{names:["width","color","visible"]})||this}return n.__extends(e,t),e.prototype._iterateLevels=function(t,e){var i,o,n;for(i in t.levels)if(t.levels[i]&&r.isSameType(t.levels[i],e.typecheck())){o=e.tpl();for(n in this._map.names)this._map.names.hasOwnProperty(n)&&(o=e.fill(n,this._map.names[n],t.levels[i],o));t.levels[i]=o}return t},e}(s),e.LineToolGannComplexProperty=a,e.createPropertiesObject=o},function(t,e,i){"use strict";function o(t,e){this._constructor="LineTool5PointsPattern";var o=e||new r("linetool5pointspattern");n.call(this,t,o),i.e(1).then(function(t){var e=i(1081).Pattern5PaneView;this._setPaneViews([new e(this,this._model)])}.bind(this).bind(null,i)).catch(i.oe)}var n=i(1).LineDataSource,r=i(6).DefaultProperty,s=i(127).DateTimeFormatter,a=i(3).propertyPages;inherit(o,n),o.prototype.pointsCount=function(){return 5},o.prototype.title=function(){return"XABCD Pattern"},o.prototype._tooltipFieldsHash={time0:{title:"Date 1",value:null},price0:{title:"Price 1",value:null},time1:{title:"Date 2",value:null},price1:{title:"Price 2",value:null},time2:{title:"Date 3",value:null},price2:{title:"Price 3",value:null},time3:{title:"Date 4",value:null},price3:{title:"Price 4",value:null},time4:{title:"Date 5",value:null},price4:{title:"Price 5",value:null}},o.prototype._updateTooltip=function(){var t,e,i,o,n,r=this._tooltipFieldsHash,a=this.points().m_values;a[0]&&(e=this._model.timeScale().indexToUserTime(a[0].index),r.time0.value=e?new s(this._model.mainSeries().isDWM()).format(e):0,r.price0.value=this._model.mainSeries()._formatter.format(a[0].price)),a[1]&&(t=this._model.timeScale().indexToUserTime(a[1].index),r.time1.value=t?new s(this._model.mainSeries().isDWM()).format(t):0,r.price1.value=this._model.mainSeries()._formatter.format(a[1].price)),a[2]&&(i=this._model.timeScale().indexToUserTime(a[2].index),r.time2.value=i?new s(this._model.mainSeries().isDWM()).format(i):0,r.price2.value=this._model.mainSeries()._formatter.format(a[2].price)),a[3]&&(o=this._model.timeScale().indexToUserTime(a[3].index),r.time3.value=o?new s(this._model.mainSeries().isDWM()).format(o):0,r.price3.value=this._model.mainSeries()._formatter.format(a[3].price)),a[4]&&(n=this._model.timeScale().indexToUserTime(a[4].index),r.time4.value=t?new s(this._model.mainSeries().isDWM()).format(n):0,r.price4.value=this._model.mainSeries()._formatter.format(a[4].price))},o.prototype.tooltip=function(){return this._updateTooltip(),this._formatTooltip()},o.prototype.getStylesPropertyPage=function(){return a.LineToolLineTool5PointsPatternStylesPropertyPage},e.LineTool5PointsPattern=o},function(t,e,i){"use strict";function o(t,e){this._constructor="LineToolNote";var n=e||new s("linetoolnote");r.call(this,t,n),this.version=o.version,i.e(1).then(function(t){var e=i(1175).NotePaneView;this._setPaneViews([new e(this,this._model)]) -}.bind(this).bind(null,i)).catch(i.oe)}function n(t,e){var i=e||new s("linetoolnoteabsolute");i.locked.value()||i.locked.setValue(!0),o.call(this,t,i)}var r=i(1).LineDataSource,s=i(6).DefaultProperty,a=i(3).propertyPages;inherit(o,r),o.TOOLTIP_WIDTH=300,o.TOOLTIP_PADDING=10,o.TOOLTIP_LINESPACING=5,o.version=1,o.prototype.pointsCount=function(){return 1},o.prototype.title=function(){return $.t("Note")},o.prototype.applyTemplate=function(t){delete t.locked,delete t.text,r.prototype.applyTemplate.call(this,t)},o.prototype.getTooltipWidth=function(){return o.TOOLTIP_WIDTH},o.prototype.getTooltipPadding=function(){return o.TOOLTIP_PADDING},o.prototype.getTooltipLineSpacing=function(){return o.TOOLTIP_LINESPACING},inherit(n,o),n.prototype.title=function(){return $.t("Anchored Note")},o.prototype.state=function(t){var e=r.prototype.state.call(this,t);return t&&(e.state.fixedSize=!1),e},o.prototype.getStylesPropertyPage=function(){return a.LineToolNotePropertyPage},e.LineToolNote=o,e.LineToolNoteAbsolute=n},function(t,e,i){"use strict";function o(t,e){this._constructor="LineToolText";var o=e||new a("linetooltext");r.call(this,t,o),this._timeScale=t.timeScale(),this._barSpacing=t.timeScale().barSpacing(),i.e(1).then(function(t){var e=i(407).TextPaneView;this._setPaneViews([new e(this,this._model)])}.bind(this).bind(null,i)).catch(i.oe)}function n(t,e){var i=e||new a("linetooltextabsolute");i.locked.value()||i.locked.setValue(!0),o.call(this,t,i)}var r=i(1).LineDataSource,s=i(46).DataSource,a=i(6).DefaultProperty,l=i(3).propertyPages;inherit(o,r),o.MIN_WIDTH=100,o.prototype.setPoint=function(t,e){var i,n,r=this.properties();if(0===t&&r.wordWrapWidth&&r.wordWrapWidth.value()){if(i=r.locked&&r.locked.value()?this.fixedPoints()[0].x:this._timeScale.indexToCoordinate(this.points()[0].index),n=this._timeScale.indexToCoordinate(e.index)-i-~~(r.fontsize.value()/6),!isFinite(n))return;r.wordWrapWidth.setValue(Math.max(o.MIN_WIDTH,n))}},o.prototype.pointsCount=function(){return 1},o.prototype.title=function(){return $.t("Text")},o.prototype.setPriceScale=function(t){s.prototype.setPriceScale.call(this,t),t&&t.priceRange()&&(this._priceDencity=t.height()/t.priceRange().length(),this._isPriceDencityLog=t.isLog())},o.prototype.restoreSize=function(){this._barSpacing=this._model.timeScale().barSpacing(),this._priceDencity=this.priceScale().height()/this.priceScale().priceRange().length(),this.updateAllViews(),this._model.updateSource(this)},o.prototype.applyTemplate=function(t){delete t.locked,delete t.text,r.prototype.applyTemplate.call(this,t)},inherit(n,o),n.prototype.title=function(){return $.t("Anchored Text")},o.prototype.state=function(t){var e=r.prototype.state.call(this,t);return t&&(e.state.fixedSize=!1),e},o.prototype.getInputsPropertyPage=function(){return null},o.prototype.getStylesPropertyPage=function(){return l.LineToolTextStylesPropertyPage},e.LineToolText=o,e.LineToolTextAbsolute=n},function(t,e,i){"use strict";var o,n,r,s,a;Object.defineProperty(e,"__esModule",{value:!0}),o=i(0),n=i(9),r=i(67),s=i(15),a=function(t){ -function e(e){var i=t.call(this)||this;return i._source=e,i}return o.__extends(e,t),e.prototype._updateRendererData=function(t){var e,i,o,r,a,l;if(t.visible=!1,e=this._source.points(),i=this._source.priceScale(),0!==e.length&&null!==i&&!i.isEmpty()&&(o=e[0],isFinite(o.price))){if(i.isPercent()){if(!(r=this._source.ownerSource()))return;if(a=r.firstValue(),!s.isNumber(a))return;o.price=n.ensureNotNull(i.priceRange()).convertToPercent(o.price,a)}l=this._source.properties().linecolor.value(),t.background=l,t.color=this.generateTextColor(l),t.coordinate=i.priceToCoordinate(o.price),t.text=i.formatter().format(o.price),t.visible=!0}},e}(r.PriceAxisView),e.LineToolHorzLinePriceAxisView=a},function(t,e,i){"use strict";function o(t,e,i){this._study=t,this._series=e,this._model=i,this._invalidated=!0,this._orderArrow={vMargin:o.DEFAULT_ORDER_ARROW_VMARGIN,width:o.DEFAULT_ORDER_ARROW_WIDTH,height:o.DEFAULT_ORDER_ARROW_HEIGHT},this._exitLineWidth=o.DEFAULT_ORDER_ARROW_EXIT_LINE_WIDTH,this._priceArrow={width:o.DEFAULT_PRICE_ARROW_WIDTH,height:o.DEFAULT_PRICE_ARROW_HEIGHT},this._text={vMargin:o.DEFAULT_TEXT_VMARGIN,font:o.DEFAULT_FONT,fontSize:o.DEFAULT_FONT_SIZE},this._checkHideTextIfBarSpacingLT=o.DEFAULT_CHECK_HIDE_TEXT_IF_BARSPACING_LT,this._textIsVisible=!0,this._colors={entryBuy:o.DEFAULT_ENTRY_BUY_COLOR,entrySell:o.DEFAULT_ENTRY_SELL_COLOR,exit:o.DEFAULT_EXIT_COLOR},this._items={entryBuy:[],entrySell:[],exit:[]},this._textWidths={},this._study.properties().strategy.orders.subscribe(this,this.update)}var n=i(8).Point,r=i(873).PaneRendererStudyStrategyOrders,s=i(53).CompositeRenderer,a=i(19).PlotRowSearchMode;o.DEFAULT_ORDER_ARROW_VMARGIN=7,o.DEFAULT_ORDER_ARROW_WIDTH=9,o.DEFAULT_ORDER_ARROW_HEIGHT=11,o.DEFAULT_ORDER_ARROW_EXIT_LINE_WIDTH=2,o.DEFAULT_PRICE_ARROW_WIDTH=5,o.DEFAULT_PRICE_ARROW_HEIGHT=9,o.DEFAULT_TEXT_VMARGIN=2,o.DEFAULT_FONT="Arial",o.DEFAULT_FONT_SIZE=10,o.DEFAULT_CHECK_HIDE_TEXT_IF_BARSPACING_LT=10,o.DEFAULT_ENTRY_BUY_COLOR="#008fff",o.DEFAULT_ENTRY_SELL_COLOR="#f00",o.DEFAULT_EXIT_COLOR="#cc47ed",o.prototype._updateImpl=function(){var t,e,i,o,r,s,l,c,h,u,d,p,_,f,m,g,v,y,b,S,w,T,C,x,P,L;if(this.clearItems(),(t=this._study.ordersData())&&t.length&&(e=this._model.timeScale(),i=this._series.priceScale(),!(!e||!i||e&&e.isEmpty()||i&&i.isEmpty())&&null!==(o=e.visibleBars()))){for(r=this._study.barsIndexes(),s=this._series.nearestIndex(o.firstBar(),a.NearestRight),l=this._series.nearestIndex(o.lastBar(),a.NearestLeft),c=s,h=[],u=[];c<=l;c++)for(d=-1;-1!==(d=r.indexOf(c,d+1));)(p=t[d])&&(h.push(p),u.push(c));for(_=this._study.properties(),f=_.strategy.orders.showLabels.value(),m=_.strategy.orders.showQty.value(),g=f||m,g&&e.barSpacing()e.width()&&(g=!1),v=g&&this._text.fontSize+this._text.vMargin||0,y=v&&v*(f+m),b=0,S={upper:[],lower:[]};b=3600&&(h=this._addLeadingZero(Math.floor(c/3600))),c%=3600,u=this._addLeadingZero(Math.floor(c/60)),c%=60,d=this._addLeadingZero(Math.floor(c)),null!==h?h+":"+u+":"+d:u+":"+d))},e.prototype._updateRendererData=function(t){var e,i,o,n,r;t.visible=!1,this._data.model.properties().scalesProperties.showSeriesLastValue.value()&&(e=this._source.lastValueData(void 0,h),e.noData||(i=this._source.properties(),i.style.value()===l.STYLE_HEIKEN_ASHI&&i.haStyle.showRealLastPrice.value()&&(o=this._source.lastValueData(void 0,!1),n=this._source.lastValueData(void 0,!0),!o.noData&&!n.noData&&o.index===n.index)||(r="",c&&i.showCountdown.value()&&-1!==u.indexOf(i.style.value())&&(r=this._countdownText()),t.secondLine=r,t.background=this._source.priceLineColor(e.color),t.color=this.generateTextColor(t.background),t.coordinate=e.coordinate, -t.floatCoordinate=e.floatCoordinate,t.text=e.text,t.visible=!0)))},e.prototype._addLeadingZero=function(t){return("0"+t).slice(-2)},e}(s.PriceAxisView),e.SeriesPriceAxisView=d},function(t,e,i){"use strict";function o(t,e){this.m_series=t,this.m_model=e,this.m_bars=[],this._invalidated=!0,this._isMarkersEnabled=P.enabled("source_selection_markers")}function n(t,e){o.call(this,t,e)}function r(t,e){o.call(this,t,e)}function s(t,e){o.call(this,t,e)}function a(t,e){o.call(this,t,e)}function l(t,e){this.m_series=t,this.m_model=e,this.m_items=[]}function c(t,e){l.call(this,t,e),this._invaidated=!0}function h(t,e){l.call(this,t,e),this._invaidated=!0}function u(t,e){l.call(this,t,e),this._invaidated=!0,this._renderer=new b}function d(t,e){this._source=t,this._model=e,this._points=[new p(0,0)],this._invalidated=!0,this._renderer=new S;var i={cursorType:L.VerticalResize,pressedMouseMoveHandler:function(t){var e,i,o,n,r=this._source.priceScale();null!==r&&(e=this._source.properties().baselineStyle,i=r.height(),o=100-t.y/i*100,n=o<0?0:Math.round(10*o)/10,e.baseLevelPercentage.setValue(Math.max(Math.min(n,100),0)))}.bind(this)};this._renderer.setHitTest(new f(f.CUSTOM_MOVE,i))}var p=i(8).Point,_=i(131).SelectionRenderer,f=i(11),m=i(326).PaneRendererBars,g=i(176).PaneRendererLine,v=i(327).PaneRendererArea,y=i(248).PaneRendererCandles,b=i(883).PaneRendererBaseline,S=i(94).HorizontalLineRenderer,w=i(53).CompositeRenderer,T=i(329),C=i(30),x=i(19).PlotRowSearchMode,P=i(5),L=i(344).PaneCursorType;o.prototype.update=function(){this._invalidated=!0},o.prototype._updateImpl=function(){var t,e,i,o,n,r,s,a,l,c,h,u,d,_,m,g=this;if(this.m_bars=[],!this.m_model.timeScale().isEmpty()&&!this.m_series.priceScale().isEmpty()&&null!==(t=this.m_model.timeScale().visibleBars())&&0!==this.m_series.bars().size()){for(e=this.m_series.nearestIndex(t.firstBar(),x.NearestRight),i=this.m_series.nearestIndex(t.lastBar(),x.NearestLeft);e<=i&&null===this.m_series.bars().valueAt(e);e++);if(!(e>i)&&(t=this.m_series.bars().range(e,i),n=this.m_series.priceScale(),r=n.properties().percentage.value(),s=this.m_series.barColorer(),a={},t.each(function(t,e){var i,n;void 0!==e[TradingView.OPEN_PLOT]&&void 0!==e[TradingView.HIGH_PLOT]&&void 0!==e[TradingView.LOW_PLOT]&&void 0!==e[TradingView.CLOSE_PLOT]&&(void 0===o&&(o=e[TradingView.CLOSE_PLOT]),i={},i.time=Math.round(t),r?(i.open=100*(e[TradingView.OPEN_PLOT]-o)/o,i.high=100*(e[TradingView.HIGH_PLOT]-o)/o,i.low=100*(e[TradingView.LOW_PLOT]-o)/o,i.close=100*(e[TradingView.CLOSE_PLOT]-o)/o):(i.open=e[TradingView.OPEN_PLOT],i.high=e[TradingView.HIGH_PLOT],i.low=e[TradingView.LOW_PLOT],i.close=e[TradingView.CLOSE_PLOT]),a.value=e,n=e[TradingView.STYLE_PLOT]?e[TradingView.STYLE_PLOT]:s.barStyle(t,!1,a),e[TradingView.STYLE_PLOT]=n,a.previousValue=e,i.color=n.barColor,i.borderColor=n.barBorderColor,i.wickColor=n.barWickColor,i.hollow=n.isBarHollow,g.m_bars.push(i))},this),n.barPricesToCoordinates(this.m_bars),this.m_model.timeScale().barIndexesToCoordinates(this.m_bars), -this.m_series===this.m_model.selectedSource()))for(l=T(e,i),this._selectionData={points:[]},this._selectionData.hittestResult=f.REGULAR,c=0;cr.precedence&&(i[i.length-1].minPrecedence=r.precedence):r instanceof s?i.push(o={minPrecedence:1/0,openBraceIndex:n}):r instanceof a&&(o=i.pop(),c=t[o.openBraceIndex-1],(h=t[n+1])instanceof l&&!(h.precedence<=o.minPrecedence)||!(!(c instanceof l)||c.precedenceo.minPrecedence&&(i[i.length-1].minPrecedence=o.minPrecedence)));for(n=e.length;n--;)t.splice(e[n],1);return t}function T(t){for(var e=0;e=1;--e)if(i=this._ticker.slice(0,e),t(i)){this._root=i,this._contract=this._ticker.slice(e);break}},_.prototype.exchange=function(t){if(this.hasOwnProperty("_ticker")||this.parse(),!(arguments.length>0))return this._exchange;null===t||void 0===t?delete this._exchange:this._exchange=t+""},_.prototype.ticker=function(t){if(this.hasOwnProperty("_ticker")||this.parse(),!(arguments.length>0))return this._ticker;null===t||void 0===t?delete this._ticker:this._ticker=t+"",delete this._root,delete this._contract},_.prototype.root=function(t){if(this.hasOwnProperty("_root")||this.parseAsFutures(),!(arguments.length>0))return this._root;null===t||void 0===t?delete this._root:(this._root=t+"",this._root&&(this._ticker=this._root+(this._contract||"")))},_.prototype.contract=function(t){if(this.hasOwnProperty("_contract")||this.parseAsFutures(),!(arguments.length>0))return this._root;null===t||void 0===t?delete this._contract:(this._contract=t+"",this._root&&(this._ticker=this._root+this._contract))},t(f,n),f.prototype.toString=function(){return this.hasOwnProperty("_normalizedValue")?this._normalizedValue:this.value},f.prototype.parse=function(){this._normalizedValue=this.value.replace(/^0+|\.0*$/g,"").replace(/(\.\d*?)0+$/,"$1").replace(/^(\.|$)/,"0$1")},m.prototype.toString=function(){return this.value},t(g,_),g.prototype.isIncomplete=!0,g.prototype.incompleteSuggest=function(){if("'"!==this.value)return"'"},t(v,f),v.prototype.isIncomplete=!0,W=RegExp($.map(function(t){return"("+("string"==typeof t.pattern?i(t.pattern):t.pattern.source)+")"}).concat(".").join("|"),"g"),{tokenize:y,validate:b,factorOutBraces:w,normalizeTokens:T,flip:C,hasBatsSymbols:A,hasEodSymbols:M,hasChxeurSymbols:E,hasChxjpySymbols:D,hasFreeDelaySymbols:V,getExchange:I,isExchange:O,SymbolToken:_,IncompleteSymbolToken:g,NumberToken:f,BinaryOperatorToken:l,OpenBraceToken:s,CloseBraceToken:a,ticker:P,shortName:R,normalize:B}}();t.exports=n}).call(e,i(5))},function(t,e,i){"use strict";function o(t){return t+"("+new Date(1e3*t).toUTCString()+")"}function n(t){var e,i,o,n;return t+="",e=t.slice(0),i=!1,o=e[e.length-1],-1==="DWM".indexOf(o)&&"S"!==o&&(i=!0,o=""),n=parseInt(i?e:e.length>1?e.slice(0,e.length-1):1),{resolution:o,interval:n}}var r,s=i(58),a=i(50),l=i(34).Interval,c=!1,h=null,u=0,d=function(t,e){this._session=new s.Session, -this._session.init(t.timezone,t.session),this._symbolInfo=t,this._resolution=e,this._extrapolatedData=[],this._modelId=u++,this._valid=!!t.timezone&&!!t.session,c&&console.log('Created model "{0}", interval "{1}", session "{2}", tz "{3}"'.format(this._modelId,this._resolution,t.session,t.timezone))};d.prototype.uniqueId=function(){return this._modelId},d.prototype.isValid=function(){return this._valid},d.prototype._barBuilder=function(){if(!this._builderCache){var t=n(this._resolution);this._builderCache=s.newBarBuilder(t.resolution,t.interval,this._session,this._session)}return this._builderCache},d.prototype.distance=function(t,e){var i,n,r,a,l;return isNumber(t)&&isNumber(e)&&this.isValid()?(i=this._extrapolatedData.length>0?this._extrapolatedData[0]:null,n=i&&this._extrapolatedData[this._extrapolatedData.length-1],1e3*t!==i&&(this._extrapolatedData=[1e3*t],i=null,n=null),(null===i||1e3*e>n)&&(r=500,a=s.extrapolateBarsFrontToTime(this._barBuilder(),n||1e3*t,1e3*e,r),this._extrapolatedData=this._extrapolatedData.concat(a)),(n=this._extrapolatedData[this._extrapolatedData.length-1])<1e3*e?{success:!1}:(l=this._extrapolatedData.indexOf(1e3*e),-1!==l?(c&&console.log('Model "{0}" "{1}", distance between "{2}" and "{3}" is "{4}"'.format(this._modelId,this._resolution,o(t),o(e),l)),{success:!0,result:l}):{success:!1})):{success:!1}},d.prototype.projectTime=function(t,e){var i,n,r,a;return isNumber(t)&&isNumber(e)&&this.isValid()?(i=this._extrapolatedData.length>0?this._extrapolatedData[0]:null,n=i&&this._extrapolatedData[this._extrapolatedData.length-1],1e3*t!==i&&(this._extrapolatedData=[1e3*t],i=null,n=null),(null===i||e>=this._extrapolatedData.length)&&(r=s.extrapolateBarsFrontByCount(this._barBuilder(),n||1e3*t,e-this._extrapolatedData.length+1),this._extrapolatedData=this._extrapolatedData.concat(r)),e model "{3}" "{4}" targetTime "{5}"'.format(this._source.uniqueId(),this._source._resolution,o(t),this._target.uniqueId(),this._target._resolution,o(e))),e):t},t.exports.SyncPoint=r,t.exports.SyncModel=d},function(t,e,i){"use strict";var o,n=i(49),r=i(887),s=i(888),a=i(889),l=i(890),c=i(891),h=i(892),u=i(893),d=(o={},o[n.STYLE_AREA]=r,o[n.STYLE_BARS]=s,o[n.STYLE_CANDLES]=a,o[n.STYLE_HEIKEN_ASHI]=l,o[n.STYLE_HOLLOW_CANDLES]=c,o[n.STYLE_LINE]=h,o[n.STYLE_BASELINE]=u,o);t.exports=d},function(t,e,i){"use strict";function o(t){return-1!==a.indexOf(t)}function n(t){return-1!==l.indexOf(t)}function r(t){return c[t]}var s,a,l,c;Object.defineProperty(e,"__esModule",{value:!0}),s=i(49),a=[s.STYLE_RENKO,s.STYLE_KAGI,s.STYLE_PNF,s.STYLE_PB,s.STYLE_HEIKEN_ASHI],e.isJapaneseStyle=o,l=[s.STYLE_RENKO,s.STYLE_PB,s.STYLE_KAGI,s.STYLE_PNF],e.hasProjection=n,c={open:function(t){return t[1]},high:function(t){return t[2]},low:function(t){return t[3]},close:function(t){return t[4]},hl2:function(t){return(t[2]+t[3])/2},hlc3:function(t){return(t[2]+t[3]+t[4])/3},ohlc4:function(t){return(t[1]+t[2]+t[3]+t[4])/4}},e.barFunction=r},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.MINUTE_SPAN=20,e.HOUR_SPAN=30,e.DAY_SPAN=40,e.WEEK_SPAN=50,e.MONTH_SPAN=60,e.YEAR_SPAN=70},function(t,e,i){var o;!function(n,r,s,a){"use strict";function l(t,e,i){return setTimeout(p(t,i),e)}function c(t,e,i){return!!Array.isArray(t)&&(h(t,i[e],i),!0)}function h(t,e,i){var o;if(t)if(t.forEach)t.forEach(e,i);else if(t.length!==a)for(o=0;o\s*\(/gm,"{anonymous}()@"):"Unknown Stack Trace",r=n.console&&(n.console.warn||n.console.log);return r&&r.call(n.console,o,i),t.apply(this,arguments)}}function d(t,e,i){var o,n=e.prototype;o=t.prototype=Object.create(n),o.constructor=t,o._super=n,i&&ft(o,i)}function p(t,e){return function(){return t.apply(e,arguments)}}function _(t,e){return typeof t==Te?t.apply(e?e[0]||a:a,e):t}function f(t,e){return t===a?e:t}function m(t,e,i){h(b(e),function(e){t.addEventListener(e,i,!1)})}function g(t,e,i){h(b(e),function(e){t.removeEventListener(e,i,!1)})}function v(t,e){for(;t;){if(t==e)return!0;t=t.parentNode}return!1}function y(t,e){return t.indexOf(e)>-1}function b(t){return t.trim().split(/\s+/g)}function S(t,e,i){if(t.indexOf&&!i)return t.indexOf(e);for(var o=0;oi[e]}):n.sort()),n}function C(t,e){for(var i,o,n=e[0].toUpperCase()+e.slice(1),r=0;r1&&!l.firstMultiple?l.firstMultiple=D(e):1===h&&(l.firstMultiple=!1),i=l.firstInput,o=l.firstMultiple,n=o?o.center:i.center,r=e.center=V(c),e.timeStamp=Pe(),e.deltaTime=e.timeStamp-i.timeStamp,e.angle=z(n,r),e.distance=B(n,r),M(l,e),e.offsetDirection=R(e.deltaX,e.deltaY),s=O(e.deltaTime,e.deltaX,e.deltaY),e.overallVelocityX=s.x,e.overallVelocityY=s.y,e.overallVelocity=xe(s.x)>xe(s.y)?s.x:s.y,e.scale=o?N(o.pointers,c):1,e.rotation=o?F(o.pointers,c):0,e.maxPointers=l.prevInput?e.pointers.length>l.prevInput.maxPointers?e.pointers.length:l.prevInput.maxPointers:e.pointers.length,E(l,e),a=t.element,v(e.srcEvent.target,a)&&(a=e.srcEvent.target),e.target=a}function M(t,e){var i=e.center,o=t.offsetDelta||{},n=t.prevDelta||{},r=t.prevInput||{};e.eventType!==It&&r.eventType!==At||(n=t.prevDelta={x:r.deltaX||0,y:r.deltaY||0},o=t.offsetDelta={x:i.x,y:i.y}),e.deltaX=n.x+(i.x-o.x),e.deltaY=n.y+(i.y-o.y)}function E(t,e){var i,o,n,r,s,l,c,h=t.lastInterval||e,u=e.timeStamp-h.timeStamp;e.eventType!=Mt&&(u>Lt||h.velocity===a)?(s=e.deltaX-h.deltaX,l=e.deltaY-h.deltaY,c=O(u,s,l),o=c.x,n=c.y,i=xe(c.x)>xe(c.y)?c.x:c.y,r=R(s,l),t.lastInterval=e):(i=h.velocity,o=h.velocityX,n=h.velocityY,r=h.direction),e.velocity=i,e.velocityX=o,e.velocityY=n,e.direction=r}function D(t){for(var e=[],i=0;i=xe(e)?t<0?Dt:Vt:e<0?Ot:Rt}function B(t,e,i){i||(i=Nt);var o=e[i[0]]-t[i[0]],n=e[i[1]]-t[i[1]];return Math.sqrt(o*o+n*n)}function z(t,e,i){i||(i=Nt);var o=e[i[0]]-t[i[0]],n=e[i[1]]-t[i[1]];return 180*Math.atan2(n,o)/Math.PI}function F(t,e){return z(e[1],e[0],Wt)+z(t[1],t[0],Wt)}function N(t,e){return B(e[0],e[1],Wt)/B(t[0],t[1],Wt)}function W(){ -this.evEl=Ht,this.evWin=Ut,this.pressed=!1,L.apply(this,arguments)}function $(){this.evEl=Gt,this.evWin=Yt,L.apply(this,arguments),this.store=this.manager.session.pointerEvents=[]}function H(){this.evTarget=Zt,this.evWin=Xt,this.started=!1,L.apply(this,arguments)}function U(t,e){var i=w(t.touches),o=w(t.changedTouches);return e&(At|Mt)&&(i=T(i.concat(o),"identifier",!0)),[i,o]}function j(){this.evTarget=Qt,this.targetIds={},L.apply(this,arguments)}function q(t,e){var i,o,n,r,s,l=w(t.touches),c=this.targetIds;if(e&(It|kt)&&1===l.length)return c[l[0].identifier]=!0,[l,l];if(n=w(t.changedTouches),r=[],s=this.target,o=l.filter(function(t){return v(t.target,s)}),e===It)for(i=0;i-1&&i.splice(t,1)},setTimeout(o,te))}function Z(t){var e,i,o,n,r=t.srcEvent.clientX,s=t.srcEvent.clientY;for(e=0;e-1&&this.requireFail.splice(e,1),this},hasRequireFailures:function(){return this.requireFail.length>0},canRecognizeWith:function(t){return!!this.simultaneous[t.id]},emit:function(t){function e(e){i.manager.emit(e,t)}var i=this,o=this.state;o<_e&&e(i.options.event+et(o)),e(i.options.event),t.additionalEvent&&e(t.additionalEvent),o>=_e&&e(i.options.event+et(o))},tryEmit:function(t){if(this.canEmit())return this.emit(t);this.state=ge},canEmit:function(){for(var t=0;te.threshold&&n&e.direction},attrTest:function(t){return nt.prototype.attrTest.call(this,t)&&(this.state&de||!(this.state&de)&&this.directionTest(t))},emit:function(t){this.pX=t.deltaX,this.pY=t.deltaY;var e=it(t.direction);e&&(t.additionalEvent=this.options.event+e),this._super.emit.call(this,t)}}),d(st,nt,{defaults:{event:"pinch",threshold:0,pointers:2},getTouchAction:function(){return[ae]},attrTest:function(t){return this._super.attrTest.call(this,t)&&(Math.abs(t.scale-1)>this.options.threshold||this.state&de)},emit:function(t){if(1!==t.scale){var e=t.scale<1?"in":"out";t.additionalEvent=this.options.event+e}this._super.emit.call(this,t)}}),d(at,tt,{defaults:{event:"press",pointers:1,time:251,threshold:9},getTouchAction:function(){return[re]},process:function(t){var e=this.options,i=t.pointers.length===e.pointers,o=t.distancee.time;if(this._input=t,!o||!i||t.eventType&(At|Mt)&&!n)this.reset();else if(t.eventType&It)this.reset(),this._timer=l(function(){this.state=fe,this.tryEmit()},e.time,this);else if(t.eventType&At)return fe;return ge},reset:function(){clearTimeout(this._timer)},emit:function(t){this.state===fe&&(t&&t.eventType&At?this.manager.emit(this.options.event+"up",t):(this._input.timeStamp=Pe(),this.manager.emit(this.options.event,this._input)))}}),d(lt,nt,{defaults:{event:"rotate",threshold:0,pointers:2},getTouchAction:function(){return[ae]},attrTest:function(t){return this._super.attrTest.call(this,t)&&(Math.abs(t.rotation)>this.options.threshold||this.state&de)}}),d(ct,nt,{defaults:{event:"swipe",threshold:10,velocity:.3,direction:Bt|zt,pointers:1},getTouchAction:function(){return rt.prototype.getTouchAction.call(this)},attrTest:function(t){var e,i=this.options.direction;return i&(Bt|zt)?e=t.overallVelocity:i&Bt?e=t.overallVelocityX:i&zt&&(e=t.overallVelocityY),this._super.attrTest.call(this,t)&&i&t.offsetDirection&&t.distance>this.options.threshold&&t.maxPointers==this.options.pointers&&xe(e)>this.options.velocity&&t.eventType&At},emit:function(t){var e=it(t.offsetDirection);e&&this.manager.emit(this.options.event+e,t), -this.manager.emit(this.options.event,t)}}),d(ht,tt,{defaults:{event:"tap",pointers:1,taps:1,interval:300,time:250,threshold:9,posThreshold:10},getTouchAction:function(){return[se]},process:function(t){var e,i,o=this.options,n=t.pointers.length===o.pointers,r=t.distance'},function(t,e,i){"use strict";function o(t){var e,i=[],n=t.m_items;for(e=0;e"),this.jqMenu=t,t.attr("cellspacing","0"),t.attr("cellpadding","0"),t.addClass("context-menu"),t.addClass("submenu");for(e in this.m_items)i=this.m_items[e],n.renderItem(t,i)}else{t=u.create(r.MENU_TAG,o),this.jqMenu=t;for(e in this.m_items)i=this.m_items[e],n.renderItem(t,i)}return this.jqMenu},n.prototype.getAttributes=function(){var t={},e=["context-menu"];return this.options.attributes&&this.options.attributes.class&&e.push(this.options.attributes.class),t.cellspacing=0,t.cellpadding=0,t.class=e.join(),t},n.prototype.deploy=function(t,e){var i=this.wrapper();return this.jqMenu=i.append(this.render()),e?($(e).data("submenu",this.jqMenu),$(document.body).append(this.jqMenu),this.jqMenu.data("parent-menu",e),this.jqMenu.data("parent-item",t.currentTarget)):$(document.body).append(this.jqMenu),h.unbindContextMenu(this.jqMenu),this._setCoords(t),this.jqMenu},n.prototype.show=function(t,e){this.deploy(t,e).show()},n.prototype.hide=function(){ -this.isShown()&&this.destroy()},n.prototype.destroy=function(){$.each(this.m_items,function(t,e){e._menu&&e._menu.destroy()}),this.jqMenu&&(this.jqMenu.remove(),this.jqMenu=null),this.m_wrapper.empty()},n.prototype._setCoords=function(t){var e,i,o,n,r,s,a,l=5,c=this.jqMenu,h=$(this.jqMenu.data("parent-item")),u={width:$(window).width(),height:Math.min($(window).height(),$("body").height())},d={top:$(document).scrollTop(),left:$(document).scrollLeft()};for(this.jqMenu.css({maxWidth:u.width-2*l,maxHeight:u.height-2*l}),e={width:c.outerWidth(),height:c.outerHeight()},h.size()?(o=h.offset(),i={top:o.top-1,left:o.left+h.outerWidth()}):i={top:t.pageY,left:t.pageX},this.jqMenu.offset(i),n=!1,r={},r.top=Math.min(i.top,u.height+d.top-e.height-l),i.left+e.width+l>u.width+d.left||this.options.reverse?(n=!0,r.left=i.left-e.width):r.left=i.left,s=t.target;s&&s!==document;s=s.parentNode)if("fixed"===$(s).css("position")){this.jqMenu.css("position","fixed");break}this.jqMenu.offset(r),n&&(a=e.width-this.jqMenu.outerWidth())&&(r.left+=a,this.jqMenu.offset(r))},n.prototype._wrapper=function(){var t=this,e=r.WRAPPER_ATTRIBUTES;return this._parentMenuItem?this.m_wrapper=u.create(r.WRAPPER_TAG,e):(this.m_wrapper=h.createPopup(e,void 0,{mouseDownOutsideEvent:function(e){var i=$();$.each(o(t),function(){i=i.add(this.m_wrapper)}),$(e.target).parents().andSelf().is(i)||t.hide()}}),this.m_wrapper.addClass("topmenu")),this.m_wrapper},n.prototype.wrapper=function(t){return this.m_wrapper||this._wrapper()},t.exports=n},function(t,e,i){"use strict";t.exports={INSERT_AT_END:0,INSERT_AT_START:1,INSERT_AT_POS:2,WRAPPER_TAG:"div",WRAPPER_ATTRIBUTES:{class:"context-menu-wrapper"},MENU_TAG:"table",ITEM_ROW_TAG:"tr",ICON_CELL_TAG:"td",TEXT_CELL_TAG:"td",RIGHT_CELL_TAG:"td",SUBMENU_CELL_TAG:"td"}},function(t,e,i){"use strict";function o(t){return"number"!=typeof t&&(t=TradingView.STUDY_COUNT_LIMIT),(0,n.createNoticeDialog)({title:$.t("Warning"),content:$.t("Studies limit exceeded: {0} studies per layout.
\nPlease, remove some studies.").format(t)})}Object.defineProperty(e,"__esModule",{value:!0}),e.createTooManyStudiesNotice=o;var n=i(145)},function(t,e,i){"use strict";var o,n,r,s,a;Object.defineProperty(e,"__esModule",{value:!0}),o=i(72),n=i(10),r=i(7),s=r.getLogger("Common.UndoStack"),a=function(){function t(){this._commands=[],this._onChange=new n}return t.prototype.onChange=function(){return this._onChange},t.prototype.isEmpty=function(){return 0===this._commands.length},t.prototype.clear=function(){this._commands.length=0,this._onChange.fire()},t.prototype.push=function(t){if(!(t instanceof o.UndoCommand))throw new TypeError("argument must be an instance of UndoCommand");this._commands.push(t),this._onChange.fire()},t.prototype.pop=function(){if(this.isEmpty())return void s.logDebug("pop: undo stack is empty");var t=this._commands.pop();return this._onChange.fire(),t},t.prototype.head=function(){if(!this.isEmpty())return this._commands[this._commands.length-1]},t}(),e.UndoStack=a},function(t,e,i){"use strict";var o,n,r,s,a -;Object.defineProperty(e,"__esModule",{value:!0}),o=i(0),n=i(72),r=function(t){function e(e,i,o){var n=t.call(this,o)||this;return n._chartModel=e,n._defaultProperty=i,n._state=i.state(),n}return o.__extends(e,t),e.prototype.undo=function(){this._defaultProperty.merge(this._state),this._defaultProperty.listeners().fire(this._defaultProperty),this._chartModel.mainSeries().onChartStyleChanged()},e}(n.UndoCommand),e.RestoreDefaultsUndoCommand=r,s=function(t){function e(e,i,o){return void 0===o&&(o="Restore User Defaults"),t.call(this,e,i,o)||this}return o.__extends(e,t),e.prototype.redo=function(){this._chartModel.restoreDefaults(this._defaultProperty)},e}(r),e.RestoreUserDefaultsUndoCommand=s,a=function(t){function e(e,i,o){return void 0===o&&(o="Restore Defaults"),t.call(this,e,i,o)||this}return o.__extends(e,t),e.prototype.redo=function(){this._chartModel.restoreFactoryDefaults(this._defaultProperty)},e}(r),e.RestoreFactoryDefaultsUndoCommand=a},function(t,e,i){"use strict";function o(t){i.e(4).then(function(e){i(414).showGoToDateDialog(t)}.bind(null,i)).catch(i.oe)}Object.defineProperty(e,"__esModule",{value:!0}),e.showGoToDateDialog=o},function(t,e){t.exports=''},function(t,e,i){"use strict";function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var n,r,s,a,l;Object.defineProperty(e,"__esModule",{value:!0}),e.AddCompareDialog=void 0,n=function(){function t(t,e){var i,o;for(i=0;i0?"+":"-",n+=Math.floor(o/60),o%60&&(n+=":"+o%60)),i.getUTCFullYear()+"-"+("0"+(i.getUTCMonth()+1)).slice(-2)+"-"+("0"+i.getUTCDate()).slice(-2)+" "+("0"+i.getUTCHours()).slice(-2)+":"+("0"+i.getUTCMinutes()).slice(-2)+" ("+n+")"}function r(t){return"string"==typeof t&&0!==t.trim().length}function s(t){var e,i,o,n,s;if(!t||0===t.length)return!0;for(e=0;e2&&void 0!==arguments[2]&&arguments[2];return t.hasOwnProperty("text")?t.hasOwnProperty("color")&&i?e.append($("",{style:"color: "+t.color}).text(t.text)):e.text(t.text):e.text(t)}function l(t,e){if(Array.isArray(t)&&2===t.length)$("
").append(a(t[0],$("
")),a(t[1],$("
"),!0)).appendTo(e);else if(t.hasOwnProperty("br")&&t.br)$("
").appendTo(e);else{var i=$("
").append(a(t,$("
"))).appendTo(e);t.hasOwnProperty("listItem")&&i.addClass("list-item")}}function c(t,e){$("").attr("href",t.href).text(t.text).addClass(t.class).appendTo(e)}function h(t,e){var i,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";if("string"==typeof t)$("

").text(t).appendTo(e);else if(t.hasOwnProperty("lines"))for(i=0;i").text(t.lines[i].line).appendTo(e):l(t.lines[i].line,e):t.lines[i].hasOwnProperty("link")&&c(t.lines[i].link,e);else t.hasOwnProperty("title")&&$("

").text(t.title).appendTo(e),t.hasOwnProperty("actual")&&$("
").append($("
").text($.t("Actual")+": "),$("
").text(t.actual||"—")).appendTo(e),t.hasOwnProperty("forecast")&&$("
").append($("
").text($.t("Forecast")+": "),$("
").text(t.forecast||"—")).appendTo(e),t.hasOwnProperty("previous")&&$("
").append($("
").text($.t("Previous")+": "),$("
").text(t.previous||"—")).appendTo(e),t.hasOwnProperty("timestamp")&&$("
").append($("
").text($.t("Date")+": "),$("
").text(n(t.timestamp,o)||"—")).appendTo(e)}var u;Object.defineProperty(e,"__esModule",{value:!0}),e.Tooltip=void 0,u=function(){function t(t,e){var i,o;for(i=0;i0&&void 0!==arguments[0]?arguments[0]:{},i=e.direction,n=void 0===i?"top":i,r=e.clickable,s=void 0!==r&&r,a=e.wide,l=void 0!==a&&a;o(this,t),this._direction=n,this._tooltipShown=!1,this._tooltipX=void 0,this._tooltipY=void 0,this._tooltipItems=null,this._width=l?250:200,this._$tooltip=$("
").addClass("tv-chart-events-source__tooltip").css({position:"absolute",width:this._width+"px"}),this._$tooltipContent=$("
").addClass("tv-chart-events-source__tooltip__content").appendTo(this._$tooltip), -s&&this._$tooltip.addClass("tv-chart-events-source__tooltip--clickable")}return u(t,[{key:"show",value:function(){var t,e,i,o,n,r,a,l,c,u,d,p,_,f,m,g,v,y,b,S=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},w=S.items,T=void 0===w?[]:w,C=S.x,x=void 0===C?0:C,P=S.y,L=void 0===P?0:P,I=S.wrapElement,k=void 0===I?null:I,A=S.timeOffset,M=void 0===A?"":A,E=S.leftBorderColor,D=void 0===E?null:E;if(k&&!s(T)){if(t=$(k).width(),e=$(k).height(),i=!1,o=!1,this._tooltipShown||(this._$tooltip.appendTo(k),this._tooltipShown=!0,i=!0,o=!0),x===this._tooltipX&&L===this._tooltipY||(i=!0),i&&(n=Math.max(Math.min(x-this._width/2,t-this._width-10),0),this._$tooltip.css({left:Math.round(n),bottom:Math.round(e-L+10)})),this._tooltipItems||(o=!0),!o)for(r=T.length;r--;)if(this._tooltipItems[r]!==T[r]){o=!0;break}if(o){if(a=void 0,T.length<=1)a=T;else{for(l={},c=T.length;c--;)u=T[c].importance,null==u&&(u=-1),l[u]||(l[u]=[]),l[u].push(T[c]);if(d=Object.keys(l).sort(function(t,e){return t-e}),d.length<=1)a=l[d[0]];else for(a=[],p=d.length;p--;)for(_=l[d[p]],f=_.length;f--;)a.push(_[f])}for(this._$tooltipContent.empty(),m=a.length;m--;)g=a[m],v="",g.hasOwnProperty("importance")?("string"==typeof g.importance&&("earnings"===g.importance?v="--importance-earnings":"splits"===g.importance?v="--importance-splits":"dividends"===g.importance?v="--importance-dividends":"list"===g.importance&&(v="--importance-list")),0===g.importance?v="--importance-normal":g.importance>0&&(v="--importance-high")):D||(v="--importance-none"),y="tv-chart-events-source__tooltip__item",v&&(y+=" "+y+v),b=$("
").attr("class",y),D&&b.css("border-left-color",D),h(g,b,M),b.appendTo(this._$tooltipContent);this._tooltipItems=T}"bottom"===this._direction&&this._$tooltip.css({bottom:Math.round(e-L-this._$tooltipContent.height()+10)})}}},{key:"hide",value:function(){this._tooltipShown&&(this._$tooltip.detach(),this._tooltipShown=!1)}},{key:"isOpened",value:function(){return this._tooltipShown}}]),t}()},function(t,e,i){"use strict";var o,n,r,s,a,l,c,h,u,d;Object.defineProperty(e,"__esModule",{value:!0}),o=i(13),i(43),n=i(352),r=i(31),s=i(24),a=i(10),l=i(17),c=i(134),h=i(417),u='
'+(Modernizr.touch?'
':"")+'
'+h+'
',i(975),d=function(){function t(e){this._widget=document.createElement("div"),this._isVertical=!1,this._hiddingTimeoutId=null,this._visibility=new l(!1),this._windowResizeListener=this._onWindowResize.bind(this),this._reorderedDelegate=new a,t._toolbars.push(this),this._options=e,this._widget=o(u).get(0),this._content=this._widget.getElementsByClassName("js-content").item(0),this._setZIndex(t._startZIndex+t._toolbars.length-1),this._options.addClass&&(this._widget.className+=" "+this._options.addClass), -this._options.layout&&"auto"!==this._options.layout&&(this._isVertical="vertical"===this._options.layout,this._updateLayoutType())}return t.prototype.destroy=function(){this.hide(!0),t._toolbars.splice(t._toolbars.indexOf(this),1),document.body.contains(this._widget)&&document.body.removeChild(this._widget),this._widget.innerHTML=""},t.prototype.isVisible=function(){return this._visibility.value()},t.prototype.visibility=function(){return this._visibility.readonly()},t.prototype.isVertical=function(){return this._isVertical},t.prototype.show=function(){var t=this;this.isVisible()||(document.body.contains(this._widget)||(this._init(),document.body.appendChild(this._widget)),this._setHiddingTimeout(null),window.addEventListener("resize",this._windowResizeListener),this.raise(),this._visibility.setValue(!0),this._widget.classList.contains("i-hidden")?(this._widget.classList.remove("i-hidden"),setTimeout(function(){t.isVisible()&&t._widget.classList.remove("i-closed")})):this._widget.classList.remove("i-closed"),this._onWindowResize())},t.prototype.hide=function(t){var e,i,o=this;void 0===t&&(t=!1),this.isVisible()&&(e=this._widget.classList.contains("i-closed"),this._widget.classList.add("i-closed"),this._visibility.setValue(!1),t||e?(this._setHiddingTimeout(null),this._widget.classList.add("i-hidden")):(i=setTimeout(function(){o._setHiddingTimeout(null),o._widget.classList.add("i-hidden")},this.hideDuration()),this._setHiddingTimeout(i)),window.removeEventListener("resize",this._windowResizeListener))},t.prototype.raise=function(){t._toolbars.length+t._startZIndex!==this._zIndex()&&(t._toolbars.splice(t._toolbars.indexOf(this),1),t._toolbars.push(this),t._updateAllZIndexes())},t.prototype.hideDuration=function(){return.75*r.dur},t.prototype.addWidget=function(t,e){var i,o,n;if(void 0===e&&(e={}),i=this.widgetsCount(),void 0===e.index&&(e.index=i),e.index<0||e.index>i)throw Error("Index must be in [0, "+i+"]");o=document.createElement("div"),o.className="tv-floating-toolbar__widget js-widget",o.appendChild(t),n=e.index===i?null:this._content.childNodes.item(e.index),this._content.insertBefore(o,n),this._onWindowResize()},t.prototype.removeWidget=function(t){var e=this._findWrapperForWidget(t);e&&(this._content.removeChild(e),this._onWindowResize())},t.prototype.widgetsCount=function(){return this._content.childNodes.length},t.prototype.showWidget=function(t){var e=this._findWrapperForWidget(t);e&&e.classList.remove("i-hidden")},t.prototype.hideWidget=function(t){var e=this._findWrapperForWidget(t);e&&e.classList.add("i-hidden")},t.prototype.removeWidgets=function(){for(;this._content.firstChild;)this._content.removeChild(this._content.firstChild);this._onWindowResize()},t.prototype.onWidgetsReordered=function(){return this._reorderedDelegate},t.prototype.onContextMenu=function(t){var e,i=this;Modernizr.touch?(e=new n(this._widget),e.get("press").set({time:500}),e.on("press",function(e){i._preventWidgetTouchEndEvent(),t(e.srcEvent)})):this._widget.addEventListener("contextmenu",t)}, -t.prototype._determineCurrentLayoutVertical=function(t){var e=this._isVertical?t.height:t.width;return window.innerWidthwindow.innerWidth&&(t.left=Math.max(0,window.innerWidth-e.width)),t.top+e.height>window.innerHeight&&(t.top=Math.max(0,window.innerHeight-e.height)),t.left=Math.max(0,t.left),t.top=Math.max(0,t.top)},t.prototype._setZIndex=function(t){this._widget.style.zIndex=t+""},t.prototype._zIndex=function(){return+this._widget.style.zIndex},t.prototype._loadPosition=function(){var t=s.getJSON(this._options.positionSettingsKey,this._options.defaultPosition);this._widget.style.left=Math.round(t.left)+"px",this._widget.style.top=Math.round(t.top)+"px",this._onWindowResize()},t.prototype._savePosition=function(){var t=this._widget.getBoundingClientRect();s.setJSON(this._options.positionSettingsKey,{left:t.left,top:t.top})},t.prototype._init=function(){this._loadPosition(),c.lazyJqueryUI(o(this._widget)).draggable({containment:"window",drag:this._onDragEvent.bind(this),handle:".js-drag",stop:this._savePosition.bind(this)}),this._options.allowSortable&&this._initSortable(),this._widget.addEventListener(Modernizr.touch?"touchstart":"mousedown",this.raise.bind(this))},t.prototype._onDragEvent=function(t,e){this._correctPosition(e.position)},t.prototype._initSortable=function(){var t=this,e=-1;c.lazyJqueryUI(o(this._content)).sortable({start:function(t,i){e=i.item.index()},stop:function(i,o){var n=o.item.index();e!==n&&t._reorderedDelegate.fire(e,n)},tolerance:"point"})},t.prototype._getCorrectedWidgetRect=function(){var t,e,i,o,n=this._widget.getBoundingClientRect();return this._widget.classList.contains("i-closed")?(t=.925,e=1/t-1,i=n.width*e,o=n.height*e,{bottom:n.bottom+o/2,height:n.height+o, -left:n.left-i/2,right:n.right+i/2,top:n.top-o/2,width:n.width+i}):n},t._updateAllZIndexes=function(){t._toolbars.forEach(function(e,i){e._setZIndex(t._startZIndex+i)})},t._startZIndex=20,t._toolbars=[],t}(),e.FloatingToolbar=d},function(t,e,i){"use strict";(function(e){var o=i(58),n=i(34).Interval,r=i(10),s=i(5),a=function(t,e){this._server=t,this._session=e,this._timezone=null,this._timezoneId="",this._isDWM=!1,this._resolution=null,this.seriesCompleted=new r,this._lastBarTimes={}};a.prototype.lastBarTime=function(t){return this._lastBarTimes[t]},a.prototype._userTimezone=function(){return this._timezone},a.prototype.setTimezone=function(t){this._timezone="exchange"===t?"exchange":e.get_timezone(t),this._timezoneId=t},a.prototype.timezone=function(){return this._timezoneId},a.prototype.setResolution=function(t){this._isDWM=n.isDWM(t),this._resolution=t},a.prototype.onRequestMetadata=function(t,e){this._server.receiveLocalResponse({method:"studies_metadata",params:[this._session,t,e]})},a.prototype.onSymbolResolved=function(t,e){this._server.receiveLocalResponse({method:"symbol_resolved",params:[this._session,t,e]})},a.prototype.onSymbolError=function(t,e){this._server.receiveLocalResponse({method:"symbol_error",params:[this._session,t,e]})},a.prototype.onStudyError=function(t,e){this._server.receiveLocalResponse({method:"study_error",params:[this._session,t,e]})},a.prototype.onSeriesLoading=function(t,e){this._server.receiveLocalResponse({method:"series_loading",params:[this._session,t,e]})},a.prototype.onSeriesCompleted=function(t,e,i){this._server.receiveLocalResponse({method:"series_completed",params:[this._session,t,i,e]}),this.seriesCompleted.fire(t)},a.prototype.onSeriesError=function(t,e){this._server.receiveLocalResponse({method:"series_error",params:[this._session,t,e]})},a.prototype.onSeriesClearData=function(t,e){var i={};i[t]={series:[],turnaround:e},this._server.receiveLocalResponse({method:"timescale_update",params:[this._session,i,{index:0,zoffset:0,changes:[],marks:[],index_diff:[]}]})},a.prototype.onStudyCompleted=function(t,e){this._server.receiveLocalResponse({method:"study_completed",params:[this._session,t,e]})},a.prototype.onStudyLoading=function(t,e){this._server.receiveLocalResponse({method:"study_loading",params:[this._session,t,e]})},a.prototype._calcMarksTime=function(t,i,n,r,a){var l,c,h,u,d,p=e.get_timezone(i),_=this;if(this._isDWM&&!s.enabled("disable_resolution_rebuild"))for(d=new o.Session,d.init(p,n),u=0;u=0;--a)if(Math.floor(r/l[a].divisor)!==Math.floor(s/l[a].divisor))return l[a].span},TradingView.ChartapiMessagerInstances=[],t.exports=a}).call(e,i(50)) -},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.supportedLineTools={cursor:{name:"cursor",onlySelectable:!0},dot:{name:"dot",onlySelectable:!0},arrow_cursor:{name:"arrow",onlySelectable:!0},eraser:{name:"eraser",onlySelectable:!0},measure:{name:"measure",onlySelectable:!0},zoom:{name:"zoom",onlySelectable:!0},brush:{name:"LineToolBrush",onlySelectable:!0},text:{name:"LineToolText",supportsText:!0},anchored_text:{name:"LineToolTextAbsolute",supportsText:!0},note:{name:"LineToolNote",supportsText:!0},anchored_note:{name:"LineToolNoteAbsolute",supportsText:!0},callout:{name:"LineToolCallout",supportsText:!0},balloon:{name:"LineToolBalloon",supportsText:!0},arrow_up:{name:"LineToolArrowMarkUp",supportsText:!0},arrow_down:{name:"LineToolArrowMarkDown",supportsText:!0},arrow_left:{name:"LineToolArrowMarkLeft",supportsText:!0},arrow_right:{name:"LineToolArrowMarkRight",supportsText:!0},price_label:{name:"LineToolPriceLabel"},flag:{name:"LineToolFlagMark"},vertical_line:{name:"LineToolVertLine"},horizontal_line:{name:"LineToolHorzLine"},horizontal_ray:{name:"LineToolHorzRay"},trend_line:{name:"LineToolTrendLine"},trend_angle:{name:"LineToolTrendAngle"},arrow:{name:"LineToolArrow"},ray:{name:"LineToolRay"},extended:{name:"LineToolExtended"},parallel_channel:{name:"LineToolParallelChannel"},disjoint_angle:{name:"LineToolDisjointAngle"},flat_bottom:{name:"LineToolFlatBottom"},pitchfork:{name:"LineToolPitchfork"},schiff_pitchfork_modified:{name:"LineToolSchiffPitchfork"},schiff_pitchfork:{name:"LineToolSchiffPitchfork2"},inside_pitchfork:{name:"LineToolInsidePitchfork"},pitchfan:{name:"LineToolPitchfan"},gannbox:{name:"LineToolGannSquare"},gannbox_square:{name:"LineToolGannComplex"},gannbox_fixed:{name:"LineToolGannFixed"},gannbox_fan:{name:"LineToolGannFan"},fib_retracement:{name:"LineToolFibRetracement"},fib_trend_ext:{name:"LineToolTrendBasedFibExtension"},fib_speed_resist_fan:{name:"LineToolFibSpeedResistanceFan"},fib_timezone:{name:"LineToolFibTimeZone"},fib_trend_time:{name:"LineToolTrendBasedFibTime"},fib_circles:{name:"LineToolFibCircles"},fib_spiral:{name:"LineToolFibSpiral"},fib_speed_resist_arcs:{name:"LineToolFibSpeedResistanceArcs"},fib_wedge:{name:"LineToolFibWedge"},fib_channel:{name:"LineToolFibChannel"},xabcd_pattern:{name:"LineTool5PointsPattern"},cypher_pattern:{name:"LineToolCypherPattern"},abcd_pattern:{name:"LineToolABCD"},triangle_pattern:{name:"LineToolTrianglePattern"},"3divers_pattern":{name:"LineToolThreeDrivers"},head_and_shoulders:{name:"LineToolHeadAndShoulders"},elliott_impulse_wave:{name:"LineToolElliottImpulse"},elliott_triangle_wave:{name:"LineToolElliottTriangle"},elliott_triple_combo:{name:"LineToolElliottTripleCombo"},elliott_correction:{name:"LineToolElliottCorrection"},elliott_double_combo:{name:"LineToolElliottDoubleCombo"},cyclic_lines:{name:"LineToolCircleLines"},time_cycles:{name:"LineToolTimeCycles"},sine_line:{name:"LineToolSineLine"},long_position:{name:"LineToolRiskRewardLong"},short_position:{name:"LineToolRiskRewardShort"},forecast:{ -name:"LineToolPrediction"},date_range:{name:"LineToolDateRange"},price_range:{name:"LineToolPriceRange"},date_and_price_range:{name:"LineToolDateAndPriceRange"},bars_pattern:{name:"LineToolBarsPattern"},ghost_feed:{name:"LineToolGhostFeed"},projection:{name:"LineToolProjection"},rectangle:{name:"LineToolRectangle"},rotated_rectangle:{name:"LineToolRotatedRectangle"},ellipse:{name:"LineToolEllipse"},triangle:{name:"LineToolTriangle"},polyline:{name:"LineToolPolyline"},curve:{name:"LineToolBezierQuadro"},double_curve:{name:"LineToolBezierCubic"},arc:{name:"LineToolArc"},icon:{name:"LineToolIcon"}}},function(t,e,i){"use strict";var o,n;Object.defineProperty(e,"__esModule",{value:!0}),o=i(48),n=function(){function t(){}return t.prototype.init=function(t,e){t.new_sym(e(1),o.Std.period(t),o.Std.period(t)),this._source=e(0),this._scaleFactor1=1,this._scaleFactor2=1},t.prototype.main=function(t,e){var i,n,r,s,a,l,c=t.symbol.time,h=o.Std[this._source](t);return t.select_sym(1),i=o.Std[this._source](t),n=t.new_var(i),r=t.new_var(t.symbol.time),isNaN(t.symbol.time)&&(n.indexOf(0),r.indexOf(0)),t.select_sym(0),isNaN(c)?null:(s=r.indexOf(c),-1!==s&&r.get(s)!==c&&(s=-1),a=s<0?NaN:n.get(s),l=this._doCalculation(this._scaleFactor1,h,this._scaleFactor2,a),[l])},t}(),e.SpreadRatioBase=n,e.spreadRatioDefaults={styles:{plot1:{linestyle:0,linewidth:2,plottype:0,trackPrice:!1,transparency:35,visible:!0,color:"#800080"}},precision:2,inputs:{source:"close",symbol2:""}},e.spreadRatioInputs=[{defval:"close",id:"source",name:"Source",options:["open","high","low","close","hl2","hlc3","ohlc4"],type:"text"},{id:"symbol2",name:"Symbol",type:"symbol",confirm:!0}],e.spreadRatioPlots=[{id:"plot1",type:"line"}],e.spreadRatioStyles={plot1:{title:"Plot",histogramBase:0}}},function(t,e,i){"use strict";function o(t){var e,i=t.dropped,o=t.className;return n.createElement(s.Icon,{className:r(o,a.icon,(e={},e[a.dropped]=i,e)),icon:l})}var n,r,s,a,l;Object.defineProperty(e,"__esModule",{value:!0}),n=i(2),r=i(14),s=i(59),a=i(1025),l=i(298),e.ToolWidgetCaret=o},function(t,e,i){"use strict";var o,n,r,s,a,l;Object.defineProperty(e,"__esModule",{value:!0}),o=i(0),n=i(2),r=i(14),s=i(103),a=i(1028),l=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._handleClick=function(){var t=e.props,i=t.onClick,o=t.onClickArg;i&&i(o)},e}return o.__extends(e,t),e.prototype.render=function(){var t,e=this.props,i=e.isFirst,o=e.isLast,l=e.hint,c=e.text,h=e.icon,u=e.isActive,d=e.isDisabled,p=e.className;return n.createElement(s.ToolWidgetButton,{icon:h,text:c,title:l,isDisabled:d,isActive:u,onClick:this._handleClick,className:r(p,a.button,(t={},t[a.first]=i,t[a.last]=o,t))})},e}(n.PureComponent),e.ToolWidgetQuickButton=l},function(t,e,i){"use strict";var o,n,r,s,a,l,c;Object.defineProperty(e,"__esModule",{value:!0}),o=i(0),i(12),n=i(2),r=i(14),s=i(1044),a=i(1045),l={remove:window.t("Remove")},c=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._handleClick=function(t){var i=e.props,o=i.onClick,n=i.onClickArg;o&&o(n,t)},e} -return o.__extends(e,t),e.prototype.render=function(){return n.createElement("span",{className:r(s.button,"apply-common-tooltip",this.props.hidden&&s.hidden),dangerouslySetInnerHTML:{__html:a},onClick:this._handleClick,title:l.remove})},e}(n.PureComponent),e.RemoveButton=c},function(t,e,i){"use strict";var o,n,r,s,a,l;Object.defineProperty(e,"__esModule",{value:!0}),o=i(0),n=i(8),r=i(64),s=i(11),a=i(131),l=function(){function t(t,e){this._invalidated=!0,this._middlePoint=null,this._points=[],this._floatPoints=[],this._source=t,this._model=e}return t.prototype.priceToCoordinate=function(t){var e,i,o,n=this._source.priceScale();return null===n?null:null===(e=n.priceRange())?null:(n.isPercent()&&null!==(i=this._source.ownerSource())&&null!==(o=i.firstValue())&&void 0!==o&&(t=e.convertToPercent(t,o)),n.priceToCoordinate(t))},t.prototype.currentPoint=function(){var t=this._model.crossHairSource();return new n.Point(t.x,t.y)},t.prototype.anchorColor=function(){return this._source.isBeingEdited()?"#D61AD3":this._model.isDark()?"#FFFFFF":"#606060"},t.prototype.isHoveredSource=function(){return this._source===this._model.hoveredSource()},t.prototype.isSelectedSource=function(){return this._source===this._model.selectedSource()},t.prototype.isAnchorsRequired=function(){return(this.isHoveredSource()||this.isSelectedSource())&&!this._model.isSnapshot()},t.prototype.update=function(){this._invalidated=!0},t.prototype.addAnchors=function(t){if(this.isAnchorsRequired()){var e=this._points;this._model.lineBeingCreated()===this._source&&(e=e.slice(0,-1)),t.append(this.createLineAnchor({points:e}))}},t.prototype.createLineAnchor=function(t){var e=r.CheckMobile.any();return new a.LineAnchor(o.__assign({},t,{color:this.anchorColor(),backgroundColor:this._model.backgroundColor(),currentPoint:this.currentPoint(),linePointBeingEdited:this._model.linePointBeingEdited(),hittestResult:s.CHANGEPOINT,radius:(e?15:7)+(this.isSelectedSource()?1:0),strokeWidth:(e?3:1)+(this.isSelectedSource()?1:0)}))},t.prototype._updateImpl=function(){var t,e,i,o,n,r,s,a;if(this._points=[],this._floatPoints=[],t=this._source.priceScale(),e=this._model.timeScale(),t&&!t.isEmpty()&&!e.isEmpty()){for(i=this._source.points(),o=0;o50?t-50:0});return s.rgbToString(i)}function n(t){var e,i,o,n=[];for(e=0,i=t;e');return null!==t&&i.appendTo(t),void 0!==e.addClass&&i.addClass(e.addClass), -$('
').appendTo(i),$('').tvcolorpicker({customColors:n(a.getJSON("pickerCustomColors",[])),direction:e.direction,hideTransparency:!!e.hideTransparency}).on("change",function(){$(this).css("border-color",o($(this).val()||l))}).bind("customcolorchange",function(t,e){a.setJSON("pickerCustomColors",e)}).appendTo(i),i}var s,a,l;Object.defineProperty(e,"__esModule",{value:!0}),i(13),i(285),s=i(32),a=i(24),l="#727272",e.addColorPicker=r},function(t,e,i){"use strict";var o,n,r,s,a,l,c,h;Object.defineProperty(e,"__esModule",{value:!0}),o=i(11),n=i(44),r=i(60),s=i(8),a=i(30),l=i(9),c=i(90),h=function(){function t(t,e,i){this._data=null,this._hitTestResult=t||new o(o.MOVEPOINT),this._backHitTestResult=e||new o(o.MOVEPOINT_BACKGROUND),this._forceOverrideTransparency=!!i}return t.prototype.setData=function(t){this._data=t},t.prototype.draw=function(t){var e,i,o,n;null===this._data||this._data.points.length<2||(t.lineCap="butt",t.strokeStyle=this._data.color,t.lineWidth=this._data.linewidth,void 0!==this._data.linestyle&&c.setLineStyle(t,this._data.linestyle),e=this._data.points,i=e[0],o=e[1],n=o.subtract(i),t.beginPath(),t.rect(i.x,i.y,n.x,n.y),this._data.linewidth>0&&t.stroke(),this._data.fillBackground&&(t.fillStyle=this.getColor(),t.fill()))},t.prototype.hitTest=function(t){var e,i,o,a,l,c,h,u,d,p;return null===this._data||this._data.points.length<2||this._data.nohittest?null:(e=this._data.points,i=e[0],o=e[1],a=new s.Point(o.x,i.y),l=new s.Point(i.x,o.y),c=n.distanceToSegment(i,a,t),c.distance<=3?this._hitTestResult:(c=n.distanceToSegment(a,o,t),c.distance<=3?this._hitTestResult:(c=n.distanceToSegment(o,l,t),c.distance<=3?this._hitTestResult:(c=n.distanceToSegment(l,i,t),c.distance<=3?this._hitTestResult:this._data.fillBackground&&(h=Math.min(i.x,o.x),u=Math.max(i.x,o.x),d=Math.min(i.y,o.y),p=Math.max(i.y,o.y),i=new s.Point(h,d),o=new s.Point(u,p),r.pointInRectangle(t,i,o))?this._backHitTestResult:null))))},t.prototype.getColor=function(){var t=l.ensure(this._data);return a.generateColor(t.backcolor,t.transparency,this._forceOverrideTransparency)},t}(),e.RectangleRenderer=h},function(t,e,i){"use strict";var o,n,r,s;Object.defineProperty(e,"__esModule",{value:!0}),o=i(0),n=i(2),r=i(39),s=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._handleOutsideEvent=function(t){e.props.handler&&!r.findDOMNode(e).contains(t.target)&&e.props.handler(t)},e}return o.__extends(e,t),e.prototype.componentDidMount=function(){this.props.click&&document.addEventListener("click",this._handleOutsideEvent,!1),this.props.mouseDown&&document.addEventListener("mousedown",this._handleOutsideEvent,!1),this.props.touchEnd&&document.addEventListener("touchend",this._handleOutsideEvent,!1),this.props.touchStart&&document.addEventListener("touchstart",this._handleOutsideEvent,!1)},e.prototype.componentWillUnmount=function(){this.props.click&&document.removeEventListener("click",this._handleOutsideEvent,!1), -this.props.mouseDown&&document.removeEventListener("mousedown",this._handleOutsideEvent,!1),this.props.touchEnd&&document.removeEventListener("touchend",this._handleOutsideEvent,!1),this.props.touchStart&&document.removeEventListener("touchstart",this._handleOutsideEvent,!1)},e.prototype.render=function(){var t=this.props,e=(t.click,t.handler,t.mouseDown,t.touchEnd,t.touchStart,t.ctor),i=void 0===e?"span":e,r=o.__rest(t,["click","handler","mouseDown","touchEnd","touchStart","ctor"]);return n.createElement(i,o.__assign({},r))},e}(n.Component),e.OutsideEvent=s},function(t,e,i){"use strict";function o(t,e,i){this._cache=t,this._cacheRect=e,this._targetRect=i}var n=i(8).Point,r=i(60).pointInRectangle,s=i(11);o.prototype.draw=function(t){t.translate(.5,.5),t.drawImage(this._cache,this._cacheRect.left,this._cacheRect.top,this._cacheRect.width,this._cacheRect.height,this._targetRect.left,this._targetRect.top,this._targetRect.width,this._targetRect.height),t.translate(-.5,-.5)},o.prototype.hitTest=function(t){var e=new n(this._targetRect.left,this._targetRect.top),i=e.add(new n(this._targetRect.width,this._targetRect.height));return r(t,e,i)?new s(s.REGULAR):null},t.exports=o},function(t,e,i){"use strict";var o,n,r;Object.defineProperty(e,"__esModule",{value:!0}),o=i(11),n=i(90),r=function(){function t(){this._data=null,this._hitTest=null}return t.prototype.setData=function(t){this._data=t},t.prototype.setHitTest=function(t){this._hitTest=t},t.prototype.draw=function(t){if(null!==this._data&&0!==this._data.points.length&&!(this._data.linewidth<=0)){var e=this._data.points[0].x;e<0||e>this._data.width||(t.translate(1,0),t.lineCap="square",t.strokeStyle=this._data.color,t.lineWidth=this._data.linewidth,void 0!==this._data.linestyle&&n.setLineStyle(t,this._data.linestyle),n.drawLine(t,e,0,e,this._data.height))}},t.prototype.hitTest=function(t){if(null===this._data||0===this._data.points.length)return null;var e=this._hitTest||new o(o.MOVEPOINT);return Math.abs(t.x-this._data.points[0].x)<=3?e:null},t}(),e.VerticalLineRenderer=r},function(t,e,i){"use strict";var o,n,r;Object.defineProperty(e,"__esModule",{value:!0}),o=i(0),n=i(28),r=function(t){function e(e,i,o,n){var r=this;return i||(i=1),"forex"!==o&&"cfd"!==o||!n?(r=t.call(this,1)||this,r._isForex=!1):(r=t.call(this,n)||this,r._isForex=!0),r._pipPriceScale=e,r._pipMinMove=i,r._pipMinMove2=n,r}return o.__extends(e,t),e.prototype.format=function(e,i,o){var n=this._isForex?this._pipMinMove2:this._pipMinMove;return void 0===n&&(n=NaN),t.prototype.format.call(this,e*this._pipPriceScale/n,i,o)},e}(n.PriceFormatter),e.PipFormatter=r},,function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),i(12);var o=function(){function t(){}return t.prototype.format=function(t){var e,i,o,n,r=t<0;return t=Math.abs(t),e=Math.floor(t/86400),t-=86400*e,i=Math.floor(t/3600),t-=3600*i,o=Math.floor(t/60),t-=60*o,n="",e&&(n+=e+$.t("d",{context:"dates"})+" "),i&&(n+=i+$.t("h",{context:"dates"})+" "),o&&(n+=o+$.t("m",{context:"dates"})+" "),t&&(n+=t+$.t("s",{context:"dates"})+" "), -r&&(n="-"+n),n.trim()},t}();e.TimeSpanFormatter=o},function(t,e,i){"use strict";function o(t){this._data=null,this._hittest=t||new a(a.MOVEPOINT),this._backHittest=new a(a.MOVEPOINT_BACKGROUND),this._points=[]}var n=i(60).pointInPolygon,r=i(44).distanceToSegment,s=i(110).TrendLineRenderer,a=i(11),l=i(30),c=i(74).LineEnd;o.prototype.setData=function(t){this._data=t,this._points=t.points},o.prototype.draw=function(t){var e,i,o;if(null!==this._data&&0!==this._points.length){for(t.beginPath(),t.lineCap="butt",t.strokeStyle=this._data.color,t.lineWidth=this._data.linewidth,t.lineStyle=this._data.linestyle,e=this._points[0],t.moveTo(e.x,e.y),i=0;i0&&t.stroke(),this._points.length>1&&(this._data.leftend===c.Arrow&&s.prototype.drawArrow(this._points[1],this._points[0],t,t.lineWidth),this._data.rightend===c.Arrow&&s.prototype.drawArrow(this._points[this._points.length-2],this._points[this._points.length-1],t,t.lineWidth))}},o.prototype.hitTest=function(t){var e,i,o,s,a;if(null===this._data||void 0!==this._data.mouseTouchable&&!this._data.mouseTouchable)return null;for(e=TradingView.isMobile.any()?24:3,i=1;i0&&(o=this._points[0],s=this._points[this._points.length-1],a=r(o,s,t),a.distance<=e)?this._hittest:this._data.filled&&this._data.fillBackground&&n(t,this._data.points)?this._backHittest:null},t.exports=o},function(t,e,i){"use strict";var o,n,r;Object.defineProperty(e,"__esModule",{value:!0}),o=i(0),n=i(2),r=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._handleKeyDown=function(t){t.keyCode===e.props.keyCode&&e.props.handler(t)},e}return o.__extends(e,t),e.prototype.componentDidMount=function(){document.addEventListener("keydown",this._handleKeyDown,!1)},e.prototype.componentWillUnmount=function(){document.removeEventListener("keydown",this._handleKeyDown,!1)},e.prototype.render=function(){return null},e}(n.PureComponent),e.KeyboardDocumentListener=r},function(t,e,i){"use strict";function o(){return[[1,0,0],[0,1,0],[0,0,1]]}function n(t,e){var i,o,n,r=[[0,0,0],[0,0,0],[0,0,0]];for(i=0;i<3;i++)for(o=0;o<3;o++)for(n=0;n<3;n++)r[i][o]+=t[i][n]*e[n][o];return r}function r(t){var e=Math.cos(t),i=Math.sin(t);return[[e,-i,0],[i,e,0],[0,0,1]]}function s(t,e){return[[t,0,0],[0,e,0],[0,0,1]]}function a(t,e){return[[1,0,t],[0,1,e],[0,0,1]]}function l(t,e){var i,o,n=[e.x,e.y,1],r=[0,0,0];for(i=0;i<3;i++)for(o=0;o<3;o++)r[i]+=n[o]*t[i][o];return new c.Point(r[0],r[1])}Object.defineProperty(e,"__esModule",{value:!0});var c=i(8);e.identityMatrix=o,e.multiplyMatrices=n,e.rotationMatrix=r,e.scalingMatrix=s,e.translationMatrix=a,e.transformPoint=l -},function(t,e){t.exports=''},function(t,e,i){var o,n,r;!function(s){n=[i(13),i(243),i(392),i(75),i(168)],o=s,void 0!==(r="function"==typeof o?o.apply(e,n):o)&&(t.exports=r)}(function(t){return t.widget("ui.slider",t.ui.mouse,{version:"1.12.1",widgetEventPrefix:"slide",options:{animate:!1,classes:{"ui-slider":"ui-corner-all","ui-slider-handle":"ui-corner-all","ui-slider-range":"ui-corner-all ui-widget-header"},distance:0,max:100,min:0,orientation:"horizontal",range:!1,step:1,value:0,values:null,change:null,slide:null,start:null,stop:null},numPages:5,_create:function(){this._keySliding=!1,this._mouseSliding=!1,this._animateOff=!0,this._handleIndex=null,this._detectOrientation(),this._mouseInit(),this._calculateNewMax(),this._addClass("ui-slider ui-slider-"+this.orientation,"ui-widget ui-widget-content"),this._refresh(),this._animateOff=!1},_refresh:function(){this._createRange(),this._createHandles(),this._setupEvents(),this._refreshValue()},_createHandles:function(){var e,i,o=this.options,n=this.element.find(".ui-slider-handle"),r=[];for(i=o.values&&o.values.length||1,n.length>i&&(n.slice(i).remove(),n=n.slice(0,i)),e=n.length;e");this.handles=n.add(t(r.join("")).appendTo(this.element)),this._addClass(this.handles,"ui-slider-handle","ui-state-default"),this.handle=this.handles.eq(0),this.handles.each(function(e){t(this).data("ui-slider-handle-index",e).attr("tabIndex",0)})},_createRange:function(){var e=this.options;e.range?(!0===e.range&&(e.values?e.values.length&&2!==e.values.length?e.values=[e.values[0],e.values[0]]:t.isArray(e.values)&&(e.values=e.values.slice(0)):e.values=[this._valueMin(),this._valueMin()]),this.range&&this.range.length?(this._removeClass(this.range,"ui-slider-range-min ui-slider-range-max"),this.range.css({left:"",bottom:""})):(this.range=t("
").appendTo(this.element),this._addClass(this.range,"ui-slider-range")),"min"!==e.range&&"max"!==e.range||this._addClass(this.range,"ui-slider-range-"+e.range)):(this.range&&this.range.remove(),this.range=null)},_setupEvents:function(){this._off(this.handles),this._on(this.handles,this._handleEvents),this._hoverable(this.handles),this._focusable(this.handles)},_destroy:function(){this.handles.remove(),this.range&&this.range.remove(),this._mouseDestroy()},_mouseCapture:function(e){var i,o,n,r,s,a,l,c=this,h=this.options;return!h.disabled&&(this.elementSize={width:this.element.outerWidth(),height:this.element.outerHeight()},this.elementOffset=this.element.offset(),i={x:e.pageX,y:e.pageY},o=this._normValueFromMouse(i),n=this._valueMax()-this._valueMin()+1, -this.handles.each(function(e){var i=Math.abs(o-c.values(e));(n>i||n===i&&(e===c._lastChangedValue||c.values(e)===h.min))&&(n=i,r=t(this),s=e)}),!1!==this._start(e,s)&&(this._mouseSliding=!0,this._handleIndex=s,this._addClass(r,null,"ui-state-active"),r.trigger("focus"),a=r.offset(),l=!t(e.target).parents().addBack().is(".ui-slider-handle"),this._clickOffset=l?{left:0,top:0}:{left:e.pageX-a.left-r.width()/2,top:e.pageY-a.top-r.height()/2-(parseInt(r.css("borderTopWidth"),10)||0)-(parseInt(r.css("borderBottomWidth"),10)||0)+(parseInt(r.css("marginTop"),10)||0)},this.handles.hasClass("ui-state-hover")||this._slide(e,s,o),this._animateOff=!0,!0))},_mouseStart:function(){return!0},_mouseDrag:function(t){var e={x:t.pageX,y:t.pageY},i=this._normValueFromMouse(e);return this._slide(t,this._handleIndex,i),!1},_mouseStop:function(t){return this._removeClass(this.handles,null,"ui-state-active"),this._mouseSliding=!1,this._stop(t,this._handleIndex),this._change(t,this._handleIndex),this._handleIndex=null,this._clickOffset=null,this._animateOff=!1,!1},_detectOrientation:function(){this.orientation="vertical"===this.options.orientation?"vertical":"horizontal"},_normValueFromMouse:function(t){var e,i,o,n,r;return"horizontal"===this.orientation?(e=this.elementSize.width,i=t.x-this.elementOffset.left-(this._clickOffset?this._clickOffset.left:0)):(e=this.elementSize.height,i=t.y-this.elementOffset.top-(this._clickOffset?this._clickOffset.top:0)),o=i/e,o>1&&(o=1),o<0&&(o=0),"vertical"===this.orientation&&(o=1-o),n=this._valueMax()-this._valueMin(),r=this._valueMin()+o*n,this._trimAlignValue(r)},_uiHash:function(t,e,i){var o={handle:this.handles[t],handleIndex:t,value:void 0!==e?e:this.value()};return this._hasMultipleValues()&&(o.value=void 0!==e?e:this.values(t),o.values=i||this.values()),o},_hasMultipleValues:function(){return this.options.values&&this.options.values.length},_start:function(t,e){return this._trigger("start",t,this._uiHash(e))},_slide:function(t,e,i){var o,n=this.value(),r=this.values();this._hasMultipleValues()&&(o=this.values(e?0:1),n=this.values(e),2===this.options.values.length&&!0===this.options.range&&(i=0===e?Math.min(o,i):Math.max(o,i)),r[e]=i),i!==n&&!1!==this._trigger("slide",t,this._uiHash(e,i,r))&&(this._hasMultipleValues()?this.values(e,i):this.value(i))},_stop:function(t,e){this._trigger("stop",t,this._uiHash(e))},_change:function(t,e){this._keySliding||this._mouseSliding||(this._lastChangedValue=e,this._trigger("change",t,this._uiHash(e)))},value:function(t){return arguments.length?(this.options.value=this._trimAlignValue(t),this._refreshValue(),void this._change(null,0)):this._value()},values:function(e,i){var o,n,r;if(arguments.length>1)return this.options.values[e]=this._trimAlignValue(i),this._refreshValue(),void this._change(null,e);if(!arguments.length)return this._values();if(!t.isArray(arguments[0]))return this._hasMultipleValues()?this._values(e):this.value();for(o=this.options.values,n=arguments[0],r=0;r=0;o--)this._change(null,o);this._animateOff=!1;break;case"step":case"min":case"max":this._animateOff=!0,this._calculateNewMax(),this._refreshValue(),this._animateOff=!1;break;case"range":this._animateOff=!0,this._refresh(),this._animateOff=!1}},_setOptionDisabled:function(t){this._super(t),this._toggleClass(null,"ui-state-disabled",!!t)},_value:function(){var t=this.options.value;return t=this._trimAlignValue(t)},_values:function(t){var e,i,o;if(arguments.length)return e=this.options.values[t],e=this._trimAlignValue(e);if(this._hasMultipleValues()){for(i=this.options.values.slice(),o=0;o=this._valueMax())return this._valueMax();var e=this.options.step>0?this.options.step:1,i=(t-this._valueMin())%e,o=t-i;return 2*Math.abs(i)>=e&&(o+=i>0?e:-e),parseFloat(o.toFixed(5))},_calculateNewMax:function(){var t=this.options.max,e=this._valueMin(),i=this.options.step;t=Math.round((t-e)/i)*i+e,t>this.options.max&&(t-=i),this.max=parseFloat(t.toFixed(this._precision()))},_precision:function(){var t=this._precisionOf(this.options.step);return null!==this.options.min&&(t=Math.max(t,this._precisionOf(this.options.min))),t},_precisionOf:function(t){var e=""+t,i=e.indexOf(".");return-1===i?0:e.length-i-1},_valueMin:function(){return this.options.min},_valueMax:function(){return this.max},_refreshRange:function(t){"vertical"===t&&this.range.css({width:"",left:""}),"horizontal"===t&&this.range.css({height:"",bottom:""})},_refreshValue:function(){var e,i,o,n,r,s=this.options.range,a=this.options,l=this,c=!this._animateOff&&a.animate,h={};this._hasMultipleValues()?this.handles.each(function(o){i=(l.values(o)-l._valueMin())/(l._valueMax()-l._valueMin())*100,h["horizontal"===l.orientation?"left":"bottom"]=i+"%",t(this).stop(1,1)[c?"animate":"css"](h,a.animate),!0===l.options.range&&("horizontal"===l.orientation?(0===o&&l.range.stop(1,1)[c?"animate":"css"]({left:i+"%"},a.animate),1===o&&l.range[c?"animate":"css"]({width:i-e+"%"},{queue:!1,duration:a.animate})):(0===o&&l.range.stop(1,1)[c?"animate":"css"]({bottom:i+"%"},a.animate),1===o&&l.range[c?"animate":"css"]({height:i-e+"%"},{queue:!1,duration:a.animate}))),e=i}):(o=this.value(), -n=this._valueMin(),r=this._valueMax(),i=r!==n?(o-n)/(r-n)*100:0,h["horizontal"===this.orientation?"left":"bottom"]=i+"%",this.handle.stop(1,1)[c?"animate":"css"](h,a.animate),"min"===s&&"horizontal"===this.orientation&&this.range.stop(1,1)[c?"animate":"css"]({width:i+"%"},a.animate),"max"===s&&"horizontal"===this.orientation&&this.range.stop(1,1)[c?"animate":"css"]({width:100-i+"%"},a.animate),"min"===s&&"vertical"===this.orientation&&this.range.stop(1,1)[c?"animate":"css"]({height:i+"%"},a.animate),"max"===s&&"vertical"===this.orientation&&this.range.stop(1,1)[c?"animate":"css"]({height:100-i+"%"},a.animate))},_handleEvents:{keydown:function(e){var i,o,n,r=t(e.target).data("ui-slider-handle-index");switch(e.keyCode){case t.ui.keyCode.HOME:case t.ui.keyCode.END:case t.ui.keyCode.PAGE_UP:case t.ui.keyCode.PAGE_DOWN:case t.ui.keyCode.UP:case t.ui.keyCode.RIGHT:case t.ui.keyCode.DOWN:case t.ui.keyCode.LEFT:if(e.preventDefault(),!this._keySliding&&(this._keySliding=!0,this._addClass(t(e.target),null,"ui-state-active"),!1===this._start(e,r)))return}switch(n=this.options.step,i=o=this._hasMultipleValues()?this.values(r):this.value(),e.keyCode){case t.ui.keyCode.HOME:o=this._valueMin();break;case t.ui.keyCode.END:o=this._valueMax();break;case t.ui.keyCode.PAGE_UP:o=this._trimAlignValue(i+(this._valueMax()-this._valueMin())/this.numPages);break;case t.ui.keyCode.PAGE_DOWN:o=this._trimAlignValue(i-(this._valueMax()-this._valueMin())/this.numPages);break;case t.ui.keyCode.UP:case t.ui.keyCode.RIGHT:if(i===this._valueMax())return;o=this._trimAlignValue(i+n);break;case t.ui.keyCode.DOWN:case t.ui.keyCode.LEFT:if(i===this._valueMin())return;o=this._trimAlignValue(i-n)}this._slide(e,r,o)},keyup:function(e){var i=t(e.target).data("ui-slider-handle-index");this._keySliding&&(this._keySliding=!1,this._stop(e,i),this._change(e,i),this._removeClass(t(e.target),null,"ui-state-active"))}}})})},function(t,e,i){"use strict";(function(e){function o(t,i,o){var n={saveAsText:$.t("Save As..."),applyDefaultText:$.t("Apply Defaults")};this._toolName=t,this._applyTemplate=i,this._options=$.extend(n,o||{}),this._list=[],e.enabled("charting_library_base")||(this.templatesDeferred=this.loadData())}var n=i(133).bindPopupMenu,r=i(154),s=r.SaveRenameDialog,a=r.InputField,l=i(112).createConfirmDialog,c=i(7).getLogger("Chart.LineToolTemplatesList");o._cache={},o.prototype.getData=function(){return this._list},o.prototype.loadData=function(){var t=this;return this._toolName in o._cache?(this._list=o._cache[this._toolName],$.Deferred().resolve()):$.get("/drawing-templates/"+this._toolName+"/",function(e){t._list=e,o._cache[t._toolName]=e}).error(function(){c.logWarn("Failed to load drawing template: "+t._toolName)})},o.prototype.templatesLoaded=function(){return this.templatesDeferred},o.prototype.invalidateToolCache=function(){delete o._cache[this._toolName]},o.prototype.createButton=function(t){var e,i=this;return t=$.extend({},t,i._options), -e=$("").addClass(t.buttonClass?t.buttonClass:"_tv-button").html(t.buttonInner?t.buttonInner:$.t("Template")+''),n(e,null,{event:"button-popup",zIndex:t.popupZIndex,activeClass:t.popupActiveClass,direction:t.popupDirection}),e.bind("click",function(e){var o,n,r;e.stopPropagation(),$(this).is("active")||(o=[],"function"==typeof t.getDataForSaveAs&&(n=function(e){var o=JSON.stringify(t.getDataForSaveAs());i.saveTemplate(e,o)},o.push({title:t.saveAsText,action:i.showSaveDialog.bind(i,n),addClass:"special"})),"function"==typeof t.defaultsCallback&&o.push({title:t.applyDefaultText,action:t.defaultsCallback,addClass:"special"}),r=[],$.each(i._list,function(e,o){r.push({title:o,action:function(){i.loadTemplate.call(i,o,t.loadTemplateCallback)},deleteAction:function(){runOrSignIn(function(){var t=$.t("Do you really want to delete Drawing Template '{0}' ?").format(o),e=l({type:"modal",content:t});e.on("action:yes",function(t){i.removeTemplate.call(i,o),t.close()}),e.open()},{source:"Delete line tool template"})}})}),r.length&&(r.sort(function(t,e){return t=t.title.toUpperCase(),e=e.title.toUpperCase(),t===e?0:t>e?1:-1}),o.push({separator:!0}),o=o.concat(r)),$(this).trigger("button-popup",[o]))}),e},o.prototype.loadTemplate=function(t,e){var i=this;return $.get("/drawing-template/"+this._toolName+"/?templateName="+encodeURIComponent(t),function(t){i._applyTemplate(JSON.parse(t.content)),e&&e()}).error(function(t){c.logWarn(t.responseText)})},o.prototype.removeTemplate=function(t){if(t){var e=this;$.post("/remove-drawing-template/",{name:t,tool:e._toolName}).error(function(t){c.logWarn(t.responseText)}),e.invalidateToolCache(),e._list=$.grep(e._list,function(e){return e!==t})}},o.prototype.saveTemplate=function(t,e){var i,o,n,r,s=this;t&&e&&(t=TradingView.clean(t),i=-1!==$.inArray(t,s._list),o=function(){var o={name:t,tool:s._toolName,content:e},n=function(){i||s._list.push(t)};$.post("/save-drawing-template/",o,n).error(function(t){c.logWarn(t.responseText)}),s.invalidateToolCache()},i?(n=$.t("Drawing Template '{0}' already exists. Do you really want to replace it?").format(t),r=l({type:"modal",content:n}),r.on("action:yes",function(t){o(),t.close()}),r.open()):o())},o.prototype.deleteAction=function(t){var e=t,i=this;runOrSignIn(function(){var t=$.t(" Do you really want to delete Drawing Template '{0}' ?").format(e),o=l({type:"modal",content:t});o.on("action:yes",function(t){i.removeTemplate.call(i,e),t.close()}),o.open()},{source:"Delete line tool template"})},o.prototype.showSaveDialog=function(t){var e="text",i=new s({fields:[new a({name:e,label:$.t("Template name")+":",maxLength:64,error:$.t("Please enter template name")})],title:$.t("Save Drawing Template As")});runOrSignIn(function(){i.show().then(function(i){t(i[e])})},{source:"Save line tool template",sourceMeta:"Chart"})},t.exports=o}).call(e,i(5))},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});!function(t){t.offset=8,t.font="Arial",t.fontSize=12,t.lineSpacing=10, -t.bgColor="rgba(255,255,255,.8)",t.borderColor="#e3e3e3",t.padding=8}(e.LabelSettings||(e.LabelSettings={}))},,,function(t,e,i){"use strict";!function(t){t.fn.selectable=function(e){return this.each(function(){var i=t(this);i.css("user-select",e?"text":"none"),i.css("-moz-user-select",e?"text":"-moz-none"),i.css("-webkit-user-select",e?"auto":"none"),(t.browser.msie||t.browser.opera)&&i.attr("unselectable",e?"off":"on")})}}(jQuery)},,function(t,e,i){var o,n,r;!function(s){n=[i(13),i(75)],o=s,void 0!==(r="function"==typeof o?o.apply(e,n):o)&&(t.exports=r)}(function(t){return t.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38}})},function(t,e){t.exports=''},function(t,e,i){"use strict";(function(t,o,n){function r(e){this._chartWidgetCollection=e,this._chartAboutToBeSavedDelegate=new t,this._chartSavedDelegate=new t,this._chartSizeLimitExceededDelegate=new t}function s(t,e,i,o){var r,s,a;o=o||{},r={wl:o.wl,images:JSON.stringify(t.images()),previews:o.previews,onWidget:o.onWidget},s=t.activeChartWidget.value().widgetCustomer(),s&&(r.customer=s),r.timezone=t.activeChartWidget.value()._properties.timezone.value(),window.urlParams&&window.urlParams.locale&&(r.language=urlParams.locale),a=n.enabled("charting_library_base")?o.snapshotUrl||"https://www.tradingview.com/snapshot/":"/snapshot/",$.post(a,r,function(t){t?e(t):i()}).fail(function(){i()})}var a=i(92);r.prototype.chartAboutToBeSaved=function(){return this._chartAboutToBeSavedDelegate},r.prototype.chartSaved=function(){return this._chartSavedDelegate},r.prototype.chartSizeLimitExceeded=function(){return this._chartSizeLimitExceededDelegate},r.prototype.whenReadyToSave=function(t){var e,i,o=this._chartWidgetCollection,n=o.activeChartWidget.value(),r=n.model().mainSeries();r.symbolInfo()&&!r.hasDelayedSymbolIntervalChange()?t():(e=null,i=null,e=function(){r.onSymbolError().unsubscribe(null,i,!0),t()},i=function(){r.onSymbolResolved().unsubscribe(null,e,!0)},r.onSymbolResolved().subscribe(null,e,!0),r.onSymbolError().subscribe(null,i,!0))},r.prototype.saveToJSON=function(){return this._fillSavingInfo(!1,!0)},r.prototype._fillAsyncInfo=function(t,e,i){function o(e){t.content=JSON.stringify($.extend(!0,r,e)),n.resolve(t)}var n,r=JSON.parse(t.content),s=this._chartWidgetCollection;return e||(i=!0),n=$.Deferred(),i?s.asyncState(!!e).then(o):s.activeChartWidget.value().asyncState(!!e).then(o),n.promise()},r.prototype._fillSavingInfo=function(t,e,i){var o,n,r,s,a,l,c,h,u,d,p,_;if(t||(e=!0),o={publish_request_id:Math.random().toString(36).substring(2)},n=this._chartWidgetCollection,r=n.activeChartWidget.value(),s=n.metaInfo,a=r.model().mainSeries(),l=a.properties(),c=a.symbolInfo(),s.id.value()&&(o.id=s.id.value()),o.name=s.name.value()||"",o.description=s.description.value()||"", -o.resolution=a.properties().interval.value(),o.symbol_type=null!==c&&c.type||"",o.exchange=null!==c&&c.exchange||"",o.listed_exchange=null!==c&&c.listed_exchange||"",null!==c&&a.isSpread()?(h=c.legs[0],u=c.base_name[0],u=u.split(":")[1],o.symbol=h,o.short_name=u,o.expression=c.full_name):(o.symbol=null!==c&&c.ticker||l.symbol.value(),o.short_name=l.shortName.value()),null!==c){for(d=[],p=0,_=c.legs.length;p<_;p++)d.push({symbol:c.legs[p],pro_symbol:c.base_name[p]});o.legs=JSON.stringify(d)}else o.legs=JSON.stringify([]);return o.content=e?JSON.stringify(n.state(!!t,i)):JSON.stringify(r.state(!!t,i)),t&&(o.image=JSON.stringify(n.images({onlyActiveChart:!e}))),o.is_realtime=t?"0":"1",o},r.prototype.publishChart=function(t){},r.prototype.publishScript=function(t,e,i){var o,n,r,s,a=this;a._scriptPublisher?a._scriptPublisher.openPublication(t,e):(o=i.ScriptPublisher,n=i.ScriptsProvider,r=i.CategoriesProvider,s=new n({publish:function(t){return new Promise(function(e,i){var o={closeForm:function(){if(t&&t.scriptPublication&&t.scriptPublication.updateScriptIdPart){var i=t.scriptPublication.updateScriptIdPart;publishedScripts.invalidateCache([i]),window.studyMarket&&(window.studyMarket.resetAllPages(),window.studyMarket.updateFavorites())}e()},showError:function(t){i(t)}};a.onPublish(t,o)})}}),a._scriptPublisher=new o({scriptsProvider:s,categoriesProvider:new r}),a._scriptPublisher.openPublication(t,e))},r.prototype.onPublish=function(t,e){function i(i){var n,r,s,l,c,h;a.publishInProgress=!1,n=i.responseText||i,"ok:"===n.substr(0,3)?(r=!1,e.savePrivacySetting&&(r=!t.is_public,TVSettings.setValue("publishchart.private",r)),kmRecord("Chart","{0} Published".format(void 0===t.script_type?"Chart":"Script"),{is_private:r}),s=n.substr(3),l=JSON.parse(s),a._chartWidgetCollection.metaInfo.id.value()||a._chartWidgetCollection.metaInfo.id.setValue(l.id),e.closeForm&&e.closeForm(),a._lastPublishUrl=l.publishUrl,a.hWnd&&(c=l.publishUrl,e.ideaUrl&&(c=o.render(e.ideaUrl,{idea:l.idea})),a.hWnd.location=c)):(e.showError&&((413===i.status||/^[\d\s]*request.+large/i.test(n.trim()))&&(n=window.t("This chart layout has a lot of objects and can't be published! Please remove some drawings and/or studies from this chart layout and try to publish it again.")),h={html:!0},e.showError(n||$.t("Error occured while publishing"),h)),a.hWnd&&(a.hWnd.close(),a.hWnd=null))}var n,r,s,a=this;a.publishInProgress||(n=a._fillSavingInfo(!0,e&&e.publishAllLayout,!0),a._fillAsyncInfo(n,!0,e&&e.publishAllLayout).then(function(e){var o=t.scriptPublication,n=!(!o||!o.updateScriptIdPart),r=new Promise(function(t,e){if(o){var i;i=n?ScriptLib.publishNext(o.scriptSource,o.updateScriptIdPart):ScriptLib.publishNew(o.scriptSource,o.scriptProtection),i.done(function(e){n||o.scriptProtection!==TVScript.Access.ACCESS_CLOSED_NEEDS_AUTH||PinePerm.add(window.user.username,e.pineId),t(e.publishedstudyscript_id)}).fail(e)}else t()});n?r.then(function(o){var n={publishedstudyscript_id:o,description:t.description,tags:t.tags};$.ajax({url:"/script-update/",type:"post",dataType:"text", -data:$.extend({},e,n),complete:i})},i):r.then(function(o){o&&(t.publishedstudyscript_id=o),$.ajax({url:"/publishchart/",type:"post",dataType:"text",data:$.extend({},e,t),complete:i})},i)}),a.publishInProgress=!0,e.onWidget&&!e.ideaUrl||""!==t.name&&""!==t.description&&t.description.length<=4e3&&t.name.length<=64&&($.cookie("publish_request_id",n.publish_request_id,{path:"/"}),r="/loading/",e.ideaUrl&&(s=urlParams.createUrlParams({ideaUrl:e.ideaUrl}),r="/loading?"+s),a.hWnd=window.open(r,"_blank")))},r.prototype._saveChart=function(t,e,i,o,n){var r=i,s=o;return r=function(t){e.id.value()||(e.id.setValue(t),e.uid.setValue(t)),"function"==typeof i&&i()},a.saveChart(t.name,t.short_name,t.resolution,t,e,r,s.bind(this))},r.prototype.saveChartSilently=function(t,e,i,o){var n=this._chartWidgetCollection.metaInfo,r=this._fillSavingInfo(e);if(o=o||{},o.chartName&&(r.name=o.chartName),r.name&&0!==r.name.length||!o.defaultChartName||(r.name=o.defaultChartName),!r.name)return void console.warn("Saving chart with empty name is not allowed");$(window).on("beforeunload.savechart",function(){return $.t("Your chart is being saved, please wait a moment before you leave this page.")}),this._chartAboutToBeSavedDelegate.fire(),this._saveChart(r,n,function(){this._chartWidgetCollection.metaInfo.name.setValue(r.name),this._chartSavedDelegate.fire(!0),t&&t(n)}.bind(this),function(){this._chartSavedDelegate.fire(!1),i&&i.apply(null,arguments)}.bind(this),o),$(window).off("beforeunload.savechart")},e.ChartSaver=r,e.takeSnapshot=s}).call(e,i(10),i(41),i(5))},function(t,e,i){"use strict";function o(t){var e,i;if(t&&t.__esModule)return t;if(e={},null!=t)for(i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e.default=t,e}function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var r,s,a,l,c,h,u,d;Object.defineProperty(e,"__esModule",{value:!0}),e.DropdownView=void 0,r=function(){function t(t,e){var i,o;for(i=0;i1&&void 0!==arguments[1]?arguments[1]:{};n(this,t),this.$el=e,this.$wrap=o.$wrap||e.find(".tv-dropdown-behavior__button"),this.$body=o.$body||e.find(".tv-dropdown-behavior__body"),this.notCloseWithCtrl=!!o.notCloseWithCtrl&&o.notCloseWithCtrl,this.closeWithEsc=void 0===o.closeWithEsc||o.closeWithEsc,this.animationDisabled=!0===o.noAnimation,this.closeWithEsc&&this.$el.attr("tabIndex",0),this.animationDisabled||this.$body.addClass("tv-dropdown-behavior__body--animated"),(e.data("scroll")||o.scroll)&&(this.$scroll=this.$body.find(".tv-dropdown-behavior__scroll"),this.$inScroll=this.$scroll.find(".tv-dropdown-behavior__inscroll"),this.scroll=new c.SidebarCustomScroll(this.$scroll,this.$inScroll,{showTopShadow:!1,showBottomShadow:!1}), -this.$scrollBar=this.scroll.getScrollBar(),this.$scrollBar&&this.$scrollBar.on("mousedown.tv-dropdown-view-scroll",function(){i.offClickOutside(),$(document).on("mouseup.tv-dropdown-view-scroll",function(){i.onClickOutside(),$(document).off("mouseup.tv-dropdown-view-scroll")})})),(e.data("adaptBody")||o.adaptBody)&&(this._adaptBody=!0),this._fitScreen=e.data("fitScreen")||o.fitScreen,this.$wrap.add(e.find(".js-dropdown-toggle")).on("click",function(t){$(t.currentTarget).hasClass("js-prevent-dropdown")||i.toggle()})}return r(t,[{key:"toggle",value:function(){this.opened?this.close(!0):this.open()}},{key:"open",value:function(){var t=this;this.animating||this.opened||this.disabled||(this.$el.trigger("beforeOpenMenu"),this.$body.removeClass("i-hidden"),this.$wrap.addClass("i-dropped"),this.$el.addClass("i-opened"),"horz"===this._fitScreen&&this.fitHorizontally(),this._adaptBody&&this.adaptBody(),this.updateDelays(),this.onClickOutside(),this._doOpenAnimation().then(function(){t.$body.addClass("i-opened"),t.$el.trigger("updateScroll"),t.$el.trigger("afterOpenMenu"),t.opened=!0}),this.closeWithEsc&&this.$el.on("keypress keyup",function(e){e.keyCode===u.ESC&&t.close(!0)}))}},{key:"onClickOutside",value:function(){var t=this;setTimeout(function(){t.$body.on("clickoutside",function(){t.close(!0)})},0)}},{key:"offClickOutside",value:function(){this.$body.off("clickoutside")}},{key:"close",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.animating||!this.opened||this.disabled||!e&&this.notCloseWithCtrl&&(window.event.ctrlKey||window.event.metaKey)||(this.offClickOutside(),this.$wrap.removeClass("i-dropped"),this.$el.trigger("beforeCloseMenu"),this._doCloseAnimation().then(function(){t.$body.removeClass("i-opened").addClass("i-hidden"),t.$el.removeClass("i-opened").trigger("afterCloseMenu"),t.opened=!1}),this.closeWithEsc&&this.$el.off("keypress keyup"))}},{key:"isOpened",value:function(){return this.opened}},{key:"updateScroll",value:function(){this.scroll&&(this.scroll.updateScrollBar(),this.scroll.scrollToStart())}},{key:"updateDelays",value:function(){var t,e,i,o,n;this.animationDisabled||(t=this.$scroll||this.$body,e=t.offset().top,i=t.outerHeight(),o=this.$body.find(".tv-dropdown-behavior__item").filter(function(t,o){var n=$(o),r=n.offset().top;return r+n.outerHeight()>=e&&r1&&void 0!==arguments[1]?arguments[1]:{};return new d(t,e)})},function(t,e,i){"use strict";function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var n;Object.defineProperty(e,"__esModule",{value:!0}),n=function(){function t(t,e){var i,o;for(i=0;i\n\t\t\t\t'+i+'\n\t\t\t\t\n\t\t\t'),this._$input=this._$field.find("input"),this._error=a}return n(t,[{key:"appendTo",value:function(t){t.append(this._$field)}},{key:"focus",value:function(){return this._$input.focus()}},{key:"select",value:function(){return this.focus().select()}},{key:"value",set:function(t){this._$input.val(t)},get:function(){return this._$input.val()}},{key:"name",get:function(){return this._name}},{key:"valid",get:function(){ -return!!this._$input.val().trim()}},{key:"error",set:function(t){this._error=t},get:function(){return this._error}}]),t}()},function(t,e,i){"use strict";function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var n,r;Object.defineProperty(e,"__esModule",{value:!0}),e.SaveRenameDialog=void 0,n=function(){function t(t,e){var i,o;for(i=0;i0&&void 0!==arguments[0]?arguments[0]:{},i=e.fields,n=e.title,r=void 0===n?"":n,s=e.destroyOnClose,a=void 0===s||s,l=e.modal,c=void 0!==l&&l;o(this,t),this._$form=$("
"),this._fields=i,this._appendFieldsToForm(),this._title=r,this._destroyOnClose=a,this._modal=c}return n(t,[{key:"setField",value:function(t,e){this._fields.find(function(e){return e.name===t}).value=e}},{key:"show",value:function(){var t=this,e=this._createDialog(),i=new Promise(function(i){e.on("action:submit",function(e){return t._onSubmit(e,i)})});return e.open(),this._fields[0].select(),i}},{key:"_appendFieldsToForm",value:function(){var t=this;this._fields.forEach(function(e){e.appendTo(t._$form)})}},{key:"_createDialog",value:function(){return(0,r.createDialog)({type:this._modal?"modal":"popup",title:this._title,content:this._$form,actionsWrapTemplate:'
',width:470,destroyOnClose:this._destroyOnClose,actions:[{name:"submit",type:"primary",text:$.t("Save"),key:13,addClass:"js-submit-button"},{name:"cancel",type:"default",text:$.t("Cancel"),method:"close",addClass:"js-cancel-button"}]})}},{key:"_onSubmit",value:function(t,e){var i=this._validate();i?(t.error(i.error),i.focus()):(e(this._collectValues(),t),t.close())}},{key:"_validate",value:function(){return this._fields.find(function(t){return!t.valid})}},{key:"_collectValues",value:function(){return this._fields.reduce(function(t,e){return t[e.name]=e.value,t},{})}}]),t}()},function(t,e,i){"use strict";(function(e,o,n){function r(){this.title=$.t("Load Chart Layout"),this._removeDialogShown=!1,this.options={},this.matchedItems=[],this.itemsData=[],this.qs=new r.QuickSearch(this.fieldsExtractor,this.searchResult.bind(this)),this.sortObj=new r.SortObject(this.modifiedCompare),this.nameSort=new r.SortObject(this.nameCompare),this.symbolSort=new r.SortObject(this.symbolCompare),this.toolsSort=new r.SortObject(this.toolsCompare),this.offset=0,h.on("chart_loaded",r.onChartLoaded,this)}function s(t){return t.getAttribute("data-id")}var a,l,c,h=i(23),u=i(65).createDialog,d=i(317).createSearchControl,p=i(201).regExpEscape -;a='
{{#withFavs}}
'+i(211)+''+i(210)+'
{{/withFavs}}
{{title}}
{{modifiedDate}}
{{chartSymbol}}
'+i(169)+"
",l='
'+$.t("Chart Layout Name")+'
'+$.t("Last Modified")+'
'+$.t("Active Symbol")+'
',c=50,r.onChartLoaded=function(){this.itemsData&&this.itemsData.length>0&&this._refreshChartsList()},r.QuickSearch=function(t,e){this.fieldsExtractor=t,this.callback=e,this.regExps=[]},r.QuickSearch.prototype.onInput=function(t){this.query=t,this.createRegexps(t),this.search()},r.QuickSearch.prototype.createRegexps=function(t){this.regExps=[],t&&this.regExps.push(RegExp("("+t.split("").map(function(t){return p(t)}).join(")(.*?)(")+")","i"))},r.QuickSearch.prototype.match=function(t){var e,i,o,n;for(e=0;e-1&&this.itemsData.splice(e,1),this.setChartsData(this.itemsData)},r.prototype.modifiedCompare=function(t,e){var i=t.modified,o=e.modified;return n(o).diff(n(i))},r.prototype.nameCompare=function(t,e){return t.title.localeCompare(e.title)},r.symbolWrap=function(t){return""===t.symbol?"multiple charts":t.symbol+" "+t.interval},r.prototype.symbolCompare=function(t,e){return r.symbolWrap(t).localeCompare(r.symbolWrap(e))},r.prototype.toolsCompare=function(t,e){var i=t.toolsCount,o=e.toolsCount;return i=this.matchedItems.length)){for(t=Math.min(this.offset+c,this.matchedItems.length),e="",i=this.offset;i");r.append(n.$control),r.append('
'),this.content=$("
").appendTo(r.find(".tv-load-chart-dialog-table")),this.header=this.layoutHeader(),this.setSort(),this.itemsListContainer=$('
').data({localScroll:!0}).appendTo(this.content),this.itemsList=$('
').appendTo(this.itemsListContainer),$('
').text($.t("There are no saved charts")).appendTo(this.itemsListContainer),this.itemsListContainer.on("click",".js-remove-button",function(t){var e=i._findItemById(s(t.currentTarget));i._onRemoveButtonClicked(e,t),t.stopPropagation()}).on("click",".js-table-row",function(t){var e=i._findItemById(s(t.currentTarget));i._onItemClicked(e,t),t.preventDefault()}).on("scrolltoend",function(){ -i.showMoreData()}),o.enabled("items_favoriting")&&this.itemsListContainer.on("click",".js-empty-star",function(t){var e=i._findItemById(s(t.currentTarget));i._onFavoriteClicked(e,!0,t),t.stopPropagation()}).on("click",".js-filled-star",function(t){var e=i._findItemById(s(t.currentTarget));i._onFavoriteClicked(e,!1,t),t.stopPropagation()}),this.header.children(".tv-load-chart-dialog-table__column--header").click($.proxy(this,"sortClick")),n.inputChangedDelegate.subscribe(this.qs,this.qs.onInput),this.favorites=e,this.setChartsData(t),this.qs.onInput(""),this._dialog&&this._dialog.close(),this._dialog=u({title:this.title,width:600,height:550,content:r,contentWrapTemplate:"
",destroyOnClose:!0,withScroll:!1,isClickOutFn:function(){return!this._removeDialogShown&&void 0}.bind(this)}),this._dialog.open()},r.prototype.highlightOccurrences=function(t){0!==t.length&&this.itemsList.children(".js-table-row").each(function(){var e,i=$(this).find(".js-column-name"),o=i.text();o=r.highlightText(o,t),i.html(o),e=$(this).find(".js-column-symbol"),o=e.text(),o=r.highlightText(o,t),e.html(o)})},r.highlightText=function(t,e){var i,o,n,r,s,a;if(t=$("
").text(t).html(),0===e.length)return t;for(i=0;i$'+a+"":"$"+a;if((r=t.replace(o,n))&&r!==t)return r}},t.exports=r}).call(e,i(41),i(5),i(38))},function(t,e,i){"use strict";function o(t,e,i,o){var s=(0,n.createConfirmDialog)({type:"modal",content:document.createTextNode($.t("Do you really want to delete Chart Layout '{0}' ?").format(t)),addClass:"delete-chart-dialog"}),a=function(){var t=o;o=null,t&&t()};s.on("action:yes",function(){o=null,r.removeChart(e,i),s.close()}),s.on("action:no",a),s.on("afterClose",a),s.open()}var n,r;Object.defineProperty(e,"__esModule",{value:!0}),e.deleteChart=o,n=i(112),r=i(92)},function(t,e,i){"use strict";function o(t){l.call(this,t),this.ch=t.char[0]||" ",this.fontFamily=t.fontFamily||"Arial",this._charCache=new a(this.ch,!1,!1,this.fontFamily,this.height)}var n=i(8).Point,r=i(45).selectionTolerance,s=i(11),a=i(328),l=i(56).PaneRendererAbstractShape;inherit(o,l),o.prototype.drawShape=function(t){var e,i,o,n,r,s,a=this._vertOffset>0?1:-1;for(e=0,i=this.items.length;e0?"middle":"bottom")},o.prototype.hitTest=function(t){var e,i,o,a=this._vertOffset,l=r(this.height);for(e=0;eo?1:-1},t}(),e.SessionEntry=d,p=function(){function t(t){void 0===t&&(t="0000-0000");var e=this;this._entries=[],this._firstDayOfWeek=s.MONDAY,this._weekEndsCount=null,"24x7"===t.toLowerCase()?u.forEach(function(t){e.addSessionEntry(t,0,0)}):this._parseSpec(t),this._entries.sort(o)}return t.prototype.entries=function(){return this._entries},t.prototype.firstDayOfWeek=function(){return this._firstDayOfWeek},t.prototype.addSessionEntry=function(t,e,i){i<=e&&0!==e&&(e-=s.minutesPerDay);var o=i===e?s.minutesPerDay:i-e;this._entries.push(new d(t,e,o))},t.prototype.isWeekEnd=function(t){var e=a.lowerbound(this._entries,new d(t,0,0),function(t,e){return t.dayOfWeek()this._entries.length-1||this._entries[e].dayOfWeek()!==t},t.prototype.weekEndsCount=function(){if(null===this._weekEndsCount){var t={};this._entries.forEach(function(e){t[e.dayOfWeek()]=1}),this._weekEndsCount=7-Object.keys(t).reduce(function(e,i){return e+(t[+i]||0)},0)}return this._weekEndsCount},t.prototype.hasWeekEnds=function(){return this.weekEndsCount()>0},t.prototype.indexOfSessionEntry=function(t,e){var i=a.lowerbound(this._entries,new d(t,e,0),function(t,e){return t.compareTo(e)<0});return i>this._entries.length-1?0:i},t.prototype.findSessionEntry=function(t,e){return this._entries[this.indexOfSessionEntry(t,e)]},t.prototype.correctTradingDay=function(t,e){var i=s.get_day_of_week(t),o=60*s.get_hours(t)+s.get_minutes(t),n=this.findSessionEntry(i,o),r=n.dayOfWeek(),a=(r-i+7)%7;return 0!==a?s.add_days_considering_dst(e,t,a):t},t.prototype.alignToSessionStart=function(t,e){var i=s.get_day_of_week(t),o=s.get_minutes_from_midnight(t),n=this.findSessionEntry(i,o),a=n.alignedStart(),l=n.dayOfWeek(),c=n.isOvernight(),h=(l-i+7)%7-(c?1:0);return 0!==h&&s.add_date(t,h),s.set_hms(t,a/60|0,a%60,0,0),r(n.length(),t,e)},t.prototype._parseSpec=function(t){var e=this,i={},o=!1;t=this._parseFirstDayOfWeek(t),t.split("|").forEach(function(t){var e,r,s=t.split(":");if(1!==s.length&&2!==s.length)return void c.logError("Bad session section: "+t);if(e=1===s.length){if(o)return void c.logError("Duplicated default section: "+t);o=!0}r=e?h:n(s[1]),r.forEach(function(t){e&&i[t]||(i[t]=s[0])})}),u.forEach(function(o){var n=i[o];void 0!==n&&n.split(",").forEach(function(i){var n,r,a=i.split("-");2!==a.length&&(c.logError("Bad sessions spec: "+t),a=["0000","0000"]),n=a[0],r=a[1],e.addSessionEntry(o,s.get_minutes_from_hhmm(n),s.get_minutes_from_hhmm(r))})})},t.prototype._parseFirstDayOfWeek=function(t){var e,i,o,n=t.split(";");return n.length>2?(c.logError("Only one `first day` specification expected @ session "+t),t):1===n.length?t:(e=n[0].indexOf("-")>=0,i=e?NaN:parseInt(n[0]),o=1,isNaN(i)&&(o=0,i=parseInt(n[1])),is.SATURDAY?(c.logError("Unexpected day index @ session: "+t+"; day index "+i),t):(this._firstDayOfWeek=i,n[o]))},t}(),e.ExchangeSession=p},,,,function(t,e,i){"use strict";(function(t){function o(e){var i,o,c,h,u,d,p,_,f,m,g;if(e=$.extend({},l,e),i=$(t.render(s,{tabs:e.tabs,customControls:e.customControls,customControlsAddClass:e.customControlsContainerAddClass},{additionalHeaderContent:e.additionalHeaderContent})),o=$(a),c=o,e.contentAddClass&&o.addClass(e.contentAddClass),!1!==e.withScroll&&(o=$('
').append(c.addClass("tv-dialog__scroll-wrap-inner"))),h=$('
').append(i).append(o),e.customControls&&i.find(".js-custom-controls").append(e.customControls),!0!==e.doNotCreatePages)for(u=0;u').append(e.tabs[u].page));return d=e.tabStateSaveKey,p=e.activeTab,_=e.tabsScrollBoxAddClass,f=e.tabAddClass,delete e.tabs,delete e.activeTab,delete e.customControls, -delete e.tabStateSaveKey,delete e.customControlsContainerAddClass,delete e.tabsScrollBoxAddClass,delete e.tabAddClass,e.closeButtonAddClass="tv-tabbed-dialog__close",e.contentWrapTemplate=h,m=(0,r.createDialog)(e),g=new n.Tabs(i.find(".tv-tabs").get(0),c.get(0),{addLeftArrowsClass:"tv-tabbed-dialog__tabs-arrow-left",addRightArrowsClass:"tv-tabbed-dialog__tabs-arrow-right",addScrollBoxClass:_,tabClass:f,saveTab:d,activeTab:p}),m.on("afterOpen",function(){g.setActivePage(g.index(),!0,!0)}),{dialog:m,tabs:g}}var n,r,s,a,l;Object.defineProperty(e,"__esModule",{value:!0}),e.createTabbedDialog=o,n=i(956),r=i(65),i(959),s='
{{#tabs}}
{{name}}
{{/tabs}}
{{#customControls}}
{{/customControls}}
{{>additionalHeaderContent}}',a='
',l={tabs:[]}}).call(e,i(41))},function(t,e){t.exports=''},function(t,e){t.exports=''},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,i){"use strict";(function(t){function e(){var e=window.parent[window.urlParams.uid].settingsAdapter;null!=e?(TVSettings.setSettingsAdapter(e),TVSettings.sync()):t.enabled("use_localstorage_for_settings")&&TVSettings.sync()}function o(){var t,e,i,o,n=urlParams.theme;return n?(t=p.savedThemeName(),e=n.toLowerCase(),(i=p.themes[e])?(p.setTheme(i.name),p.syncTheme(),n===t?$.Deferred().resolve():(o=$.Deferred(),p.getStdTheme(i.name).then(function(t){o.resolve(t.content)}).catch(function(t){console.warn("Cannot load theme {0}, reason: {1}".format(i.name,t)),o.resolve()}),o.promise())):$.Deferred().resolve()):$.Deferred().resolve()}function n(){JSON.parse(urlParams.disabledFeatures).forEach(function(e){t.setEnabled(e,!1)}),JSON.parse(urlParams.enabledFeatures).forEach(function(e){t.setEnabled(e,!0)})}function r(){ -t.enabled("saveload_storage_customization")&&(window.parent[urlParams.uid].saveLoadAdapter?_.setCustomAdapter(window.parent[urlParams.uid].saveLoadAdapter):void 0!==urlParams.chartsStorageUrl&&urlParams.chartsStorageUrl&&void 0!==urlParams.clientId&&urlParams.clientId?_.initialize(urlParams.clientId,urlParams.userId,urlParams.chartsStorageUrl,urlParams.chartsStorageVer||"1.0"):(t.setEnabled("saveload_storage_customization",!1),t.setEnabled("header_saveload",!1)))}function s(){q.resolve()}var a,l,c,h,u,d,p,_,f,m,g,v,y,b,S,w,T,C,x,P,L,I,k,A,M,E,D,V,O,R,B,z,F,N,W,H,U,j,q,G;i(571),i(12),a=i(574),i(575),i(299),i(602),n(),l=i(2),c=i(39),h=i(603).HeaderToolbar,u=i(622).DrawingToolbar,d=i(307).isDrawingToolbarVisible,p=i(311),_=i(312),f=i(52).Action,m=i(394).ChartSaver,g=i(745).StudyTemplates,v=i(760).FavoriteStudyTemplateService,y=i(76),b=i(23),S=i(28),w=S.formatterOptions,T=S.customFormatters,C=i(761),x=i(762),P=i(770).SaveLoadWidget,L=i(93).TVXWindowEvents,I=i(775),k=i(208),A=i(323).Root,M=i(780).ChartPage,E=new A(window),D=new M(E.allocate()),i(783),V=i(784),O=i(974).FavoriteDrawingToolbar,R=i(977),B=i(1002),z=i(33),F=i(1011),i(235),i(1019),N=i(71),W=window.parent[urlParams.uid].customIndicatorsUrl,H=$.Deferred(),U=$.Deferred(),$.when(H,U).done(function(){ChartApiInstance.start()}),W?$.getScript(W).done(function(){void 0!==window.__customIndicators&&window.isArray(window.__customIndicators)&&(window.PineJS=i(48),JSServer.studyLibrary=JSServer.studyLibrary.concat(window.__customIndicators),console.log("{0} custom indicators loaded.".format(window.__customIndicators.length)),H.resolve())}).fail(function(t){console.warn("Error loading custom indicators @ `{0}`: {1} ({2}) ".format(W,t.statusText,t.status)),H.resolve()}):H.resolve(),window.widgetReady=function(t){b.subscribe("onChartReady",t)},window.customizeUI=function(t){null!=t.studiesOverrides&&z.setDefaultsOverrides(t.studiesOverrides),window.__defaultsOverrides=t.defaultsOverrides},window.applyStudiesOverrides=function(t){t&&window.chartWidgetCollection.applyStudiesOverrides(t)},window.applyOverrides=function(t){$.extend(!0,window.__defaultsOverrides,t),window.applyDefaultsOverrides(TradingView.defaultProperties.chartproperties),window.applyDefaultOverridesToLinetools(),window.chartWidgetCollection.applyOverrides(t)},window.changeTheme=function(t){var e=p.themes[t.toLowerCase()];e&&window.tradingViewApi.themes().setStdTheme(e.name).then(function(){window.applyOverrides(window.__defaultsOverrides)})},window.is_authenticated=!1,window.parent[urlParams.uid].brokerFactory,window.t("charts by TradingView"),window.t("powered by TradingView"),j=function(e){var o,n,r,s,a,p,_,f,S,A,M,E,z,W;if(!Modernizr.canvas||!Modernizr.canvastext)throw Error("Charting library cannot be running under this browser");t.setEnabled("charting_library_debug_mode","true"===urlParams.debug),t.setEnabled("chart_property_page_trading",!1),t.setEnabled("chart_property_page_template_button",!1),o=window.headerChartPanel=$(".header-chart-panel"),n=$("#library-container"), -t.enabled("remove_library_container_border")&&(n.css("border","0px"),n.css("padding","1px")),window.customizeUI({studiesOverrides:urlParams.studiesOverrides?JSON.parse(urlParams.studiesOverrides):void 0,defaultsOverrides:JSON.parse(urlParams.overrides)}),urlParams.numeric_formatting=urlParams.numeric_formatting&&JSON.parse(urlParams.numeric_formatting),urlParams.numeric_formatting&&"string"==typeof urlParams.numeric_formatting.decimal_sign&&(w.decimalSign=urlParams.numeric_formatting.decimal_sign[0]),window.ChartApiInstance=new B(window.parent[urlParams.uid].datafeed),window.parent[urlParams.uid].customFormatters&&(window.parent[urlParams.uid].customFormatters.timeFormatter&&(T.timeFormatter=window.parent[urlParams.uid].customFormatters.timeFormatter),window.parent[urlParams.uid].customFormatters.dateFormatter&&(T.dateFormatter=window.parent[urlParams.uid].customFormatters.dateFormatter)),ChartApiInstance.setTimeFramesList(JSON.parse(urlParams.timeFrames)),ChartApiInstance.setStudiesAccessController(ChartApiInstance.createStudiesAccessController(urlParams.studiesAccess)),r=urlParams.chartContent?JSON.parse(urlParams.chartContent).json:void 0,s=urlParams.interval||"D",a={resizerBridge:D.allocate({areaName:"center"}),padding:t.enabled("border_around_the_chart")?5:0,edge:t.enabled("border_around_the_chart")?6:0,content:r,widgetOptions:{hideIdeas:!0,addVolume:!0,handleSessionErrors:!0,muteSessionErrors:!0,timezone:urlParams.timezone,defSymbol:urlParams.symbol,defInterval:s,defTimeframe:urlParams.timeframe&&urlParams.timeframe.toLowerCase()},globalEvents:!0,snapshotUrl:urlParams.snapshotUrl},p=t.enabled("left_toolbar"),p&&(_=new O({left:window.innerWidth/2,top:window.headerChartPanel.outerHeight()+61}),a.widgetOptions.favoriteDrawingToolbar=_,a.widgetOptions.isDrawingToolbarVisible=d),r&&void 0!==r.extendedData&&(f=r.extendedData,a.metaInfo={id:f.uid,name:f.name,description:f.description,uid:f.uid,username:"",tags:""}),S=window.chartWidgetCollection=new V(a),window.studyMarket=new x(S,window.user),"undefined"!=typeof serviceLocator&&serviceLocator.registerService(CHART_WIDGET_COLLECTION_SERVICE,S),S.activeChartWidget.subscribe(function(t){b.emit("activeChartChanged",S.getAll().indexOf(t))}),window.saver=new m(S),window.chartWidget=S.activeChartWidget.value(),window.pro=new TradingView.Pro,A=JSON.parse(urlParams.favorites),A.intervals=A.intervals.map(function(t){var e=""+t;return e.match(/1[DWMYdwmy]/)&&(e=e.slice(1)),e}),t.enabled("study_templates")&&(M=new v(L,TVSettings),window.studyTemplates=new g({chartWidgetCollection:S,favoriteStudyTemplatesService:M})),t.enabled("header_widget")&&(E=D.allocate({areaName:"top"}),window.headerWidget=c.render(l.createElement(h,{tools:i(1023).getRestrictedToolSet(),chartSaver:window.saver,chartApiInstance:ChartApiInstance,chartWidgetCollection:S,defaultIntervals:Object.keys(ChartApiInstance.defaultResolutions()),defaultFavoriteStyles:A.chartTypes,defaultFavoriteIntervals:A.intervals,headerChartPanel:o,hideStudyTemplates:!0,resizerBridge:E,studyMarket:window.studyMarket, -studyTemplates:window.studyTemplates,favoriteStudyTemplatesService:M,allowedModes:t.enabled("caption_buttons_text_if_possible")?void 0:["medium"]}),E.body.value()[0])),window.tradingViewApi=new F(S,window.saver,ChartApiInstance,t.enabled("header_saveload")?new P(null,S):null),y.bindToChartWidgetCollection(S),z=urlParams.toolbarbg&&/^[0-9a-f]+$/i.test(urlParams.toolbarbg)?urlParams.toolbarbg+"":void 0,z&&$("",l.id=m,(c?l:f).innerHTML+=i,f.appendChild(l),c||(f.style.background="",f.style.overflow="hidden",u=g.style.overflow,g.style.overflow="hidden",g.appendChild(f)),a=n(l,e),c?l.parentNode.removeChild(l):(f.parentNode.removeChild(f),g.style.overflow=u),!!a},S=function(){function e(e,i){i=i||t.createElement(r[e]||"div"),e="on"+e;var a=e in i;return a||(i.setAttribute||(i=t.createElement("div")),i.setAttribute&&i.removeAttribute&&(i.setAttribute(e,""),a=o(i[e],"function"),o(i[e],"undefined")||(i[e]=n),i.removeAttribute(e))),i=null,a}var r={select:"input",change:"input",submit:"form",reset:"form",error:"img",load:"img",abort:"img"};return e}(),O={}.hasOwnProperty;c=o(O,"undefined")||o(O.call,"undefined")?function(e,t){return t in e&&o(e.constructor.prototype[t],"undefined")}:function(e,t){return O.call(e,t)},Function.prototype.bind||(Function.prototype.bind=function(e){var t,n,r=this;if("function"!=typeof r)throw new TypeError;return t=E.call(arguments,1),n=function(){var o,i,a;return this instanceof n?(o=function(){},o.prototype=r.prototype,i=new o,a=r.apply(i,t.concat(E.call(arguments))),Object(a)===a?a:i):r.apply(e,t.concat(E.call(arguments)))}}),k.flexbox=function(){return u("flexWrap")},k.canvas=function(){var e=t.createElement("canvas");return!!e.getContext&&!!e.getContext("2d")}, +k.canvastext=function(){return!!d.canvas&&!!o(t.createElement("canvas").getContext("2d").fillText,"function")},k.touch=function(){var n;return"ontouchstart"in e||e.DocumentTouch&&t instanceof DocumentTouch?n=!0:C("@media ("+b.join("touch-enabled),(")+m+"){#modernizr{top:9px;position:absolute}}",function(e){n=9===e.offsetTop}),n},k.history=function(){return!!e.history&&!!history.pushState},k.draganddrop=function(){var e=t.createElement("div");return"draggable"in e||"ondragstart"in e&&"ondrop"in e},k.websockets=function(){return"WebSocket"in e||"MozWebSocket"in e},k.multiplebgs=function(){return r("background:url(https://),url(https://),red url(https://)"),/(url\s*\(.*?){3}/.test(v.background)},k.csscolumns=function(){return u("columnCount")},k.csstransitions=function(){return u("transition")},k.localstorage=function(){try{return localStorage.setItem(m,m),localStorage.removeItem(m),!0}catch(e){return!1}};for(f in k)c(k,f)&&(l=f.toLowerCase(),d[l]=k[f](),T.push((d[l]?"":"no-")+l));return d.addTest=function(e,t){if("object"==typeof e)for(var r in e)c(e,r)&&d.addTest(r,e[r]);else{if(e=e.toLowerCase(),d[e]!==n)return d;t="function"==typeof t?t():t,void 0!==h&&h&&(g.className+=" feature-"+(t?"":"no-")+e),d[e]=t}return d},r(""),y=null,d._version=p,d._prefixes=b,d._domPrefixes=_,d._cssomPrefixes=x,d.hasEvent=S,d.testProp=function(e){return a([e])},d.testAllProps=u,d.testStyles=C,g.className=g.className.replace(/(^|\s)no-js(\s|$)/,"$1$2")+(h?" feature-js feature-"+T.join(" feature-"):""),d}(window,document);!r.touch||"onorientationchange"in window||(r.touch=!1,document.documentElement.className=document.documentElement.className.replace("feature-touch","feature-no-touch")),r.addTest("pointerevents",function(){var e,t=document.createElement("x"),n=document.documentElement,r=window.getComputedStyle,o=!1;return"pointerEvents"in t.style&&(t.style.pointerEvents="auto",t.style.pointerEvents="x",n.appendChild(t),r&&(e=r(t,""),o=!!e&&"auto"===e.pointerEvents),n.removeChild(t),!!o)}),r.addTest("flexbox",r.testAllProps("flexBasis","1px",!0))},,,,,,,,,,,function(e,t,n){var r=n(36),o=n(22).document,i=r(o)&&r(o.createElement);e.exports=function(e){return i?o.createElement(e):{}}},function(e,t,n){var r=n(36);e.exports=function(e,t){if(!r(e))return e;var n,o;if(t&&"function"==typeof(n=e.toString)&&!r(o=n.call(e)))return o;if("function"==typeof(n=e.valueOf)&&!r(o=n.call(e)))return o;if(!t&&"function"==typeof(n=e.toString)&&!r(o=n.call(e)))return o;throw TypeError("Can't convert object to primitive value")}},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},function(e,t,n){var r=n(91)("meta"),o=n(36),i=n(52),a=n(47).f,s=0,u=Object.isExtensible||function(){return!0},l=!n(64)(function(){return u(Object.preventExtensions({}))}),c=function(e){a(e,r,{value:{i:"O"+ ++s,w:{}}})},f=function(e,t){if(!o(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!i(e,r)){if(!u(e))return"F";if(!t)return"E";c(e)}return e[r].i},p=function(e,t){if(!i(e,r)){if(!u(e))return!0;if(!t)return!1 +;c(e)}return e[r].w},d=function(e){return l&&h.NEED&&u(e)&&!i(e,r)&&c(e),e},h=e.exports={KEY:r,NEED:!1,fastKey:f,getWeak:p,onFreeze:d}},function(e,t,n){var r=n(22),o="__core-js_shared__",i=r[o]||(r[o]={});e.exports=function(e){return i[e]||(i[e]={})}},function(e,t,n){var r=n(77);e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==r(e)?e.split(""):Object(e)}},function(e,t,n){var r=n(112),o=Math.max,i=Math.min;e.exports=function(e,t){return e=r(e),e<0?o(e+t,0):i(e,t)}},function(e,t,n){var r=n(142)("keys"),o=n(91);e.exports=function(e){return r[e]||(r[e]=o(e))}},function(e,t){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t,n){var r=n(54),o=n(367),i=n(146),a=n(145)("IE_PROTO"),s=function(){},u="prototype",l=function(){var e,t=n(138)("iframe"),r=i.length,o="<",a=">";for(t.style.display="none",n(220).appendChild(t),t.src="javascript:",e=t.contentWindow.document,e.open(),e.write(o+"script"+a+"document.F=Object"+o+"/script"+a),e.close(),l=e.F;r--;)delete l[u][i[r]];return l()};e.exports=Object.create||function(e,t){var n;return null!==e?(s[u]=r(e),n=new s,s[u]=null,n[a]=e):n=l(),void 0===t?n:o(n,t)}},function(e,t){e.exports="\t\n\v\f\r   ᠎              \u2028\u2029\ufeff"},function(e,t,n){var r=n(389),o=n(65);e.exports=function(e,t,n){if(r(t))throw TypeError("String#"+n+" doesn't accept regex!");return o(e)+""}},function(e,t,n){var r=n(23)("match");e.exports=function(e){var t=/./;try{"/./"[e](t)}catch(n){try{return t[r]=!1,!"/./"[e](t)}catch(e){}}return!0}},function(e,t,n){var r,o=n(23)("iterator"),i=!1;try{r=[7][o](),r.return=function(){i=!0},Array.from(r,function(){throw 2})}catch(e){}e.exports=function(e,t){var n,r,a;if(!t&&!i)return!1;n=!1;try{r=[7],a=r[o](),a.next=function(){return{done:n=!0}},r[o]=function(){return a},e(r)}catch(e){}return n}},function(e,t){e.exports=function(e,t,n,r){if(!(e instanceof t)||void 0!==r&&r in e)throw TypeError(n+": incorrect invocation!");return e}},function(e,t,n){var r=n(55),o=n(225),i=n(226),a=n(54),s=n(66),u=n(227),l={},c={};t=e.exports=function(e,t,n,f,p){var d,h,g,m,y=p?function(){return e}:u(e),v=r(n,f,t?2:1),b=0;if("function"!=typeof y)throw TypeError(e+" is not iterable!");if(i(y)){for(d=s(e.length);d>b;b++)if((m=t?v(a(h=e[b])[0],h[1]):v(e[b]))===l||m===c)return m}else for(g=y.call(e);!(h=g.next()).done;)if((m=o(g,v,h.value,t))===l||m===c)return m},t.BREAK=l,t.RETURN=c},function(e,t,n){var r=n(75);e.exports=function(e,t,n){for(var o in t)r(e,o,t[o],n);return e}},function(e,t,n){"use strict";function r(e,t,n,r,i,a,s,u){var l,c,f;if(o(t),!e)throw void 0===t?l=Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings."):(c=[n,r,i,a,s,u],f=0,l=Error(t.replace(/%s/g,function(){return c[f++]})),l.name="Invariant Violation"),l.framesToPop=1,l}var o=function(e){};e.exports=r},function(e,t,n){"use strict";function r(e){return function(){return e}} +var o=function(){};o.thatReturns=r,o.thatReturnsFalse=r(!1),o.thatReturnsTrue=r(!0),o.thatReturnsNull=r(null),o.thatReturnsThis=function(){return this},o.thatReturnsArgument=function(e){return e},e.exports=o},function(e,t){function n(e){return e&&e.__esModule?e:{default:e}}e.exports=n},,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,n){var r,o;(function(){function n(e){function t(t,n,r,o,i,a){for(;i>=0&&i0?0:s-1;return arguments.length<3&&(o=n[a?a[l]:l],l+=e),t(n,r,o,a,l,s)}}function i(e){return function(t,n,r){var o,i;for(n=l(n,r),o=h(t),i=e>0?0:o-1;i>=0&&i0?a=i>=0?i:Math.max(i+s,a):s=i>=0?Math.min(i+1,s):i+s+1;else if(n&&i&&s)return i=n(r,o),r[i]===o?i:-1;if(o!==o)return i=t(F.call(r,a,s),$.isNaN),i>=0?i+a:-1;for(i=e>0?a:s-1;i>=0&&i=0&&t<=d},$.each=$.forEach=function(e,t,n){var r,o,i;if(t=u(t,n),g(e))for(r=0,o=e.length;r=0},$.invoke=function(e,t){var n=F.call(arguments,2),r=$.isFunction(t);return $.map(e,function(e){var o=r?t:e[t];return null==o?o:o.apply(e,n)})},$.pluck=function(e,t){return $.map(e,$.property(t))},$.where=function(e,t){return $.filter(e,$.matcher(t))},$.findWhere=function(e,t){return $.find(e,$.matcher(t))},$.max=function(e,t,n){var r,o,i,a,s=-1/0,u=-1/0;if(null==t&&null!=e)for(e=g(e)?e:$.values(e),i=0,a=e.length;is&&(s=r);else t=l(t,n),$.each(e,function(e,n,r){((o=t(e,n,r))>u||o===-1/0&&s===-1/0)&&(s=e,u=o)});return s},$.min=function(e,t,n){var r,o,i,a,s=1/0,u=1/0;if(null==t&&null!=e)for(e=g(e)?e:$.values(e),i=0,a=e.length;ir||void 0===n)return 1;if(nt?(s&&(clearTimeout(s),s=null),u=c,i=e.apply(r,o),s||(r=o=null)):s||!1===n.trailing||(s=setTimeout(a,l)),i}},$.debounce=function(e,t,n){var r,o,i,a,s,u=function(){var l=$.now()-a;l=0?r=setTimeout(u,t-l):(r=null,n||(s=e.apply(i,o),r||(i=o=null)))};return function(){i=this,o=arguments,a=$.now();var l=n&&!r;return r||(r=setTimeout(u,t)),l&&(s=e.apply(i,o),i=o=null),s}}, +$.wrap=function(e,t){return $.partial(t,e)},$.negate=function(e){return function(){return!e.apply(this,arguments)}},$.compose=function(){var e=arguments,t=e.length-1;return function(){for(var n=t,r=e[t].apply(this,arguments);n--;)r=e[n].call(this,r);return r}},$.after=function(e,t){return function(){if(--e<1)return t.apply(this,arguments)}},$.before=function(e,t){var n;return function(){return--e>0&&(n=t.apply(this,arguments)),e<=1&&(t=null),n}},$.once=$.partial($.before,2),b=!{toString:null}.propertyIsEnumerable("toString"),w=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],$.keys=function(e){var t,n;if(!$.isObject(e))return[];if(W)return W(e);t=[];for(n in e)$.has(e,n)&&t.push(n);return b&&s(e,t),t},$.allKeys=function(e){var t,n;if(!$.isObject(e))return[];t=[];for(n in e)t.push(n);return b&&s(e,t),t},$.values=function(e){var t,n=$.keys(e),r=n.length,o=Array(r);for(t=0;t":">",'"':""","'":"'","`":"`"},k=$.invert(_),T=function(e){var t=function(t){return e[t]},n="(?:"+$.keys(e).join("|")+")",r=RegExp(n),o=RegExp(n,"g");return function(e){return e=null==e?"":""+e,r.test(e)?e.replace(o,t):e}},$.escape=T(_),$.unescape=T(k),$.result=function(e,t,n){var r=null==e?void 0:e[t];return void 0===r&&(r=n),$.isFunction(r)?r.call(e):r},E=0,$.uniqueId=function(e){var t=++E+"";return e?e+t:t},$.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g},C=/(.)^/,S={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},O=/\\|'|\r|\n|\u2028|\u2029/g,N=function(e){return"\\"+S[e]},$.template=function(e,t,n){var r,o,i,a,s,u;!t&&n&&(t=n),t=$.defaults({},t,$.templateSettings),r=RegExp([(t.escape||C).source,(t.interpolate||C).source,(t.evaluate||C).source].join("|")+"|$","g"),o=0,i="__p+='",e.replace(r,function(t,n,r,a,s){return i+=e.slice(o,s).replace(O,N),o=s+t.length,n?i+="'+\n((__t=("+n+"))==null?'':_.escape(__t))+\n'":r?i+="'+\n((__t=("+r+"))==null?'':__t)+\n'":a&&(i+="';\n"+a+"\n__p+='"),t}),i+="';\n",t.variable||(i="with(obj||{}){\n"+i+"}\n"), +i="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+i+"return __p;\n";try{a=Function(t.variable||"obj","_",i)}catch(e){throw e.source=i,e}return s=function(e){return a.call(this,e,$)},u=t.variable||"obj",s.source="function("+u+"){\n"+i+"}",s},$.chain=function(e){var t=$(e);return t._chain=!0,t},P=function(e,t){return e._chain?$(t).chain():t},$.mixin=function(e){$.each($.functions(e),function(t){var n=$[t]=e[t];$.prototype[t]=function(){var e=[this._wrapped];return R.apply(e,arguments),P(this,n.apply($,e))}})},$.mixin($),$.each(["pop","push","reverse","shift","sort","splice","unshift"],function(e){var t=M[e];$.prototype[e]=function(){var n=this._wrapped;return t.apply(n,arguments),"shift"!==e&&"splice"!==e||0!==n.length||delete n[0],P(this,n)}}),$.each(["concat","join","slice"],function(e){var t=M[e];$.prototype[e]=function(){return P(this,t.apply(this._wrapped,arguments))}}),$.prototype.value=function(){return this._wrapped},$.prototype.valueOf=$.prototype.toJSON=$.prototype.value,$.prototype.toString=function(){return""+this._wrapped},r=[],void 0!==(o=function(){return $}.apply(t,r))&&(e.exports=o)}).call(this)},,,,function(e,t,n){var r,o,i;!function(a){o=[n(14),n(80)],r=a,void 0!==(i="function"==typeof r?r.apply(t,o):r)&&(e.exports=i)}(function(e){var t=0,n=Array.prototype.slice;return e.cleanData=function(t){return function(n){var r,o,i;for(i=0;null!=(o=n[i]);i++)try{r=e._data(o,"events"),r&&r.remove&&e(o).triggerHandler("remove")}catch(e){}t(n)}}(e.cleanData),e.widget=function(t,n,r){var o,i,a,s,u={},l=t.split(".")[0];return t=t.split(".")[1],s=l+"-"+t,r||(r=n,n=e.Widget),e.isArray(r)&&(r=e.extend.apply(null,[{}].concat(r))),e.expr[":"][s.toLowerCase()]=function(t){return!!e.data(t,s)},e[l]=e[l]||{},o=e[l][t],i=e[l][t]=function(e,t){if(!this._createWidget)return new i(e,t);arguments.length&&this._createWidget(e,t)},e.extend(i,o,{version:r.version,_proto:e.extend({},r),_childConstructors:[]}),a=new n,a.options=e.widget.extend({},a.options),e.each(r,function(t,r){if(!e.isFunction(r))return void(u[t]=r);u[t]=function(){function e(){return n.prototype[t].apply(this,arguments)}function o(e){return n.prototype[t].apply(this,e)}return function(){var t,n=this._super,i=this._superApply;return this._super=e,this._superApply=o,t=r.apply(this,arguments),this._super=n,this._superApply=i,t}}()}),i.prototype=e.widget.extend(a,{widgetEventPrefix:o?a.widgetEventPrefix||t:t},u,{constructor:i,namespace:l,widgetName:t,widgetFullName:s}),o?(e.each(o._childConstructors,function(t,n){var r=n.prototype;e.widget(r.namespace+"."+r.widgetName,i,n._proto)}),delete o._childConstructors):n._childConstructors.push(i),e.widget.bridge(t,i),i},e.widget.extend=function(t){for(var r,o,i=n.call(arguments,1),a=0,s=i.length;a",options:{classes:{},disabled:!1,create:null},_createWidget:function(n,r){r=e(r||this.defaultElement||this)[0],this.element=e(r),this.uuid=t++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=e(),this.hoverable=e(),this.focusable=e(),this.classesElementLookup={},r!==this&&(e.data(r,this.widgetFullName,this),this._on(!0,this.element,{remove:function(e){e.target===r&&this.destroy()}}),this.document=e(r.style?r.ownerDocument:r.document||r),this.window=e(this.document[0].defaultView||this.document[0].parentWindow)),this.options=e.widget.extend({},this.options,this._getCreateOptions(),n),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:e.noop,_create:e.noop,_init:e.noop,destroy:function(){var t=this;this._destroy(),e.each(this.classesElementLookup,function(e,n){t._removeClass(n,e)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:e.noop,widget:function(){return this.element},option:function(t,n){var r,o,i,a=t;if(0===arguments.length)return e.widget.extend({},this.options);if("string"==typeof t)if(a={},r=t.split("."),t=r.shift(),r.length){for(o=a[t]=e.widget.extend({},this.options[t]),i=0;iu;)r(s,n=t[u++])&&(~i(l,n)||l.push(n));return l}},function(e,t,n){var r=n(56),o=n(66),i=n(144);e.exports=function(e){return function(t,n,a){var s,u=r(t),l=o(u.length),c=i(a,l);if(e&&n!=n){for(;l>c;)if((s=u[c++])!=s)return!0}else for(;l>c;c++)if((e||c in u)&&u[c]===n)return e||c||0;return!e&&-1}}},function(e,t,n){var r=n(77);e.exports=Array.isArray||function(e){return"Array"==r(e)}},function(e,t,n){e.exports=n(22).document&&document.documentElement},function(e,t,n){var r=n(217),o=n(146).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return r(e,o)}},function(e,t,n){var r=n(93),o=n(90),i=n(56),a=n(139),s=n(52),u=n(215),l=Object.getOwnPropertyDescriptor;t.f=n(53)?l:function(e,t){if(e=i(e),t=a(t,!0),u)try{return l(e,t)}catch(e){}if(s(e,t))return o(!r.f.call(e,t),e[t])}},function(e,t,n){var r=n(36),o=Math.floor;e.exports=function(e){return!r(e)&&isFinite(e)&&o(e)===e}},function(e,t,n){var r=n(10),o=n(65),i=n(64),a=n(149),s="["+a+"]",u="​…",l=RegExp("^"+s+s+"*"),c=RegExp(s+s+"*$"),f=function(e,t,n){var o={},s=i(function(){return!!a[e]()||u[e]()!=u}),l=o[e]=s?t(p):a[e];n&&(o[n]=l),r(r.P+r.F*s,"String",o)},p=f.trim=function(e,t){return e=o(e)+"",1&t&&(e=e.replace(l,"")),2&t&&(e=e.replace(c,"")),e};e.exports=f},function(e,t,n){var r=n(54);e.exports=function(e,t,n,o){try{return o?t(r(n)[0],n[1]):t(n)}catch(t){var i=e.return;throw void 0!==i&&r(i.call(e)),t}}},function(e,t,n){var r=n(113),o=n(23)("iterator"),i=Array.prototype;e.exports=function(e){return void 0!==e&&(r.Array===e||i[o]===e)}},function(e,t,n){var r=n(228),o=n(23)("iterator"),i=n(113);e.exports=n(89).getIteratorMethod=function(e){if(void 0!=e)return e[o]||e["@@iterator"]||i[r(e)]}},function(e,t,n){var r=n(77),o=n(23)("toStringTag"),i="Arguments"==r(function(){return arguments}()),a=function(e,t){try{return e[t]}catch(e){}};e.exports=function(e){var t,n,s;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=a(t=Object(e),o))?n:i?r(t):"Object"==(s=r(t))&&"function"==typeof t.callee?"Arguments":s}},function(e,t,n){var r=n(55),o=n(143),i=n(94),a=n(66),s=n(400);e.exports=function(e,t){var n=1==e,u=2==e,l=3==e,c=4==e,f=6==e,p=5==e||f,d=t||s;return function(t,s,h){for(var g,m,y=i(t),v=o(y),b=r(s,h,3),w=a(v.length),x=0,_=n?d(t,w):u?d(t,0):void 0;w>x;x++)if((p||x in v)&&(g=v[x],m=b(g,x,y), +e))if(n)_[x]=m;else if(m)switch(e){case 3:return!0;case 5:return g;case 6:return x;case 2:_.push(g)}else if(c)return!1;return f?-1:l||c?c:_}}},function(e,t){e.exports=function(e,t){return{value:t,done:!!e}}},function(e,t,n){"use strict";var r=n(111),o=n(10),i=n(75),a=n(74),s=n(52),u=n(113),l=n(404),c=n(92),f=n(405),p=n(23)("iterator"),d=!([].keys&&"next"in[].keys()),h="keys",g="values",m=function(){return this};e.exports=function(e,t,n,y,v,b,w){var x,_,k,T,E,C,S,O,N,P,j,A;if(l(n,t,y),x=function(e){if(!d&&e in E)return E[e];switch(e){case h:case g:return function(){return new n(this,e)}}return function(){return new n(this,e)}},_=t+" Iterator",k=v==g,T=!1,E=e.prototype,C=E[p]||E["@@iterator"]||v&&E[v],S=C||x(v),O=v?k?x("entries"):S:void 0,N="Array"==t?E.entries||C:C,N&&(A=f(N.call(new e)))!==Object.prototype&&(c(A,_,!0),r||s(A,p)||a(A,p,m)),k&&C&&C.name!==g&&(T=!0,S=function(){return C.call(this)}),r&&!w||!d&&!T&&E[p]||a(E,p,S),u[t]=S,u[_]=m,v)if(P={values:k?S:x(g),keys:b?S:x(h),entries:O},w)for(j in P)j in E||i(E,j,P[j]);else o(o.P+o.F*(d||T),t,P);return P}},function(e,t,n){var r,o,i,a=n(55),s=n(408),u=n(220),l=n(138),c=n(22),f=c.process,p=c.setImmediate,d=c.clearImmediate,h=c.MessageChannel,g=0,m={},y="onreadystatechange",v=function(){var e,t=+this;m.hasOwnProperty(t)&&(e=m[t],delete m[t],e())},b=function(e){v.call(e.data)};p&&d||(p=function(e){for(var t=[],n=1;arguments.length>n;)t.push(arguments[n++]);return m[++g]=function(){s("function"==typeof e?e:Function(e),t)},r(g),g},d=function(e){delete m[e]},"process"==n(77)(f)?r=function(e){f.nextTick(a(v,e,1))}:h?(o=new h,i=o.port2,o.port1.onmessage=b,r=a(i.postMessage,i,1)):c.addEventListener&&"function"==typeof postMessage&&!c.importScripts?(r=function(e){c.postMessage(e+"","*")},c.addEventListener("message",b,!1)):r=y in l("script")?function(e){u.appendChild(l("script"))[y]=function(){u.removeChild(this),v.call(e)}}:function(e){setTimeout(a(v,e,1),0)}),e.exports={set:p,clear:d}},function(e,t,n){"use strict";var r=n(22),o=n(47),i=n(53),a=n(23)("species");e.exports=function(e){var t=r[e];i&&t&&!t[a]&&o.f(t,a,{configurable:!0,get:function(){return this}})}},function(e,t,n){"use strict";var r=n(47).f,o=n(148),i=n(155),a=n(55),s=n(153),u=n(65),l=n(154),c=n(231),f=n(230),p=n(233),d=n(53),h=n(141).fastKey,g=d?"_s":"size",m=function(e,t){var n,r=h(t);if("F"!==r)return e._i[r];for(n=e._f;n;n=n.n)if(n.k==t)return n};e.exports={getConstructor:function(e,t,n,c){var f=e(function(e,r){s(e,f,t,"_i"),e._i=o(null),e._f=void 0,e._l=void 0,e[g]=0,void 0!=r&&l(r,n,e[c],e)});return i(f.prototype,{clear:function(){for(var e=this,t=e._i,n=e._f;n;n=n.n)n.r=!0,n.p&&(n.p=n.p.n=void 0),delete t[n.i];e._f=e._l=void 0,e[g]=0},delete:function(e){var t,n,r=this,o=m(r,e);return o&&(t=o.n,n=o.p,delete r._i[o.i],o.r=!0,n&&(n.n=t),t&&(t.p=n),r._f==o&&(r._f=t),r._l==o&&(r._l=n),r[g]--),!!o},forEach:function(e){s(this,f,"forEach");for(var t,n=a(e,arguments.length>1?arguments[1]:void 0,3);t=t?t.n:this._f;)for(n(t.v,t.k,this);t&&t.r;)t=t.p},has:function(e){return!!m(this,e)}}),d&&r(f.prototype,"size",{ +get:function(){return u(this[g])}}),f},def:function(e,t,n){var r,o,i=m(e,t);return i?i.v=n:(e._l=i={i:o=h(t,!0),k:t,v:n,p:r=e._l,n:void 0,r:!1},e._f||(e._f=i),r&&(r.n=i),e[g]++,"F"!==o&&(e._i[o]=i)),e},getEntry:m,setStrong:function(e,t,n){c(e,t,function(e,t){this._t=e,this._k=t,this._l=void 0},function(){for(var e=this,t=e._k,n=e._l;n&&n.r;)n=n.p;return e._t&&(e._l=n=n?n.n:e._t._f)?"keys"==t?f(0,n.k):"values"==t?f(0,n.v):f(0,[n.k,n.v]):(e._t=void 0,f(1))},n?"entries":"values",!n,!0),p(t)}}},function(e,t,n){"use strict";var r=n(22),o=n(10),i=n(75),a=n(155),s=n(141),u=n(154),l=n(153),c=n(36),f=n(64),p=n(152),d=n(92),h=n(411);e.exports=function(e,t,n,g,m,y){var v,b,w,x,_,k=r[e],T=k,E=m?"set":"add",C=T&&T.prototype,S={},O=function(e){var t=C[e];i(C,e,"delete"==e?function(e){return!(y&&!c(e))&&t.call(this,0===e?0:e)}:"has"==e?function(e){return!(y&&!c(e))&&t.call(this,0===e?0:e)}:"get"==e?function(e){return y&&!c(e)?void 0:t.call(this,0===e?0:e)}:"add"==e?function(e){return t.call(this,0===e?0:e),this}:function(e,n){return t.call(this,0===e?0:e,n),this})};return"function"==typeof T&&(y||C.forEach&&!f(function(){(new T).entries().next()}))?(v=new T,b=v[E](y?{}:-0,1)!=v,w=f(function(){v.has(1)}),x=p(function(e){new T(e)}),_=!y&&f(function(){for(var e=new T,t=5;t--;)e[E](t,t);return!e.has(-0)}),x||(T=t(function(t,n){l(t,T,e);var r=h(new k,t,T);return void 0!=n&&u(n,m,r[E],r),r}),T.prototype=C,C.constructor=T),(w||_)&&(O("delete"),O("has"),m&&O("get")),(_||b)&&O(E),y&&C.clear&&delete C.clear):(T=g.getConstructor(t,e,m,E),a(T.prototype,n),s.NEED=!0),d(T,e),S[e]=T,o(o.G+o.W+o.F*(T!=k),S),y||g.setStrong(T,e,m),T}},function(e,t,n){var r=n(76),o=n(56),i=n(93).f;e.exports=function(e){return function(t){for(var n,a=o(t),s=r(a),u=s.length,l=0,c=[];u>l;)i.call(a,n=s[l++])&&c.push(e?[n,a[n]]:a[n]);return c}}},function(e,t,n){e.exports=n(417).default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default={processors:{},addPostProcessor:function(e){this.processors[e.name]=e},handle:function(e,t,n,r,o){var i=this;return e.forEach(function(e){i.processors[e]&&(t=i.processors[e].process(t,n,r,o))}),t}}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e){return e.interpolation={unescapeSuffix:"HTML"},e.interpolation.prefix=e.interpolationPrefix||"__",e.interpolation.suffix=e.interpolationSuffix||"__",e.interpolation.escapeValue=e.escapeInterpolation||!1,e.interpolation.nestingPrefix=e.reusePrefix||"$t(",e.interpolation.nestingSuffix=e.reuseSuffix||")",e}function i(e){return e.resStore&&(e.resources=e.resStore),e.ns&&e.ns.defaultNs?(e.defaultNS=e.ns.defaultNs,e.ns=e.ns.namespaces):e.defaultNS=e.ns||"translation",e.fallbackToDefaultNS&&e.defaultNS&&(e.fallbackNS=e.defaultNS),e.saveMissing=e.sendMissing,e.saveMissingTo=e.sendMissingTo||"current",e.returnNull=!e.fallbackOnNull,e.returnEmptyString=!e.fallbackOnEmpty,e.returnObjects=e.returnObjectTrees,e.joinArrays="\n",e.returnedObjectHandler=e.objectTreeKeyHandler,e.parseMissingKeyHandler=e.parseMissingKey, +e.appendNamespaceToMissingKey=!0,e.nsSeparator=e.nsseparator,e.keySeparator=e.keyseparator,"sprintf"===e.shortcutFunction&&(e.overloadTranslationOptionHandler=function(e){var t,n=[];for(t=1;t1&&void 0!==arguments[1]?arguments[1]:{},r=n.bubbles,o=void 0!==r&&r,i=n.cancelable,a=void 0!==i&&i,s=n.detail,u=void 0===s?null:s;try{return new window.CustomEvent(e,{bubbles:o,cancelable:a,detail:u})}catch(n){return t=document.createEvent("CustomEvent"),t.initCustomEvent(e,o,a,u),t}}},function(e,t,n){"use strict";function r(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function o(){var e,t,n,r,o;try{if(!Object.assign)return!1;if(e=new String("abc"),e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;return r=Object.getOwnPropertyNames(t).map(function(e){return t[e]}),"0123456789"!==r.join("")?!1:(o={},"abcdefghijklmnopqrst".split("").forEach(function(e){o[e]=e}), +"abcdefghijklmnopqrst"===Object.keys(Object.assign({},o)).join(""))}catch(e){return!1}}var i=Object.getOwnPropertySymbols,a=Object.prototype.hasOwnProperty,s=Object.prototype.propertyIsEnumerable;e.exports=o()?Object.assign:function(e,t){var n,o,u,l,c,f=r(e);for(u=1;u=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}})})},,,function(e,t,n){!function(t,r){ +e.exports=r(n(20),n(59),n(449))}(0,function(e,t,n){return function(e){function t(r){if(n[r])return n[r].exports;var o=n[r]={exports:{},id:r,loaded:!1};return e[r].call(o.exports,o,o.exports,t),o.loaded=!0,o.exports}var n={};return t.m=e,t.c=n,t.p="dist/",t(0)}([function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=n(1),i=r(o);t.default=i.default,e.exports=t.default},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var s=function(){function e(e,t){var n,r;for(n=0;n0&&void 0!==arguments[0]?arguments[0]:n.props.includeMargin;n.props.shouldMeasure&&(n._node.parentNode||n._setDOMNode(),e=n.getDimensions(n._node,r),t="function"==typeof n.props.children,n._propsToMeasure.some(function(r){if(e[r]!==n._lastDimensions[r])return n.props.onMeasure(e),t&&void 0!==n&&n.setState({dimensions:e}),n._lastDimensions=e,!0}))},n.state={dimensions:{width:0,height:0,top:0,right:0,bottom:0,left:0}},n._node=null,n._propsToMeasure=n._getPropsToMeasure(e),n._lastDimensions={},n}return a(t,e),s(t,[{key:"componentDidMount",value:function(){var e=this;this._setDOMNode(),this.measure(),this.resizeObserver=new h.default(function(){return e.measure()}),this.resizeObserver.observe(this._node)}},{key:"componentWillReceiveProps",value:function(e){var t=(e.config,e.whitelist),n=e.blacklist;this.props.whitelist===t&&this.props.blacklist===n||(this._propsToMeasure=this._getPropsToMeasure({whitelist:t,blacklist:n}))}},{key:"componentWillUnmount",value:function(){this.resizeObserver.disconnect(this._node),this._node=null}},{key:"_setDOMNode",value:function(){this._node=p.default.findDOMNode(this)}},{key:"getDimensions",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this._node,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.props.includeMargin;return(0,m.default)(e,{margin:t})}},{key:"_getPropsToMeasure",value:function(e){var t=e.whitelist,n=e.blacklist +;return t.filter(function(e){return n.indexOf(e)<0})}},{key:"render",value:function(){var e=this.props.children;return u.Children.only("function"==typeof e?e(this.state.dimensions):e)}}]),t}(u.Component);y.propTypes={whitelist:c.default.array,blacklist:c.default.array,includeMargin:c.default.bool,useClone:c.default.bool,cloneOptions:c.default.object,shouldMeasure:c.default.bool,onMeasure:c.default.func},y.defaultProps={whitelist:["width","height","top","right","bottom","left"],blacklist:[],includeMargin:!0,useClone:!1,cloneOptions:{},shouldMeasure:!0,onMeasure:function(){return null}},t.default=y,e.exports=t.default},function(t,n){t.exports=e},function(e,t,n){(function(t){"use strict";var r,o,i,a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};"production"!==t.env.NODE_ENV?(r="function"==typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,o=function(e){return"object"===(void 0===e?"undefined":a(e))&&null!==e&&e.$$typeof===r},i=!0,e.exports=n(5)(o,i)):e.exports=n(12)()}).call(t,n(4))},function(e,t){"use strict";function n(){throw Error("setTimeout has not been defined")}function r(){throw Error("clearTimeout has not been defined")}function o(e){if(c===setTimeout)return setTimeout(e,0);if((c===n||!c)&&setTimeout)return c=setTimeout,setTimeout(e,0);try{return c(e,0)}catch(t){try{return c.call(null,e,0)}catch(t){return c.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===r||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?d=p.concat(d):g=-1,d.length&&s())}function s(){var e,t;if(!h){for(e=o(a),h=!0,t=d.length;t;){for(p=d,d=[];++g1)for(t=1;t1?t-1:0),r=1;r2?n-2:0),i=2;i1&&void 0!==arguments[1]?arguments[1]:{},n=e.getBoundingClientRect(),r=void 0,o=void 0,i=void 0;return t.margin&&(i=(0,a.default)(getComputedStyle(e))),t.margin?(r=i.left+n.width+i.right,o=i.top+n.height+i.bottom):(r=n.width,o=n.height),{width:r,height:o,top:n.top,right:n.right,bottom:n.bottom,left:n.left}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var i=n(16),a=r(i);e.exports=t.default},function(e,t){"use strict";function n(e){return e=e||{},{top:r(e.marginTop),right:r(e.marginRight),bottom:r(e.marginBottom),left:r(e.marginLeft)}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=n;var r=function(e){return parseInt(e)||0};e.exports=t.default}])})},function(e,t,n){"use strict";!function(e){function t(t){var n=t||window.event,r=[].slice.call(arguments,1),o=0,i=0,a=0;return t=e.event.fix(n),t.type="mousewheel",n.wheelDelta&&(o=n.wheelDelta/120),n.detail&&(o=-n.detail/3),a=o,void 0!==n.axis&&n.axis===n.HORIZONTAL_AXIS&&(a=0,i=-1*o),void 0!==n.wheelDeltaY&&(a=n.wheelDeltaY/120),void 0!==n.wheelDeltaX&&(i=-1*n.wheelDeltaX/120),r.unshift(t,o,i,a),(e.event.dispatch||e.event.handle).apply(this,r)}var n,r=["wheel","mousewheel","DOMMouseScroll","MozMousePixelScroll"],o=["mousewheel","DomMouseScroll","MozMousePixelScroll"];if(e.event.fixHooks)for(n=r.length;n;)e.event.fixHooks[r[--n]]=e.event.mouseHooks;e.event.special.mousewheel={setup:function(){if(this.addEventListener)for(var e=o.length;e;)this.addEventListener(o[--e],t,!1);else this.onmousewheel=t},teardown:function(){if(this.removeEventListener)for(var e=o.length;e;)this.removeEventListener(o[--e],t,!1);else this.onmousewheel=null}},e.fn.extend({mousewheel:function(e){return e?this.bind("mousewheel",e):this.trigger("mousewheel")},unmousewheel:function(e){return this.unbind("mousewheel",e)}})}(jQuery)},,function(e,t,n){"use strict" +;var r=n(24),o=r.rgba,i=r.areEqualRgb,a=r.areEqualRgba,s=r.normalizeHue,u=r.normalizeHsvSaturation,l=r.normalizeValue,c=r.hsv,f=r.rgbToHsv,p=r.hsvToRgb,d=r.rgbToString,h=r.rgbaToString,g=r.parseRgb,m=r.parseRgba,y=n(436),v=n(192).ESC;!function(e){function t(e){return""===e?e:h(m(e))}function n(e){e&&(e.join||(e=e?(""+e).split(","):[]),w=e)}function r(_){function k(t){var n=!1,r=g(t);return e.each(w,function(e,t){if(i(g(t),r))return n=!0,!1}),!n&&(w=[d(r)].concat(w.slice(0,b-1)),!0)}function T(t,n,r){var i=e(this);t=h(o(g(t),n)),E.call(this,t),i.removeData("tvcolorpicker").removeData("tvcolorpicker-custom-color"),r&&(P.call(i),i.blur())}function E(t){var n=e(this);n.val(t),n.change(),t?n.trigger("pick-color",t):n.trigger("pick-transparent"),C.call(this,t)}function C(t){if(""===t)return void e(this).addClass("tvcolorpicker-gradient-widget");e(this).removeClass("tvcolorpicker-gradient-widget"),e(this).css({backgroundColor:t,color:t})}function S(t,n){var r,o,a,s,u,l,c;return n=n||{},r=this,o=r.prop("ownerDocument"),a=e(r).val().toLowerCase(),s=o.createElement("table"),u=o.createElement("tbody"),s.appendChild(u),c=0,e.each(t,function(t,o){var s,f;c++,t%b==0&&(l=e("

").appendTo(u)),s=e('').appendTo(l),f=e('
').appendTo(s).find(".tvcolorpicker-swatch").data("color",o),n.addClass&&f.addClass(n.addClass),o&&(o=o.toLowerCase(),a&&i(g(a),g(o))&&f.addClass("active"),f.css({backgroundColor:o}).data("color",o),f.bind("click",function(){T.call(r,o,A.val(),!0)}))}),e(s).addClass("tvcolorpicker-table"),c?s:e()}function O(t,n,r){var o,i=e(t).prop("ownerDocument"),a=i.defaultView,s=e(t).offset(),u={left:e(i).scrollLeft(),top:e(i).scrollTop()},l={width:e(t).outerWidth(),height:e(t).outerHeight()},c={width:e(a).width(),height:e(a).height()},f={width:e(n).outerWidth(),height:e(n).outerHeight()};switch("function"==typeof r.direction?r.direction():r.direction){default:case"down":o={top:s.top+l.height+r.offset,left:s.left+r.drift};break;case"right":o={top:s.top+r.drift,left:s.left+l.width+r.offset}}o.top+f.height>c.height+u.top&&(o.top=c.height-f.height+u.top),s.left+f.width>c.width&&(o.left=c.width-f.width),o.left+="px",o.top+="px",n.css(o)}function N(t){function n(e){var t=e.originalEvent,n=e.offsetX||e.layerX||t&&(t.offsetX||t.layerX)||0,r=e.offsetY||e.layerY||t&&(t.offsetY||t.layerY)||0;P.css({left:n+"px",top:r+"px"}),z[0]=s(n/H),z[1]=u(1-r/I),L.css({backgroundColor:d(p(c(z[0],z[1],1)))}),_()}function r(t){1==t.which&&(U=!1,K.is(".opened")&&e($).get(0).focus())}function i(t){var n=t.pageY,r=e(F),o=r.offset().top,i=n-o;return i>r.height()?r.height():i<0?0:i}function v(e){var t=i(e);R.css({top:t+"px"}),z[2]=l(1-Math.max(0,Math.min(t,I))/I),_()}function b(t){1==t.which&&(W=!1,e(V).unbind("mouseup",b),K.is(".opened")&&e($).get(0).focus())}function _(){var e,t;B&&(B=!1,K.find(".tvcolorpicker-swatch.active").removeClass("active")),e=o(p(z),A.val()),a(m($.val().toUpperCase()),e)||(t=h(e), +$.data("tvcolorpicker-custom-color",t),E.call($,t))}var k,C,N,P,M,D,L,R,F,I,H,U,W,B,z,q=!1,$=e(this),V=$.prop("ownerDocument"),K=e('
'),X=e('
').appendTo(K);return X.append(S.call(this,["rgb(0, 0, 0)","rgb(66, 66, 66)","rgb(101, 101, 101)","rgb(152, 152, 152)","rgb(182, 182, 182)","rgb(203, 203, 203)","rgb(216, 216, 216)","rgb(238, 238, 238)","rgb(242, 242, 242)","rgb(255, 255, 255)"])),X.append(S.call(this,["rgb(151, 0, 0)","rgb(255, 0, 0)","rgb(255, 152, 0)","rgb(255, 255, 0)","rgb(0, 255, 0)","rgb(0, 255, 255)","rgb(73, 133, 231)","rgb(0, 0, 255)","rgb(152, 0, 255)","rgb(255, 0, 255)"])),X.append(S.call(this,["rgb(230, 184, 175)","rgb(244, 204, 204)","rgb(252, 229, 205)","rgb(255, 242, 204)","rgb(217, 234, 211)","rgb(208, 224, 227)","rgb(201, 218, 248)","rgb(207, 226, 243)","rgb(217, 210, 233)","rgb(234, 209, 220)","rgb(221, 126, 107)","rgb(234, 153, 153)","rgb(249, 203, 156)","rgb(255, 229, 153)","rgb(182, 215, 168)","rgb(162, 196, 201)","rgb(164, 194, 244)","rgb(159, 197, 232)","rgb(180, 167, 214)","rgb(213, 166, 189)","rgb(204, 65, 37)","rgb(224, 102, 102)","rgb(246, 178, 107)","rgb(255, 217, 102)","rgb(147, 196, 125)","rgb(118, 165, 175)","rgb(109, 158, 235)","rgb(111, 168, 220)","rgb(142, 124, 195)","rgb(194, 123, 160)","rgb(166, 28, 0)","rgb(204, 0, 0)","rgb(230, 145, 56)","rgb(241, 194, 50)","rgb(106, 168, 79)","rgb(69, 129, 142)","rgb(60, 120, 216)","rgb(61, 133, 198)","rgb(103, 78, 167)","rgb(166, 77, 121)","rgb(133, 32, 12)","rgb(153, 0, 0)","rgb(180, 95, 6)","rgb(191, 144, 0)","rgb(56, 118, 29)","rgb(19, 79, 92)","rgb(17, 85, 204)","rgb(11, 83, 148)","rgb(53, 28, 117)","rgb(116, 27, 71)","rgb(91, 15, 0)","rgb(102, 0, 0)","rgb(120, 63, 4)","rgb(127, 96, 0)","rgb(39, 78, 19)","rgb(12, 52, 61)","rgb(28, 69, 135)","rgb(7, 55, 99)","rgb(32, 18, 77)","rgb(76, 17, 48)"])),k=e('
').css({display:"none"}).appendTo(K),C=e('
').appendTo(k),N=e('
').appendTo(C),P=e('
').appendTo(N),M=e('
').appendTo(N),D=e('
').appendTo(C),L=e('
').appendTo(D),R=e('
').appendTo(L),F=e('
').appendTo(L),A=y(e(this),t.hideTransparency),A.initEvents(),A.updateColor(),A.$el.appendTo(K),A.val(m($.val()||x)[3]),I=N.height(),H=N.width(),U=!1,W=!1,B=!0,z=[0,0,.5],M.bind("mousedown",function(t){1==t.which&&(U=!0,e(V).bind("mouseup",r),n(t),t.preventDefault())}),M.bind("mousemove",function(e){U&&(n(e),e.preventDefault())}),e(A).on("change",function(){if(q)return void _();T.call(this,e(this).val()||x,A.val())}.bind(this)),e(A).on("afterChange",function(){e(this).focus()}.bind(this)),D.bind("mousedown",function(t){1==t.which&&(W=!0,e(V).bind("mouseup",b),v(t),t.preventDefault())}),e(V).bind("mousemove",function(e){W&&(v(e), +e.preventDefault())}),e('
'+window.t("Custom color...")+"").appendTo(K).bind("click",function(){var t,n=e(this).is(".active");n||k.css({minWidth:X.width()+"px",minHeight:X.height()+"px"}),e(this)[n?"removeClass":"addClass"]("active"),q=e(this).is(".active"),k.css({display:n?"none":"block"}),X.css({display:n?"block":"none"}),n?$.removeData("tvcolorpicker-custom-color"):(I=N.height(),H=N.width(),t=g($.val()||x),z=f(t),P.css({left:~~(z[0]*H)+"px",top:~~((1-z[1])*I)+"px"}),R.css({top:~~((1-z[2])*I)+"px"}),L.css({backgroundColor:d(p(c(z[0],z[1],1)))}))}),K.append(e(S.call(this,w,{addClass:"tvcolorpicker-user"})).addClass("tvcolorpicker-user-swatches")),e(V.body).append(K),O($,K,t),V.addEventListener("keydown",j,!1),K}function P(){var t=e(this).prop("ownerDocument")||document;e(t).find(".tvcolorpicker-popup").removeClass("opened").remove(),e(A).off("change"),e(A).off("afterChange"),t.removeEventListener("keydown",j,!1),e(M).data("tvcolorpicker",null),e(M).each(function(){var t,n=e(this).data("tvcolorpicker-custom-color");n&&(k(n)&&e(this).trigger("customcolorchange",[w]),e(this).data("tvcolorpicker-custom-color",null)),t=e(this).data("tvcolorpicker-previous-color"),t&&t!=e(this).val()&&e(this).trigger("change"),e(this).removeData("tvcolorpicker-previous-color")})}function j(e){e.keyCode===v&&(P.call(M),M.blur())}var A,M;return _=e.extend({},r.options,_||{}),M=this,_&&"customColors"in _&&n(_.customColors),this.each(function(){function n(){var e=t(a.val());C.call(a,e)}var r,o,i,a=e(this);a.val(t(a.val())),r=null,o=!1,a.addClass("tvcolorpicker-widget").attr("autocomplete","off").attr("readonly",!0),i=function(){a.data("tvcolorpicker")||(P.call(a),r=N.call(a,_),a.data("tvcolorpicker-custom-color",null),a.data("tvcolorpicker",r),a.data("tvcolorpicker-previous-color",a.val()),r.bind("mousedown click",function(t){e(t.target).parents().andSelf().is(r)&&(a.focus(),o=!0,setTimeout(function(){o=!1},0))}))},a.on("touchstart",i),a.focus(i),P.call(a),a.bind("blur",function(e){o?e.stopPropagation():P.call(a)}),a.change(function(e){n()}),n()})}var b,w,x;if(!e)throw Error("This program cannot be run in DOS mode");r.setCustomColors=n,e.fn.tvcolorpicker=r,b=10,w=[],x="rgb(14, 15, 16)",r.options={direction:"down",offset:0,drift:0}}(window.jQuery)},,,function(e,t,n){"use strict";function r(){return new Promise(function(e){n.e(23).then(function(t){n(330),e()}.bind(null,n)).catch(n.oe)})}var o;Object.defineProperty(t,"__esModule",{value:!0}),t.lazyVelocity=r,o=n(14),n.n(o),$.fn.velocity=function(){var e,t=this,n=[];for(e=0;e-1?t:e}function d(e,t){t=t||{};var n=t.body;if("string"==typeof e)this.url=e;else{if(e.bodyUsed)throw new TypeError("Already read");this.url=e.url,this.credentials=e.credentials,t.headers||(this.headers=new o(e.headers)),this.method=e.method,this.mode=e.mode,n||null==e._bodyInit||(n=e._bodyInit,e.bodyUsed=!0)}if(this.credentials=t.credentials||this.credentials||"omit",!t.headers&&this.headers||(this.headers=new o(t.headers)),this.method=p(t.method||this.method||"GET"),this.mode=t.mode||this.mode||null,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&n)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(n)}function h(e){var t=new FormData;return e.trim().split("&").forEach(function(e){var n,r,o;e&&(n=e.split("="),r=n.shift().replace(/\+/g," "),o=n.join("=").replace(/\+/g," "),t.append(decodeURIComponent(r),decodeURIComponent(o)))}),t}function g(e){var t=new o;return e.split("\r\n").forEach(function(e){var n,r=e.split(":"),o=r.shift().trim();o&&(n=r.join(":").trim(),t.append(o,n))}),t}function m(e,t){t||(t={}),this.type="default",this.status="status"in t?t.status:200,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in t?t.statusText:"OK",this.headers=new o(t.headers),this.url=t.url||"",this._initBody(e)}var y,v,b,w,x,_;e.fetch||(y={searchParams:"URLSearchParams"in e,iterable:"Symbol"in e&&"iterator"in Symbol,blob:"FileReader"in e&&"Blob"in e&&function(){try{return new Blob,!0}catch(e){return!1}}(),formData:"FormData"in e,arrayBuffer:"ArrayBuffer"in e},y.arrayBuffer&&(v=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],b=function(e){return e&&DataView.prototype.isPrototypeOf(e)},w=ArrayBuffer.isView||function(e){return e&&v.indexOf(Object.prototype.toString.call(e))>-1}),o.prototype.append=function(e,r){e=t(e),r=n(r);var o=this.map[e];o||(o=[],this.map[e]=o),o.push(r)},o.prototype.delete=function(e){delete this.map[t(e)]},o.prototype.get=function(e){var n=this.map[t(e)];return n?n[0]:null},o.prototype.getAll=function(e){return this.map[t(e)]||[]},o.prototype.has=function(e){return this.map.hasOwnProperty(t(e))},o.prototype.set=function(e,r){this.map[t(e)]=[n(r)]},o.prototype.forEach=function(e,t){Object.getOwnPropertyNames(this.map).forEach(function(n){this.map[n].forEach(function(r){e.call(t,r,n,this)},this)},this)},o.prototype.keys=function(){var e=[];return this.forEach(function(t,n){e.push(n)}),r(e)},o.prototype.values=function(){var e=[];return this.forEach(function(t){e.push(t)}),r(e)},o.prototype.entries=function(){var e=[];return this.forEach(function(t,n){e.push([n,t])}),r(e)},y.iterable&&(o.prototype[Symbol.iterator]=o.prototype.entries),x=["DELETE","GET","HEAD","OPTIONS","POST","PUT"],d.prototype.clone=function(){return new d(this,{body:this._bodyInit})},f.call(d.prototype), +f.call(m.prototype),m.prototype.clone=function(){return new m(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new o(this.headers),url:this.url})},m.error=function(){var e=new m(null,{status:0,statusText:""});return e.type="error",e},_=[301,302,303,307,308],m.redirect=function(e,t){if(-1===_.indexOf(t))throw new RangeError("Invalid status code");return new m(null,{status:t,headers:{location:e}})},e.Headers=o,e.Request=d,e.Response=m,e.fetch=function(e,t){return new Promise(function(n,r){var o=new d(e,t),i=new XMLHttpRequest;i.onload=function(){var e,t={status:i.status,statusText:i.statusText,headers:g(i.getAllResponseHeaders()||"")};t.url="responseURL"in i?i.responseURL:t.headers.get("X-Request-URL"),e="response"in i?i.response:i.responseText,n(new m(e,t))},i.onerror=function(){r(new TypeError("Network request failed"))},i.ontimeout=function(){r(new TypeError("Network request failed"))},i.open(o.method,o.url,!0),"include"===o.credentials&&(i.withCredentials=!0),"responseType"in i&&y.blob&&(i.responseType="blob"),o.headers.forEach(function(e,t){i.setRequestHeader(t,e)}),i.send(void 0===o._bodyInit?null:o._bodyInit)})},e.fetch.polyfill=!0)}("undefined"!=typeof self?self:this)},function(e,t,n){"use strict";if(window._babelPolyfill)throw Error("only one instance of babel/polyfill is allowed");window._babelPolyfill=!0,n(363),n(369),n(371),n(372),n(373),n(374),n(375),n(376),n(377),n(379),n(381),n(382),n(384),n(385),n(386),n(388),n(390),n(391),n(393),n(394),n(395),n(397),n(399),n(402),n(403),n(406),n(410),n(413),n(414),n(415),n(416)},function(e,t,n){"use strict";var r,o,i=n(22),a=n(52),s=n(53),u=n(10),l=n(75),c=n(141).KEY,f=n(64),p=n(142),d=n(92),h=n(91),g=n(23),m=n(216),y=n(364),v=n(365),b=n(366),w=n(219),x=n(54),_=n(56),k=n(139),T=n(90),E=n(148),C=n(368),S=n(222),O=n(47),N=n(76),P=S.f,j=O.f,A=C.f,M=i.Symbol,D=i.JSON,L=D&&D.stringify,R="prototype",F=g("_hidden"),I=g("toPrimitive"),H={}.propertyIsEnumerable,U=p("symbol-registry"),W=p("symbols"),B=p("op-symbols"),z=Object[R],q="function"==typeof M,$=i.QObject,V=!$||!$[R]||!$[R].findChild,K=s&&f(function(){return 7!=E(j({},"a",{get:function(){return j(this,"a",{value:7}).a}})).a})?function(e,t,n){var r=P(z,t);r&&delete z[t],j(e,t,n),r&&e!==z&&j(z,t,r)}:j,X=function(e){var t=W[e]=E(M[R]);return t._k=e,t},G=q&&"symbol"==typeof M.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof M},Q=function(e,t,n){return e===z&&Q(B,t,n),x(e),t=k(t,!0),x(n),a(W,t)?(n.enumerable?(a(e,F)&&e[F][t]&&(e[F][t]=!1),n=E(n,{enumerable:T(0,!1)})):(a(e,F)||j(e,F,T(1,{})),e[F][t]=!0),K(e,t,n)):j(e,t,n)},Y=function(e,t){x(e);for(var n,r=b(t=_(t)),o=0,i=r.length;i>o;)Q(e,n=r[o++],t[n]);return e},J=function(e,t){return void 0===t?E(e):Y(E(e),t)},Z=function(e){var t=H.call(this,e=k(e,!0));return!(this===z&&a(W,e)&&!a(B,e))&&(!(t||!a(this,e)||!a(W,e)||a(this,F)&&this[F][e])||t)},ee=function(e,t){if(e=_(e),t=k(t,!0),e!==z||!a(W,t)||a(B,t)){var n=P(e,t);return!n||!a(W,t)||a(e,F)&&e[F][t]||(n.enumerable=!0),n}},te=function(e){ +for(var t,n=A(_(e)),r=[],o=0;n.length>o;)a(W,t=n[o++])||t==F||t==c||r.push(t);return r},ne=function(e){for(var t,n=e===z,r=A(n?B:_(e)),o=[],i=0;r.length>i;)!a(W,t=r[i++])||n&&!a(z,t)||o.push(W[t]);return o};for(q||(M=function(){var e,t;if(this instanceof M)throw TypeError("Symbol is not a constructor!");return e=h(arguments.length>0?arguments[0]:void 0),t=function(n){this===z&&t.call(B,n),a(this,F)&&a(this[F],e)&&(this[F][e]=!1),K(this,e,T(1,n))},s&&V&&K(z,e,{configurable:!0,set:t}),X(e)},l(M[R],"toString",function(){return this._k}),S.f=ee,O.f=Q,n(221).f=C.f=te,n(93).f=Z,n(147).f=ne,s&&!n(111)&&l(z,"propertyIsEnumerable",Z,!0),m.f=function(e){return X(g(e))}),u(u.G+u.W+u.F*!q,{Symbol:M}),r="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),o=0;r.length>o;)g(r[o++]);for(r=N(g.store),o=0;r.length>o;)y(r[o++]);u(u.S+u.F*!q,"Symbol",{for:function(e){return a(U,e+="")?U[e]:U[e]=M(e)},keyFor:function(e){if(G(e))return v(U,e);throw TypeError(e+" is not a symbol!")},useSetter:function(){V=!0},useSimple:function(){V=!1}}),u(u.S+u.F*!q,"Object",{create:J,defineProperty:Q,defineProperties:Y,getOwnPropertyDescriptor:ee,getOwnPropertyNames:te,getOwnPropertySymbols:ne}),D&&u(u.S+u.F*(!q||f(function(){var e=M();return"[null]"!=L([e])||"{}"!=L({a:e})||"{}"!=L(Object(e))})),"JSON",{stringify:function(e){if(void 0!==e&&!G(e)){for(var t,n,r=[e],o=1;arguments.length>o;)r.push(arguments[o++]);return t=r[1],"function"==typeof t&&(n=t),!n&&w(t)||(t=function(e,t){if(n&&(t=n.call(this,e,t)),!G(t))return t}),r[1]=t,L.apply(D,r)}}}),M[R][I]||n(74)(M[R],I,M[R].valueOf),d(M,"Symbol"),d(Math,"Math",!0),d(i.JSON,"JSON",!0)},function(e,t,n){var r=n(22),o=n(89),i=n(111),a=n(216),s=n(47).f;e.exports=function(e){var t=o.Symbol||(o.Symbol=i?{}:r.Symbol||{});"_"==e.charAt(0)||e in t||s(t,e,{value:a.f(e)})}},function(e,t,n){var r=n(76),o=n(56);e.exports=function(e,t){for(var n,i=o(e),a=r(i),s=a.length,u=0;s>u;)if(i[n=a[u++]]===t)return n}},function(e,t,n){var r=n(76),o=n(147),i=n(93);e.exports=function(e){var t,n,a,s,u=r(e),l=o.f;if(l)for(t=l(e),n=i.f,a=0;t.length>a;)n.call(e,s=t[a++])&&u.push(s);return u}},function(e,t,n){var r=n(47),o=n(54),i=n(76);e.exports=n(53)?Object.defineProperties:function(e,t){o(e);for(var n,a=i(t),s=a.length,u=0;s>u;)r.f(e,n=a[u++],t[n]);return e}},function(e,t,n){var r=n(56),o=n(221).f,i={}.toString,a="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],s=function(e){try{return o(e)}catch(e){return a.slice()}};e.exports.f=function(e){return a&&"[object Window]"==i.call(e)?s(e):o(r(e))}},function(e,t,n){var r=n(10);r(r.S+r.F,"Object",{assign:n(370)})},function(e,t,n){"use strict";var r=n(76),o=n(147),i=n(93),a=n(94),s=n(143),u=Object.assign;e.exports=!u||n(64)(function(){var e={},t={},n=Symbol(),r="abcdefghijklmnopqrst";return e[n]=7,r.split("").forEach(function(e){t[e]=e}),7!=u({},e)[n]||Object.keys(u({},t)).join("")!=r})?function(e,t){ +for(var n,u,l,c,f,p=a(e),d=arguments.length,h=1,g=o.f,m=i.f;d>h;)for(n=s(arguments[h++]),u=g?r(n).concat(g(n)):r(n),l=u.length,c=0;l>c;)m.call(n,f=u[c++])&&(p[f]=n[f]);return p}:u},function(e,t,n){var r=n(10),o=n(22).isFinite;r(r.S,"Number",{isFinite:function(e){return"number"==typeof e&&o(e)}})},function(e,t,n){var r=n(10);r(r.S,"Number",{isInteger:n(223)})},function(e,t,n){var r=n(10);r(r.S,"Number",{isNaN:function(e){return e!=e}})},function(e,t,n){var r=n(10),o=n(223),i=Math.abs;r(r.S,"Number",{isSafeInteger:function(e){return o(e)&&i(e)<=9007199254740991}})},function(e,t,n){var r=n(10);r(r.S,"Number",{MAX_SAFE_INTEGER:9007199254740991})},function(e,t,n){var r=n(10);r(r.S,"Number",{MIN_SAFE_INTEGER:-9007199254740991})},function(e,t,n){var r=n(10),o=n(378);r(r.S+r.F*(Number.parseFloat!=o),"Number",{parseFloat:o})},function(e,t,n){var r=n(22).parseFloat,o=n(224).trim;e.exports=1/r(n(149)+"-0")!=-1/0?function(e){var t=o(e+"",3),n=r(t);return 0===n&&"-"==t.charAt(0)?-0:n}:r},function(e,t,n){var r=n(10),o=n(380);r(r.S+r.F*(Number.parseInt!=o),"Number",{parseInt:o})},function(e,t,n){var r=n(22).parseInt,o=n(224).trim,i=n(149),a=/^[\-+]?0[xX]/;e.exports=8!==r(i+"08")||22!==r(i+"0x16")?function(e,t){var n=o(e+"",3);return r(n,t>>>0||(a.test(n)?16:10))}:r},function(e,t,n){var r=n(10);r(r.S,"Math",{log10:function(e){return Math.log(e)/Math.LN10}})},function(e,t,n){var r=n(10);r(r.S,"Math",{sign:n(383)})},function(e,t){e.exports=Math.sign||function(e){return 0==(e=+e)||e!=e?e:e<0?-1:1}},function(e,t,n){var r=n(10);r(r.S,"Math",{trunc:function(e){return(e>0?Math.floor:Math.ceil)(e)}})},function(e,t,n){var r=n(10),o=n(144),i=String.fromCharCode,a=String.fromCodePoint;r(r.S+r.F*(!!a&&1!=a.length),"String",{fromCodePoint:function(e){for(var t,n=[],r=arguments.length,a=0;r>a;){if(t=+arguments[a++],o(t,1114111)!==t)throw RangeError(t+" is not a valid code point");n.push(t<65536?i(t):i(55296+((t-=65536)>>10),t%1024+56320))}return n.join("")}})},function(e,t,n){"use strict";var r=n(10),o=n(387)(!1);r(r.P,"String",{codePointAt:function(e){return o(this,e)}})},function(e,t,n){var r=n(112),o=n(65);e.exports=function(e){return function(t,n){var i,a,s=o(t)+"",u=r(n),l=s.length;return u<0||u>=l?e?"":void 0:(i=s.charCodeAt(u),i<55296||i>56319||u+1===l||(a=s.charCodeAt(u+1))<56320||a>57343?e?s.charAt(u):i:e?s.slice(u,u+2):a-56320+(i-55296<<10)+65536)}}},function(e,t,n){"use strict";var r=n(10),o=n(66),i=n(150),a="endsWith",s=""[a];r(r.P+r.F*n(151)(a),"String",{endsWith:function(e){var t=i(this,e,a),n=arguments.length>1?arguments[1]:void 0,r=o(t.length),u=void 0===n?r:Math.min(o(n),r),l=e+"";return s?s.call(t,l,u):t.slice(u-l.length,u)===l}})},function(e,t,n){var r=n(36),o=n(77),i=n(23)("match");e.exports=function(e){var t;return r(e)&&(void 0!==(t=e[i])?!!t:"RegExp"==o(e))}},function(e,t,n){"use strict";var r=n(10),o=n(150),i="includes";r(r.P+r.F*n(151)(i),"String",{includes:function(e){return!!~o(this,e,i).indexOf(e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){var r=n(10);r(r.P,"String",{repeat:n(392)})},function(e,t,n){ +"use strict";var r=n(112),o=n(65);e.exports=function(e){var t=o(this)+"",n="",i=r(e);if(i<0||i==1/0)throw RangeError("Count can't be negative");for(;i>0;(i>>>=1)&&(t+=t))1&i&&(n+=t);return n}},function(e,t,n){"use strict";var r=n(10),o=n(66),i=n(150),a="startsWith",s=""[a];r(r.P+r.F*n(151)(a),"String",{startsWith:function(e){var t=i(this,e,a),n=o(Math.min(arguments.length>1?arguments[1]:void 0,t.length)),r=e+"";return s?s.call(t,r,n):t.slice(n,n+r.length)===r}})},function(e,t,n){var r=Date.prototype,o="Invalid Date",i="toString",a=r[i],s=r.getTime;new Date(NaN)+""!=o&&n(75)(r,i,function(){var e=s.call(this);return e===e?a.call(this):o})},function(e,t,n){"use strict";var r=n(55),o=n(10),i=n(94),a=n(225),s=n(226),u=n(66),l=n(396),c=n(227);o(o.S+o.F*!n(152)(function(e){Array.from(e)}),"Array",{from:function(e){var t,n,o,f,p=i(e),d="function"==typeof this?this:Array,h=arguments.length,g=h>1?arguments[1]:void 0,m=void 0!==g,y=0,v=c(p);if(m&&(g=r(g,h>2?arguments[2]:void 0,2)),void 0==v||d==Array&&s(v))for(t=u(p.length),n=new d(t);t>y;y++)l(n,y,m?g(p[y],y):p[y]);else for(f=v.call(p),n=new d;!(o=f.next()).done;y++)l(n,y,m?a(f,g,[o.value,y],!0):o.value);return n.length=y,n}})},function(e,t,n){"use strict";var r=n(47),o=n(90);e.exports=function(e,t,n){t in e?r.f(e,t,o(0,n)):e[t]=n}},function(e,t,n){var r=n(10);r(r.P,"Array",{fill:n(398)}),n(95)("fill")},function(e,t,n){"use strict";var r=n(94),o=n(144),i=n(66);e.exports=function(e){for(var t=r(this),n=i(t.length),a=arguments.length,s=o(a>1?arguments[1]:void 0,n),u=a>2?arguments[2]:void 0,l=void 0===u?n:o(u,n);l>s;)t[s++]=e;return t}},function(e,t,n){"use strict";var r=n(10),o=n(229)(5),i="find",a=!0;i in[]&&Array(1)[i](function(){a=!1}),r(r.P+r.F*a,"Array",{find:function(e){return o(this,e,arguments.length>1?arguments[1]:void 0)}}),n(95)(i)},function(e,t,n){var r=n(401);e.exports=function(e,t){return new(r(e))(t)}},function(e,t,n){var r=n(36),o=n(219),i=n(23)("species");e.exports=function(e){var t;return o(e)&&(t=e.constructor,"function"!=typeof t||t!==Array&&!o(t.prototype)||(t=void 0),r(t)&&null===(t=t[i])&&(t=void 0)),void 0===t?Array:t}},function(e,t,n){"use strict";var r=n(10),o=n(229)(6),i="findIndex",a=!0;i in[]&&Array(1)[i](function(){a=!1}),r(r.P+r.F*a,"Array",{findIndex:function(e){return o(this,e,arguments.length>1?arguments[1]:void 0)}}),n(95)(i)},function(e,t,n){"use strict";var r=n(95),o=n(230),i=n(113),a=n(56);e.exports=n(231)(Array,"Array",function(e,t){this._t=a(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,n=this._i++;return!e||n>=e.length?(this._t=void 0,o(1)):"keys"==t?o(0,n):"values"==t?o(0,e[n]):o(0,[n,e[n]])},"values"),i.Arguments=i.Array,r("keys"),r("values"),r("entries")},function(e,t,n){"use strict";var r=n(148),o=n(90),i=n(92),a={};n(74)(a,n(23)("iterator"),function(){return this}),e.exports=function(e,t,n){e.prototype=r(a,{next:o(1,n)}),i(e,t+" Iterator")}},function(e,t,n){var r=n(52),o=n(94),i=n(145)("IE_PROTO"),a=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=o(e), +r(e,i)?e[i]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?a:null}},function(e,t,n){"use strict";var r,o,i,a,s,u,l,c,f,p,d,h,g,m,y,v,b,w=n(111),x=n(22),_=n(55),k=n(228),T=n(10),E=n(36),C=n(140),S=n(153),O=n(154),N=n(407),P=n(232).set,j=n(409)(),A="Promise",M=x.TypeError,D=x.process,L=x[A];D=x.process,r="process"==k(D),o=function(){},u=!!function(){try{var e=L.resolve(1),t=(e.constructor={})[n(23)("species")]=function(e){e(o,o)};return(r||"function"==typeof PromiseRejectionEvent)&&e.then(o)instanceof t}catch(e){}}(),l=function(e,t){return e===t||e===L&&t===s},c=function(e){var t;return!(!E(e)||"function"!=typeof(t=e.then))&&t},f=function(e){return l(L,e)?new p(e):new a(e)},p=a=function(e){var t,n;this.promise=new e(function(e,r){if(void 0!==t||void 0!==n)throw M("Bad Promise constructor");t=e,n=r}),this.resolve=C(t),this.reject=C(n)},d=function(e){try{e()}catch(e){return{error:e}}},h=function(e,t){if(!e._n){e._n=!0;var n=e._c;j(function(){for(var r=e._v,o=1==e._s,i=0,a=function(t){var n,i,a=o?t.ok:t.fail,s=t.resolve,u=t.reject,l=t.domain;try{a?(o||(2==e._h&&y(e),e._h=1),!0===a?n=r:(l&&l.enter(),n=a(r),l&&l.exit()),n===t.promise?u(M("Promise-chain cycle")):(i=c(n))?i.call(n,s,u):s(n)):u(r)}catch(e){u(e)}};n.length>i;)a(n[i++]);e._c=[],e._n=!1,t&&!e._h&&g(e)})}},g=function(e){P.call(x,function(){var t,n,o,i=e._v;if(m(e)&&(t=d(function(){r?D.emit("unhandledRejection",i,e):(n=x.onunhandledrejection)?n({promise:e,reason:i}):(o=x.console)&&o.error&&o.error("Unhandled promise rejection",i)}),e._h=r||m(e)?2:1),e._a=void 0,t)throw t.error})},m=function(e){if(1==e._h)return!1;for(var t,n=e._a||e._c,r=0;n.length>r;)if(t=n[r++],t.fail||!m(t.promise))return!1;return!0},y=function(e){P.call(x,function(){var t;r?D.emit("rejectionHandled",e):(t=x.onrejectionhandled)&&t({promise:e,reason:e._v})})},v=function(e){var t=this;t._d||(t._d=!0,t=t._w||t,t._v=e,t._s=2,t._a||(t._a=t._c.slice()),h(t,!0))},b=function(e){var t,n=this;if(!n._d){n._d=!0,n=n._w||n;try{if(n===e)throw M("Promise can't be resolved itself");(t=c(e))?j(function(){var r={_w:n,_d:!1};try{t.call(e,_(b,r,1),_(v,r,1))}catch(e){v.call(r,e)}}):(n._v=e,n._s=1,h(n,!1))}catch(e){v.call({_w:n,_d:!1},e)}}},u||(L=function(e){S(this,L,A,"_h"),C(e),i.call(this);try{e(_(b,this,1),_(v,this,1))}catch(e){v.call(this,e)}},i=function(e){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1},i.prototype=n(155)(L.prototype,{then:function(e,t){var n=f(N(this,L));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=r?D.domain:void 0,this._c.push(n),this._a&&this._a.push(n),this._s&&h(this,!1),n.promise},catch:function(e){return this.then(void 0,e)}}),p=function(){var e=new i;this.promise=e,this.resolve=_(b,e,1),this.reject=_(v,e,1)}),T(T.G+T.W+T.F*!u,{Promise:L}),n(92)(L,A),n(233)(A),s=n(89)[A],T(T.S+T.F*!u,A,{reject:function(e){var t=f(this);return(0,t.reject)(e),t.promise}}),T(T.S+T.F*(w||!u),A,{resolve:function(e){if(e instanceof L&&l(e.constructor,this))return e;var t=f(this) +;return(0,t.resolve)(e),t.promise}}),T(T.S+T.F*!(u&&n(152)(function(e){L.all(e).catch(o)})),A,{all:function(e){var t=this,n=f(t),r=n.resolve,o=n.reject,i=d(function(){var n=[],i=0,a=1;O(e,!1,function(e){var s=i++,u=!1;n.push(void 0),a++,t.resolve(e).then(function(e){u||(u=!0,n[s]=e,--a||r(n))},o)}),--a||r(n)});return i&&o(i.error),n.promise},race:function(e){var t=this,n=f(t),r=n.reject,o=d(function(){O(e,!1,function(e){t.resolve(e).then(n.resolve,r)})});return o&&r(o.error),n.promise}})},function(e,t,n){var r=n(54),o=n(140),i=n(23)("species");e.exports=function(e,t){var n,a=r(e).constructor;return void 0===a||void 0==(n=r(a)[i])?t:o(n)}},function(e,t){e.exports=function(e,t,n){var r=void 0===n;switch(t.length){case 0:return r?e():e.call(n);case 1:return r?e(t[0]):e.call(n,t[0]);case 2:return r?e(t[0],t[1]):e.call(n,t[0],t[1]);case 3:return r?e(t[0],t[1],t[2]):e.call(n,t[0],t[1],t[2]);case 4:return r?e(t[0],t[1],t[2],t[3]):e.call(n,t[0],t[1],t[2],t[3])}return e.apply(n,t)}},function(e,t,n){var r=n(22),o=n(232).set,i=r.MutationObserver||r.WebKitMutationObserver,a=r.process,s=r.Promise,u="process"==n(77)(a);e.exports=function(){var e,t,n,l,c,f,p=function(){var r,o;for(u&&(r=a.domain)&&r.exit();e;){o=e.fn,e=e.next;try{o()}catch(r){throw e?n():t=void 0,r}}t=void 0,r&&r.enter()};return u?n=function(){a.nextTick(p)}:i?(l=!0,c=document.createTextNode(""),new i(p).observe(c,{characterData:!0}),n=function(){c.data=l=!l}):s&&s.resolve?(f=s.resolve(),n=function(){f.then(p)}):n=function(){o.call(r,p)},function(r){var o={fn:r,next:void 0};t&&(t.next=o),e||(e=o,n()),t=o}}},function(e,t,n){"use strict";var r=n(234);e.exports=n(235)("Map",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{get:function(e){var t=r.getEntry(this,e);return t&&t.v},set:function(e,t){return r.def(this,0===e?0:e,t)}},r,!0)},function(e,t,n){var r=n(36),o=n(412).set;e.exports=function(e,t,n){var i,a=t.constructor;return a!==n&&"function"==typeof a&&(i=a.prototype)!==n.prototype&&r(i)&&o&&o(e,i),e}},function(e,t,n){var r=n(36),o=n(54),i=function(e,t){if(o(e),!r(t)&&null!==t)throw TypeError(t+": can't set as prototype!")};e.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(e,t,r){try{r=n(55)(Function.call,n(222).f(Object.prototype,"__proto__").set,2),r(e,[]),t=!(e instanceof Array)}catch(e){t=!0}return function(e,n){return i(e,n),t?e.__proto__=n:r(e,n),e}}({},!1):void 0),check:i}},function(e,t,n){"use strict";var r=n(234);e.exports=n(235)("Set",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return r.def(this,e=0===e?0:e,e)}},r)},function(e,t,n){"use strict";var r=n(10),o=n(218)(!0);r(r.P,"Array",{includes:function(e){return o(this,e,arguments.length>1?arguments[1]:void 0)}}),n(95)("includes")},function(e,t,n){var r=n(10),o=n(236)(!1);r(r.S,"Object",{values:function(e){return o(e)}})},function(e,t,n){var r=n(10),o=n(236)(!0);r(r.S,"Object",{entries:function(e){return o(e)}})},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}} +var o,i;Object.defineProperty(t,"__esModule",{value:!0}),o=n(418),i=r(o),t.default=i.default},function(e,t,n){"use strict";function r(e){var t,n;if(e&&e.__esModule)return e;if(t={},null!=e)for(n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function o(e){return e&&e.__esModule?e:{default:e}}function i(e,t){var n,r,o,i=Object.getOwnPropertyNames(t);for(n=0;n1?t-1:0),r=1;r1?t-1:0),r=1;r1?t-1:0),r=1;r=0?"rtl":"ltr":"rtl"},t.prototype.createInstance=function(){return new t(arguments.length<=0||void 0===arguments[0]?{}:arguments[0],arguments[1])},t.prototype.cloneInstance=function(){var e=this,n=arguments.length<=0||void 0===arguments[0]?{}:arguments[0],r=arguments[1],o=new t(c({},n,this.options,{isClone:!0}),r);return["store","translator","services","language"].forEach(function(t){o[t]=e[t]}),o},t}(h.default),t.default=new D},function(e,t,n){"use strict";function r(e){var t,n;if(e&&e.__esModule)return e;if(t={},null!=e)for(n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function o(e){return e&&e.__esModule?e:{default:e}}function i(e,t){var n,r,o,i=Object.getOwnPropertyNames(t);for(n=0;n-1&&this.options.ns.splice(t,1)},t.prototype.getResource=function(e,t,n){var r,o=arguments.length<=3||void 0===arguments[3]?{}:arguments[3],i=o.keySeparator||this.options.keySeparator;return void 0===i&&(i="."),r=[e,t],n&&"string"!=typeof n&&(r=r.concat(n)),n&&"string"==typeof n&&(r=r.concat(i?n.split(i):n)),e.indexOf(".")>-1&&(r=e.split(".")),d.getPath(this.data,r)},t.prototype.addResource=function(e,t,n,r){var o,i=arguments.length<=4||void 0===arguments[4]?{silent:!1}:arguments[4],a=this.options.keySeparator;void 0===a&&(a="."),o=[e,t],n&&(o=o.concat(a?n.split(a):n)),e.indexOf(".")>-1&&(o=e.split("."),r=t,t=o[1]),this.addNamespaces(t),d.setPath(this.data,o,r),i.silent||this.emit("added",e,t,n,r)},t.prototype.addResources=function(e,t,n){for(var r in n)"string"==typeof n[r]&&this.addResource(e,t,r,n[r],{silent:!0});this.emit("added",e,t,n)},t.prototype.addResourceBundle=function(e,t,n,r,o){var i,a=[e,t];e.indexOf(".")>-1&&(a=e.split("."),r=n,n=t,t=a[1]),this.addNamespaces(t),i=d.getPath(this.data,a)||{},r?d.deepExtend(i,n,o):i=l({},i,n),d.setPath(this.data,a,i),this.emit("added",e,t,n)},t.prototype.removeResourceBundle=function(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit("removed",e,t)},t.prototype.hasResourceBundle=function(e,t){return void 0!==this.getResource(e,t)},t.prototype.getResourceBundle=function(e,t){return t||(t=this.options.defaultNS),"v1"===this.options.compatibilityAPI?l({},this.getResource(e,t)):this.getResource(e,t)},t.prototype.toJSON=function(){return this.data},t}(f.default),t.default=h},function(e,t,n){"use strict";function r(e){var t,n;if(e&&e.__esModule)return e;if(t={},null!=e)for(n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function o(e){return e&&e.__esModule?e:{default:e}}function i(e,t){var n,r,o,i=Object.getOwnPropertyNames(t);for(n=0;n-1&&(r=e.split(o),n=r[0],e=r[1]),"string"==typeof n&&(n=[n]),{key:e,namespaces:n}},t.prototype.translate=function(e){var t,n,r,o,i,a,s,u,f,p,d,h,g,m,y,b,w=arguments.length<=1||void 0===arguments[1]?{}:arguments[1];if("object"!==(void 0===w?"undefined":c(w))?w=this.options.overloadTranslationOptionHandler(arguments):"v1"===this.options.compatibilityAPI&&(w=v.convertTOptions(w)),void 0===e||null===e||""===e)return"";if("number"==typeof e&&(e+=""),"string"==typeof e&&(e=[e]),(t=w.lng||this.language)&&"cimode"===t.toLowerCase())return e[e.length-1];if(n=w.keySeparator||this.options.keySeparator||".",r=this.extractFromKey(e[e.length-1],w),o=r.key,i=r.namespaces,a=i[i.length-1],s=this.resolve(e,w),u=Object.prototype.toString.apply(s),f=["[object Number]","[object Function]","[object RegExp]"],p=void 0!==w.joinArrays?w.joinArrays:this.options.joinArrays,s&&"string"!=typeof s&&f.indexOf(u)<0&&(!p||"[object Array]"!==u)){if(!w.returnObjects&&!this.options.returnObjects)return this.logger.warn("accessing an object - but returnObjects options is not enabled!"),this.options.returnedObjectHandler?this.options.returnedObjectHandler(o,s,w):"key '"+o+" ("+this.language+")' returned an object instead of string.";d="[object Array]"===u?[]:{};for(h in s)d[h]=this.translate(""+o+n+h,l({joinArrays:!1,ns:i},w));s=d}else if(p&&"[object Array]"===u)(s=s.join(p))&&(s=this.extendTranslation(s,o,w));else{if(g=!1,m=!1,this.isValidLookup(s)||void 0===w.defaultValue||(g=!0,s=w.defaultValue),this.isValidLookup(s)||(m=!0,s=o),m||g){if(this.logger.log("missingKey",t,a,o,s),y=[],"fallback"===this.options.saveMissingTo&&this.options.fallbackLng&&this.options.fallbackLng[0])for(b=0;b-1?n[1].toLowerCase():n[0]))},e.prototype.formatLanguageCode=function(e){var t,n;return"string"==typeof e&&e.indexOf("-")>-1?(t=["hans","hant","latn","cyrl","cans","mong","arab"],n=e.split("-"), +this.options.lowerCaseLng?n=n.map(function(e){return e.toLowerCase()}):2===n.length?(n[0]=n[0].toLowerCase(),n[1]=n[1].toUpperCase(),t.indexOf(n[1].toLowerCase())>-1&&(n[1]=i(n[1].toLowerCase()))):3===n.length&&(n[0]=n[0].toLowerCase(),2===n[1].length&&(n[1]=n[1].toUpperCase()),"sgn"!==n[0]&&2===n[2].length&&(n[2]=n[2].toUpperCase()),t.indexOf(n[1].toLowerCase())>-1&&(n[1]=i(n[1].toLowerCase())),t.indexOf(n[2].toLowerCase())>-1&&(n[2]=i(n[2].toLowerCase()))),n.join("-")):this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e},e.prototype.isWhitelisted=function(e,t){return("languageOnly"===this.options.load||this.options.nonExplicitWhitelist&&!t)&&(e=this.getLanguagePartFromCode(e)),!this.whitelist||!this.whitelist.length||this.whitelist.indexOf(e)>-1},e.prototype.toResolveHierarchy=function(e,t){var n,r,o=this;return t=t||this.options.fallbackLng||[],"string"==typeof t&&(t=[t]),n=[],r=function(e){var t=!(arguments.length<=1||void 0===arguments[1])&&arguments[1];o.isWhitelisted(e,t)?n.push(e):o.logger.warn("rejecting non-whitelisted language code: "+e)},"string"==typeof e&&e.indexOf("-")>-1?("languageOnly"!==this.options.load&&r(this.formatLanguageCode(e),!0),"currentOnly"!==this.options.load&&r(this.getLanguagePartFromCode(e))):"string"==typeof e&&r(this.formatLanguageCode(e)),t.forEach(function(e){n.indexOf(e)<0&&r(o.formatLanguageCode(e))}),n},e}(),t.default=u},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(){var e={};return l.forEach(function(t){t.lngs.forEach(function(n){return e[n]={numbers:t.nr,plurals:c[t.fc]}})}),e}var a,s,u,l,c,f;Object.defineProperty(t,"__esModule",{value:!0}),a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol?"symbol":typeof e},s=n(57),u=r(s),l=[{lngs:["ach","ak","am","arn","br","fil","gun","ln","mfe","mg","mi","oc","tg","ti","tr","uz","wa"],nr:[1,2],fc:1},{lngs:["af","an","ast","az","bg","bn","ca","da","de","dev","el","en","eo","es","es_ar","et","eu","fi","fo","fur","fy","gl","gu","ha","he","hi","hu","hy","ia","it","kn","ku","lb","mai","ml","mn","mr","nah","nap","nb","ne","nl","nn","no","nso","pa","pap","pms","ps","pt","pt_br","rm","sco","se","si","so","son","sq","sv","sw","ta","te","tk","ur","yo"],nr:[1,2],fc:2},{lngs:["ay","bo","cgg","fa","id","ja","jbo","ka","kk","km","ko","ky","lo","ms","sah","su","th","tt","ug","vi","wo","zh"],nr:[1],fc:3},{lngs:["be","bs","dz","hr","ru","sr","uk"],nr:[1,2,5],fc:4},{lngs:["ar"],nr:[0,1,2,3,11,100],fc:5},{lngs:["cs","sk"],nr:[1,2,5],fc:6},{lngs:["csb","pl"],nr:[1,2,5],fc:7},{lngs:["cy"],nr:[1,2,3,8],fc:8},{lngs:["fr"],nr:[1,2],fc:9},{lngs:["ga"],nr:[1,2,3,7,11],fc:10},{lngs:["gd"],nr:[1,2,3,20],fc:11},{lngs:["is"],nr:[1,2],fc:12},{lngs:["jv"],nr:[0,1],fc:13},{lngs:["kw"],nr:[1,2,3,4],fc:14},{lngs:["lt"],nr:[1,2,10],fc:15},{lngs:["lv"],nr:[1,2,0],fc:16},{lngs:["mk"],nr:[1,2],fc:17},{ +lngs:["mnk"],nr:[0,1,2],fc:18},{lngs:["mt"],nr:[1,2,11,20],fc:19},{lngs:["or"],nr:[2,1],fc:2},{lngs:["ro"],nr:[1,2,20],fc:20},{lngs:["sl"],nr:[5,1,2,3],fc:21}],c={1:function(e){return+(e>1)},2:function(e){return+(1!=e)},3:function(e){return 0},4:function(e){return+(e%10==1&&e%100!=11?0:e%10>=2&&e%10<=4&&(e%100<10||e%100>=20)?1:2)},5:function(e){return+(0===e?0:1==e?1:2==e?2:e%100>=3&&e%100<=10?3:e%100>=11?4:5)},6:function(e){return+(1==e?0:e>=2&&e<=4?1:2)},7:function(e){return+(1==e?0:e%10>=2&&e%10<=4&&(e%100<10||e%100>=20)?1:2)},8:function(e){return+(1==e?0:2==e?1:8!=e&&11!=e?2:3)},9:function(e){return+(e>=2)},10:function(e){return+(1==e?0:2==e?1:e<7?2:e<11?3:4)},11:function(e){return+(1==e||11==e?0:2==e||12==e?1:e>2&&e<20?2:3)},12:function(e){return+(e%10!=1||e%100==11)},13:function(e){return+(0!==e)},14:function(e){return+(1==e?0:2==e?1:3==e?2:3)},15:function(e){return+(e%10==1&&e%100!=11?0:e%10>=2&&(e%100<10||e%100>=20)?1:2)},16:function(e){return+(e%10==1&&e%100!=11?0:0!==e?1:2)},17:function(e){return+(1==e||e%10==1?0:1)},18:function(e){return+(0==e?0:1==e?1:2)},19:function(e){return+(1==e?0:0===e||e%100>1&&e%100<11?1:e%100>10&&e%100<20?2:3)},20:function(e){return+(1==e?0:0===e||e%100>0&&e%100<20?1:2)},21:function(e){return+(e%100==1?1:e%100==2?2:e%100==3||e%100==4?3:0)}},f=function(){function e(t){var n=arguments.length<=1||void 0===arguments[1]?{}:arguments[1];o(this,e),this.languageUtils=t,this.options=n,this.logger=u.default.create("pluralResolver"),this.rules=i()}return e.prototype.addRule=function(e,t){this.rules[e]=t},e.prototype.getRule=function(e){return this.rules[this.languageUtils.getLanguagePartFromCode(e)]},e.prototype.needsPlural=function(e){var t=this.getRule(e);return!(t&&t.numbers.length<=1)},e.prototype.getSuffix=function(e,t){var n,r=this,o=this.getRule(e);return o?(n=function(){var e,n,i;return 1===o.numbers.length?{v:""}:(e=o.noAbs?o.plurals(t):o.plurals(Math.abs(t)),n=o.numbers[e],2===o.numbers.length&&1===o.numbers[0]&&(2===n?n="plural":1===n&&(n="")),i=function(){return r.options.prepend&&""+n?r.options.prepend+""+n:""+n},"v1"===r.options.compatibilityJSON?1===n?{v:""}:"number"==typeof n?{v:"_plural_"+n}:{v:i()}:"v2"===r.options.compatibilityJSON||2===o.numbers.length&&1===o.numbers[0]?{v:i()}:2===o.numbers.length&&1===o.numbers[0]?{v:i()}:{v:r.options.prepend&&""+e?r.options.prepend+""+e:""+e})}(),"object"===(void 0===n?"undefined":a(n))?n.v:void 0):(this.logger.warn("no plural rule found for: "+e),"")},e}(),t.default=f},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e){var t,n;if(e&&e.__esModule)return e;if(t={},null!=e)for(n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var a,s,u,l,c;Object.defineProperty(t,"__esModule",{value:!0}),a=n(97),s=o(a),u=n(57),l=r(u),c=function(){function e(){var t=arguments.length<=0||void 0===arguments[0]?{}:arguments[0];i(this,e),this.logger=l.default.create("interpolator"), +this.init(t,!0)}return e.prototype.init=function(){var e,t=arguments.length<=0||void 0===arguments[0]?{}:arguments[0];arguments[1]&&(this.options=t,this.format=t.interpolation&&t.interpolation.format||function(e){return e}),t.interpolation||(t.interpolation={escapeValue:!0}),e=t.interpolation,this.escapeValue=e.escapeValue,this.prefix=e.prefix?s.regexEscape(e.prefix):e.prefixEscaped||"{{",this.suffix=e.suffix?s.regexEscape(e.suffix):e.suffixEscaped||"}}",this.formatSeparator=e.formatSeparator?s.regexEscape(e.formatSeparator):e.formatSeparator||",",this.unescapePrefix=e.unescapeSuffix?"":e.unescapePrefix||"-",this.unescapeSuffix=this.unescapePrefix?"":e.unescapeSuffix||"",this.nestingPrefix=e.nestingPrefix?s.regexEscape(e.nestingPrefix):e.nestingPrefixEscaped||s.regexEscape("$t("),this.nestingSuffix=e.nestingSuffix?s.regexEscape(e.nestingSuffix):e.nestingSuffixEscaped||s.regexEscape(")"),this.resetRegExp()},e.prototype.reset=function(){this.options&&this.init(this.options)},e.prototype.resetRegExp=function(){var e,t,n=this.prefix+"(.+?)"+this.suffix;this.regexp=RegExp(n,"g"),e=this.prefix+this.unescapePrefix+"(.+?)"+this.unescapeSuffix+this.suffix,this.regexpUnescape=RegExp(e,"g"),t=this.nestingPrefix+"(.+?)"+this.nestingSuffix,this.nestingRegexp=RegExp(t,"g")},e.prototype.interpolate=function(e,t,n){function r(e){return e.replace(/\$/g,"$$$$")}var o,i=this,a=void 0,u=void 0,l=function(e){var r,o,a;return e.indexOf(i.formatSeparator)<0?s.getPath(t,e):(r=e.split(i.formatSeparator),o=r.shift().trim(),a=r.join(i.formatSeparator).trim(),i.format(s.getPath(t,o),a,n))};for(this.resetRegExp();a=this.regexpUnescape.exec(e);)o=l(a[1].trim()),e=e.replace(a[0],o),this.regexpUnescape.lastIndex=0;for(;a=this.regexp.exec(e);)u=l(a[1].trim()),"string"!=typeof u&&(u=s.makeString(u)),u||(this.logger.warn("missed to pass in variable "+a[1]+" for interpolating "+e),u=""),u=r(this.escapeValue?s.escape(u):u),e=e.replace(a[0],u),this.regexp.lastIndex=0;return e},e.prototype.nest=function(e,t){function n(e){return e.replace(/\$/g,"$$$$")}function r(e){var t,n;if(e.indexOf(",")<0)return e;t=e.split(","),e=t.shift(),n=t.join(","),n=this.interpolate(n,u);try{u=JSON.parse(n)}catch(t){this.logger.error("failed parsing options string in nesting for key "+e,t)}return e}var o=arguments.length<=2||void 0===arguments[2]?{}:arguments[2],i=void 0,a=void 0,u=JSON.parse(JSON.stringify(o));for(u.applyPostProcessor=!1;i=this.nestingRegexp.exec(e);)a=t(r.call(this,i[1].trim()),u),"string"!=typeof a&&(a=s.makeString(a)),a||(this.logger.warn("missed to pass in variable "+i[1]+" for interpolating "+e),a=""),a=n(this.escapeValue?s.escape(a):a),e=e.replace(i[0],a),this.regexp.lastIndex=0;return e},e}(),t.default=c},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e){var t,n;if(e&&e.__esModule)return e;if(t={},null!=e)for(n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function i(e,t){var n,r,o,i=Object.getOwnPropertyNames(t);for(n=0;n
"),i=r.children()[0];return e("body").append(r),t=i.offsetWidth,r.css("overflow","scroll"),n=i.offsetWidth,t===n&&(n=r[0].clientWidth),r.remove(),o=t-n},getScrollInfo:function(t){var n=t.isWindow||t.isDocument?"":t.element.css("overflow-x"),r=t.isWindow||t.isDocument?"":t.element.css("overflow-y"),o="scroll"===n||"auto"===n&&t.width0?"right":"center",vertical:s<0?"top":r>0?"bottom":"middle"};di(a(r),a(s))?f.important="horizontal":f.important="vertical",o.using.call(this,e,f)}),u.offset(e.extend(E,{using:s}))})},e.ui.position={fit:{left:function(e,t){var n,r=t.within,o=r.isWindow?r.scrollLeft:r.offset.left,a=r.width,s=e.left-t.collisionPosition.marginLeft,u=o-s,l=s+t.collisionWidth-a-o;t.collisionWidth>a?u>0&&l<=0?(n=e.left+u+t.collisionWidth-a-o,e.left+=u-n):e.left=l>0&&u<=0?o:u>l?o+a-t.collisionWidth:o:u>0?e.left+=u:l>0?e.left-=l:e.left=i(e.left-s,e.left)},top:function(e,t){var n,r=t.within,o=r.isWindow?r.scrollTop:r.offset.top,a=t.within.height,s=e.top-t.collisionPosition.marginTop,u=o-s,l=s+t.collisionHeight-a-o;t.collisionHeight>a?u>0&&l<=0?(n=e.top+u+t.collisionHeight-a-o,e.top+=u-n):e.top=l>0&&u<=0?o:u>l?o+a-t.collisionHeight:o:u>0?e.top+=u:l>0?e.top-=l:e.top=i(e.top-s,e.top)}},flip:{left:function(e,t){var n,r,o=t.within,i=o.offset.left+o.scrollLeft,s=o.width,u=o.isWindow?o.scrollLeft:o.offset.left,l=e.left-t.collisionPosition.marginLeft,c=l-u,f=l+t.collisionWidth-s-u,p="left"===t.my[0]?-t.elemWidth:"right"===t.my[0]?t.elemWidth:0,d="left"===t.at[0]?t.targetWidth:"right"===t.at[0]?-t.targetWidth:0,h=-2*t.offset[0];c<0?((n=e.left+p+d+h+t.collisionWidth-s-i)<0||n0&&((r=e.left-t.collisionPosition.marginLeft+p+d+h-u)>0||a(r)0&&((n=e.top-t.collisionPosition.marginTop+d+h+g-u)>0||a(n)e?0:r.max")[0],h=e.each;d.style.cssText="background-color:rgba(1,1,1,.5)",p.rgba=d.style.backgroundColor.indexOf("rgba")>-1,h(c,function(e,t){t.cache="_"+e,t.props.alpha={idx:3,type:"percent",def:1}}),l.fn=e.extend(l.prototype,{parse:function(o,a,s,u){if(o===t)return this._rgba=[null,null,null,null],this;(o.jquery||o.nodeType)&&(o=e(o).css(a),a=t);var f=this,p=e.type(o),d=this._rgba=[];return a!==t&&(o=[o,a,s,u],p="array"),"string"===p?this.parse(r(o)||i._default):"array"===p?(h(c.rgba.props,function(e,t){d[t.idx]=n(o[t.idx],t)}),this):"object"===p?(o instanceof l?h(c,function(e,t){o[t.cache]&&(f[t.cache]=o[t.cache].slice())}):h(c,function(t,r){var i=r.cache;h(r.props,function(e,t){if(!f[i]&&r.to){if("alpha"===e||null==o[e])return;f[i]=r.to(f._rgba)}f[i][t.idx]=n(o[e],t,!0)}),f[i]&&e.inArray(null,f[i].slice(0,3))<0&&(f[i][3]=1,r.from&&(f._rgba=r.from(f[i])))}),this):t},is:function(e){var t=l(e),n=!0,r=this;return h(c,function(e,o){var i,a=t[o.cache] +;return a&&(i=r[o.cache]||o.to&&o.to(r._rgba)||[],h(o.props,function(e,t){if(null!=a[t.idx])return n=a[t.idx]===i[t.idx]})),n}),n},_space:function(){var e=[],t=this;return h(c,function(n,r){t[r.cache]&&e.push(n)}),e.pop()},transition:function(e,t){var r=l(e),o=r._space(),i=c[o],a=0===this.alpha()?l("transparent"):this,s=a[i.cache]||i.to(a._rgba),u=s.slice();return r=r[i.cache],h(i.props,function(e,o){var i=o.idx,a=s[i],l=r[i],c=f[o.type]||{};null!==l&&(null===a?u[i]=l:(c.mod&&(l-a>c.mod/2?a+=c.mod:a-l>c.mod/2&&(a-=c.mod)),u[i]=n((l-a)*t+a,o)))}),this[o](u)},blend:function(t){if(1===this._rgba[3])return this;var n=this._rgba.slice(),r=n.pop(),o=l(t)._rgba;return l(e.map(n,function(e,t){return(1-r)*o[t]+r*e}))},toRgbaString:function(){var t="rgba(",n=e.map(this._rgba,function(e,t){return null==e?t>2?1:0:e});return 1===n[3]&&(n.pop(),t="rgb("),t+n.join()+")"},toHslaString:function(){var t="hsla(",n=e.map(this.hsla(),function(e,t){return null==e&&(e=t>2?1:0),t&&t<3&&(e=Math.round(100*e)+"%"),e});return 1===n[3]&&(n.pop(),t="hsl("),t+n.join()+")"},toHexString:function(t){var n=this._rgba.slice(),r=n.pop();return t&&n.push(~~(255*r)),"#"+e.map(n,function(e){return e=(e||0).toString(16),1===e.length?"0"+e:e}).join("")},toString:function(){return 0===this._rgba[3]?"transparent":this.toRgbaString()}}),l.fn.parse.prototype=l.fn,c.hsla.to=function(e){if(null==e[0]||null==e[1]||null==e[2])return[null,null,null,e[3]];var t,n,r=e[0]/255,o=e[1]/255,i=e[2]/255,a=e[3],s=Math.max(r,o,i),u=Math.min(r,o,i),l=s-u,c=s+u,f=.5*c;return t=u===s?0:r===s?60*(o-i)/l+360:o===s?60*(i-r)/l+120:60*(r-o)/l+240,n=0===l?0:f<=.5?l/c:l/(2-c),[Math.round(t)%360,n,f,null==a?1:a]},c.hsla.from=function(e){if(null==e[0]||null==e[1]||null==e[2])return[null,null,null,e[3]];var t=e[0]/360,n=e[1],r=e[2],i=e[3],a=r<=.5?r*(1+n):r+n-r*n,s=2*r-a;return[Math.round(255*o(s,a,t+1/3)),Math.round(255*o(s,a,t)),Math.round(255*o(s,a,t-1/3)),i]},h(c,function(r,o){var i=o.props,a=o.cache,u=o.to,c=o.from;l.fn[r]=function(r){if(u&&!this[a]&&(this[a]=u(this._rgba)),r===t)return this[a].slice();var o,s=e.type(r),f="array"===s||"object"===s?r:arguments,p=this[a].slice();return h(i,function(e,t){var r=f["object"===s?e:t.idx];null==r&&(r=p[t.idx]),p[t.idx]=n(r,t)}),c?(o=l(c(p)),o[a]=p,o):l(p)},h(i,function(t,n){l.fn[t]||(l.fn[t]=function(o){var i,a=e.type(o),u="alpha"===t?this._hsla?"hsla":"rgba":r,l=this[u](),c=l[n.idx];return"undefined"===a?c:("function"===a&&(o=o.call(this,c),a=e.type(o)),null==o&&n.empty?this:("string"===a&&(i=s.exec(o))&&(o=c+parseFloat(i[2])*("+"===i[1]?1:-1)),l[n.idx]=o,this[u](l)))})})}),l.hook=function(t){var n=t.split(" ");h(n,function(t,n){e.cssHooks[n]={set:function(t,o){var i,a,s="";if("transparent"!==o&&("string"!==e.type(o)||(i=r(o)))){if(o=l(i||o),!p.rgba&&1!==o._rgba[3]){for(a="backgroundColor"===n?t.parentNode:t;(""===s||"transparent"===s)&&a&&a.style;)try{s=e.css(a,"backgroundColor"),a=a.parentNode}catch(e){}o=o.blend(s&&"transparent"!==s?s:"_default")}o=o.toRgbaString()}try{t.style[n]=o}catch(e){}}},e.fx.step[n]=function(t){ +t.colorInit||(t.start=l(t.elem,n),t.end=l(t.end),t.colorInit=!0),e.cssHooks[n].set(t.elem,t.start.transition(t.end,t.pos))}})},l.hook(a),e.cssHooks.borderColor={expand:function(e){var t={};return h(["Top","Right","Bottom","Left"],function(n,r){t["border"+r+"Color"]=e}),t}},i=e.Color.names={aqua:"#00ffff",black:"#000000",blue:"#0000ff",fuchsia:"#ff00ff",gray:"#808080",green:"#008000",lime:"#00ff00",maroon:"#800000",navy:"#000080",olive:"#808000",purple:"#800080",red:"#ff0000",silver:"#c0c0c0",teal:"#008080",white:"#ffffff",yellow:"#ffff00",transparent:[null,null,null,0],_default:"#ffffff"}}(o),function(){function t(t){var n,r,o=t.ownerDocument.defaultView?t.ownerDocument.defaultView.getComputedStyle(t,null):t.currentStyle,i={};if(o&&o.length&&o[0]&&o[o[0]])for(r=o.length;r--;)n=o[r],"string"==typeof o[n]&&(i[e.camelCase(n)]=o[n]);else for(n in o)"string"==typeof o[n]&&(i[n]=o[n]);return i}function n(t,n){var r,o,a={};for(r in n)o=n[r],t[r]!==o&&(i[r]||!e.fx.step[r]&&isNaN(parseFloat(o))||(a[r]=o));return a}var r=["add","remove","toggle"],i={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};e.each(["borderLeftStyle","borderRightStyle","borderBottomStyle","borderTopStyle"],function(t,n){e.fx.step[n]=function(e){("none"!==e.end&&!e.setAttr||1===e.pos&&!e.setAttr)&&(o.style(e.elem,n,e.end),e.setAttr=!0)}}),e.fn.addBack||(e.fn.addBack=function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}),e.effects.animateClass=function(o,i,a,s){var u=e.speed(i,a,s);return this.queue(function(){var i,a=e(this),s=a.attr("class")||"",l=u.children?a.find("*").addBack():a;l=l.map(function(){return{el:e(this),start:t(this)}}),i=function(){e.each(r,function(e,t){o[t]&&a[t+"Class"](o[t])})},i(),l=l.map(function(){return this.end=t(this.el[0]),this.diff=n(this.start,this.end),this}),a.attr("class",s),l=l.map(function(){var t=this,n=e.Deferred(),r=e.extend({},u,{queue:!1,complete:function(){n.resolve(t)}});return this.el.animate(this.diff,r),n.promise()}),e.when.apply(e,l.get()).done(function(){i(),e.each(arguments,function(){var t=this.el;e.each(this.diff,function(e){t.css(e,"")})}),u.complete.call(a[0])})})},e.fn.extend({addClass:function(t){return function(n,r,o,i){return r?e.effects.animateClass.call(this,{add:n},r,o,i):t.apply(this,arguments)}}(e.fn.addClass),removeClass:function(t){return function(n,r,o,i){return arguments.length>1?e.effects.animateClass.call(this,{remove:n},r,o,i):t.apply(this,arguments)}}(e.fn.removeClass),toggleClass:function(t){return function(n,r,o,i,a){return"boolean"==typeof r||void 0===r?o?e.effects.animateClass.call(this,r?{add:n}:{remove:n},o,i,a):t.apply(this,arguments):e.effects.animateClass.call(this,{toggle:n},r,o,i)}}(e.fn.toggleClass),switchClass:function(t,n,r,o,i){return e.effects.animateClass.call(this,{add:n,remove:t},r,o,i)}})}(),function(){function o(t,n,r,o){return e.isPlainObject(t)&&(n=t,t=t.effect),t={effect:t},null==n&&(n={}),e.isFunction(n)&&(o=n,r=null,n={}),("number"==typeof n||e.fx.speeds[n])&&(o=r,r=n,n={}), +e.isFunction(r)&&(o=r,r=null),n&&e.extend(t,n),r=r||n.duration,t.duration=e.fx.off?0:"number"==typeof r?r:r in e.fx.speeds?e.fx.speeds[r]:e.fx.speeds._default,t.complete=o||n.complete,t}function i(t){return!(t&&"number"!=typeof t&&!e.fx.speeds[t])||("string"==typeof t&&!e.effects.effect[t]||(!!e.isFunction(t)||"object"==typeof t&&!t.effect))}function a(e,t){var n=t.outerWidth(),r=t.outerHeight(),o=/^rect\((-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto)\)$/,i=o.exec(e)||["",0,n,r,0];return{top:parseFloat(i[1])||0,right:"auto"===i[2]?n:parseFloat(i[2]),bottom:"auto"===i[3]?r:parseFloat(i[3]),left:parseFloat(i[4])||0}}e.expr&&e.expr.filters&&e.expr.filters.animated&&(e.expr.filters.animated=function(t){return function(n){return!!e(n).data(r)||t(n)}}(e.expr.filters.animated)),!1!==e.uiBackCompat&&e.extend(e.effects,{save:function(e,n){for(var r=0,o=n.length;r
").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0}),o={width:t.width(),height:t.height()},i=document.activeElement;try{i.id}catch(e){i=document.body}return t.wrap(r),(t[0]===i||e.contains(t[0],i))&&e(i).trigger("focus"),r=t.parent(),"static"===t.css("position")?(r.css({position:"relative"}),t.css({position:"relative"})):(e.extend(n,{position:t.css("position"),zIndex:t.css("z-index")}),e.each(["top","left","bottom","right"],function(e,r){n[r]=t.css(r),isNaN(parseInt(n[r],10))&&(n[r]="auto")}),t.css({position:"relative",top:0,left:0,right:"auto",bottom:"auto"})),t.css(o),r.css(n).show()},removeWrapper:function(t){var n=document.activeElement;return t.parent().is(".ui-effects-wrapper")&&(t.parent().replaceWith(t),(t[0]===n||e.contains(t[0],n))&&e(n).trigger("focus")),t}}),e.extend(e.effects,{version:"1.12.1",define:function(t,n,r){return r||(r=n,n="effect"),e.effects.effect[t]=r,e.effects.effect[t].mode=n,r},scaledDimensions:function(e,t,n){if(0===t)return{height:0,width:0,outerHeight:0,outerWidth:0};var r="horizontal"!==n?(t||100)/100:1,o="vertical"!==n?(t||100)/100:1;return{height:e.height()*o,width:e.width()*r,outerHeight:e.outerHeight()*o,outerWidth:e.outerWidth()*r}},clipToBox:function(e){return{width:e.clip.right-e.clip.left,height:e.clip.bottom-e.clip.top,left:e.clip.left,top:e.clip.top}},unshift:function(e,t,n){var r=e.queue();t>1&&r.splice.apply(r,[1,0].concat(r.splice(t,n))),e.dequeue()},saveStyle:function(e){e.data(n,e[0].style.cssText)},restoreStyle:function(e){e[0].style.cssText=e.data(n)||"",e.removeData(n)},mode:function(e,t){var n=e.is(":hidden");return"toggle"===t&&(t=n?"show":"hide"), +(n?"hide"===t:"show"===t)&&(t="none"),t},getBaseline:function(e,t){var n,r;switch(e[0]){case"top":n=0;break;case"middle":n=.5;break;case"bottom":n=1;break;default:n=e[0]/t.height}switch(e[1]){case"left":r=0;break;case"center":r=.5;break;case"right":r=1;break;default:r=e[1]/t.width}return{x:r,y:n}},createPlaceholder:function(n){var r,o=n.css("position"),i=n.position();return n.css({marginTop:n.css("marginTop"),marginBottom:n.css("marginBottom"),marginLeft:n.css("marginLeft"),marginRight:n.css("marginRight")}).outerWidth(n.outerWidth()).outerHeight(n.outerHeight()),/^(static|relative)/.test(o)&&(o="absolute",r=e("<"+n[0].nodeName+">").insertAfter(n).css({display:/^(inline|ruby)/.test(n.css("display"))?"inline-block":"block",visibility:"hidden",marginTop:n.css("marginTop"),marginBottom:n.css("marginBottom"),marginLeft:n.css("marginLeft"),marginRight:n.css("marginRight"),float:n.css("float")}).outerWidth(n.outerWidth()).outerHeight(n.outerHeight()).addClass("ui-effects-placeholder"),n.data(t+"placeholder",r)),n.css({position:o,left:i.left,top:i.top}),r},removePlaceholder:function(e){var n=t+"placeholder",r=e.data(n);r&&(r.remove(),e.removeData(n))},cleanUp:function(t){e.effects.restoreStyle(t),e.effects.removePlaceholder(t)},setTransition:function(t,n,r,o){return o=o||{},e.each(n,function(e,n){var i=t.cssUnit(n);i[0]>0&&(o[n]=i[0]*r+i[1])}),o}}),e.fn.extend({effect:function(){function t(t){function o(){u.removeData(r),e.effects.cleanUp(u),"hide"===n.mode&&u.hide(),s()}function s(){e.isFunction(l)&&l.call(u[0]),e.isFunction(t)&&t()}var u=e(this);n.mode=f.shift(),!1===e.uiBackCompat||a?"none"===n.mode?(u[c](),s()):i.call(u[0],n,o):(u.is(":hidden")?"hide"===c:"show"===c)?(u[c](),s()):i.call(u[0],n,s)}var n=o.apply(this,arguments),i=e.effects.effect[n.effect],a=i.mode,s=n.queue,u=s||"fx",l=n.complete,c=n.mode,f=[],p=function(t){var n=e(this),o=e.effects.mode(n,c)||a;n.data(r,!0),f.push(o),a&&("show"===o||o===a&&"hide"===o)&&n.show(),a&&"none"===o||e.effects.saveStyle(n),e.isFunction(t)&&t()};return e.fx.off||!i?c?this[c](n.duration,l):this.each(function(){l&&l.call(this)}):!1===s?this.each(p).each(t):this.queue(u,p).queue(u,t)},show:function(e){return function(t){if(i(t))return e.apply(this,arguments);var n=o.apply(this,arguments);return n.mode="show",this.effect.call(this,n)}}(e.fn.show),hide:function(e){return function(t){if(i(t))return e.apply(this,arguments);var n=o.apply(this,arguments);return n.mode="hide",this.effect.call(this,n)}}(e.fn.hide),toggle:function(e){return function(t){if(i(t)||"boolean"==typeof t)return e.apply(this,arguments);var n=o.apply(this,arguments);return n.mode="toggle",this.effect.call(this,n)}}(e.fn.toggle),cssUnit:function(t){var n=this.css(t),r=[];return e.each(["em","px","%","pt"],function(e,t){n.indexOf(t)>0&&(r=[parseFloat(n),t])}),r},cssClip:function(e){return e?this.css("clip","rect("+e.top+"px "+e.right+"px "+e.bottom+"px "+e.left+"px)"):a(this.css("clip"),this)},transfer:function(t,n){ +var r=e(this),o=e(t.to),i="fixed"===o.css("position"),a=e("body"),s=i?a.scrollTop():0,u=i?a.scrollLeft():0,l=o.offset(),c={top:l.top-s,left:l.left-u,height:o.innerHeight(),width:o.innerWidth()},f=r.offset(),p=e("
").appendTo("body").addClass(t.className).css({top:f.top-s,left:f.left-u,height:r.innerHeight(),width:r.innerWidth(),position:i?"fixed":"absolute"}).animate(c,t.duration,t.easing,function(){p.remove(),e.isFunction(n)&&n()})}}),e.fx.step.clip=function(t){t.clipInit||(t.start=e(t.elem).cssClip(),"string"==typeof t.end&&(t.end=a(t.end,t.elem)),t.clipInit=!0),e(t.elem).cssClip({top:t.pos*(t.end.top-t.start.top)+t.start.top,right:t.pos*(t.end.right-t.start.right)+t.start.right,bottom:t.pos*(t.end.bottom-t.start.bottom)+t.start.bottom,left:t.pos*(t.end.left-t.start.left)+t.start.left})}}(),function(){var t={};e.each(["Quad","Cubic","Quart","Quint","Expo"],function(e,n){t[n]=function(t){return Math.pow(t,e+2)}}),e.extend(t,{Sine:function(e){return 1-Math.cos(e*Math.PI/2)},Circ:function(e){return 1-Math.sqrt(1-e*e)},Elastic:function(e){return 0===e||1===e?e:-Math.pow(2,8*(e-1))*Math.sin((80*(e-1)-7.5)*Math.PI/15)},Back:function(e){return e*e*(3*e-2)},Bounce:function(e){for(var t,n=4;e<((t=Math.pow(2,--n))-1)/11;);return 1/Math.pow(4,3-n)-7.5625*Math.pow((3*t-2)/22-e,2)}}),e.each(t,function(t,n){e.easing["easeIn"+t]=n,e.easing["easeOut"+t]=function(e){return 1-n(1-e)},e.easing["easeInOut"+t]=function(e){return e<.5?n(2*e)/2:1-n(-2*e+2)/2}})}(),e.effects})},function(e,t,n){"use strict";!function(e){function t(t){var n,r;"string"==typeof t.data&&(n=t.handler,r=t.data.toLowerCase().split(" "),t.handler=function(t){var o,i,a,s,u,l;if(this===t.target||!/textarea|select/i.test(t.target.nodeName)&&"text"!==t.target.type)for(o="keypress"!==t.type&&e.hotkeys.specialKeys[t.which],i=String.fromCharCode(t.which).toLowerCase(),a="",s={},t.ctrlKey&&"ctrl"!==o&&(a+="ctrl+"),t.altKey&&"alt"!==o&&(a+="alt+"),t.metaKey&&!t.ctrlKey&&"meta"!==o&&(a+="meta+"),t.shiftKey&&"shift"!==o&&(a+="shift+"),o?s[a+o]=!0:(s[a+i]=!0,s[a+e.hotkeys.shiftNums[i]]=!0,"shift+"===a&&(s[e.hotkeys.shiftNums[i]]=!0)),u=0,l=r.length;u","/":"?","\\":"|"}},e.each(["keydown","keyup","keypress"],function(){e.event.special[this]={add:t}})}(jQuery)},function(e,t,n){var r,o,i;!function(n,a){ +"object"==typeof t&&t&&"string"!=typeof t.nodeName?a(t):(o=[t],r=a,void 0!==(i="function"==typeof r?r.apply(t,o):r)&&(e.exports=i))}(0,function(e){function t(e){return"function"==typeof e}function n(e){return m(e)?"array":typeof e}function r(e){return e.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function o(e,t){return null!=e&&"object"==typeof e&&t in e}function i(e,t){return y.call(e,t)}function a(e){return!i(v,e)}function s(e){return(e+"").replace(/[&<>"'`=\/]/g,function(e){return b[e]})}function u(t,n){function o(){if(d&&!h)for(;p.length;)delete u[p.pop()];else p=[];d=!1,h=!1}function i(e){if("string"==typeof e&&(e=e.split(x,2)),!m(e)||2!==e.length)throw Error("Invalid tags: "+e);g=RegExp(r(e[0])+"\\s*"),y=RegExp("\\s*"+r(e[1])),v=RegExp("\\s*"+r("}"+e[1]))}var s,u,p,d,h,g,y,v,b,E,C,S,O,N,P,j,A;if(!t)return[];for(s=[],u=[],p=[],d=!1,h=!1,i(n||e.tags),b=new f(t);!b.eos();){if(E=b.pos,S=b.scanUntil(g))for(j=0,A=S.length;j0?s[s.length-1][4]:i;break;default:a.push(t)}return i}function f(e){this.string=e,this.tail=e,this.pos=0}function p(e,t){this.view=e,this.cache={".":this.view},this.parent=t}function d(){this.cache={}}var h,g=Object.prototype.toString,m=Array.isArray||function(e){return"[object Array]"===g.call(e)},y=RegExp.prototype.test,v=/\S/,b={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/","`":"`","=":"="},w=/\s*/,x=/\s+/,_=/\s*=/,k=/\s*\}/,T=/#|\^|\/|>|\{|&|=|!/;f.prototype.eos=function(){return""===this.tail},f.prototype.scan=function(e){var t,n=this.tail.match(e);return n&&0===n.index?(t=n[0],this.tail=this.tail.substring(t.length),this.pos+=t.length,t):""},f.prototype.scanUntil=function(e){var t,n=this.tail.search(e);switch(n){case-1:t=this.tail,this.tail="";break;case 0:t="";break;default:t=this.tail.substring(0,n),this.tail=this.tail.substring(n)}return this.pos+=t.length,t},p.prototype.push=function(e){return new p(e,this)},p.prototype.lookup=function(e){var n,r,i,a,s,u=this.cache;if(u.hasOwnProperty(e))n=u[e];else{for(r=this,s=!1;r;){if(e.indexOf(".")>0)for(n=r.view,i=e.split("."), +a=0;null!=n&&a"===i?a=this.renderPartial(o,t,n,r):"&"===i?a=this.unescapedValue(o,t):"name"===i?a=this.escapedValue(o,t):"text"===i&&(a=this.rawValue(o)),void 0!==a&&(l+=a);return l},d.prototype.renderSection=function(e,n,r,o){function i(e){return u.render(e,n,r)}var a,s,u=this,l="",c=n.lookup(e[1]);if(c){if(m(c))for(a=0,s=c.length;a "+o.stack+")

"):window.__tv_js_errors.push(e+" (found at "+t+", line "+n+" at time "+a+")"),i)try{i.apply(window,arguments)}catch(e){}}}()},function(e,t,n){var r,o,i;!function(a){o=[n(14)],r=a,void 0!==(i="function"==typeof r?r.apply(t,o):r)&&(e.exports=i)}(function(e){function t(e){return s.raw?e:encodeURIComponent(e)}function n(e){return s.raw?e:decodeURIComponent(e)}function r(e){return t(s.json?JSON.stringify(e):e+"")}function o(e){0===e.indexOf('"')&&(e=e.slice(1,-1).replace(/\\"/g,'"').replace(/\\\\/g,"\\"));try{return e=decodeURIComponent(e.replace(a," ")),s.json?JSON.parse(e):e}catch(e){}}function i(t,n){var r=s.raw?t:o(t);return e.isFunction(n)?n(r):r}var a=/\+/g,s=e.cookie=function(o,a,u){var l,c,f,p,d,h,g,m,y;if(void 0!==a&&!e.isFunction(a))return u=e.extend({},s.defaults,u),"number"==typeof u.expires&&(l=u.expires,c=u.expires=new Date,c.setTime(+c+864e5*l)),document.cookie=t(o)+"="+r(a)+(u.expires?"; expires="+u.expires.toUTCString():"")+(u.path?"; path="+u.path:"")+(u.domain?"; domain="+u.domain:"")+(u.secure?"; secure":"");for(f=o?void 0:{},p=document.cookie?document.cookie.split("; "):[],d=0,h=p.length;d0)return o=e(s.children()[r-1]),u._changeSelectbox(t,o.val(),o.text()),!1;if(40==n&&r",{id:"sbHolder_"+l.uid,class:l.settings.classHolder}),g=s.data("selectbox-css"),g&&c.css(g),f=e("",{id:"sbSelector_"+l.uid,href:"#",class:l.settings.classSelector,click:function(n){n.preventDefault(),n.stopPropagation(),r.apply(e(this),[]);var o=e(this).attr("id").split("_")[1];u._state[o]?u._closeSelectbox(t):(u._openSelectbox(t),p.focus())},keyup:function(e){a(e.keyCode)}}),p=e("",{id:"sbToggle_"+l.uid,href:"#",class:l.settings.classToggle,click:function(n){n.preventDefault(),n.stopPropagation(),r.apply(e(this),[]);var o=e(this).attr("id").split("_")[1];u._state[o]?u._closeSelectbox(t):(u._openSelectbox(t),p.focus())},keyup:function(e){a(e.keyCode)}}),e('
').appendTo(p),p.appendTo(c),d=e("
a",t=f.getElementsByTagName("*"),n=f.getElementsByTagName("a")[0],!t||!t.length||!n)return{};r=bt.createElement("select"),o=r.appendChild(bt.createElement("option")),i=f.getElementsByTagName("input")[0],e={leadingWhitespace:3===f.firstChild.nodeType,tbody:!f.getElementsByTagName("tbody").length,htmlSerialize:!!f.getElementsByTagName("link").length,style:/top/.test(n.getAttribute("style")),hrefNormalized:"/a"===n.getAttribute("href"),opacity:/^0.55/.test(n.style.opacity),cssFloat:!!n.style.cssFloat,checkOn:"on"===i.value,optSelected:o.selected,getSetAttribute:"t"!==f.className,enctype:!!bt.createElement("form").enctype,html5Clone:"<:nav>"!==bt.createElement("nav").cloneNode(!0).outerHTML,submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0,pixelMargin:!0},xt.boxModel=e.boxModel="CSS1Compat"===bt.compatMode,i.checked=!0, -e.noCloneChecked=i.cloneNode(!0).checked,r.disabled=!0,e.optDisabled=!o.disabled;try{delete f.test}catch(t){e.deleteExpando=!1}if(!f.addEventListener&&f.attachEvent&&f.fireEvent&&(f.attachEvent("onclick",function(){e.noCloneEvent=!1}),f.cloneNode(!0).fireEvent("onclick")),i=bt.createElement("input"),i.value="t",i.setAttribute("type","radio"),e.radioValue="t"===i.value,i.setAttribute("checked","checked"),i.setAttribute("name","t"),f.appendChild(i),a=bt.createDocumentFragment(),a.appendChild(f.lastChild),e.checkClone=a.cloneNode(!0).cloneNode(!0).lastChild.checked,e.appendChecked=i.checked,a.removeChild(i),a.appendChild(f),f.attachEvent)for(l in{submit:1,change:1,focusin:1})u="on"+l,c=u in f,c||(f.setAttribute(u,"return;"),c="function"==typeof f[u]),e[l+"Bubbles"]=c;return a.removeChild(f),a=r=o=f=i=null,xt(function(){var t,n,r,o,i,a,u,l,d,p,h,m,g=bt.getElementsByTagName("body")[0];g&&(u=1,m="padding:0;margin:0;border:",p="position:absolute;top:0;left:0;width:1px;height:1px;",h=m+"0;visibility:hidden;",l="style='"+p+m+"5px solid #000;",d="
",t=bt.createElement("div"),t.style.cssText=h+"width:0;height:0;position:static;top:0;margin-top:"+u+"px",g.insertBefore(t,g.firstChild),f=bt.createElement("div"),t.appendChild(f),f.innerHTML="
t
",s=f.getElementsByTagName("td"),c=0===s[0].offsetHeight,s[0].style.display="",s[1].style.display="none",e.reliableHiddenOffsets=c&&0===s[0].offsetHeight,window.getComputedStyle&&(f.innerHTML="",a=bt.createElement("div"),a.style.width="0",a.style.marginRight="0",f.style.width="2px",f.appendChild(a),e.reliableMarginRight=0===(parseInt((window.getComputedStyle(a,null)||{marginRight:0}).marginRight,10)||0)),void 0!==f.style.zoom&&(f.innerHTML="",f.style.width=f.style.padding="1px",f.style.border=0,f.style.overflow="hidden",f.style.display="inline",f.style.zoom=1,e.inlineBlockNeedsLayout=3===f.offsetWidth,f.style.display="block",f.style.overflow="visible",f.innerHTML="
",e.shrinkWrapBlocks=3!==f.offsetWidth),f.style.cssText=p+h,f.innerHTML=d,n=f.firstChild,r=n.firstChild,o=n.nextSibling.firstChild.firstChild,i={doesNotAddBorder:5!==r.offsetTop,doesAddBorderForTableAndCells:5===o.offsetTop},r.style.position="fixed",r.style.top="20px",i.fixedPosition=20===r.offsetTop||15===r.offsetTop,r.style.position=r.style.top="",n.style.overflow="hidden",n.style.position="relative",i.subtractsBorderForOverflowNotVisible=-5===r.offsetTop,i.doesNotIncludeMarginInBodyOffset=g.offsetTop!==u,window.getComputedStyle&&(f.style.marginTop="1%",e.pixelMargin="1%"!==(window.getComputedStyle(f,null)||{marginTop:0}).marginTop),void 0!==t.style.zoom&&(t.style.zoom=1),g.removeChild(t),a=f=t=null,xt.extend(e,i))}),e}(),L=/^(?:\{.*\}|\[.*\])$/,j=/([A-Z])/g,xt.extend({cache:{},uuid:0,expando:"jQuery"+(xt.fn.jquery+Math.random()).replace(/\D/g,""),noData:{embed:!0, -object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(e){return!!(e=e.nodeType?xt.cache[e[xt.expando]]:e[xt.expando])&&!o(e)},data:function(e,t,n,r){if(xt.acceptData(e)){var o,i,a,s=xt.expando,u="string"==typeof t,l=e.nodeType,c=l?xt.cache:e,f=l?e[s]:e[s]&&s,d="events"===t;if(f&&c[f]&&(d||r||c[f].data)||!u||void 0!==n)return f||(l?e[s]=f=++xt.uuid:f=s),c[f]||(c[f]={},l||(c[f].toJSON=xt.noop)),"object"!=typeof t&&"function"!=typeof t||(r?c[f]=xt.extend(c[f],t):c[f].data=xt.extend(c[f].data,t)),o=i=c[f],r||(i.data||(i.data={}),i=i.data),void 0!==n&&(i[xt.camelCase(t)]=n),d&&!i[t]?o.events:(u?null==(a=i[t])&&(a=i[xt.camelCase(t)]):a=i,a)}},removeData:function(e,t,n){if(xt.acceptData(e)){var r,i,a,s=xt.expando,u=e.nodeType,l=u?xt.cache:e,c=u?e[s]:s;if(l[c]){if(t&&(r=n?l[c]:l[c].data)){xt.isArray(t)||(t in r?t=[t]:(t=xt.camelCase(t),t=t in r?[t]:t.split(" ")));for(i=0,a=t.length;i1,null,!1))},removeData:function(e){return this.each(function(){xt.removeData(this,e)})}}),xt.extend({_mark:function(e,t){e&&(t=(t||"fx")+"mark",xt._data(e,t,(xt._data(e,t)||0)+1))},_unmark:function(e,t,n){if(!0!==e&&(n=t,t=e,e=!1),t){n=n||"fx";var r=n+"mark",o=e?0:(xt._data(t,r)||1)-1;o?xt._data(t,r,o):(xt.removeData(t,r,!0),i(t,n,"mark"))}},queue:function(e,t,n){var r;if(e)return t=(t||"fx")+"queue",r=xt._data(e,t),n&&(!r||xt.isArray(n)?r=xt._data(e,t,xt.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||"fx";var n=xt.queue(e,t),r=n.shift(),o={};"inprogress"===r&&(r=n.shift()),r&&("fx"===t&&n.unshift("inprogress"),xt._data(e,t+".run",o),r.call(e,function(){xt.dequeue(e,t)},o)),n.length||(xt.removeData(e,t+"queue "+t+".run",!0),i(e,t,"queue"))}}),xt.fn.extend({queue:function(e,t){var n=2;return"string"!=typeof e&&(t=e,e="fx",n--),arguments.length1)},removeAttr:function(e){return this.each(function(){xt.removeAttr(this,e)})},prop:function(e,t){return xt.access(this,xt.prop,e,t,arguments.length>1)},removeProp:function(e){return e=xt.propFix[e]||e,this.each(function(){try{this[e]=void 0,delete this[e]}catch(e){}})},addClass:function(e){var t,n,r,o,i,a,s;if(xt.isFunction(e))return this.each(function(t){xt(this).addClass(e.call(this,t,this.className))});if(e&&"string"==typeof e)for(t=e.split(F),n=0,r=this.length;n-1)return!0;return!1},val:function(e){var t,n,r,o=this[0];{if(arguments.length)return r=xt.isFunction(e),this.each(function(n){var o,i=xt(this);1===this.nodeType&&(o=r?e.call(this,n,i.val()):e, -null==o?o="":"number"==typeof o?o+="":xt.isArray(o)&&(o=xt.map(o,function(e){return null==e?"":e+""})),(t=xt.valHooks[this.type]||xt.valHooks[this.nodeName.toLowerCase()])&&"set"in t&&void 0!==t.set(this,o,"value")||(this.value=o))});if(o)return(t=xt.valHooks[o.type]||xt.valHooks[o.nodeName.toLowerCase()])&&"get"in t&&void 0!==(n=t.get(o,"value"))?n:(n=o.value,"string"==typeof n?n.replace(R,""):null==n?"":n)}}}),xt.extend({valHooks:{option:{get:function(e){var t=e.attributes.value;return!t||t.specified?e.value:e.text}},select:{get:function(e){var t,n,r,o,i=e.selectedIndex,a=[],s=e.options,u="select-one"===e.type;if(i<0)return null;for(n=u?i:0,r=u?i+1:s.length;n=0}),n.length||(e.selectedIndex=-1),n}}},attrFn:{val:!0,css:!0,html:!0,text:!0,data:!0,width:!0,height:!0,offset:!0},attr:function(e,t,n,r){var o,i,a,s=e.nodeType;if(e&&3!==s&&8!==s&&2!==s)return r&&t in xt.attrFn?xt(e)[t](n):void 0===e.getAttribute?xt.prop(e,t,n):(a=1!==s||!xt.isXMLDoc(e),a&&(t=t.toLowerCase(),i=xt.attrHooks[t]||(W.test(t)?B:z)),void 0!==n?null===n?void xt.removeAttr(e,t):i&&"set"in i&&a&&void 0!==(o=i.set(e,n,t))?o:(e.setAttribute(t,""+n),n):i&&"get"in i&&a&&null!==(o=i.get(e,t))?o:(o=e.getAttribute(t),null===o?void 0:o))},removeAttr:function(e,t){var n,r,o,i,a,s=0;if(t&&1===e.nodeType)for(r=t.toLowerCase().split(F),i=r.length;s=0}})}),q=/^(?:textarea|input|select)$/i,$=/^([^\.]*)?(?:\.(.+))?$/,K=/(?:^|\s)hover(\.\S+)?\b/,G=/^key/,J=/^(?:mouse|contextmenu)|click/,X=/^(?:focusinfocus|focusoutblur)$/,Q=/^(\w*)(?:#([\w\-]+))?(?:\.([\w\-]+))?$/,Z=function(e){var t=Q.exec(e);return t&&(t[1]=(t[1]||"").toLowerCase(),t[3]=t[3]&&RegExp("(?:^|\\s)"+t[3]+"(?:\\s|$)")),t},ee=function(e,t){var n=e.attributes||{};return(!t[1]||e.nodeName.toLowerCase()===t[1])&&(!t[2]||(n.id||{}).value===t[2])&&(!t[3]||t[3].test((n.class||{}).value))},te=function(e){return xt.event.special.hover?e:e.replace(K,"mouseenter$1 mouseleave$1")},xt.event={add:function(e,t,n,r,o){var i,a,s,u,l,c,f,d,p,h,m;if(3!==e.nodeType&&8!==e.nodeType&&t&&n&&(i=xt._data(e))){for(n.handler&&(p=n,n=p.handler,o=p.selector),n.guid||(n.guid=xt.guid++),s=i.events,s||(i.events=s={}),a=i.handle,a||(i.handle=a=function(e){return void 0===xt||e&&xt.event.triggered===e.type?void 0:xt.event.dispatch.apply(a.elem,arguments)},a.elem=e),t=xt.trim(te(t)).split(" "),u=0;u=0&&(h=h.slice(0,-1),i=!0),h.indexOf(".")>=0&&(m=h.split("."),h=m.shift(),m.sort()),n&&!xt.event.customEvent[h]||xt.event.global[h]))if(e="object"==typeof e?e[xt.expando]?e:new xt.Event(h,e):new xt.Event(h),e.type=h,e.isTrigger=!0,e.exclusive=i,e.namespace=m.join("."),e.namespace_re=e.namespace?RegExp("(^|\\.)"+m.join("\\.(?:.*\\.)?")+"(\\.|$)"):null,l=h.indexOf(":")<0?"on"+h:"",n){if(e.result=void 0,e.target||(e.target=n),t=null!=t?xt.makeArray(t):[],t.unshift(e),c=xt.event.special[h]||{},!c.trigger||!1!==c.trigger.apply(n,t)){if(d=[[n,c.bindType||h]],!r&&!c.noBubble&&!xt.isWindow(n)){for(p=c.delegateType||h,s=X.test(p+h)?n:n.parentNode,u=null;s;s=s.parentNode)d.push([s,p]),u=s;u&&u===n.ownerDocument&&d.push([u.defaultView||u.parentWindow||window,p])}for(a=0;ad&&g.push({elem:this,matches:f.slice(d)}),t=0;t0?this.on(t,null,e,n):this.trigger(t)},xt.attrFn&&(xt.attrFn[t]=!0),G.test(t)&&(xt.event.fixHooks[t]=xt.event.keyHooks),J.test(t)&&(xt.event.fixHooks[t]=xt.event.mouseHooks)}),function(){function e(e,t,n,r,o,i){var a,s,u,l;for(a=0,s=r.length;a0){c=l;break}l=l[e]}o[s]=c}}var n,r,o,i,a,s,u,l,c,f,d=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,p="sizcache"+(Math.random()+"").replace(".",""),h=0,m=Object.prototype.toString,g=!1,y=!0,v=/\\/g,b=/\r\n/g,_=/\W/;[0,0].sort(function(){return y=!1,0}),n=function(e,t,r,a){var s,l,c,p,h,g,y,v,b,_,w,x,k;if(r=r||[],t=t||bt,s=t,1!==t.nodeType&&9!==t.nodeType)return[];if(!e||"string"!=typeof e)return r;_=!0,w=n.isXML(t),x=[],k=e;do{if(d.exec(""),(l=d.exec(k))&&(k=l[3],x.push(l[1]),l[2])){h=l[3];break}}while(l) -;if(x.length>1&&i.exec(e))if(2===x.length&&o.relative[x[0]])c=f(x[0]+x[1],t,a);else for(c=o.relative[x[0]]?[t]:n(x.shift(),t);x.length;)e=x.shift(),o.relative[e]&&(e+=x.shift()),c=f(e,c,a);else if(!a&&x.length>1&&9===t.nodeType&&!w&&o.match.ID.test(x[0])&&!o.match.ID.test(x[x.length-1])&&(g=n.find(x.shift(),t,w),t=g.expr?n.filter(g.expr,g.set)[0]:g.set[0]),t)for(g=a?{expr:x.pop(),set:u(a)}:n.find(x.pop(),1!==x.length||"~"!==x[0]&&"+"!==x[0]||!t.parentNode?t:t.parentNode,w),c=g.expr?n.filter(g.expr,g.set):g.set,x.length>0?p=u(c):_=!1;x.length;)y=x.pop(),v=y,o.relative[y]?v=x.pop():y="",null==v&&(v=t),o.relative[y](p,v,w);else p=x=[];if(p||(p=c),p||n.error(y||e),"[object Array]"===m.call(p))if(_)if(t&&1===t.nodeType)for(b=0;null!=p[b];b++)p[b]&&(!0===p[b]||1===p[b].nodeType&&n.contains(t,p[b]))&&r.push(c[b]);else for(b=0;null!=p[b];b++)p[b]&&1===p[b].nodeType&&r.push(c[b]);else r.push.apply(r,p);else u(p,r);return h&&(n(h,s,r,a),n.uniqueSort(r)),r},n.uniqueSort=function(e){if(l&&(g=y,e.sort(l),g))for(var t=1;t0},n.find=function(e,t,n){var r,i,a,s,u,l;if(!e)return[];for(i=0,a=o.order.length;i":function(e,t){var r,o,i="string"==typeof t,a=0,s=e.length;if(i&&!_.test(t))for(t=t.toLowerCase();a=0)?n||r.push(a):n&&(t[s]=!1));return!1},ID:function(e){return e[1].replace(v,"")},TAG:function(e,t){return e[1].replace(v,"").toLowerCase()},CHILD:function(e){if("nth"===e[1]){e[2]||n.error(e[0]),e[2]=e[2].replace(/^\+|\s*/g,"");var t=/(-?)(\d*)(?:n([+\-]?\d*))?/.exec("even"===e[2]&&"2n"||"odd"===e[2]&&"2n+1"||!/\D/.test(e[2])&&"0n+"+e[2]||e[2]);e[2]=t[1]+(t[2]||1)-0,e[3]=t[3]-0}else e[2]&&n.error(e[0]);return e[0]=h++,e},ATTR:function(e,t,n,r,i,a){var s=e[1]=e[1].replace(v,"");return!a&&o.attrMap[s]&&(e[1]=o.attrMap[s]),e[4]=(e[4]||e[5]||"").replace(v,""),"~="===e[2]&&(e[4]=" "+e[4]+" "),e},PSEUDO:function(e,t,r,i,a){if("not"===e[1]){if(!((d.exec(e[3])||"").length>1||/^\w/.test(e[3]))){var s=n.filter(e[3],t,r,!0^a);return r||i.push.apply(i,s),!1}e[3]=n(e[3],null,null,t)}else if(o.match.POS.test(e[0])||o.match.CHILD.test(e[0]))return!0;return e},POS:function(e){return e.unshift(!0),e}},filters:{enabled:function(e){return!1===e.disabled&&"hidden"!==e.type},disabled:function(e){return!0===e.disabled},checked:function(e){return!0===e.checked},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,!0===e.selected},parent:function(e){return!!e.firstChild},empty:function(e){return!e.firstChild},has:function(e,t,r){return!!n(r[3],e).length},header:function(e){return/h\d/i.test(e.nodeName)},text:function(e){var t=e.getAttribute("type"),n=e.type -;return"input"===e.nodeName.toLowerCase()&&"text"===n&&(t===n||null===t)},radio:function(e){return"input"===e.nodeName.toLowerCase()&&"radio"===e.type},checkbox:function(e){return"input"===e.nodeName.toLowerCase()&&"checkbox"===e.type},file:function(e){return"input"===e.nodeName.toLowerCase()&&"file"===e.type},password:function(e){return"input"===e.nodeName.toLowerCase()&&"password"===e.type},submit:function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&"submit"===e.type},image:function(e){return"input"===e.nodeName.toLowerCase()&&"image"===e.type},reset:function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&"reset"===e.type},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},input:function(e){return/input|select|textarea|button/i.test(e.nodeName)},focus:function(e){return e===e.ownerDocument.activeElement}},setFilters:{first:function(e,t){return 0===t},last:function(e,t,n,r){return t===r.length-1},even:function(e,t){return t%2==0},odd:function(e,t){return t%2==1},lt:function(e,t,n){return tn[3]-0},nth:function(e,t,n){return n[3]-0===t},eq:function(e,t,n){return n[3]-0===t}},filter:{PSEUDO:function(e,t,i,a){var s,u,l,c=t[1],f=o.filters[c];if(f)return f(e,i,t,a);if("contains"===c)return(e.textContent||e.innerText||r([e])||"").indexOf(t[3])>=0;if("not"===c){for(s=t[3],u=0,l=s.length;u=0}},ID:function(e,t){return 1===e.nodeType&&e.getAttribute("id")===t},TAG:function(e,t){return"*"===t&&1===e.nodeType||!!e.nodeName&&e.nodeName.toLowerCase()===t},CLASS:function(e,t){return(" "+(e.className||e.getAttribute("class"))+" ").indexOf(t)>-1},ATTR:function(e,t){var r=t[1],i=n.attr?n.attr(e,r):o.attrHandle[r]?o.attrHandle[r](e):null!=e[r]?e[r]:e.getAttribute(r),a=i+"",s=t[2],u=t[4];return null==i?"!="===s:!s&&n.attr?null!=i:"="===s?a===u:"*="===s?a.indexOf(u)>=0:"~="===s?(" "+a+" ").indexOf(u)>=0:u?"!="===s?a!==u:"^="===s?0===a.indexOf(u):"$="===s?a.substr(a.length-u.length)===u:"|="===s&&(a===u||a.substr(0,u.length+1)===u+"-"):a&&!1!==i},POS:function(e,t,n,r){var i=t[2],a=o.setFilters[i];if(a)return a(e,n,t,r)}}},i=o.match.POS,a=function(e,t){return"\\"+(t-0+1)};for(s in o.match)o.match[s]=RegExp(o.match[s].source+/(?![^\[]*\])(?![^\(]*\))/.source),o.leftMatch[s]=RegExp(/(^(?:.|\r|\n)*?)/.source+o.match[s].source.replace(/\\(\d+)/g,a));o.match.globalPOS=i,u=function(e,t){return e=Array.prototype.slice.call(e,0),t?(t.push.apply(t,e),t):e};try{ -Array.prototype.slice.call(bt.documentElement.childNodes,0)[0].nodeType}catch(e){u=function(e,t){var n,r=0,o=t||[];if("[object Array]"===m.call(e))Array.prototype.push.apply(o,e);else if("number"==typeof e.length)for(n=e.length;r",n.insertBefore(e,n.firstChild),bt.getElementById(t)&&(o.find.ID=function(e,t,n){if(void 0!==t.getElementById&&!n){var r=t.getElementById(e[1]);return r?r.id===e[1]||void 0!==r.getAttributeNode&&r.getAttributeNode("id").nodeValue===e[1]?[r]:void 0:[]}},o.filter.ID=function(e,t){var n=void 0!==e.getAttributeNode&&e.getAttributeNode("id");return 1===e.nodeType&&n&&n.nodeValue===t}),n.removeChild(e),n=e=null}(),function(){var e=bt.createElement("div");e.appendChild(bt.createComment("")),e.getElementsByTagName("*").length>0&&(o.find.TAG=function(e,t){var n,r,o=t.getElementsByTagName(e[1]);if("*"===e[1]){for(n=[],r=0;o[r];r++)1===o[r].nodeType&&n.push(o[r]);o=n}return o}),e.innerHTML="",e.firstChild&&void 0!==e.firstChild.getAttribute&&"#"!==e.firstChild.getAttribute("href")&&(o.attrHandle.href=function(e){return e.getAttribute("href",2)}),e=null}(),bt.querySelectorAll&&function(){var e,t=n,r=bt.createElement("div");if(r.innerHTML="

",!r.querySelectorAll||0!==r.querySelectorAll(".TEST").length){n=function(e,r,i,a){var s,l,c,f,d,p,h;if(r=r||bt,!a&&!n.isXML(r)){if((s=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(e))&&(1===r.nodeType||9===r.nodeType)){if(s[1])return u(r.getElementsByTagName(e),i);if(s[2]&&o.find.CLASS&&r.getElementsByClassName)return u(r.getElementsByClassName(s[2]),i)}if(9===r.nodeType){if("body"===e&&r.body)return u([r.body],i);if(s&&s[3]){if(!(l=r.getElementById(s[3]))||!l.parentNode)return u([],i);if(l.id===s[3])return u([l],i)}try{return u(r.querySelectorAll(e),i)}catch(e){}}else if(1===r.nodeType&&"object"!==r.nodeName.toLowerCase()){c=r,f=r.getAttribute("id"),d=f||"__sizzle__",p=r.parentNode,h=/^\s*[+~]/.test(e),f?d=d.replace(/'/g,"\\$&"):r.setAttribute("id",d),h&&p&&(r=r.parentNode);try{if(!h||p)return u(r.querySelectorAll("[id='"+d+"'] "+e),i)}catch(e){}finally{f||c.removeAttribute("id")}}}return t(e,r,i,a)};for(e in t)n[e]=t[e];r=null}}(), -function(){var e,t,r=bt.documentElement,i=r.matchesSelector||r.mozMatchesSelector||r.webkitMatchesSelector||r.msMatchesSelector;if(i){e=!i.call(bt.createElement("div"),"div"),t=!1;try{i.call(bt.documentElement,"[test!='']:sizzle")}catch(e){t=!0}n.matchesSelector=function(r,a){if(a=a.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']"),!n.isXML(r))try{if(t||!o.match.PSEUDO.test(a)&&!/!=/.test(a)){var s=i.call(r,a);if(s||!e||r.document&&11!==r.document.nodeType)return s}}catch(e){}return n(a,null,null,[r]).length>0}}}(),function(){var e=bt.createElement("div");e.innerHTML="
",e.getElementsByClassName&&0!==e.getElementsByClassName("e").length&&(e.lastChild.className="e",1!==e.getElementsByClassName("e").length&&(o.order.splice(1,0,"CLASS"),o.find.CLASS=function(e,t,n){if(void 0!==t.getElementsByClassName&&!n)return t.getElementsByClassName(e[1])},e=null))}(),bt.documentElement.contains?n.contains=function(e,t){return e!==t&&(!e.contains||e.contains(t))}:bt.documentElement.compareDocumentPosition?n.contains=function(e,t){return!!(16&e.compareDocumentPosition(t))}:n.contains=function(){return!1},n.isXML=function(e){var t=(e?e.ownerDocument||e:0).documentElement;return!!t&&"HTML"!==t.nodeName},f=function(e,t,r){for(var i,a,s,u=[],l="",c=t.nodeType?[t]:t;i=o.match.PSEUDO.exec(e);)l+=i[0],e=e.replace(o.match.PSEUDO,"");for(e=o.relative[e]?e+"*":e,a=0,s=c.length;a0)for(i=o;i=0:xt.filter(e,this).length>0:this.filter(e).length>0)},closest:function(e,t){var n,r,o,i,a=[],s=this[0];if(xt.isArray(e)){for(o=1;s&&s.ownerDocument&&s!==t;){for(n=0;n-1:xt.find.matchesSelector(s,e)){a.push(s);break}if(!(s=s.parentNode)||!s.ownerDocument||s===t||11===s.nodeType)break}return a=a.length>1?xt.unique(a):a, -this.pushStack(a,"closest",e)},index:function(e){return e?"string"==typeof e?xt.inArray(this[0],xt(e)):xt.inArray(e.jquery?e[0]:e,this):this[0]&&this[0].parentNode?this.prevAll().length:-1},add:function(e,t){var n="string"==typeof e?xt(e,t):xt.makeArray(e&&e.nodeType?[e]:e),r=xt.merge(this.get(),n);return this.pushStack(u(n[0])||u(r[0])?r:xt.unique(r))},andSelf:function(){return this.add(this.prevObject)}}),xt.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return xt.dir(e,"parentNode")},parentsUntil:function(e,t,n){return xt.dir(e,"parentNode",n)},next:function(e){return xt.nth(e,2,"nextSibling")},prev:function(e){return xt.nth(e,2,"previousSibling")},nextAll:function(e){return xt.dir(e,"nextSibling")},prevAll:function(e){return xt.dir(e,"previousSibling")},nextUntil:function(e,t,n){return xt.dir(e,"nextSibling",n)},prevUntil:function(e,t,n){return xt.dir(e,"previousSibling",n)},siblings:function(e){return xt.sibling((e.parentNode||{}).firstChild,e)},children:function(e){return xt.sibling(e.firstChild)},contents:function(e){return xt.nodeName(e,"iframe")?e.contentDocument||e.contentWindow.document:xt.makeArray(e.childNodes)}},function(e,t){xt.fn[e]=function(n,r){var o=xt.map(this,t,n);return ne.test(e)||(r=n),r&&"string"==typeof r&&(o=xt.filter(r,o)),o=this.length>1&&!ue[e]?xt.unique(o):o,(this.length>1||oe.test(r))&&re.test(e)&&(o=o.reverse()),this.pushStack(o,e,ae.call(arguments).join(","))}}),xt.extend({filter:function(e,t,n){return n&&(e=":not("+e+")"),1===t.length?xt.find.matchesSelector(t[0],e)?[t[0]]:[]:xt.find.matches(e,t)},dir:function(e,t,n){for(var r=[],o=e[t];o&&9!==o.nodeType&&(void 0===n||1!==o.nodeType||!xt(o).is(n));)1===o.nodeType&&r.push(o),o=o[t];return r},nth:function(e,t,n,r){t=t||1;for(var o=0;e&&(1!==e.nodeType||++o!==t);e=e[n]);return e},sibling:function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n}}),le="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",ce=/ jQuery\d+="(?:\d+|null)"/g,fe=/^\s+/,de=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,pe=/<([\w:]+)/,he=/
","
"],tr:[2,"","
"],td:[3,"","
"],col:[2,"","
"],area:[1,"",""],_default:[0,"",""]},ke=c(bt),xe.optgroup=xe.option,xe.tbody=xe.tfoot=xe.colgroup=xe.caption=xe.thead,xe.th=xe.td,xt.support.htmlSerialize||(xe._default=[1,"div
","
"]),xt.fn.extend({text:function(e){return xt.access(this,function(e){ -return void 0===e?xt.text(this):this.empty().append((this[0]&&this[0].ownerDocument||bt).createTextNode(e))},null,e,arguments.length)},wrapAll:function(e){if(xt.isFunction(e))return this.each(function(t){xt(this).wrapAll(e.call(this,t))});if(this[0]){var t=xt(e,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){for(var e=this;e.firstChild&&1===e.firstChild.nodeType;)e=e.firstChild;return e}).append(this)}return this},wrapInner:function(e){return xt.isFunction(e)?this.each(function(t){xt(this).wrapInner(e.call(this,t))}):this.each(function(){var t=xt(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=xt.isFunction(e);return this.each(function(n){xt(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(){return this.parent().each(function(){xt.nodeName(this,"body")||xt(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(e){1===this.nodeType&&this.appendChild(e)})},prepend:function(){return this.domManip(arguments,!0,function(e){1===this.nodeType&&this.insertBefore(e,this.firstChild)})},before:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(e){this.parentNode.insertBefore(e,this)});if(arguments.length){var e=xt.clean(arguments);return e.push.apply(e,this.toArray()),this.pushStack(e,"before",arguments)}},after:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(e){this.parentNode.insertBefore(e,this.nextSibling)});if(arguments.length){var e=this.pushStack(this,"after",arguments);return e.push.apply(e,xt.clean(arguments)),e}},remove:function(e,t){for(var n,r=0;null!=(n=this[r]);r++)e&&!xt.filter(e,[n]).length||(t||1!==n.nodeType||(xt.cleanData(n.getElementsByTagName("*")),xt.cleanData([n])),n.parentNode&&n.parentNode.removeChild(n));return this},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)for(1===e.nodeType&&xt.cleanData(e.getElementsByTagName("*"));e.firstChild;)e.removeChild(e.firstChild);return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return xt.clone(this,e,t)})},html:function(e){return xt.access(this,function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e)return 1===t.nodeType?t.innerHTML.replace(ce,""):null;if("string"==typeof e&&!ge.test(e)&&(xt.support.leadingWhitespace||!fe.test(e))&&!xe[(pe.exec(e)||["",""])[1].toLowerCase()]){e=e.replace(de,"<$1>");try{for(;n1&&s0?this.clone(!0):this).get(),xt(s[r])[t](i),a=a.concat(i);return this.pushStack(a,e,s.selector)}}),xt.extend({clone:function(e,t,n){var r,o,i,a=xt.support.html5Clone||xt.isXMLDoc(e)||!ve.test("<"+e.nodeName+">")?e.cloneNode(!0):y(e);if(!(xt.support.noCloneEvent&&xt.support.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||xt.isXMLDoc(e)))for(p(e,a),r=h(e),o=h(a),i=0;r[i];++i)o[i]&&p(r[i],o[i]);if(t&&(d(e,a),n))for(r=h(e),o=h(a),i=0;r[i];++i)d(r[i],o[i]);return r=o=null,a},clean:function(e,t,n,r){var o,i,a,s,u,l,f,d,p,h,m,y,v,b,_,w=[];for(t=t||bt,void 0===t.createElement&&(t=t.ownerDocument||t[0]&&t[0].ownerDocument||bt),s=0;null!=(u=e[s]);s++)if("number"==typeof u&&(u+=""),u){if("string"==typeof u)if(me.test(u)){for(u=u.replace(de,"<$1>"),l=(pe.exec(u)||["",""])[1].toLowerCase(),f=xe[l]||xe._default,d=f[0],p=t.createElement("div"),h=ke.childNodes,t===bt?ke.appendChild(p):c(t).appendChild(p),p.innerHTML=f[1]+u+f[2];d--;)p=p.lastChild;if(!xt.support.tbody)for(y=he.test(u),v="table"!==l||y?""!==f[1]||y?[]:p.childNodes:p.firstChild&&p.firstChild.childNodes,a=v.length-1;a>=0;--a)xt.nodeName(v[a],"tbody")&&!v[a].childNodes.length&&v[a].parentNode.removeChild(v[a]);!xt.support.leadingWhitespace&&fe.test(u)&&p.insertBefore(t.createTextNode(fe.exec(u)[0]),p.firstChild),u=p.childNodes,p&&(p.parentNode.removeChild(p), -h.length>0&&(m=h[h.length-1])&&m.parentNode&&m.parentNode.removeChild(m))}else u=t.createTextNode(u);if(!xt.support.appendChecked)if(u[0]&&"number"==typeof(b=u.length))for(a=0;a1)},xt.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Le(e,"opacity");return""===n?"1":n}return e.style.opacity}}},cssNumber:{fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{float:xt.support.cssFloat?"cssFloat":"styleFloat"},style:function(e,t,n,r){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var o,i,a=xt.camelCase(t),s=e.style,u=xt.cssHooks[a];if(t=xt.cssProps[a]||a,void 0===n)return u&&"get"in u&&void 0!==(o=u.get(e,!1,r))?o:s[t];if(!(i=typeof n,"string"===i&&(o=Oe.exec(n))&&(n=+(o[1]+1)*+o[2]+parseFloat(xt.css(e,t)),i="number"),null==n||"number"===i&&isNaN(n)||("number"!==i||xt.cssNumber[a]||(n+="px"),u&&"set"in u&&void 0===(n=u.set(e,n)))))try{s[t]=n}catch(e){}}},css:function(e,t,n){var r,o;return t=xt.camelCase(t),o=xt.cssHooks[t],t=xt.cssProps[t]||t,"cssFloat"===t&&(t="float"),o&&"get"in o&&void 0!==(r=o.get(e,!0,n))?r:Le?Le(e,t):void 0},swap:function(e,t,n){var r,o,i={};for(o in t)i[o]=e.style[o],e.style[o]=t[o];r=n.call(e);for(o in t)e.style[o]=i[o];return r}}),xt.curCSS=xt.css,bt.defaultView&&bt.defaultView.getComputedStyle&&(je=function(e,t){var n,r,o,i,a=e.style;return t=t.replace(Ce,"-$1").toLowerCase(),(r=e.ownerDocument.defaultView)&&(o=r.getComputedStyle(e,null))&&(""!==(n=o.getPropertyValue(t))||xt.contains(e.ownerDocument.documentElement,e)||(n=xt.style(e,t))),!xt.support.pixelMargin&&o&&De.test(t)&&Me.test(n)&&(i=a.width,a.width=n,n=o.width,a.width=i),n}),bt.documentElement.currentStyle&&(Ae=function(e,t){var n,r,o,i=e.currentStyle&&e.currentStyle[t],a=e.style;return null==i&&a&&(o=a[t])&&(i=o),Me.test(i)&&(n=a.left,r=e.runtimeStyle&&e.runtimeStyle.left,r&&(e.runtimeStyle.left=e.currentStyle.left), -a.left="fontSize"===t?"1em":i,i=a.pixelLeft+"px",a.left=n,r&&(e.runtimeStyle.left=r)),""===i?"auto":i}),Le=je||Ae,xt.each(["height","width"],function(e,t){xt.cssHooks[t]={get:function(e,n,r){if(n)return 0!==e.offsetWidth?v(e,t,r):xt.swap(e,Ne,function(){return v(e,t,r)})},set:function(e,t){return Ee.test(t)?t+"px":t}}}),xt.support.opacity||(xt.cssHooks.opacity={get:function(e,t){return Se.test((t&&e.currentStyle?e.currentStyle.filter:e.style.filter)||"")?parseFloat(RegExp.$1)/100+"":t?"1":""},set:function(e,t){var n=e.style,r=e.currentStyle,o=xt.isNumeric(t)?"alpha(opacity="+100*t+")":"",i=r&&r.filter||n.filter||"";n.zoom=1,t>=1&&""===xt.trim(i.replace(Te,""))&&(n.removeAttribute("filter"),r&&!r.filter)||(n.filter=Te.test(i)?i.replace(Te,o):i+" "+o)}}),xt(function(){xt.support.reliableMarginRight||(xt.cssHooks.marginRight={get:function(e,t){return xt.swap(e,{display:"inline-block"},function(){return t?Le(e,"margin-right"):e.style.marginRight})}})}),xt.expr&&xt.expr.filters&&(xt.expr.filters.hidden=function(e){var t=e.offsetWidth,n=e.offsetHeight;return 0===t&&0===n||!xt.support.reliableHiddenOffsets&&"none"===(e.style&&e.style.display||xt.css(e,"display"))},xt.expr.filters.visible=function(e){return!xt.expr.filters.hidden(e)}),xt.each({margin:"",padding:"",border:"Width"},function(e,t){xt.cssHooks[e+t]={expand:function(n){var r,o="string"==typeof n?n.split(" "):[n],i={};for(r=0;r<4;r++)i[e+Pe[r]+t]=o[r]||o[r-2]||o[0];return i}}}),Fe=/%20/g,Re=/\[\]$/,Ie=/\r?\n/g,He=/#.*$/,Ye=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,We=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,Ue=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,ze=/^(?:GET|HEAD)$/,Be=/^\/\//,Ve=/\?/,qe=/)<[^<]*)*<\/script>/gi,$e=/^(?:select|textarea)/i,Ke=/\s+/,Ge=/([?&])_=[^&]*/,Je=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,Xe=xt.fn.load,Qe={},Ze={},nt="*/*";try{et=wt.href}catch(e){et=bt.createElement("a"),et.href="",et=et.href}tt=Je.exec(et.toLowerCase())||[],xt.fn.extend({load:function(e,t,n){var r,o,i,a;return"string"!=typeof e&&Xe?Xe.apply(this,arguments):this.length?(r=e.indexOf(" "),r>=0&&(o=e.slice(r,e.length),e=e.slice(0,r)),i="GET",t&&(xt.isFunction(t)?(n=t,t=void 0):"object"==typeof t&&(t=xt.param(t,xt.ajaxSettings.traditional),i="POST")),a=this,xt.ajax({url:e,type:i,dataType:"html",data:t,complete:function(e,t,r){r=e.responseText,e.isResolved()&&(e.done(function(e){r=e}),a.html(o?xt("
").append(r.replace(qe,"")).find(o):r)),n&&a.each(n,[r,t,e])}}),this):this},serialize:function(){return xt.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?xt.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||$e.test(this.nodeName)||We.test(this.type))}).map(function(e,t){var n=xt(this).val();return null==n?null:xt.isArray(n)?xt.map(n,function(e,n){return{name:t.name,value:e.replace(Ie,"\r\n")}}):{name:t.name,value:n.replace(Ie,"\r\n")}}).get()}}), -xt.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(e,t){xt.fn[t]=function(e){return this.on(t,e)}}),xt.each(["get","post"],function(e,t){xt[t]=function(e,n,r,o){return xt.isFunction(n)&&(o=o||r,r=n,n=void 0),xt.ajax({type:t,url:e,data:n,success:r,dataType:o})}}),xt.extend({getScript:function(e,t){return xt.get(e,void 0,t,"script")},getJSON:function(e,t,n){return xt.get(e,t,n,"json")},ajaxSetup:function(e,t){return t?w(e,xt.ajaxSettings):(t=e,e=xt.ajaxSettings),w(e,t),e},ajaxSettings:{url:et,isLocal:Ue.test(tt[1]),global:!0,type:"GET",contentType:"application/x-www-form-urlencoded; charset=UTF-8",processData:!0,async:!0,accepts:{xml:"application/xml, text/xml",html:"text/html",text:"text/plain",json:"application/json, text/javascript","*":nt},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText"},converters:{"* text":window.String,"text html":!0,"text json":xt.parseJSON,"text xml":xt.parseXML},flatOptions:{context:!0,url:!0}},ajaxPrefilter:b(Qe),ajaxTransport:b(Ze),ajax:function(e,t){function n(e,t,n,c){if(2!==y){y=2,m&&clearTimeout(m),h=void 0,d=c||"",w.readyState=e>0?4:0;var f,p,g,b,_,x=t,S=n?k(r,w,n):void 0;if(e>=200&&e<300||304===e)if(r.ifModified&&((b=w.getResponseHeader("Last-Modified"))&&(xt.lastModified[l]=b),(_=w.getResponseHeader("Etag"))&&(xt.etag[l]=_)),304===e)x="notmodified",f=!0;else try{p=T(r,S),x="success",f=!0}catch(e){x="parsererror",g=e}else g=x,x&&!e||(x="error",e<0&&(e=0));w.status=e,w.statusText=""+(t||x),f?a.resolveWith(o,[p,x,w]):a.rejectWith(o,[w,x,g]),w.statusCode(u),u=void 0,v&&i.trigger("ajax"+(f?"Success":"Error"),[w,r,f?p:g]),s.fireWith(o,[w,x]),v&&(i.trigger("ajaxComplete",[w,r]),--xt.active||xt.event.trigger("ajaxStop"))}}var r,o,i,a,s,u,l,c,f,d,p,h,m,g,y,v,b,w,x,S;if("object"==typeof e&&(t=e,e=void 0),t=t||{},r=xt.ajaxSetup({},t),o=r.context||r,i=o!==r&&(o.nodeType||o instanceof xt)?xt(o):xt.event,a=xt.Deferred(),s=xt.Callbacks("once memory"),u=r.statusCode||{},c={},f={},y=0,w={readyState:0,setRequestHeader:function(e,t){if(!y){var n=e.toLowerCase();e=f[n]=f[n]||e,c[e]=t}return this},getAllResponseHeaders:function(){return 2===y?d:null},getResponseHeader:function(e){var t;if(2===y){if(!p)for(p={};t=Ye.exec(d);)p[t[1].toLowerCase()]=t[2];t=p[e.toLowerCase()]}return void 0===t?null:t},overrideMimeType:function(e){return y||(r.mimeType=e),this},abort:function(e){return e=e||"abort",h&&h.abort(e),n(0,e),this}},a.promise(w),w.success=w.done,w.error=w.fail,w.complete=s.add,w.statusCode=function(e){if(e){var t;if(y<2)for(t in e)u[t]=[u[t],e[t]];else t=e[w.status],w.then(t,t)}return this},r.url=((e||r.url)+"").replace(He,"").replace(Be,tt[1]+"//"),r.dataTypes=xt.trim(r.dataType||"*").toLowerCase().split(Ke),null==r.crossDomain&&(g=Je.exec(r.url.toLowerCase()),r.crossDomain=!(!g||g[1]==tt[1]&&g[2]==tt[2]&&(g[3]||("http:"===g[1]?80:443))==(tt[3]||("http:"===tt[1]?80:443)))),r.data&&r.processData&&"string"!=typeof r.data&&(r.data=xt.param(r.data,r.traditional)),_(Qe,r,t,w),2===y)return!1;v=r.global, -r.type=r.type.toUpperCase(),r.hasContent=!ze.test(r.type),v&&0==xt.active++&&xt.event.trigger("ajaxStart"),r.hasContent||(r.data&&(r.url+=(Ve.test(r.url)?"&":"?")+r.data,delete r.data),l=r.url,!1===r.cache&&(x=xt.now(),S=r.url.replace(Ge,"$1_="+x),r.url=S+(S===r.url?(Ve.test(r.url)?"&":"?")+"_="+x:""))),(r.data&&r.hasContent&&!1!==r.contentType||t.contentType)&&w.setRequestHeader("Content-Type",r.contentType),r.ifModified&&(l=l||r.url,xt.lastModified[l]&&w.setRequestHeader("If-Modified-Since",xt.lastModified[l]),xt.etag[l]&&w.setRequestHeader("If-None-Match",xt.etag[l])),w.setRequestHeader("Accept",r.dataTypes[0]&&r.accepts[r.dataTypes[0]]?r.accepts[r.dataTypes[0]]+("*"!==r.dataTypes[0]?", "+nt+"; q=0.01":""):r.accepts["*"]);for(b in r.headers)w.setRequestHeader(b,r.headers[b]);if(r.beforeSend&&(!1===r.beforeSend.call(o,w,r)||2===y))return w.abort(),!1;for(b in{success:1,error:1,complete:1})w[b](r[b]);if(h=_(Ze,r,t,w)){w.readyState=1,v&&i.trigger("ajaxSend",[w,r]),r.async&&r.timeout>0&&(m=setTimeout(function(){w.abort("timeout")},r.timeout));try{y=1,h.send(c,n)}catch(e){if(!(y<2))throw e;n(-1,e)}}else n(-1,"No Transport");return w},param:function(e,t){var n,r=[],o=function(e,t){t=xt.isFunction(t)?t():t,r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(t)};if(void 0===t&&(t=xt.ajaxSettings.traditional),xt.isArray(e)||e.jquery&&!xt.isPlainObject(e))xt.each(e,function(){o(this.name,this.value)});else for(n in e)x(n,e[n],t,o);return r.join("&").replace(Fe,"+")}}),xt.extend({active:0,lastModified:{},etag:{}}),rt=xt.now(),ot=/(\=)\?(&|$)|\?\?/i,xt.ajaxSetup({jsonp:"callback",jsonpCallback:function(){return xt.expando+"_"+rt++}}),xt.ajaxPrefilter("json jsonp",function(e,t,n){var r,o,i,a,s,u,l="string"==typeof e.data&&/^application\/x\-www\-form\-urlencoded/.test(e.contentType);if("jsonp"===e.dataTypes[0]||!1!==e.jsonp&&(ot.test(e.url)||l&&ot.test(e.data)))return o=e.jsonpCallback=xt.isFunction(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,i=window[o],a=e.url,s=e.data,u="$1"+o+"$2",!1!==e.jsonp&&(a=a.replace(ot,u),e.url===a&&(l&&(s=s.replace(ot,u)),e.data===s&&(a+=(/\?/.test(a)?"&":"?")+e.jsonp+"="+o))),e.url=a,e.data=s,window[o]=function(e){r=[e]},n.always(function(){window[o]=i,r&&xt.isFunction(i)&&window[o](r[0])}),e.converters["script json"]=function(){return r||xt.error(o+" was not called"),r[0]},e.dataTypes[0]="json","script"}),xt.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/javascript|ecmascript/},converters:{"text script":function(e){return xt.globalEval(e),e}}}),xt.ajaxPrefilter("script",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET",e.global=!1)}),xt.ajaxTransport("script",function(e){if(e.crossDomain){var t,n=bt.head||bt.getElementsByTagName("head")[0]||bt.documentElement;return{send:function(r,o){t=bt.createElement("script"),t.async="async",e.scriptCharset&&(t.charset=e.scriptCharset),t.src=e.url,t.onload=t.onreadystatechange=function(e,r){ -(r||!t.readyState||/loaded|complete/.test(t.readyState))&&(t.onload=t.onreadystatechange=null,n&&t.parentNode&&n.removeChild(t),t=void 0,r||o(200,"success"))},n.insertBefore(t,n.firstChild)},abort:function(){t&&t.onload(0,1)}}}}),it=!!window.ActiveXObject&&function(){for(var e in st)st[e](0,1)},at=0,xt.ajaxSettings.xhr=window.ActiveXObject?function(){return!this.isLocal&&S()||C()}:S,function(e){xt.extend(xt.support,{ajax:!!e,cors:!!e&&"withCredentials"in e})}(xt.ajaxSettings.xhr()),xt.support.ajax&&xt.ajaxTransport(function(e){if(!e.crossDomain||xt.support.cors){var t;return{send:function(n,r){var o,i,a=e.xhr();if(e.username?a.open(e.type,e.url,e.async,e.username,e.password):a.open(e.type,e.url,e.async),e.xhrFields)for(i in e.xhrFields)a[i]=e.xhrFields[i];e.mimeType&&a.overrideMimeType&&a.overrideMimeType(e.mimeType),e.crossDomain||n["X-Requested-With"]||(n["X-Requested-With"]="XMLHttpRequest");try{for(i in n)a.setRequestHeader(i,n[i])}catch(e){}a.send(e.hasContent&&e.data||null),t=function(n,i){var s,u,l,c,f;try{if(t&&(i||4===a.readyState))if(t=void 0,o&&(a.onreadystatechange=xt.noop,it&&delete st[o]),i)4!==a.readyState&&a.abort();else{s=a.status,l=a.getAllResponseHeaders(),c={},f=a.responseXML,f&&f.documentElement&&(c.xml=f);try{c.text=a.responseText}catch(n){}try{u=a.statusText}catch(e){u=""}s||!e.isLocal||e.crossDomain?1223===s&&(s=204):s=c.text?200:404}}catch(e){i||r(-1,e)}c&&r(s,u,c,l)},e.async&&4!==a.readyState?(o=++at,it&&(st||(st={},xt(window).unload(it)),st[o]=t),a.onreadystatechange=t):t()},abort:function(){t&&t(0,1)}}}}),ut={},ft=/^(?:toggle|show|hide)$/,dt=/^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,ht=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]],xt.fn.extend({show:function(e,t,n){var r,o,i,a;if(e||0===e)return this.animate(O("show",3),e,t,n);for(i=0,a=this.length;i=s.duration+this.startTime){this.now=this.end,this.pos=this.state=1,this.update(),s.animatedProperties[this.prop]=!0;for(t in s.animatedProperties)!0!==s.animatedProperties[t]&&(i=!1);if(i){if(null==s.overflow||xt.support.shrinkWrapBlocks||xt.each(["","X","Y"],function(e,t){a.style["overflow"+t]=s.overflow[e]}),s.hide&&xt(a).hide(),s.hide||s.show)for(t in s.animatedProperties)xt.style(a,t,s.orig[t]),xt.removeData(a,"fxshow"+t,!0),xt.removeData(a,"toggle"+t,!0);r=s.complete,r&&(s.complete=!1,r.call(a))}return!1}return s.duration==1/0?this.now=o:(n=o-this.startTime,this.state=n/s.duration,this.pos=xt.easing[s.animatedProperties[this.prop]](this.state,n,0,1,s.duration),this.now=this.start+(this.end-this.start)*this.pos),this.update(),!0}},xt.extend(xt.fx,{tick:function(){for(var e,t=xt.timers,n=0;n-1,u={},l={},s?(l=r.position(),c=l.top,f=l.left):(c=parseFloat(i)||0,f=parseFloat(a)||0),xt.isFunction(t)&&(t=t.call(e,n,o)),null!=t.top&&(u.top=t.top-o.top+c),null!=t.left&&(u.left=t.left-o.left+f),"using"in t?t.using.call(e,u):r.css(u)}},xt.fn.extend({position:function(){if(!this[0])return null;var e=this[0],t=this.offsetParent(),n=this.offset(),r=vt.test(t[0].nodeName)?{top:0,left:0}:t.offset();return n.top-=parseFloat(xt.css(e,"marginTop"))||0,n.left-=parseFloat(xt.css(e,"marginLeft"))||0,r.top+=parseFloat(xt.css(t[0],"borderTopWidth"))||0,r.left+=parseFloat(xt.css(t[0],"borderLeftWidth"))||0,{top:n.top-r.top,left:n.left-r.left}},offsetParent:function(){return this.map(function(){for(var e=this.offsetParent||bt.body;e&&!vt.test(e.nodeName)&&"static"===xt.css(e,"position");)e=e.offsetParent;return e})}}),xt.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,t){var n=/Y/.test(t);xt.fn[e]=function(r){return xt.access(this,function(e,r,o){var i=N(e);if(void 0===o)return i?t in i?i[t]:xt.support.boxModel&&i.document.documentElement[r]||i.document.body[r]:e[r];i?i.scrollTo(n?xt(i).scrollLeft():o,n?o:xt(i).scrollTop()):e[r]=o},e,r,arguments.length,null)}}),xt.each({Height:"height",Width:"width" -},function(e,t){var n="client"+e,r="scroll"+e,o="offset"+e;xt.fn["inner"+e]=function(){var e=this[0];return e?e.style?parseFloat(xt.css(e,t,"padding")):this[t]():null},xt.fn["outer"+e]=function(e){var n=this[0];return n?n.style?parseFloat(xt.css(n,t,e?"margin":"border")):this[t]():null},xt.fn[t]=function(e){return xt.access(this,function(e,t,i){var a,s,u,l;return xt.isWindow(e)?(a=e.document,s=a.documentElement[n],xt.support.boxModel&&s||a.body&&a.body[n]||s):9===e.nodeType?(a=e.documentElement,a[n]>=a[r]?a[n]:Math.max(e.body[r],a[r],e.body[o],a[o])):void 0===i?(u=xt.css(e,t),l=parseFloat(u),xt.isNumeric(l)?l:u):void xt(e).css(t,i)},t,e,arguments.length,null)}}),e.exports=window.jQuery=window.$=xt},function(e,t,n){var r,o;!function(){"use strict";function n(){var e,t,r,o,a,s=[];for(e=0;en?n:Math.round(t)}function o(e,t,n){return $.isNaN(t)?e:tn?n:Math.round(1e4*t)/1e4}function i(e){return r(0,e,255)}function a(e){return r(0,e,255)}function s(e){return r(0,e,255)}function u(e){return o(0,e,1)}function l(e,t,n){return[i(e),a(t),s(n)]}function c(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]}function f(e,t,n,r){var o,l,c;return Array.isArray(e)?(o=e,r=t,[o[0],o[1],o[2],u(r)]):(l=e,c=t,n=n||0,r=r||0,[i(l),a(c),s(n),u(r)])}function d(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]&&e[3]===t[3]}function p(e){return o(0,e,1)}function h(e){return o(0,e,1)}function m(e){return o(0,e,1)}function g(e){return o(0,e,1)}function y(e){return o(0,e,1)}function v(e,t,n){return[p(e),h(t),g(n)]}function b(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]}function _(e,t,n){return[p(e),m(t),y(n)]}function w(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]}function x(e){var t,n=e[0],r=e[1],o=e[2],i=n/255,a=r/255,s=o/255,u=Math.min(i,a,s),l=Math.max(i,a,s),c=0,f=0,d=(u+l)/2;if(u===l)c=0,f=0;else switch(t=l-u,f=d>.5?t/(2-l-u):t/(l+u),l){case i:c=((a-s)/t+(a1&&(n-=1), -n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function T(e){var t,n,r,o,u,l=e[0],c=e[1],f=e[2];return 0===c?t=n=r=f:(o=f<.5?f*(1+c):f+c-f*c,u=2*f-o,t=k(u,o,l+1/3),n=k(u,o,l),r=k(u,o,l-1/3)),[i(255*t),a(255*n),s(255*r)]}function S(e){var t=e[0],n=e[1],r=e[2],o=t/255,i=n/255,a=r/255,s=Math.min(o,i,a),u=Math.max(o,i,a),l=u-s,c=0,f=0===u?0:l/u,d=u;if(u===s)c=0;else switch(u){case t:c=((i-a)/l+(i255)throw Error("invalid threshold value, valid values are [0, 255]");return E(e)>=t?"white":"black"}function z(e){var t,n,r,o,i;if(e=e.toLowerCase(),j(G,e)){if(null!==(t=R(G[e])))return t;throw Error("Invalid named color definition")}return null!==(n=A(e))?n:null!==(r=R(e))?r:null!==(o=H(e))?o:(i=Y(e),null!==i?i:null)}function B(e){var t=z(e);if(null!==t)return t;throw Error("Passed color string does not match any of the known color representations")}function V(e){var t,n,r,o,i,a,s,u;if(e=e.toLowerCase(),j(G,e)){if(null!==(t=R(G[e])))return n=t[0],r=t[1],o=t[2],[n,r,o,1];throw Error("Invalid named color definition")}return null!==(i=A(e))?(n=i[0],r=i[1],o=i[2],[n,r,o,1]):null!==(a=R(e))?(n=a[0],r=a[1],o=a[2],[n,r,o,1]):null!==(s=H(e))?(n=s[0],r=s[1],o=s[2],[n,r,o,1]):(u=Y(e),null!==u?u:null)}function q(e){var t=V(e);if(null!==t)return t;throw Error("Passed color string does not match any of the known color representations")}var $,K,G,J,X,Q,Z;Object.defineProperty(t,"__esModule",{value:!0}),$=n(198),t.normalizeRedComponent=i,t.normalizeGreenComponent=a, -t.normalizeBlueComponent=s,t.normalizeAlphaComponent=u,t.rgb=l,t.areEqualRgb=c,t.rgba=f,t.areEqualRgba=d,t.normalizeHue=p,t.normalizeHslSaturation=h,t.normalizeHsvSaturation=m,t.normalizeLightness=g,t.normalizeValue=y,t.hsl=v,t.areEqualHsl=b,t.hsv=_,t.areEqualHsv=w,t.rgbToHsl=x,t.hslToRgb=T,t.rgbToHsv=S,t.hsvToRgb=C,K=[.199,.687,.114],t.rgbToGrayscale=E,t.distanceRgb=M,t.invertRgb=O,t.darkenRgb=D,t.blendRgba=N,t.shiftRgb=P,t.shiftColor=L,G={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dodgerblue:"#1e90ff",feldspar:"#d19275",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslateblue:"#8470ff",lightslategray:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370d8",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#d87093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",snow:"#fffafa",springgreen:"#00ff7f", -steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",violetred:"#d02090",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},function(e){function t(e){return[i(parseInt(e[1],10)),a(parseInt(e[2],10)),s(parseInt(e[3],10))]}e.re=/^rgb\(\s*(-?\d{1,10})\s*,\s*(-?\d{1,10})\s*,\s*(-?\d{1,10})\s*\)$/,e.parse=t}(J||(J={})),t.rgbToString=F,function(e){function t(e){return[i(parseInt(e[1],16)),a(parseInt(e[2],16)),s(parseInt(e[3],16))]}e.re=/^#([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,e.parse=t}(X||(X={})),t.rgbToHexString=I,function(e){function t(e){return[i(parseInt(e[1]+e[1],16)),a(parseInt(e[2]+e[2],16)),s(parseInt(e[3]+e[3],16))]}e.re=/^#([0-9a-fA-F])([0-9a-fA-F])([0-9a-fA-F])$/,e.parse=t}(Q||(Q={})),function(e){function t(e){return[i(parseInt(e[1],10)),a(parseInt(e[2],10)),s(parseInt(e[3],10)),u(parseFloat(e[4]))]}e.re=/^rgba\(\s*(-?\d{1,10})\s*,\s*(-?\d{1,10})\s*,\s*(-?\d{1,10})\s*,\s*(-?[\d]{0,10}(?:\.\d+)?)\s*\)$/,e.parse=t}(Z||(Z={})),t.rgbaToString=W,t.rgbToBlackWhiteString=U,t.tryParseRgb=z,t.parseRgb=B,t.tryParseRgba=V,t.parseRgba=q},,,,function(e,t){e.exports=function(e){try{return!!e()}catch(e){return!0}}},function(e,t,n){var r=n(16),o=n(251),i=n(113),a=Object.defineProperty;t.f=n(55)?Object.defineProperty:function(e,t,n){if(r(e),t=i(t,!0),r(n),o)try{return a(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},function(e,t,n){(function(e){!function(t,n){e.exports=n()}(0,function(){"use strict";function t(){return Fn.apply(null,arguments)}function r(e){Fn=e}function o(e){return"[object Array]"===Object.prototype.toString.call(e)}function i(e){return e instanceof Date||"[object Date]"===Object.prototype.toString.call(e)}function a(e,t){var n,r=[];for(n=0;n0)for(n in Yr)r=Yr[n],void 0!==(o=t[r])&&(e[r]=o);return e}function m(e){h(this,e),this._d=new Date(null!=e._d?e._d.getTime():NaN),!1===Wr&&(Wr=!0,t.updateOffset(this),Wr=!1)}function g(e){return e instanceof m||null!=e&&null!=e._isAMomentObject}function y(e){return e<0?Math.ceil(e):Math.floor(e)}function v(e){var t=+e,n=0;return 0!==t&&isFinite(t)&&(n=y(t)),n}function b(e,t,n){var r,o=Math.min(e.length,t.length),i=Math.abs(e.length-t.length),a=0;for(r=0;r0;){if(r=k(o.slice(0,t).join("-")))return r;if(n&&n.length>=t&&b(o,n,!0)>=t-1)break;t--}i++}return null}function k(t){var r=null;if(!Ur[t]&&void 0!==e&&e&&e.exports)try{r=Rn._abbr,n(523)("./"+t),T(r)}catch(e){}return Ur[t]}function T(e,t){var n;return e&&(n=void 0===t?C(e):S(e,t))&&(Rn=n),Rn._abbr}function S(e,t){return null!==t?(t.abbr=e,Ur[e]=Ur[e]||new _,Ur[e].set(t),T(e),Ur[e]):(delete Ur[e],null)}function C(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return Rn;if(!o(e)){if(t=k(e))return t;e=[e]}return x(e)}function E(e,t){var n=e.toLowerCase();zr[n]=zr[n+"s"]=zr[t]=e}function M(e){return"string"==typeof e?zr[e]||zr[e.toLowerCase()]:void 0}function O(e){var t,n,r={};for(n in e)s(e,n)&&(t=M(n))&&(r[t]=e[n]);return r}function D(e,n){return function(r){return null!=r?(P(this,e,r),t.updateOffset(this,n),this):N(this,e)}}function N(e,t){return e._d["get"+(e._isUTC?"UTC":"")+t]()}function P(e,t,n){return e._d["set"+(e._isUTC?"UTC":"")+t](n)}function L(e,t){var n;if("object"==typeof e)for(n in e)this.set(n,e[n]);else if(e=M(e),"function"==typeof this[e])return this[e](t);return this}function j(e,t,n){var r=""+Math.abs(e),o=t-r.length;return(e>=0?n?"+":"":"-")+(""+Math.pow(10,Math.max(0,o))).substr(1)+r}function A(e,t,n,r){var o=r;"string"==typeof r&&(o=function(){return this[r]()}),e&&($r[e]=o),t&&($r[t[0]]=function(){return j(o.apply(this,arguments),t[1],t[2])}),n&&($r[n]=function(){return this.localeData().ordinal(o.apply(this,arguments),e)})}function F(e){return e.match(/\[[\s\S]/)?e.replace(/^\[|\]$/g,""):e.replace(/\\/g,"")}function R(e){var t,n,r=e.match(Br);for(t=0,n=r.length;t=0&&Vr.test(e);)e=e.replace(Vr,n),Vr.lastIndex=0,r-=1;return e}function Y(e){return"function"==typeof e&&"[object Function]"===Object.prototype.toString.call(e)}function W(e,t,n){uo[e]=Y(t)?t:function(e){return e&&n?n:t}}function U(e,t){ -return s(uo,e)?uo[e](t._strict,t._locale):RegExp(z(e))}function z(e){return e.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(e,t,n,r,o){return t||n||r||o}).replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function B(e,t){var n,r=t;for("string"==typeof e&&(e=[e]),"number"==typeof t&&(r=function(e,n){n[t]=v(e)}),n=0;n11?fo:n[po]<1||n[po]>$(n[co],n[fo])?po:n[ho]<0||n[ho]>24||24===n[ho]&&(0!==n[mo]||0!==n[go]||0!==n[yo])?ho:n[mo]<0||n[mo]>59?mo:n[go]<0||n[go]>59?go:n[yo]<0||n[yo]>999?yo:-1,f(e)._overflowDayOfYear&&(tpo)&&(t=po),f(e).overflow=t),e}function te(e){!1===t.suppressDeprecationWarnings&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+e)}function ne(e,t){var n=!0;return u(function(){return n&&(te(e+"\n"+Error().stack),n=!1),t.apply(this,arguments)},t)}function re(e,t){Yn[e]||(te(t),Yn[e]=!0)}function oe(e){var t,n,r=e._i,o=Wn.exec(r);if(o){for(f(e).iso=!0,t=0,n=Un.length;to&&(i-=7),i0?e:e-1,dayOfYear:i>0?i:ue(e-1)+i}}function ve(e){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==e?t:this.add(e-t,"d")}function be(e,t,n){return null!=e?e:null!=t?t:n}function _e(e){var t=new Date;return e._useUTC?[t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()]:[t.getFullYear(),t.getMonth(),t.getDate()]}function we(e){var t,n,r,o,i=[];if(!e._d){for(r=_e(e),e._w&&null==e._a[po]&&null==e._a[fo]&&xe(e),e._dayOfYear&&(o=be(e._a[co],r[co]),e._dayOfYear>ue(o)&&(f(e)._overflowDayOfYear=!0),n=se(o,0,e._dayOfYear),e._a[fo]=n.getUTCMonth(),e._a[po]=n.getUTCDate()),t=0;t<3&&null==e._a[t];++t)e._a[t]=i[t]=r[t];for(;t<7;t++)e._a[t]=i[t]=null==e._a[t]?2===t?1:0:e._a[t];24===e._a[ho]&&0===e._a[mo]&&0===e._a[go]&&0===e._a[yo]&&(e._nextDay=!0,e._a[ho]=0),e._d=(e._useUTC?se:ae).apply(null,i),null!=e._tzm&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[ho]=24)}}function xe(e){var t,n,r,o,i,a,s;t=e._w,null!=t.GG||null!=t.W||null!=t.E?(i=1,a=4,n=be(t.GG,e._a[co],fe(Ne(),1,4).year),r=be(t.W,1),o=be(t.E,1)):(i=e._locale._week.dow,a=e._locale._week.doy,n=be(t.gg,e._a[co],fe(Ne(),i,a).year),r=be(t.w,1),null!=t.d?(o=t.d)0&&f(e).unusedInput.push(a),s=s.slice(s.indexOf(r)+r.length),l+=r.length),$r[i]?(r?f(e).empty=!1:f(e).unusedTokens.push(i),q(i,r,e)):e._strict&&!r&&f(e).unusedTokens.push(i);f(e).charsLeftOver=u-l,s.length>0&&f(e).unusedInput.push(s),!0===f(e).bigHour&&e._a[ho]<=12&&e._a[ho]>0&&(f(e).bigHour=void 0),e._a[ho]=Te(e._locale,e._a[ho],e._meridiem),we(e),ee(e)}function Te(e,t,n){var r;return null==n?t:null!=e.meridiemHour?e.meridiemHour(t,n):null!=e.isPM?(r=e.isPM(n),r&&t<12&&(t+=12),r||12!==t||(t=0),t):t}function Se(e){var t,n,r,o,i;if(0===e._f.length)return f(e).invalidFormat=!0,void(e._d=new Date(NaN));for(o=0;othis.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function Ke(){var e,t;return void 0!==this._isDSTShifted?this._isDSTShifted:(e={},h(e,this),e=Me(e),e._a?(t=e._isUTC?l(e._a):Ne(e._a),this._isDSTShifted=this.isValid()&&b(e._a,t.toArray())>0):this._isDSTShifted=!1,this._isDSTShifted)}function Ge(){return!this._isUTC}function Je(){return this._isUTC}function Xe(){return this._isUTC&&0===this._offset}function Qe(e,t){var n,r,o,i=e,a=null;return Fe(e)?i={ms:e._milliseconds,d:e._days, -M:e._months}:"number"==typeof e?(i={},t?i[t]=e:i.milliseconds=e):(a=Jn.exec(e))?(n="-"===a[1]?-1:1,i={y:0,d:v(a[po])*n,h:v(a[ho])*n,m:v(a[mo])*n,s:v(a[go])*n,ms:v(a[yo])*n}):(a=Xn.exec(e))?(n="-"===a[1]?-1:1,i={y:Ze(a[2],n),M:Ze(a[3],n),d:Ze(a[4],n),h:Ze(a[5],n),m:Ze(a[6],n),s:Ze(a[7],n),w:Ze(a[8],n)}):null==i?i={}:"object"==typeof i&&("from"in i||"to"in i)&&(o=tt(Ne(i.from),Ne(i.to)),i={},i.ms=o.milliseconds,i.M=o.months),r=new Ae(i),Fe(e)&&s(e,"_locale")&&(r._locale=e._locale),r}function Ze(e,t){var n=e&&parseFloat(e.replace(",","."));return(isNaN(n)?0:n)*t}function et(e,t){var n={milliseconds:0,months:0};return n.months=t.month()-e.month()+12*(t.year()-e.year()),e.clone().add(n.months,"M").isAfter(t)&&--n.months,n.milliseconds=+t-+e.clone().add(n.months,"M"),n}function tt(e,t){var n;return t=He(t,e),e.isBefore(t)?n=et(e,t):(n=et(t,e),n.milliseconds=-n.milliseconds,n.months=-n.months),n}function nt(e,t){return function(n,r){var o,i;return null===r||isNaN(+r)||(re(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period)."),i=n,n=r,r=i),n="string"==typeof n?+n:n,o=Qe(n,r),rt(this,o,e),this}}function rt(e,n,r,o){var i=n._milliseconds,a=n._days,s=n._months;o=null==o||o,i&&e._d.setTime(+e._d+i*r),a&&P(e,"Date",N(e,"Date")+a*r),s&&X(e,N(e,"Month")+s*r),o&&t.updateOffset(e,a||s)}function ot(e,t){var n=e||Ne(),r=He(n,this).startOf("day"),o=this.diff(r,"days",!0),i=o<-6?"sameElse":o<-1?"lastWeek":o<0?"lastDay":o<1?"sameDay":o<2?"nextDay":o<7?"nextWeek":"sameElse";return this.format(t&&t[i]||this.localeData().calendar(i,this,Ne(n)))}function it(){return new m(this)}function at(e,t){return t=M(void 0!==t?t:"millisecond"),"millisecond"===t?(e=g(e)?e:Ne(e),+this>+e):(g(e)?+e:+Ne(e))<+this.clone().startOf(t)}function st(e,t){var n;return t=M(void 0!==t?t:"millisecond"),"millisecond"===t?(e=g(e)?e:Ne(e),+this<+e):(n=g(e)?+e:+Ne(e),+this.clone().endOf(t)11?n?"pm":"PM":n?"am":"AM"}function Jt(e,t){t[yo]=v(1e3*("0."+e))}function Xt(){return this._isUTC?"UTC":""}function Qt(){return this._isUTC?"Coordinated Universal Time":""}function Zt(e){return Ne(1e3*e)}function en(){return Ne.apply(null,arguments).parseZone()}function tn(e,t,n){var r=this._calendar[e];return"function"==typeof r?r.call(t,n):r}function nn(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return t||!n?t:(this._longDateFormat[e]=n.replace(/MMMM|MM|DD|dddd/g,function(e){return e.slice(1)}),this._longDateFormat[e])}function rn(){return this._invalidDate}function on(e){return this._ordinal.replace("%d",e)}function an(e){return e}function sn(e,t,n,r){var o=this._relativeTime[n];return"function"==typeof o?o(e,t,n,r):o.replace(/%d/i,e)}function un(e,t){var n=this._relativeTime[e>0?"future":"past"];return"function"==typeof n?n(t):n.replace(/%s/i,t)}function ln(e){var t,n;for(n in e)t=e[n],"function"==typeof t?this[n]=t:this["_"+n]=t;this._ordinalParseLenient=RegExp(this._ordinalParse.source+"|"+/\d{1,2}/.source)}function cn(e,t,n,r){var o=C(),i=l().set(r,t);return o[n](i,e)}function fn(e,t,n,r,o){var i,a;if("number"==typeof e&&(t=e,e=void 0),e=e||"",null!=t)return cn(e,t,n,o);for(a=[],i=0;i=0&&a>=0&&s>=0||i<=0&&a<=0&&s<=0||(i+=864e5*wn(Tn(s)+a),a=0,s=0),u.milliseconds=i%1e3,e=y(i/1e3),u.seconds=e%60,t=y(e/60),u.minutes=t%60,n=y(t/60),u.hours=n%24,a+=y(n/24),o=y(kn(a)),s+=o,a-=wn(Tn(o)),r=y(s/12),s%=12,u.days=a,u.months=s,u.years=r,this}function kn(e){return 4800*e/146097}function Tn(e){return 146097*e/4800}function Sn(e){var t,n,r=this._milliseconds;if("month"===(e=M(e))||"year"===e)return t=this._days+r/864e5,n=this._months+kn(t),"month"===e?n:n/12;switch(t=this._days+Math.round(Tn(this._months)),e){case"week":return t/7+r/6048e5;case"day":return t+r/864e5;case"hour":return 24*t+r/36e5;case"minute":return 1440*t+r/6e4;case"second":return 86400*t+r/1e3;case"millisecond":return Math.floor(864e5*t)+r;default:throw Error("Unknown unit "+e)}}function Cn(){ -return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*v(this._months/12)}function En(e){return function(){return this.as(e)}}function Mn(e){return e=M(e),this[e+"s"]()}function On(e){return function(){return this._data[e]}}function Dn(){return y(this.days()/7)}function Nn(e,t,n,r,o){return o.relativeTime(t||1,!!n,e,r)}function Pn(e,t,n){var r=Qe(e).abs(),o=Fr(r.as("s")),i=Fr(r.as("m")),a=Fr(r.as("h")),s=Fr(r.as("d")),u=Fr(r.as("M")),l=Fr(r.as("y")),c=o0,c[4]=n,Nn.apply(null,c)}function Ln(e,t){return void 0!==Rr[e]&&(void 0===t?Rr[e]:(Rr[e]=t,!0))}function jn(e){var t=this.localeData(),n=Pn(this,!e,t);return e&&(n=t.pastFuture(+this,n)),t.postformat(n)}function An(){var e,t,n,r,o,i,a,s,u=Ir(this._milliseconds)/1e3,l=Ir(this._days),c=Ir(this._months),f=y(u/60),d=y(f/60);return u%=60,f%=60,e=y(c/12),c%=12,t=e,n=c,r=l,o=d,i=f,a=u,s=this.asSeconds(),s?(s<0?"-":"")+"P"+(t?t+"Y":"")+(n?n+"M":"")+(r?r+"D":"")+(o||i||a?"T":"")+(o?o+"H":"")+(i?i+"M":"")+(a?a+"S":""):"P0D"}var Fn,Rn,In,Hn,Yn,Wn,Un,zn,Bn,Vn,qn,$n,Kn,Gn,Jn,Xn,Qn,Zn,er,tr,nr,rr,or,ir,ar,sr,ur,lr,cr,fr,dr,pr,hr,mr,gr,yr,vr,br,_r,wr,xr,kr,Tr,Sr,Cr,Er,Mr,Or,Dr,Nr,Pr,Lr,jr,Ar,Fr,Rr,Ir,Hr,Yr=t.momentProperties=[],Wr=!1,Ur={},zr={},Br=/(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Q|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,Vr=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,qr={},$r={},Kr=/\d/,Gr=/\d\d/,Jr=/\d{3}/,Xr=/\d{4}/,Qr=/[+-]?\d{6}/,Zr=/\d\d?/,eo=/\d{1,3}/,to=/\d{1,4}/,no=/[+-]?\d{1,6}/,ro=/\d+/,oo=/[+-]?\d+/,io=/Z|[+-]\d\d:?\d\d/gi,ao=/[+-]?\d+(\.\d{1,3})?/,so=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,uo={},lo={},co=0,fo=1,po=2,ho=3,mo=4,go=5,yo=6;for(A("M",["MM",2],"Mo",function(){return this.month()+1}),A("MMM",0,0,function(e){return this.localeData().monthsShort(this,e)}),A("MMMM",0,0,function(e){return this.localeData().months(this,e)}),E("month","M"),W("M",Zr),W("MM",Zr,Gr),W("MMM",so),W("MMMM",so),B(["M","MM"],function(e,t){t[fo]=v(e)-1}),B(["MMM","MMMM"],function(e,t,n,r){var o=n._locale.monthsParse(e,r,n._strict);null!=o?t[fo]=o:f(n).invalidMonth=e}),In="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),Hn="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),Yn={},t.suppressDeprecationWarnings=!1,Wn=/^\s*(?:[+-]\d{6}|\d{4})-(?:(\d\d-\d\d)|(W\d\d$)|(W\d\d-\d)|(\d\d\d))((T| )(\d\d(:\d\d(:\d\d(\.\d+)?)?)?)?([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,Un=[["YYYYYY-MM-DD",/[+-]\d{6}-\d{2}-\d{2}/],["YYYY-MM-DD",/\d{4}-\d{2}-\d{2}/],["GGGG-[W]WW-E",/\d{4}-W\d{2}-\d/],["GGGG-[W]WW",/\d{4}-W\d{2}/],["YYYY-DDD",/\d{4}-\d{3}/]],zn=[["HH:mm:ss.SSSS",/(T| )\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss",/(T| )\d\d:\d\d:\d\d/],["HH:mm",/(T| )\d\d:\d\d/],["HH",/(T| )\d\d/]], -Bn=/^\/?Date\((\-?\d+)/i,t.createFromInputFallback=ne("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.",function(e){e._d=new Date(e._i+(e._useUTC?" UTC":""))}),A(0,["YY",2],0,function(){return this.year()%100}),A(0,["YYYY",4],0,"year"),A(0,["YYYYY",5],0,"year"),A(0,["YYYYYY",6,!0],0,"year"),E("year","y"),W("Y",oo),W("YY",Zr,Gr),W("YYYY",to,Xr),W("YYYYY",no,Qr),W("YYYYYY",no,Qr),B(["YYYYY","YYYYYY"],co),B("YYYY",function(e,n){n[co]=2===e.length?t.parseTwoDigitYear(e):v(e)}),B("YY",function(e,n){n[co]=t.parseTwoDigitYear(e)}),t.parseTwoDigitYear=function(e){return v(e)+(v(e)>68?1900:2e3)},Vn=D("FullYear",!1),A("w",["ww",2],"wo","week"),A("W",["WW",2],"Wo","isoWeek"),E("week","w"),E("isoWeek","W"),W("w",Zr),W("ww",Zr,Gr),W("W",Zr),W("WW",Zr,Gr),V(["w","ww","W","WW"],function(e,t,n,r){t[r.substr(0,1)]=v(e)}),qn={dow:0,doy:6},A("DDD",["DDDD",3],"DDDo","dayOfYear"),E("dayOfYear","DDD"),W("DDD",eo),W("DDDD",Jr),B(["DDD","DDDD"],function(e,t,n){n._dayOfYear=v(e)}),t.ISO_8601=function(){},$n=ne("moment().min is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548",function(){var e=Ne.apply(null,arguments);return ethis?this:e}),Re("Z",":"),Re("ZZ",""),W("Z",io),W("ZZ",io),B(["Z","ZZ"],function(e,t,n){n._useUTC=!0,n._tzm=Ie(e)}),Gn=/([\+\-]|\d\d)/gi,t.updateOffset=function(){},Jn=/(\-)?(?:(\d*)\.)?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?)?/,Xn=/^(-)?P(?:(?:([0-9,.]*)Y)?(?:([0-9,.]*)M)?(?:([0-9,.]*)D)?(?:T(?:([0-9,.]*)H)?(?:([0-9,.]*)M)?(?:([0-9,.]*)S)?)?|([0-9,.]*)W)$/,Qe.fn=Ae.prototype,Qn=nt(1,"add"),Zn=nt(-1,"subtract"),t.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",er=ne("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(e){return void 0===e?this.localeData():this.locale(e)}),A(0,["gg",2],0,function(){return this.weekYear()%100}),A(0,["GG",2],0,function(){return this.isoWeekYear()%100}),Nt("gggg","weekYear"),Nt("ggggg","weekYear"),Nt("GGGG","isoWeekYear"),Nt("GGGGG","isoWeekYear"),E("weekYear","gg"),E("isoWeekYear","GG"),W("G",oo),W("g",oo),W("GG",Zr,Gr),W("gg",Zr,Gr),W("GGGG",to,Xr),W("gggg",to,Xr),W("GGGGG",no,Qr),W("ggggg",no,Qr),V(["gggg","ggggg","GGGG","GGGGG"],function(e,t,n,r){t[r.substr(0,2)]=v(e)}),V(["gg","GG"],function(e,n,r,o){n[o]=t.parseTwoDigitYear(e)}),A("Q",0,0,"quarter"),E("quarter","Q"),W("Q",Kr),B("Q",function(e,t){t[fo]=3*(v(e)-1)}),A("D",["DD",2],"Do","date"),E("date","D"),W("D",Zr),W("DD",Zr,Gr),W("Do",function(e,t){return e?t._ordinalParse:t._ordinalParseLenient}),B(["D","DD"],po),B("Do",function(e,t){t[po]=v(e.match(Zr)[0],10)}),tr=D("Date",!0),A("d",0,"do","day"),A("dd",0,0,function(e){return this.localeData().weekdaysMin(this,e)}),A("ddd",0,0,function(e){ -return this.localeData().weekdaysShort(this,e)}),A("dddd",0,0,function(e){return this.localeData().weekdays(this,e)}),A("e",0,0,"weekday"),A("E",0,0,"isoWeekday"),E("day","d"),E("weekday","e"),E("isoWeekday","E"),W("d",Zr),W("e",Zr),W("E",Zr),W("dd",so),W("ddd",so),W("dddd",so),V(["dd","ddd","dddd"],function(e,t,n){var r=n._locale.weekdaysParse(e);null!=r?t.d=r:f(n).invalidWeekday=e}),V(["d","e","E"],function(e,t,n,r){t[r]=v(e)}),nr="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),rr="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),or="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),A("H",["HH",2],0,"hour"),A("h",["hh",2],0,function(){return this.hours()%12||12}),qt("a",!0),qt("A",!1),E("hour","h"),W("a",$t),W("A",$t),W("H",Zr),W("h",Zr),W("HH",Zr,Gr),W("hh",Zr,Gr),B(["H","HH"],ho),B(["a","A"],function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e}),B(["h","hh"],function(e,t,n){t[ho]=v(e),f(n).bigHour=!0}),ir=/[ap]\.?m?\.?/i,ar=D("Hours",!0),A("m",["mm",2],0,"minute"),E("minute","m"),W("m",Zr),W("mm",Zr,Gr),B(["m","mm"],mo),sr=D("Minutes",!1),A("s",["ss",2],0,"second"),E("second","s"),W("s",Zr),W("ss",Zr,Gr),B(["s","ss"],go),ur=D("Seconds",!1),A("S",0,0,function(){return~~(this.millisecond()/100)}),A(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),A(0,["SSS",3],0,"millisecond"),A(0,["SSSS",4],0,function(){return 10*this.millisecond()}),A(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),A(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),A(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),A(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),A(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),E("millisecond","ms"),W("S",eo,Kr),W("SS",eo,Gr),W("SSS",eo,Jr),lr="SSSS";lr.length<=9;lr+="S")W(lr,ro);for(lr="S";lr.length<=9;lr+="S")B(lr,Jt);return cr=D("Milliseconds",!1),A("z",0,0,"zoneAbbr"),A("zz",0,0,"zoneName"),fr=m.prototype,fr.add=Qn,fr.calendar=ot,fr.clone=it,fr.diff=ct,fr.endOf=xt,fr.format=ht,fr.from=mt,fr.fromNow=gt,fr.to=yt,fr.toNow=vt,fr.get=L,fr.invalidAt=Dt,fr.isAfter=at,fr.isBefore=st,fr.isBetween=ut,fr.isSame=lt,fr.isValid=Mt,fr.lang=er,fr.locale=bt,fr.localeData=_t,fr.max=Kn,fr.min=$n,fr.parsingFlags=Ot,fr.set=L,fr.startOf=wt,fr.subtract=Zn,fr.toArray=Ct,fr.toObject=Et,fr.toDate=St,fr.toISOString=pt,fr.toJSON=pt,fr.toString=dt,fr.unix=Tt,fr.valueOf=kt,fr.year=Vn,fr.isLeapYear=ce,fr.weekYear=Lt,fr.isoWeekYear=jt,fr.quarter=fr.quarters=Rt,fr.month=Q,fr.daysInMonth=Z,fr.week=fr.weeks=me,fr.isoWeek=fr.isoWeeks=ge,fr.weeksInYear=Ft,fr.isoWeeksInYear=At,fr.date=tr,fr.day=fr.days=zt,fr.weekday=Bt,fr.isoWeekday=Vt,fr.dayOfYear=ve,fr.hour=fr.hours=ar,fr.minute=fr.minutes=sr,fr.second=fr.seconds=ur,fr.millisecond=fr.milliseconds=cr,fr.utcOffset=We,fr.utc=ze,fr.local=Be,fr.parseZone=Ve,fr.hasAlignedHourOffset=qe,fr.isDST=$e,fr.isDSTShifted=Ke,fr.isLocal=Ge,fr.isUtcOffset=Je,fr.isUtc=Xe,fr.isUTC=Xe,fr.zoneAbbr=Xt,fr.zoneName=Qt,fr.dates=ne("dates accessor is deprecated. Use date instead.",tr), -fr.months=ne("months accessor is deprecated. Use month instead",Q),fr.years=ne("years accessor is deprecated. Use year instead",Vn),fr.zone=ne("moment().zone is deprecated, use moment().utcOffset instead. https://github.com/moment/moment/issues/1779",Ue),dr=fr,pr={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},hr={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},mr="Invalid date",gr="%d",yr=/\d{1,2}/,vr={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},br=_.prototype,br._calendar=pr,br.calendar=tn,br._longDateFormat=hr,br.longDateFormat=nn,br._invalidDate=mr,br.invalidDate=rn,br._ordinal=gr,br.ordinal=on,br._ordinalParse=yr,br.preparse=an,br.postformat=an,br._relativeTime=vr,br.relativeTime=sn,br.pastFuture=un,br.set=ln,br.months=K,br._months=In,br.monthsShort=G,br._monthsShort=Hn,br.monthsParse=J,br.week=de,br._week=qn,br.firstDayOfYear=he,br.firstDayOfWeek=pe,br.weekdays=Ht,br._weekdays=nr,br.weekdaysMin=Wt,br._weekdaysMin=or,br.weekdaysShort=Yt,br._weekdaysShort=rr,br.weekdaysParse=Ut,br.isPM=Kt,br._meridiemParse=ir,br.meridiem=Gt,T("en",{ordinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10;return e+(1===v(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")}}),t.lang=ne("moment.lang is deprecated. Use moment.locale instead.",T),t.langData=ne("moment.langData is deprecated. Use moment.localeData instead.",C),_r=Math.abs,wr=En("ms"),xr=En("s"),kr=En("m"),Tr=En("h"),Sr=En("d"),Cr=En("w"),Er=En("M"),Mr=En("y"),Or=On("milliseconds"),Dr=On("seconds"),Nr=On("minutes"),Pr=On("hours"),Lr=On("days"),jr=On("months"),Ar=On("years"),Fr=Math.round,Rr={s:45,m:45,h:22,d:26,M:11},Ir=Math.abs,Hr=Ae.prototype,Hr.abs=yn,Hr.add=bn,Hr.subtract=_n,Hr.as=Sn,Hr.asMilliseconds=wr,Hr.asSeconds=xr,Hr.asMinutes=kr,Hr.asHours=Tr,Hr.asDays=Sr,Hr.asWeeks=Cr,Hr.asMonths=Er,Hr.asYears=Mr,Hr.valueOf=Cn,Hr._bubble=xn,Hr.get=Mn,Hr.milliseconds=Or,Hr.seconds=Dr,Hr.minutes=Nr,Hr.hours=Pr,Hr.days=Lr,Hr.weeks=Dn,Hr.months=jr,Hr.years=Ar,Hr.humanize=jn,Hr.toISOString=An,Hr.toString=An,Hr.toJSON=An,Hr.locale=bt,Hr.localeData=_t,Hr.toIsoString=ne("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",An),Hr.lang=er,A("X",0,0,"unix"),A("x",0,0,"valueOf"),W("x",oo),W("X",ao),B("X",function(e,t,n){n._d=new Date(1e3*parseFloat(e,10))}),B("x",function(e,t,n){n._d=new Date(v(e))}),t.version="2.10.6",r(Ne),t.fn=dr,t.min=Le,t.max=je,t.utc=l,t.unix=Zt,t.months=dn,t.isDate=i,t.locale=T,t.invalid=p,t.duration=Qe,t.isMoment=g,t.weekdays=hn,t.parseZone=en,t.localeData=C,t.isDuration=Fe,t.monthsShort=pn,t.weekdaysMin=gn,t.defineLocale=S,t.weekdaysShort=mn,t.normalizeUnits=M,t.relativeTimeThreshold=Ln,t})}).call(t,n(42)(e))},function(e,t,n){"use strict";function r(){ -if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(r)}catch(e){console.error(e)}}r(),e.exports=n(546)},,function(e,t,n){(function(t){e.exports=t.Mustache=n(522)}).call(t,n(78))},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t,n){"use strict";var r=window.Modernizr=function(e,t,n){function r(e){v.cssText=e}function o(e,t){return typeof e===t}function i(e,t){return!!~(""+e).indexOf(t)}function a(e,t){var r,o;for(r in e)if(o=e[r],!i(o,"-")&&v[o]!==n)return"pfx"!=t||o;return!1}function s(e,t,r){var i,a;for(i in e)if((a=t[e[i]])!==n)return!1===r?e[i]:o(a,"function")?a.bind(r||t):a;return!1}function u(e,t,n){var r=e.charAt(0).toUpperCase()+e.slice(1),i=(e+" "+w.join(r+" ")+r).split(" ");return o(t,"string")||o(t,"undefined")?a(i,t):(i=(e+" "+x.join(r+" ")+r).split(" "),s(i,t,n))}var l,c,f,d="2.8.3",p={},h=!0,m=t.documentElement,g="modernizr",y=t.createElement(g),v=y.style,b=" -webkit- -moz- -o- -ms- ".split(" "),_="Webkit Moz O ms",w=_.split(" "),x=_.toLowerCase().split(" "),k={},T=[],S=T.slice,C=function(e,n,r,o){var i,a,s,u,l=t.createElement("div"),c=t.body,f=c||t.createElement("body");if(parseInt(r,10))for(;r--;)s=t.createElement("div"),s.id=o?o[r]:g+(r+1),l.appendChild(s);return i='­",l.id=g,(c?l:f).innerHTML+=i,f.appendChild(l),c||(f.style.background="",f.style.overflow="hidden",u=m.style.overflow,m.style.overflow="hidden",m.appendChild(f)),a=n(l,e),c?l.parentNode.removeChild(l):(f.parentNode.removeChild(f),m.style.overflow=u),!!a},E=function(){function e(e,i){i=i||t.createElement(r[e]||"div"),e="on"+e;var a=e in i;return a||(i.setAttribute||(i=t.createElement("div")),i.setAttribute&&i.removeAttribute&&(i.setAttribute(e,""),a=o(i[e],"function"),o(i[e],"undefined")||(i[e]=n),i.removeAttribute(e))),i=null,a}var r={select:"input",change:"input",submit:"form",reset:"form",error:"img",load:"img",abort:"img"};return e}(),M={}.hasOwnProperty;c=o(M,"undefined")||o(M.call,"undefined")?function(e,t){return t in e&&o(e.constructor.prototype[t],"undefined")}:function(e,t){return M.call(e,t)},Function.prototype.bind||(Function.prototype.bind=function(e){var t,n,r=this;if("function"!=typeof r)throw new TypeError;return t=S.call(arguments,1),n=function(){var o,i,a;return this instanceof n?(o=function(){},o.prototype=r.prototype,i=new o,a=r.apply(i,t.concat(S.call(arguments))),Object(a)===a?a:i):r.apply(e,t.concat(S.call(arguments)))}}),k.flexbox=function(){return u("flexWrap")},k.canvas=function(){var e=t.createElement("canvas");return!!e.getContext&&!!e.getContext("2d")},k.canvastext=function(){return!!p.canvas&&!!o(t.createElement("canvas").getContext("2d").fillText,"function")},k.touch=function(){var n -;return"ontouchstart"in e||e.DocumentTouch&&t instanceof DocumentTouch?n=!0:C("@media ("+b.join("touch-enabled),(")+g+"){#modernizr{top:9px;position:absolute}}",function(e){n=9===e.offsetTop}),n},k.history=function(){return!!e.history&&!!history.pushState},k.draganddrop=function(){var e=t.createElement("div");return"draggable"in e||"ondragstart"in e&&"ondrop"in e},k.websockets=function(){return"WebSocket"in e||"MozWebSocket"in e},k.multiplebgs=function(){return r("background:url(https://),url(https://),red url(https://)"),/(url\s*\(.*?){3}/.test(v.background)},k.csscolumns=function(){return u("columnCount")},k.csstransitions=function(){return u("transition")},k.localstorage=function(){try{return localStorage.setItem(g,g),localStorage.removeItem(g),!0}catch(e){return!1}};for(f in k)c(k,f)&&(l=f.toLowerCase(),p[l]=k[f](),T.push((p[l]?"":"no-")+l));return p.addTest=function(e,t){if("object"==typeof e)for(var r in e)c(e,r)&&p.addTest(r,e[r]);else{if(e=e.toLowerCase(),p[e]!==n)return p;t="function"==typeof t?t():t,void 0!==h&&h&&(m.className+=" feature-"+(t?"":"no-")+e),p[e]=t}return p},r(""),y=null,p._version=d,p._prefixes=b,p._domPrefixes=x,p._cssomPrefixes=w,p.hasEvent=E,p.testProp=function(e){return a([e])},p.testAllProps=u,p.testStyles=C,m.className=m.className.replace(/(^|\s)no-js(\s|$)/,"$1$2")+(h?" feature-js feature-"+T.join(" feature-"):""),p}(window,document);!r.touch||"onorientationchange"in window||(r.touch=!1,document.documentElement.className=document.documentElement.className.replace("feature-touch","feature-no-touch")),r.addTest("pointerevents",function(){var e,t=document.createElement("x"),n=document.documentElement,r=window.getComputedStyle,o=!1;return"pointerEvents"in t.style&&(t.style.pointerEvents="auto",t.style.pointerEvents="x",n.appendChild(t),r&&(e=r(t,""),o=!!e&&"auto"===e.pointerEvents),n.removeChild(t),!!o)}),r.addTest("flexbox",r.testAllProps("flexBasis","1px",!0))},,,,,,,,function(e,t){var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},,,,function(e,t,n){e.exports=!n(36)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},,,,,,,function(e,t,n){var r=n(182),o=n(82);e.exports=function(e){return r(o(e))}},function(e,t,n){var r=n(138),o=Math.min;e.exports=function(e){return e>0?o(r(e),9007199254740991):0}},,,,,function(e,t,n){var r=n(97);e.exports=function(e,t,n){if(r(e),void 0===t)return e;switch(n){case 1:return function(n){return e.call(t,n)};case 2:return function(n,r){return e.call(t,n,r)};case 3:return function(n,r,o){return e.call(t,n,r,o)}}return function(){return e.apply(t,arguments)}}},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o,i,a;Object.defineProperty(t,"__esModule",{value:!0}),o=Object.assign||function(e){var t,n,r;for(t=1;t0&&void 0!==arguments[0]?arguments[0]:n.props.includeMargin;n.props.shouldMeasure&&(n._node.parentNode||n._setDOMNode(),e=n.getDimensions(n._node,r),t="function"==typeof n.props.children,n._propsToMeasure.some(function(r){if(e[r]!==n._lastDimensions[r])return n.props.onMeasure(e),t&&void 0!==n&&n.setState({dimensions:e}),n._lastDimensions=e,!0}))},n.state={dimensions:{width:0,height:0,top:0,right:0,bottom:0,left:0}},n._node=null,n._propsToMeasure=n._getPropsToMeasure(e),n._lastDimensions={},n}return a(t,e),s(t,[{key:"componentDidMount",value:function(){var e=this;this._setDOMNode(),this.measure(),this.resizeObserver=new h.default(function(){return e.measure()}),this.resizeObserver.observe(this._node)}},{key:"componentWillReceiveProps",value:function(e){var t=(e.config,e.whitelist),n=e.blacklist;this.props.whitelist===t&&this.props.blacklist===n||(this._propsToMeasure=this._getPropsToMeasure({whitelist:t,blacklist:n}))}},{key:"componentWillUnmount",value:function(){this.resizeObserver.disconnect(this._node),this._node=null}},{key:"_setDOMNode",value:function(){this._node=d.default.findDOMNode(this)}},{key:"getDimensions",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this._node,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.props.includeMargin;return(0,g.default)(e,{margin:t})}},{key:"_getPropsToMeasure",value:function(e){var t=e.whitelist,n=e.blacklist;return t.filter(function(e){return n.indexOf(e)<0})}},{key:"render",value:function(){var e=this.props.children;return u.Children.only("function"==typeof e?e(this.state.dimensions):e)}}]),t}(u.Component);y.propTypes={whitelist:c.default.array,blacklist:c.default.array,includeMargin:c.default.bool,useClone:c.default.bool,cloneOptions:c.default.object,shouldMeasure:c.default.bool,onMeasure:c.default.func},y.defaultProps={whitelist:["width","height","top","right","bottom","left"],blacklist:[],includeMargin:!0,useClone:!1,cloneOptions:{},shouldMeasure:!0,onMeasure:function(){return null}},t.default=y,e.exports=t.default},function(t,n){t.exports=e},function(e,t,n){(function(t){"use strict";var r,o,i,a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};"production"!==t.env.NODE_ENV?(r="function"==typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,o=function(e){return"object"===(void 0===e?"undefined":a(e))&&null!==e&&e.$$typeof===r},i=!0,e.exports=n(5)(o,i)):e.exports=n(12)()}).call(t,n(4)) -},function(e,t){"use strict";function n(){throw Error("setTimeout has not been defined")}function r(){throw Error("clearTimeout has not been defined")}function o(e){if(c===setTimeout)return setTimeout(e,0);if((c===n||!c)&&setTimeout)return c=setTimeout,setTimeout(e,0);try{return c(e,0)}catch(t){try{return c.call(null,e,0)}catch(t){return c.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===r||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&d&&(h=!1,d.length?p=d.concat(p):m=-1,p.length&&s())}function s(){var e,t;if(!h){for(e=o(a),h=!0,t=p.length;t;){for(d=p,p=[];++m1)for(t=1;t1?t-1:0),r=1;r2?n-2:0),i=2;i1&&void 0!==arguments[1]?arguments[1]:{},n=e.getBoundingClientRect(),r=void 0,o=void 0,i=void 0;return t.margin&&(i=(0, -a.default)(getComputedStyle(e))),t.margin?(r=i.left+n.width+i.right,o=i.top+n.height+i.bottom):(r=n.width,o=n.height),{width:r,height:o,top:n.top,right:n.right,bottom:n.bottom,left:n.left}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var i=n(16),a=r(i);e.exports=t.default},function(e,t){"use strict";function n(e){return e=e||{},{top:r(e.marginTop),right:r(e.marginRight),bottom:r(e.marginBottom),left:r(e.marginLeft)}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=n;var r=function(e){return parseInt(e)||0};e.exports=t.default}])})},,,,,,,,,,,,function(e,t){var n=e.exports={version:"2.4.0"};"number"==typeof __e&&(__e=n)},function(e,t,n){var r=n(18),o=n(79),i=n(51),a=n(114)("src"),s="toString",u=Function[s],l=(""+u).split(s);n(95).inspectSource=function(e){return u.call(e)},(e.exports=function(e,t,n,s){var u="function"==typeof n;u&&(i(n,"name")||o(n,"name",t)),e[t]!==n&&(u&&(i(n,a)||o(n,a,e[t]?""+e[t]:l.join(t+""))),e===r?e[t]=n:s?e[t]?e[t]=n:o(e,t,n):(delete e[t],o(e,t,n)))})(Function.prototype,s,function(){return"function"==typeof this&&this[a]||u.call(this)})},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},function(e,t,n){var r=n(253),o=n(184);e.exports=Object.keys||function(e){return r(e,o)}},function(e,t,n){var r=n(116),o=n(80),i=n(62),a=n(113),s=n(51),u=n(251),l=Object.getOwnPropertyDescriptor;t.f=n(55)?l:function(e,t){if(e=i(e),t=a(t,!0),u)try{return l(e,t)}catch(e){}if(s(e,t))return o(!r.f.call(e,t),e[t])}},function(e,t,n){var r=n(82);e.exports=function(e){return Object(r(e))}},function(e,t,n){var r=n(20)("unscopables"),o=Array.prototype;void 0==o[r]&&n(79)(o,r,{}),e.exports=function(e){o[r][e]=!0}},,,,,,,,,,,,function(e,t,n){var r=n(29);e.exports=function(e,t){if(!r(e))return e;var n,o;if(t&&"function"==typeof(n=e.toString)&&!r(o=n.call(e)))return o;if("function"==typeof(n=e.valueOf)&&!r(o=n.call(e)))return o;if(!t&&"function"==typeof(n=e.toString)&&!r(o=n.call(e)))return o;throw TypeError("Can't convert object to primitive value")}},function(e,t){var n=0,r=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++n+r).toString(36))}},function(e,t,n){var r=n(37).f,o=n(51),i=n(20)("toStringTag");e.exports=function(e,t,n){e&&!o(e=n?e:e.prototype,i)&&r(e,i,{configurable:!0,value:t})}},function(e,t){t.f={}.propertyIsEnumerable},function(e,t,n){var r=n(51),o=n(100),i=n(183)("IE_PROTO"),a=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=o(e),r(e,i)?e[i]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?a:null}},function(e,t,n){var r,o;(function(){function n(e){function t(t,n,r,o,i,a){for(;i>=0&&i0?0:s-1;return arguments.length<3&&(o=n[a?a[l]:l],l+=e),t(n,r,o,a,l,s)}}function i(e){return function(t,n,r){var o,i;for(n=l(n,r),o=h(t),i=e>0?0:o-1;i>=0&&i0?a=i>=0?i:Math.max(i+s,a):s=i>=0?Math.min(i+1,s):i+s+1;else if(n&&i&&s)return i=n(r,o),r[i]===o?i:-1;if(o!==o)return i=t(R.call(r,a,s),V.isNaN),i>=0?i+a:-1;for(i=e>0?a:s-1;i>=0&&i=0&&t<=p},V.each=V.forEach=function(e,t,n){var r,o,i;if(t=u(t,n),m(e))for(r=0,o=e.length;r=0},V.invoke=function(e,t){var n=R.call(arguments,2),r=V.isFunction(t);return V.map(e,function(e){var o=r?t:e[t] -;return null==o?o:o.apply(e,n)})},V.pluck=function(e,t){return V.map(e,V.property(t))},V.where=function(e,t){return V.filter(e,V.matcher(t))},V.findWhere=function(e,t){return V.find(e,V.matcher(t))},V.max=function(e,t,n){var r,o,i,a,s=-1/0,u=-1/0;if(null==t&&null!=e)for(e=m(e)?e:V.values(e),i=0,a=e.length;is&&(s=r);else t=l(t,n),V.each(e,function(e,n,r){((o=t(e,n,r))>u||o===-1/0&&s===-1/0)&&(s=e,u=o)});return s},V.min=function(e,t,n){var r,o,i,a,s=1/0,u=1/0;if(null==t&&null!=e)for(e=m(e)?e:V.values(e),i=0,a=e.length;ir||void 0===n)return 1;if(nt?(s&&(clearTimeout(s),s=null),u=c,i=e.apply(r,o),s||(r=o=null)):s||!1===n.trailing||(s=setTimeout(a,l)),i}},V.debounce=function(e,t,n){var r,o,i,a,s,u=function(){var l=V.now()-a;l=0?r=setTimeout(u,t-l):(r=null,n||(s=e.apply(i,o),r||(i=o=null)))};return function(){i=this,o=arguments,a=V.now();var l=n&&!r;return r||(r=setTimeout(u,t)),l&&(s=e.apply(i,o),i=o=null),s}},V.wrap=function(e,t){return V.partial(t,e)},V.negate=function(e){return function(){return!e.apply(this,arguments)}},V.compose=function(){var e=arguments,t=e.length-1;return function(){for(var n=t,r=e[t].apply(this,arguments);n--;)r=e[n].call(this,r);return r}},V.after=function(e,t){return function(){if(--e<1)return t.apply(this,arguments)}},V.before=function(e,t){var n;return function(){return--e>0&&(n=t.apply(this,arguments)),e<=1&&(t=null),n}},V.once=V.partial(V.before,2),b=!{toString:null}.propertyIsEnumerable("toString"),_=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],V.keys=function(e){var t,n;if(!V.isObject(e))return[];if(W)return W(e);t=[] -;for(n in e)V.has(e,n)&&t.push(n);return b&&s(e,t),t},V.allKeys=function(e){var t,n;if(!V.isObject(e))return[];t=[];for(n in e)t.push(n);return b&&s(e,t),t},V.values=function(e){var t,n=V.keys(e),r=n.length,o=Array(r);for(t=0;t":">",'"':""","'":"'","`":"`"},k=V.invert(x),T=function(e){var t=function(t){return e[t]},n="(?:"+V.keys(e).join("|")+")",r=RegExp(n),o=RegExp(n,"g");return function(e){return e=null==e?"":""+e,r.test(e)?e.replace(o,t):e}},V.escape=T(x),V.unescape=T(k),V.result=function(e,t,n){var r=null==e?void 0:e[t];return void 0===r&&(r=n),V.isFunction(r)?r.call(e):r},S=0,V.uniqueId=function(e){var t=++S+"";return e?e+t:t},V.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g},C=/(.)^/,E={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},M=/\\|'|\r|\n|\u2028|\u2029/g,O=function(e){return"\\"+E[e]},V.template=function(e,t,n){var r,o,i,a,s,u;!t&&n&&(t=n),t=V.defaults({},t,V.templateSettings),r=RegExp([(t.escape||C).source,(t.interpolate||C).source,(t.evaluate||C).source].join("|")+"|$","g"),o=0,i="__p+='",e.replace(r,function(t,n,r,a,s){return i+=e.slice(o,s).replace(M,O),o=s+t.length,n?i+="'+\n((__t=("+n+"))==null?'':_.escape(__t))+\n'":r?i+="'+\n((__t=("+r+"))==null?'':__t)+\n'":a&&(i+="';\n"+a+"\n__p+='"),t}),i+="';\n",t.variable||(i="with(obj||{}){\n"+i+"}\n"),i="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+i+"return __p;\n";try{a=Function(t.variable||"obj","_",i)}catch(e){throw e.source=i,e}return s=function(e){return a.call(this,e,V)},u=t.variable||"obj",s.source="function("+u+"){\n"+i+"}",s},V.chain=function(e){var t=V(e);return t._chain=!0,t},D=function(e,t){return e._chain?V(t).chain():t},V.mixin=function(e){V.each(V.functions(e),function(t){var n=V[t]=e[t];V.prototype[t]=function(){var e=[this._wrapped];return F.apply(e,arguments),D(this,n.apply(V,e))}})},V.mixin(V),V.each(["pop","push","reverse","shift","sort","splice","unshift"],function(e){var t=L[e];V.prototype[e]=function(){var n=this._wrapped;return t.apply(n,arguments), -"shift"!==e&&"splice"!==e||0!==n.length||delete n[0],D(this,n)}}),V.each(["concat","join","slice"],function(e){var t=L[e];V.prototype[e]=function(){return D(this,t.apply(this._wrapped,arguments))}}),V.prototype.value=function(){return this._wrapped},V.prototype.valueOf=V.prototype.toJSON=V.prototype.value,V.prototype.toString=function(){return""+this._wrapped},r=[],void 0!==(o=function(){return V}.apply(t,r))&&(e.exports=o)}).call(this)},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});var o=function(){function e(){r(this,e),this.observers={}}return e.prototype.on=function(e,t){var n=this;e.split(" ").forEach(function(e){n.observers[e]=n.observers[e]||[],n.observers[e].push(t)})},e.prototype.off=function(e,t){var n=this;this.observers[e]&&this.observers[e].forEach(function(){if(t){var r=n.observers[e].indexOf(t);r>-1&&n.observers[e].splice(r,1)}else delete n.observers[e]})},e.prototype.emit=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r-1?e.replace(/###/g,"."):e}for(var o,i="string"!=typeof t?[].concat(t):t.split(".");i.length>1;){if(!e)return{};o=r(i.shift()),!e[o]&&n&&(e[o]=new n),e=e[o]}return e?{obj:e,k:r(i.shift())}:{}}function a(e,t,n){var r=i(e,t,Object);r.obj[r.k]=n}function s(e,t,n,r){var o=i(e,t,Object),a=o.obj,s=o.k;a[s]=a[s]||[],r&&(a[s]=a[s].concat(n)),r||a[s].push(n)}function u(e,t){var n=i(e,t),r=n.obj,o=n.k;if(r)return r[o]}function l(e,t,n){for(var r in t)r in e?"string"==typeof e[r]||e[r]instanceof String||"string"==typeof t[r]||t[r]instanceof String?n&&(e[r]=t[r]):l(e[r],t[r],n):e[r]=t[r];return e}function c(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}function f(e){return"string"==typeof e?e.replace(/[&<>"'\/]/g,function(e){return d[e]}):e}Object.defineProperty(t,"__esModule",{value:!0}),t.makeString=r,t.copy=o,t.setPath=a,t.pushPath=s,t.getPath=u,t.deepExtend=l,t.regexEscape=c,t.escape=f;var d={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"}},,,,,,,,,,,,,,,,,function(e,t){e.exports=!1},function(e,t){var n=Math.ceil,r=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(e>0?r:n)(e)}},function(e,t,n){var r=n(138),o=Math.max,i=Math.min;e.exports=function(e,t){return e=r(e),e<0?o(e+t,0):i(e,t)}},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t,n){var r=n(16),o=n(426),i=n(184),a=n(183)("IE_PROTO"),s=function(){},u="prototype",l=function(){var e,t=n(179)("iframe"),r=i.length,o="<",a=">";for(t.style.display="none",n(256).appendChild(t),t.src="javascript:",e=t.contentWindow.document,e.open(), -e.write(o+"script"+a+"document.F=Object"+o+"/script"+a),e.close(),l=e.F;r--;)delete l[u][i[r]];return l()};e.exports=Object.create||function(e,t){var n;return null!==e?(s[u]=r(e),n=new s,s[u]=null,n[a]=e):n=l(),void 0===t?n:o(n,t)}},function(e,t){e.exports={}},function(e,t,n){"use strict";function r(e){return function(){return e}}var o=function(){};o.thatReturns=r,o.thatReturnsFalse=r(!1),o.thatReturnsTrue=r(!0),o.thatReturnsNull=r(null),o.thatReturnsThis=function(){return this},o.thatReturnsArgument=function(e){return e},e.exports=o},,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,n){var r,o,i;!function(a){o=[n(13),n(75)],r=a,void 0!==(i="function"==typeof r?r.apply(t,o):r)&&(e.exports=i)}(function(e){var t=0,n=Array.prototype.slice;return e.cleanData=function(t){return function(n){var r,o,i;for(i=0;null!=(o=n[i]);i++)try{r=e._data(o,"events"),r&&r.remove&&e(o).triggerHandler("remove")}catch(e){}t(n)}}(e.cleanData),e.widget=function(t,n,r){var o,i,a,s,u={},l=t.split(".")[0];return t=t.split(".")[1],s=l+"-"+t,r||(r=n,n=e.Widget),e.isArray(r)&&(r=e.extend.apply(null,[{}].concat(r))),e.expr[":"][s.toLowerCase()]=function(t){return!!e.data(t,s)},e[l]=e[l]||{},o=e[l][t],i=e[l][t]=function(e,t){if(!this._createWidget)return new i(e,t);arguments.length&&this._createWidget(e,t)},e.extend(i,o,{version:r.version,_proto:e.extend({},r),_childConstructors:[]}),a=new n,a.options=e.widget.extend({},a.options),e.each(r,function(t,r){if(!e.isFunction(r))return void(u[t]=r);u[t]=function(){function e(){return n.prototype[t].apply(this,arguments)}function o(e){return n.prototype[t].apply(this,e)}return function(){var t,n=this._super,i=this._superApply;return this._super=e,this._superApply=o,t=r.apply(this,arguments),this._super=n,this._superApply=i,t}}()}),i.prototype=e.widget.extend(a,{widgetEventPrefix:o?a.widgetEventPrefix||t:t},u,{constructor:i,namespace:l,widgetName:t,widgetFullName:s}),o?(e.each(o._childConstructors,function(t,n){var r=n.prototype;e.widget(r.namespace+"."+r.widgetName,i,n._proto)}),delete o._childConstructors):n._childConstructors.push(i),e.widget.bridge(t,i),i},e.widget.extend=function(t){for(var r,o,i=n.call(arguments,1),a=0,s=i.length;a",options:{classes:{},disabled:!1,create:null},_createWidget:function(n,r){r=e(r||this.defaultElement||this)[0],this.element=e(r),this.uuid=t++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=e(),this.hoverable=e(),this.focusable=e(),this.classesElementLookup={},r!==this&&(e.data(r,this.widgetFullName,this),this._on(!0,this.element,{remove:function(e){e.target===r&&this.destroy()}}),this.document=e(r.style?r.ownerDocument:r.document||r),this.window=e(this.document[0].defaultView||this.document[0].parentWindow)),this.options=e.widget.extend({},this.options,this._getCreateOptions(),n),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:e.noop,_create:e.noop,_init:e.noop,destroy:function(){var t=this;this._destroy(),e.each(this.classesElementLookup,function(e,n){t._removeClass(n,e)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:e.noop,widget:function(){return this.element},option:function(t,n){var r,o,i,a=t;if(0===arguments.length)return e.widget.extend({},this.options);if("string"==typeof t)if(a={},r=t.split("."),t=r.shift(),r.length){for(o=a[t]=e.widget.extend({},this.options[t]),i=0;i22025.465794806718||n(10)<22025.465794806718||-2e-17!=n(-2e-17)?function(e){return 0==(e=+e)?e:e>-1e-6&&e<1e-6?e+e*e/2:Math.exp(e)-1}:n},function(e,t,n){"use strict";var r=n(137),o=n(4),i=n(96),a=n(79),s=n(51),u=n(142),l=n(261),c=n(115),f=n(117),d=n(20)("iterator"),p=!([].keys&&"next"in[].keys()),h="keys",m="values",g=function(){return this};e.exports=function(e,t,n,y,v,b,_){var w,x,k,T,S,C,E,M,O,D,N,P;if(l(n,t,y),w=function(e){if(!p&&e in S)return S[e];switch(e){case h:case m:return function(){return new n(this,e)}}return function(){return new n(this,e)}},x=t+" Iterator",k=v==m,T=!1,S=e.prototype,C=S[d]||S["@@iterator"]||v&&S[v],E=C||w(v),M=v?k?w("entries"):E:void 0,O="Array"==t?S.entries||C:C,O&&(P=f(O.call(new e)))!==Object.prototype&&(c(P,x,!0),r||s(P,d)||a(P,d,g)),k&&C&&C.name!==m&&(T=!0,E=function(){return C.call(this)}),r&&!_||!p&&!T&&S[d]||a(S,d,E),u[t]=E,u[x]=g,v)if(D={values:k?E:w(m),keys:b?E:w(h),entries:M},_)for(N in D)N in S||i(S,N,D[N]);else o(o.P+o.F*(p||T),t,D);return D}},function(e,t,n){var r=n(470),o=n(82);e.exports=function(e,t,n){if(r(t))throw TypeError("String#"+n+" doesn't accept regex!");return o(e)+""}},function(e,t,n){var r=n(20)("match");e.exports=function(e){var t=/./;try{"/./"[e](t)}catch(n){try{return t[r]=!1,!"/./"[e](t)}catch(e){}}return!0}},function(e,t,n){var r,o=n(20)("iterator"),i=!1;try{r=[7][o](),r.return=function(){i=!0},Array.from(r,function(){throw 2})}catch(e){}e.exports=function(e,t){var n,r,a;if(!t&&!i)return!1;n=!1;try{r=[7],a=r[o](),a.next=function(){return{ -done:n=!0}},r[o]=function(){return a},e(r)}catch(e){}return n}},function(e,t,n){"use strict";var r=n(18),o=n(37),i=n(55),a=n(20)("species");e.exports=function(e){var t=r[e];i&&t&&!t[a]&&o.f(t,a,{configurable:!0,get:function(){return this}})}},function(e,t){e.exports=function(e,t,n,r){if(!(e instanceof t)||void 0!==r&&r in e)throw TypeError(n+": incorrect invocation!");return e}},function(e,t,n){var r=n(68),o=n(262),i=n(263),a=n(16),s=n(63),u=n(265),l={},c={};t=e.exports=function(e,t,n,f,d){var p,h,m,g,y=d?function(){return e}:u(e),v=r(n,f,t?2:1),b=0;if("function"!=typeof y)throw TypeError(e+" is not iterable!");if(i(y)){for(p=s(e.length);p>b;b++)if((g=t?v(a(h=e[b])[0],h[1]):v(e[b]))===l||g===c)return g}else for(m=y.call(e);!(h=m.next()).done;)if((g=o(m,v,h.value,t))===l||g===c)return g},t.BREAK=l,t.RETURN=c},function(e,t,n){var r=n(96);e.exports=function(e,t,n){for(var o in t)r(e,o,t[o],n);return e}},function(e,t,n){"use strict";function r(e){return"number"==typeof e&&isFinite(e)}function o(e){return"number"==typeof e&&e%1==0}function i(e){return!(e<=0||e>0)}function a(e){return Math.round(1e10*e)/1e10}function s(e,t){var n=e/t,r=Math.floor(n),o=n-r;return o>2e-10?a(o>.5?(r+1)*t:r*t):e}Object.defineProperty(t,"__esModule",{value:!0}),t.isNumber=r,t.isInteger=o,t.isNaN=i,t.fixComputationError=a,t.alignTo=s},function(e,t){function n(e){return e&&e.__esModule?e:{default:e}}e.exports=n},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}var o=n(556),i=r(o),a=n(291),s=r(a);e.exports={TransitionGroup:s.default,CSSTransitionGroup:i.default}},,,function(e,t,n){var r,o,i;!function(a){o=[n(13),n(388),n(75),n(168)],r=a,void 0!==(i="function"==typeof r?r.apply(t,o):r)&&(e.exports=i)}(function(e){var t=!1;return e(document).on("mouseup",function(){t=!1}),e.widget("ui.mouse",{version:"1.12.1",options:{cancel:"input, textarea, button, select, option",distance:1,delay:0},_mouseInit:function(){var t=this;this.element.on("mousedown."+this.widgetName,function(e){return t._mouseDown(e)}).on("click."+this.widgetName,function(n){if(!0===e.data(n.target,t.widgetName+".preventClickEvent"))return e.removeData(n.target,t.widgetName+".preventClickEvent"),n.stopImmediatePropagation(),!1}),this.started=!1},_mouseDestroy:function(){this.element.off("."+this.widgetName),this._mouseMoveDelegate&&this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate)},_mouseDown:function(n){if(!t){this._mouseMoved=!1,this._mouseStarted&&this._mouseUp(n),this._mouseDownEvent=n;var r=this,o=1===n.which,i=!("string"!=typeof this.options.cancel||!n.target.nodeName)&&e(n.target).closest(this.options.cancel).length;return!(o&&!i&&this._mouseCapture(n))||(this.mouseDelayMet=!this.options.delay,this.mouseDelayMet||(this._mouseDelayTimer=setTimeout(function(){r.mouseDelayMet=!0},this.options.delay)),this._mouseDistanceMet(n)&&this._mouseDelayMet(n)&&(this._mouseStarted=!1!==this._mouseStart(n),!this._mouseStarted)?(n.preventDefault(), -!0):(!0===e.data(n.target,this.widgetName+".preventClickEvent")&&e.removeData(n.target,this.widgetName+".preventClickEvent"),this._mouseMoveDelegate=function(e){return r._mouseMove(e)},this._mouseUpDelegate=function(e){return r._mouseUp(e)},this.document.on("mousemove."+this.widgetName,this._mouseMoveDelegate).on("mouseup."+this.widgetName,this._mouseUpDelegate),n.preventDefault(),t=!0,!0))}},_mouseMove:function(t){if(this._mouseMoved){if(e.ui.ie&&(!document.documentMode||document.documentMode<9)&&!t.button)return this._mouseUp(t);if(!t.which)if(t.originalEvent.altKey||t.originalEvent.ctrlKey||t.originalEvent.metaKey||t.originalEvent.shiftKey)this.ignoreMissingWhich=!0;else if(!this.ignoreMissingWhich)return this._mouseUp(t)}return(t.which||t.button)&&(this._mouseMoved=!0),this._mouseStarted?(this._mouseDrag(t),t.preventDefault()):(this._mouseDistanceMet(t)&&this._mouseDelayMet(t)&&(this._mouseStarted=!1!==this._mouseStart(this._mouseDownEvent,t),this._mouseStarted?this._mouseDrag(t):this._mouseUp(t)),!this._mouseStarted)},_mouseUp:function(n){this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate),this._mouseStarted&&(this._mouseStarted=!1,n.target===this._mouseDownEvent.target&&e.data(n.target,this.widgetName+".preventClickEvent",!0),this._mouseStop(n)),this._mouseDelayTimer&&(clearTimeout(this._mouseDelayTimer),delete this._mouseDelayTimer),this.ignoreMissingWhich=!1,t=!1,n.preventDefault()},_mouseDistanceMet:function(e){return Math.max(Math.abs(this._mouseDownEvent.pageX-e.pageX),Math.abs(this._mouseDownEvent.pageY-e.pageY))>=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}})})},function(e,t,n){"use strict";function r(){return new Promise(function(e){n.e(0).then(function(t){n(389),e()}.bind(null,n)).catch(n.oe)})}Object.defineProperty(t,"__esModule",{value:!0}),n(13),t.lazyVelocity=r,$.fn.velocity=function(){var e,t=this,n=[];for(e=0;eu;)r(s,n=t[u++])&&(~i(l,n)||l.push(n));return l}},function(e,t,n){var r=n(62),o=n(63),i=n(139);e.exports=function(e){return function(t,n,a){var s,u=r(t),l=o(u.length),c=i(a,l);if(e&&n!=n){for(;l>c;)if((s=u[c++])!=s)return!0}else for(;l>c;c++)if((e||c in u)&&u[c]===n)return e||c||0;return!e&&-1}}},function(e,t,n){var r=n(81);e.exports=Array.isArray||function(e){return"Array"==r(e)}},function(e,t,n){e.exports=n(18).document&&document.documentElement},function(e,t,n){var r=n(29),o=Math.floor;e.exports=function(e){return!r(e)&&isFinite(e)&&o(e)===e} -},function(e,t,n){var r=n(4),o=n(82),i=n(36),a=n(187),s="["+a+"]",u="​…",l=RegExp("^"+s+s+"*"),c=RegExp(s+s+"*$"),f=function(e,t,n){var o={},s=i(function(){return!!a[e]()||u[e]()!=u}),l=o[e]=s?t(d):a[e];n&&(o[n]=l),r(r.P+r.F*s,"String",o)},d=f.trim=function(e,t){return e=o(e)+"",1&t&&(e=e.replace(l,"")),2&t&&(e=e.replace(c,"")),e};e.exports=f},function(e,t){e.exports=Math.log1p||function(e){return(e=+e)>-1e-8&&e<1e-8?e-e*e/2:Math.log(1+e)}},function(e,t,n){var r=n(138),o=n(82);e.exports=function(e){return function(t,n){var i,a,s=o(t)+"",u=r(n),l=s.length;return u<0||u>=l?e?"":void 0:(i=s.charCodeAt(u),i<55296||i>56319||u+1===l||(a=s.charCodeAt(u+1))<56320||a>57343?e?s.charAt(u):i:e?s.slice(u,u+2):a-56320+(i-55296<<10)+65536)}}},function(e,t,n){"use strict";var r=n(141),o=n(80),i=n(115),a={};n(79)(a,n(20)("iterator"),function(){return this}),e.exports=function(e,t,n){e.prototype=r(a,{next:o(1,n)}),i(e,t+" Iterator")}},function(e,t,n){var r=n(16);e.exports=function(e,t,n,o){try{return o?t(r(n)[0],n[1]):t(n)}catch(t){var i=e.return;throw void 0!==i&&r(i.call(e)),t}}},function(e,t,n){var r=n(142),o=n(20)("iterator"),i=Array.prototype;e.exports=function(e){return void 0!==e&&(r.Array===e||i[o]===e)}},function(e,t,n){"use strict";var r=n(37),o=n(80);e.exports=function(e,t,n){t in e?r.f(e,t,o(0,n)):e[t]=n}},function(e,t,n){var r=n(266),o=n(20)("iterator"),i=n(142);e.exports=n(95).getIteratorMethod=function(e){if(void 0!=e)return e[o]||e["@@iterator"]||i[r(e)]}},function(e,t,n){var r=n(81),o=n(20)("toStringTag"),i="Arguments"==r(function(){return arguments}()),a=function(e,t){try{return e[t]}catch(e){}};e.exports=function(e){var t,n,s;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=a(t=Object(e),o))?n:i?r(t):"Object"==(s=r(t))&&"function"==typeof t.callee?"Arguments":s}},function(e,t,n){var r=n(68),o=n(182),i=n(100),a=n(63),s=n(485);e.exports=function(e,t){var n=1==e,u=2==e,l=3==e,c=4==e,f=6==e,d=5==e||f,p=t||s;return function(t,s,h){for(var m,g,y=i(t),v=o(y),b=r(s,h,3),_=a(v.length),w=0,x=n?p(t,_):u?p(t,0):void 0;_>w;w++)if((d||w in v)&&(m=v[w],g=b(m,w,y),e))if(n)x[w]=g;else if(g)switch(e){case 3:return!0;case 5:return m;case 6:return w;case 2:x.push(m)}else if(c)return!1;return f?-1:l||c?c:x}}},function(e,t){e.exports=function(e,t){return{value:t,done:!!e}}},function(e,t,n){var r,o,i,a=n(68),s=n(270),u=n(256),l=n(179),c=n(18),f=c.process,d=c.setImmediate,p=c.clearImmediate,h=c.MessageChannel,m=0,g={},y="onreadystatechange",v=function(){var e,t=+this;g.hasOwnProperty(t)&&(e=g[t],delete g[t],e())},b=function(e){v.call(e.data)};d&&p||(d=function(e){for(var t=[],n=1;arguments.length>n;)t.push(arguments[n++]);return g[++m]=function(){s("function"==typeof e?e:Function(e),t)},r(m),m},p=function(e){delete g[e]},"process"==n(81)(f)?r=function(e){f.nextTick(a(v,e,1))}:h?(o=new h,i=o.port2,o.port1.onmessage=b,r=a(i.postMessage,i,1)):c.addEventListener&&"function"==typeof postMessage&&!c.importScripts?(r=function(e){c.postMessage(e+"","*")},c.addEventListener("message",b,!1)):r=y in l("script")?function(e){ -u.appendChild(l("script"))[y]=function(){u.removeChild(this),v.call(e)}}:function(e){setTimeout(a(v,e,1),0)}),e.exports={set:d,clear:p}},function(e,t){e.exports=function(e,t,n){var r=void 0===n;switch(t.length){case 0:return r?e():e.call(n);case 1:return r?e(t[0]):e.call(n,t[0]);case 2:return r?e(t[0],t[1]):e.call(n,t[0],t[1]);case 3:return r?e(t[0],t[1],t[2]):e.call(n,t[0],t[1],t[2]);case 4:return r?e(t[0],t[1],t[2],t[3]):e.call(n,t[0],t[1],t[2],t[3])}return e.apply(n,t)}},function(e,t,n){"use strict";var r=n(37).f,o=n(141),i=n(197),a=n(68),s=n(195),u=n(82),l=n(196),c=n(190),f=n(268),d=n(194),p=n(55),h=n(180).fastKey,m=p?"_s":"size",g=function(e,t){var n,r=h(t);if("F"!==r)return e._i[r];for(n=e._f;n;n=n.n)if(n.k==t)return n};e.exports={getConstructor:function(e,t,n,c){var f=e(function(e,r){s(e,f,t,"_i"),e._i=o(null),e._f=void 0,e._l=void 0,e[m]=0,void 0!=r&&l(r,n,e[c],e)});return i(f.prototype,{clear:function(){for(var e=this,t=e._i,n=e._f;n;n=n.n)n.r=!0,n.p&&(n.p=n.p.n=void 0),delete t[n.i];e._f=e._l=void 0,e[m]=0},delete:function(e){var t,n,r=this,o=g(r,e);return o&&(t=o.n,n=o.p,delete r._i[o.i],o.r=!0,n&&(n.n=t),t&&(t.p=n),r._f==o&&(r._f=t),r._l==o&&(r._l=n),r[m]--),!!o},forEach:function(e){s(this,f,"forEach");for(var t,n=a(e,arguments.length>1?arguments[1]:void 0,3);t=t?t.n:this._f;)for(n(t.v,t.k,this);t&&t.r;)t=t.p},has:function(e){return!!g(this,e)}}),p&&r(f.prototype,"size",{get:function(){return u(this[m])}}),f},def:function(e,t,n){var r,o,i=g(e,t);return i?i.v=n:(e._l=i={i:o=h(t,!0),k:t,v:n,p:r=e._l,n:void 0,r:!1},e._f||(e._f=i),r&&(r.n=i),e[m]++,"F"!==o&&(e._i[o]=i)),e},getEntry:g,setStrong:function(e,t,n){c(e,t,function(e,t){this._t=e,this._k=t,this._l=void 0},function(){for(var e=this,t=e._k,n=e._l;n&&n.r;)n=n.p;return e._t&&(e._l=n=n?n.n:e._t._f)?"keys"==t?f(0,n.k):"values"==t?f(0,n.v):f(0,[n.k,n.v]):(e._t=void 0,f(1))},n?"entries":"values",!n,!0),d(t)}}},function(e,t,n){"use strict";var r=n(18),o=n(4),i=n(96),a=n(197),s=n(180),u=n(196),l=n(195),c=n(29),f=n(36),d=n(193),p=n(115),h=n(496);e.exports=function(e,t,n,m,g,y){var v,b,_,w,x,k=r[e],T=k,S=g?"set":"add",C=T&&T.prototype,E={},M=function(e){var t=C[e];i(C,e,"delete"==e?function(e){return!(y&&!c(e))&&t.call(this,0===e?0:e)}:"has"==e?function(e){return!(y&&!c(e))&&t.call(this,0===e?0:e)}:"get"==e?function(e){return y&&!c(e)?void 0:t.call(this,0===e?0:e)}:"add"==e?function(e){return t.call(this,0===e?0:e),this}:function(e,n){return t.call(this,0===e?0:e,n),this})};return"function"==typeof T&&(y||C.forEach&&!f(function(){(new T).entries().next()}))?(v=new T,b=v[S](y?{}:-0,1)!=v,_=f(function(){v.has(1)}),w=d(function(e){new T(e)}),x=!y&&f(function(){for(var e=new T,t=5;t--;)e[S](t,t);return!e.has(-0)}),w||(T=t(function(t,n){l(t,T,e);var r=h(new k,t,T);return void 0!=n&&u(n,g,r[S],r),r}),T.prototype=C,C.constructor=T),(_||x)&&(M("delete"),M("has"),g&&M("get")),(x||b)&&M(S),y&&C.clear&&delete C.clear):(T=m.getConstructor(t,e,g,S),a(T.prototype,n),s.NEED=!0),p(T,e),E[e]=T,o(o.G+o.W+o.F*(T!=k),E),y||m.setStrong(T,e,g),T}},function(e,t,n){ -var r=n(98),o=n(62),i=n(116).f;e.exports=function(e){return function(t){for(var n,a=o(t),s=r(a),u=s.length,l=0,c=[];u>l;)i.call(a,n=s[l++])&&c.push(e?[n,a[n]]:a[n]);return c}}},function(e,t,n){!function(e,t){t(n(38))}(0,function(e){"use strict";return e.defineLocale("en-gb",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},ordinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")},week:{dow:1,doy:4}})})},function(e,t,n){!function(e,t){t(n(38))}(0,function(e){"use strict";var t="Ene._Feb._Mar._Abr._May._Jun._Jul._Ago._Sep._Oct._Nov._Dic.".split("_"),n="Ene_Feb_Mar_Abr_May_Jun_Jul_Ago_Sep_Oct_Nov_Dic".split("_");return e.defineLocale("es",{months:"Enero_Febrero_Marzo_Abril_Mayo_Junio_Julio_Agosto_Septiembre_Octubre_Noviembre_Diciembre".split("_"),monthsShort:function(e,r){return/-MMM-/.test(r)?n[e.month()]:t[e.month()]},weekdays:"Domingo_Lunes_Martes_Miércoles_Jueves_Viernes_Sábado".split("_"),weekdaysShort:"Dom._Lun._Mar._Mié._Jue._Vie._Sáb.".split("_"),weekdaysMin:"Do_Lu_Ma_Mi_Ju_Vi_Sá".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY H:mm",LLLL:"dddd, D [de] MMMM [de] YYYY H:mm"},calendar:{sameDay:function(){return"[hoy a la"+(1!==this.hours()?"s":"")+"] LT"},nextDay:function(){return"[mañana a la"+(1!==this.hours()?"s":"")+"] LT"},nextWeek:function(){return"dddd [a la"+(1!==this.hours()?"s":"")+"] LT"},lastDay:function(){return"[ayer a la"+(1!==this.hours()?"s":"")+"] LT"},lastWeek:function(){return"[el] dddd [pasado a la"+(1!==this.hours()?"s":"")+"] LT"},sameElse:"L"},relativeTime:{future:"en %s",past:"hace %s",s:"unos segundos",m:"un minuto",mm:"%d minutos",h:"una hora",hh:"%d horas",d:"un día",dd:"%d días",M:"un mes",MM:"%d meses",y:"un año",yy:"%d años"},ordinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})})},function(e,t,n){!function(e,t){t(n(38))}(0,function(e){"use strict";return e.defineLocale("it",{months:"gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre".split("_"),monthsShort:"gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic".split("_"),weekdays:"Domenica_Lunedì_Martedì_Mercoledì_Giovedì_Venerdì_Sabato".split("_"), -weekdaysShort:"Dom_Lun_Mar_Mer_Gio_Ven_Sab".split("_"),weekdaysMin:"D_L_Ma_Me_G_V_S".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Oggi alle] LT",nextDay:"[Domani alle] LT",nextWeek:"dddd [alle] LT",lastDay:"[Ieri alle] LT",lastWeek:function(){switch(this.day()){case 0:return"[la scorsa] dddd [alle] LT";default:return"[lo scorso] dddd [alle] LT"}},sameElse:"L"},relativeTime:{future:function(e){return(/^[0-9].+$/.test(e)?"tra":"in")+" "+e},past:"%s fa",s:"alcuni secondi",m:"un minuto",mm:"%d minuti",h:"un'ora",hh:"%d ore",d:"un giorno",dd:"%d giorni",M:"un mese",MM:"%d mesi",y:"un anno",yy:"%d anni"},ordinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})})},function(e,t,n){!function(e,t){t(n(38))}(0,function(e){"use strict";return e.defineLocale("ja",{months:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),weekdays:"日曜日_月曜日_火曜日_水曜日_木曜日_金曜日_土曜日".split("_"),weekdaysShort:"日_月_火_水_木_金_土".split("_"),weekdaysMin:"日_月_火_水_木_金_土".split("_"),longDateFormat:{LT:"Ah時m分",LTS:"Ah時m分s秒",L:"YYYY/MM/DD",LL:"YYYY年M月D日",LLL:"YYYY年M月D日Ah時m分",LLLL:"YYYY年M月D日Ah時m分 dddd"},meridiemParse:/午前|午後/i,isPM:function(e){return"午後"===e},meridiem:function(e,t,n){return e<12?"午前":"午後"},calendar:{sameDay:"[今日] LT",nextDay:"[明日] LT",nextWeek:"[来週]dddd LT",lastDay:"[昨日] LT",lastWeek:"[前週]dddd LT",sameElse:"L"},relativeTime:{future:"%s後",past:"%s前",s:"数秒",m:"1分",mm:"%d分",h:"1時間",hh:"%d時間",d:"1日",dd:"%d日",M:"1ヶ月",MM:"%dヶ月",y:"1年",yy:"%d年"}})})},function(e,t,n){!function(e,t){t(n(38))}(0,function(e){"use strict";return e.defineLocale("ko",{months:"1월_2월_3월_4월_5월_6월_7월_8월_9월_10월_11월_12월".split("_"),monthsShort:"1월_2월_3월_4월_5월_6월_7월_8월_9월_10월_11월_12월".split("_"),weekdays:"일요일_월요일_화요일_수요일_목요일_금요일_토요일".split("_"),weekdaysShort:"일_월_화_수_목_금_토".split("_"),weekdaysMin:"일_월_화_수_목_금_토".split("_"),longDateFormat:{LT:"A h시 m분",LTS:"A h시 m분 s초",L:"YYYY.MM.DD",LL:"YYYY년 MMMM D일",LLL:"YYYY년 MMMM D일 A h시 m분",LLLL:"YYYY년 MMMM D일 dddd A h시 m분"},calendar:{sameDay:"오늘 LT",nextDay:"내일 LT",nextWeek:"dddd LT",lastDay:"어제 LT",lastWeek:"지난주 dddd LT",sameElse:"L"},relativeTime:{future:"%s 후",past:"%s 전",s:"몇초",ss:"%d초",m:"일분",mm:"%d분",h:"한시간",hh:"%d시간",d:"하루",dd:"%d일",M:"한달",MM:"%d달",y:"일년",yy:"%d년"},ordinalParse:/\d{1,2}일/,ordinal:"%d일",meridiemParse:/오전|오후/,isPM:function(e){return"오후"===e},meridiem:function(e,t,n){return e<12?"오전":"오후"}})})},function(e,t,n){!function(e,t){t(n(38))}(0,function(e){"use strict";function t(e){return e%10<5&&e%10>1&&~~(e/10)%10!=1}function n(e,n,r){var o=e+" ";switch(r){case"m":return n?"minuta":"minutę";case"mm":return o+(t(e)?"minuty":"minut");case"h":return n?"godzina":"godzinę";case"hh":return o+(t(e)?"godziny":"godzin");case"MM":return o+(t(e)?"miesiące":"miesięcy");case"yy":return o+(t(e)?"lata":"lat")}} -var r="styczeń_luty_marzec_kwiecień_maj_czerwiec_lipiec_sierpień_wrzesień_październik_listopad_grudzień".split("_"),o="stycznia_lutego_marca_kwietnia_maja_czerwca_lipca_sierpnia_września_października_listopada_grudnia".split("_");return e.defineLocale("pl",{months:function(e,t){return""===t?"("+o[e.month()]+"|"+r[e.month()]+")":/D MMMM/.test(t)?o[e.month()]:r[e.month()]},monthsShort:"sty_lut_mar_kwi_maj_cze_lip_sie_wrz_paź_lis_gru".split("_"),weekdays:"niedziela_poniedziałek_wtorek_środa_czwartek_piątek_sobota".split("_"),weekdaysShort:"nie_pon_wt_śr_czw_pt_sb".split("_"),weekdaysMin:"N_Pn_Wt_Śr_Cz_Pt_So".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Dziś o] LT",nextDay:"[Jutro o] LT",nextWeek:"[W] dddd [o] LT",lastDay:"[Wczoraj o] LT",lastWeek:function(){switch(this.day()){case 0:return"[W zeszłą niedzielę o] LT";case 3:return"[W zeszłą środę o] LT";case 6:return"[W zeszłą sobotę o] LT";default:return"[W zeszły] dddd [o] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"%s temu",s:"kilka sekund",m:n,mm:n,h:n,hh:n,d:"1 dzień",dd:"%d dni",M:"miesiąc",MM:n,y:"rok",yy:n},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})})},function(e,t,n){!function(e,t){t(n(38))}(0,function(e){"use strict";return e.defineLocale("pt",{months:"Janeiro_Fevereiro_Março_Abril_Maio_Junho_Julho_Agosto_Setembro_Outubro_Novembro_Dezembro".split("_"),monthsShort:"Jan_Fev_Mar_Abr_Mai_Jun_Jul_Ago_Set_Out_Nov_Dez".split("_"),weekdays:"Domingo_Segunda-Feira_Terça-Feira_Quarta-Feira_Quinta-Feira_Sexta-Feira_Sábado".split("_"),weekdaysShort:"Dom_Seg_Ter_Qua_Qui_Sex_Sáb".split("_"),weekdaysMin:"Dom_2ª_3ª_4ª_5ª_6ª_Sáb".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY HH:mm",LLLL:"dddd, D [de] MMMM [de] YYYY HH:mm"},calendar:{sameDay:"[Hoje às] LT",nextDay:"[Amanhã às] LT",nextWeek:"dddd [às] LT",lastDay:"[Ontem às] LT",lastWeek:function(){return 0===this.day()||6===this.day()?"[Último] dddd [às] LT":"[Última] dddd [às] LT"},sameElse:"L"},relativeTime:{future:"em %s",past:"há %s",s:"segundos",m:"um minuto",mm:"%d minutos",h:"uma hora",hh:"%d horas",d:"um dia",dd:"%d dias",M:"um mês",MM:"%d meses",y:"um ano",yy:"%d anos"},ordinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})})},function(e,t,n){!function(e,t){t(n(38))}(0,function(e){"use strict";return e.defineLocale("pt-br",{months:"Janeiro_Fevereiro_Março_Abril_Maio_Junho_Julho_Agosto_Setembro_Outubro_Novembro_Dezembro".split("_"),monthsShort:"Jan_Fev_Mar_Abr_Mai_Jun_Jul_Ago_Set_Out_Nov_Dez".split("_"),weekdays:"Domingo_Segunda-Feira_Terça-Feira_Quarta-Feira_Quinta-Feira_Sexta-Feira_Sábado".split("_"),weekdaysShort:"Dom_Seg_Ter_Qua_Qui_Sex_Sáb".split("_"),weekdaysMin:"Dom_2ª_3ª_4ª_5ª_6ª_Sáb".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY [às] HH:mm",LLLL:"dddd, D [de] MMMM [de] YYYY [às] HH:mm"},calendar:{ -sameDay:"[Hoje às] LT",nextDay:"[Amanhã às] LT",nextWeek:"dddd [às] LT",lastDay:"[Ontem às] LT",lastWeek:function(){return 0===this.day()||6===this.day()?"[Último] dddd [às] LT":"[Última] dddd [às] LT"},sameElse:"L"},relativeTime:{future:"em %s",past:"%s atrás",s:"poucos segundos",m:"um minuto",mm:"%d minutos",h:"uma hora",hh:"%d horas",d:"um dia",dd:"%d dias",M:"um mês",MM:"%d meses",y:"um ano",yy:"%d anos"},ordinalParse:/\d{1,2}º/,ordinal:"%dº"})})},function(e,t,n){!function(e,t){t(n(38))}(0,function(e){"use strict";function t(e,t){var n=e.split("_");return t%10==1&&t%100!=11?n[0]:t%10>=2&&t%10<=4&&(t%100<10||t%100>=20)?n[1]:n[2]}function n(e,n,r){var o={mm:n?"минута_минуты_минут":"минуту_минуты_минут",hh:"час_часа_часов",dd:"день_дня_дней",MM:"месяц_месяца_месяцев",yy:"год_года_лет"};return"m"===r?n?"минута":"минуту":e+" "+t(o[r],+e)}function r(e,t){return{nominative:"январь_февраль_март_апрель_май_июнь_июль_август_сентябрь_октябрь_ноябрь_декабрь".split("_"),accusative:"января_февраля_марта_апреля_мая_июня_июля_августа_сентября_октября_ноября_декабря".split("_")}[/D[oD]?(\[[^\[\]]*\]|\s+)+MMMM?/.test(t)?"accusative":"nominative"][e.month()]}function o(e,t){return{nominative:"янв_фев_март_апр_май_июнь_июль_авг_сен_окт_ноя_дек".split("_"),accusative:"янв_фев_мар_апр_мая_июня_июля_авг_сен_окт_ноя_дек".split("_")}[/D[oD]?(\[[^\[\]]*\]|\s+)+MMMM?/.test(t)?"accusative":"nominative"][e.month()]}function i(e,t){return{nominative:"воскресенье_понедельник_вторник_среда_четверг_пятница_суббота".split("_"),accusative:"воскресенье_понедельник_вторник_среду_четверг_пятницу_субботу".split("_")}[/\[ ?[Вв] ?(?:прошлую|следующую|эту)? ?\] ?dddd/.test(t)?"accusative":"nominative"][e.day()]}return e.defineLocale("ru",{months:r,monthsShort:o,weekdays:i,weekdaysShort:"вс_пн_вт_ср_чт_пт_сб".split("_"),weekdaysMin:"вс_пн_вт_ср_чт_пт_сб".split("_"),monthsParse:[/^янв/i,/^фев/i,/^мар/i,/^апр/i,/^ма[й|я]/i,/^июн/i,/^июл/i,/^авг/i,/^сен/i,/^окт/i,/^ноя/i,/^дек/i],longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY г.",LLL:"D MMMM YYYY г., HH:mm",LLLL:"dddd, D MMMM YYYY г., HH:mm"},calendar:{sameDay:"[Сегодня в] LT",nextDay:"[Завтра в] LT",lastDay:"[Вчера в] LT",nextWeek:function(){return 2===this.day()?"[Во] dddd [в] LT":"[В] dddd [в] LT"},lastWeek:function(e){if(e.week()===this.week())return 2===this.day()?"[Во] dddd [в] LT":"[В] dddd [в] LT";switch(this.day()){case 0:return"[В прошлое] dddd [в] LT";case 1:case 2:case 4:return"[В прошлый] dddd [в] LT";case 3:case 5:case 6:return"[В прошлую] dddd [в] LT"}},sameElse:"L"},relativeTime:{future:"через %s",past:"%s назад",s:"несколько секунд",m:n,mm:n,h:"час",hh:n,d:"день",dd:n,M:"месяц",MM:n,y:"год",yy:n},meridiemParse:/ночи|утра|дня|вечера/i,isPM:function(e){return/^(дня|вечера)$/.test(e)},meridiem:function(e,t,n){return e<4?"ночи":e<12?"утра":e<17?"дня":"вечера"},ordinalParse:/\d{1,2}-(й|го|я)/,ordinal:function(e,t){switch(t){case"M":case"d":case"DDD":return e+"-й";case"D":return e+"-го";case"w":case"W":return e+"-я";default:return e}},week:{dow:1,doy:7}})}) -},function(e,t,n){!function(e,t){t(n(38))}(0,function(e){"use strict";var t={1:"'inci",5:"'inci",8:"'inci",70:"'inci",80:"'inci",2:"'nci",7:"'nci",20:"'nci",50:"'nci",3:"'üncü",4:"'üncü",100:"'üncü",6:"'ncı",9:"'uncu",10:"'uncu",30:"'uncu",60:"'ıncı",90:"'ıncı"};return e.defineLocale("tr",{months:"Ocak_Şubat_Mart_Nisan_Mayıs_Haziran_Temmuz_Ağustos_Eylül_Ekim_Kasım_Aralık".split("_"),monthsShort:"Oca_Şub_Mar_Nis_May_Haz_Tem_Ağu_Eyl_Eki_Kas_Ara".split("_"),weekdays:"Pazar_Pazartesi_Salı_Çarşamba_Perşembe_Cuma_Cumartesi".split("_"),weekdaysShort:"Paz_Pts_Sal_Çar_Per_Cum_Cts".split("_"),weekdaysMin:"Pz_Pt_Sa_Ça_Pe_Cu_Ct".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[bugün saat] LT",nextDay:"[yarın saat] LT",nextWeek:"[haftaya] dddd [saat] LT",lastDay:"[dün] LT",lastWeek:"[geçen hafta] dddd [saat] LT",sameElse:"L"},relativeTime:{future:"%s sonra",past:"%s önce",s:"birkaç saniye",m:"bir dakika",mm:"%d dakika",h:"bir saat",hh:"%d saat",d:"bir gün",dd:"%d gün",M:"bir ay",MM:"%d ay",y:"bir yıl",yy:"%d yıl"},ordinalParse:/\d{1,2}'(inci|nci|üncü|ncı|uncu|ıncı)/,ordinal:function(e){if(0===e)return e+"'ıncı";var n=e%10,r=e%100-n,o=e>=100?100:null;return e+(t[n]||t[r]||t[o])},week:{dow:1,doy:7}})})},function(e,t,n){"use strict";!function(e){function t(t){var n=t||window.event,r=[].slice.call(arguments,1),o=0,i=0,a=0;return t=e.event.fix(n),t.type="mousewheel",n.wheelDelta&&(o=n.wheelDelta/120),n.detail&&(o=-n.detail/3),a=o,void 0!==n.axis&&n.axis===n.HORIZONTAL_AXIS&&(a=0,i=-1*o),void 0!==n.wheelDeltaY&&(a=n.wheelDeltaY/120),void 0!==n.wheelDeltaX&&(i=-1*n.wheelDeltaX/120),r.unshift(t,o,i,a),(e.event.dispatch||e.event.handle).apply(this,r)}var n,r=["wheel","mousewheel","DOMMouseScroll","MozMousePixelScroll"],o=["mousewheel","DomMouseScroll","MozMousePixelScroll"];if(e.event.fixHooks)for(n=r.length;n;)e.event.fixHooks[r[--n]]=e.event.mouseHooks;e.event.special.mousewheel={setup:function(){if(this.addEventListener)for(var e=o.length;e;)this.addEventListener(o[--e],t,!1);else this.onmousewheel=t},teardown:function(){if(this.removeEventListener)for(var e=o.length;e;)this.removeEventListener(o[--e],t,!1);else this.onmousewheel=null}},e.fn.extend({mousewheel:function(e){return e?this.bind("mousewheel",e):this.trigger("mousewheel")},unmousewheel:function(e){return this.unbind("mousewheel",e)}})}(jQuery)},function(e,t,n){"use strict";var r=n(32),o=r.rgba,i=r.areEqualRgb,a=r.areEqualRgba,s=r.normalizeHue,u=r.normalizeHsvSaturation,l=r.normalizeValue,c=r.hsv,f=r.rgbToHsv,d=r.hsvToRgb,p=r.rgbToString,h=r.rgbaToString,m=r.parseRgb,g=r.parseRgba,y=n(528);!function(e){function t(e){return""===e?e:h(g(e))}function n(e){e&&(e.join||(e=e?(""+e).split(","):[]),b=e)}function r(w){function x(t){var n=!1,r=m(t);return e.each(b,function(e,t){if(i(m(t),r))return n=!0,!1}),!n&&(b=[p(r)].concat(b.slice(0,v-1)),!0)}function k(t,n,r){var i=e(this);t=h(o(m(t),n)),T.call(this,t), -i.removeData("tvcolorpicker").removeData("tvcolorpicker-custom-color"),r&&(O(),i.blur())}function T(t){var n=e(this);n.val(t),n.change(),t?n.trigger("pick-color",t):n.trigger("pick-transparent"),S.call(this,t)}function S(t){if(""===t)return void e(this).addClass("tvcolorpicker-gradient-widget");e(this).removeClass("tvcolorpicker-gradient-widget"),e(this).css({backgroundColor:t,color:t})}function C(t,n){var r,o,a,s,u,l;return n=n||{},r=this,o=e(r).val().toLowerCase(),a=document.createElement("table"),s=document.createElement("tbody"),a.appendChild(s),l=0,e.each(t,function(t,a){var c,f;l++,t%v==0&&(u=e("
").appendTo(s)),c=e('').appendTo(u),f=e('
').appendTo(c).find(".tvcolorpicker-swatch").data("color",a),n.addClass&&f.addClass(n.addClass),a&&(a=a.toLowerCase(),o&&i(m(o),m(a))&&f.addClass("active"),f.css({backgroundColor:a}).data("color",a),f.bind("click",function(){k.call(r,a,D.val(),!0)}))}),e(a).addClass("tvcolorpicker-table"),l?a:e()}function E(t,n,r){var o,i=e(t).offset(),a={left:e(document).scrollLeft(),top:e(document).scrollTop()},s={width:e(t).outerWidth(),height:e(t).outerHeight()},u={width:e(window).width(),height:e(window).height()},l={width:e(n).outerWidth(),height:e(n).outerHeight()};switch("function"==typeof r.direction?r.direction():r.direction){default:case"down":o={top:i.top+s.height+r.offset,left:i.left+r.drift};break;case"right":o={top:i.top+r.drift,left:i.left+s.width+r.offset}}o.top+l.height>u.height+a.top&&(o.top=u.height-l.height+a.top),i.left+l.width>u.width&&(o.left=u.width-l.width),o.left+="px",o.top+="px",n.css(o)}function M(t){function n(e){var t=e.originalEvent,n=e.offsetX||e.layerX||t&&(t.offsetX||t.layerX)||0,r=e.offsetY||e.layerY||t&&(t.offsetY||t.layerY)||0;N.css({left:n+"px",top:r+"px"}),U[0]=s(n/I),U[1]=u(1-r/R),j.css({backgroundColor:p(d(c(U[0],U[1],1)))}),x()}function r(t){1==t.which&&(H=!1,V.is(".opened")&&e(B).get(0).focus())}function i(t){var n=t.pageY,r=e(F),o=r.offset().top,i=n-o;return i>r.height()?r.height():i<0?0:i}function v(e){var t=i(e);A.css({top:t+"px"}),U[2]=l(1-Math.max(0,Math.min(t,R))/R),x()}function w(t){1==t.which&&(Y=!1,e(document).unbind("mouseup",w),V.is(".opened")&&e(B).get(0).focus())}function x(){var e,t;W&&(W=!1,V.find(".tvcolorpicker-swatch.active").removeClass("active")),e=o(d(U),D.val()),a(g(B.val().toUpperCase()),e)||(t=h(e),B.data("tvcolorpicker-custom-color",t),T.call(B,t))}var S,M,O,N,P,L,j,A,F,R,I,H,Y,W,U,z=!1,B=e(this),V=e('
'),q=e('
').appendTo(V);return q.append(C.call(this,["rgb(0, 0, 0)","rgb(66, 66, 66)","rgb(101, 101, 101)","rgb(152, 152, 152)","rgb(182, 182, 182)","rgb(203, 203, 203)","rgb(216, 216, 216)","rgb(238, 238, 238)","rgb(242, 242, 242)","rgb(255, 255, 255)"])), -q.append(C.call(this,["rgb(151, 0, 0)","rgb(255, 0, 0)","rgb(255, 152, 0)","rgb(255, 255, 0)","rgb(0, 255, 0)","rgb(0, 255, 255)","rgb(73, 133, 231)","rgb(0, 0, 255)","rgb(152, 0, 255)","rgb(255, 0, 255)"])),q.append(C.call(this,["rgb(230, 184, 175)","rgb(244, 204, 204)","rgb(252, 229, 205)","rgb(255, 242, 204)","rgb(217, 234, 211)","rgb(208, 224, 227)","rgb(201, 218, 248)","rgb(207, 226, 243)","rgb(217, 210, 233)","rgb(234, 209, 220)","rgb(221, 126, 107)","rgb(234, 153, 153)","rgb(249, 203, 156)","rgb(255, 229, 153)","rgb(182, 215, 168)","rgb(162, 196, 201)","rgb(164, 194, 244)","rgb(159, 197, 232)","rgb(180, 167, 214)","rgb(213, 166, 189)","rgb(204, 65, 37)","rgb(224, 102, 102)","rgb(246, 178, 107)","rgb(255, 217, 102)","rgb(147, 196, 125)","rgb(118, 165, 175)","rgb(109, 158, 235)","rgb(111, 168, 220)","rgb(142, 124, 195)","rgb(194, 123, 160)","rgb(166, 28, 0)","rgb(204, 0, 0)","rgb(230, 145, 56)","rgb(241, 194, 50)","rgb(106, 168, 79)","rgb(69, 129, 142)","rgb(60, 120, 216)","rgb(61, 133, 198)","rgb(103, 78, 167)","rgb(166, 77, 121)","rgb(133, 32, 12)","rgb(153, 0, 0)","rgb(180, 95, 6)","rgb(191, 144, 0)","rgb(56, 118, 29)","rgb(19, 79, 92)","rgb(17, 85, 204)","rgb(11, 83, 148)","rgb(53, 28, 117)","rgb(116, 27, 71)","rgb(91, 15, 0)","rgb(102, 0, 0)","rgb(120, 63, 4)","rgb(127, 96, 0)","rgb(39, 78, 19)","rgb(12, 52, 61)","rgb(28, 69, 135)","rgb(7, 55, 99)","rgb(32, 18, 77)","rgb(76, 17, 48)"])),S=e('
').css({display:"none"}).appendTo(V),M=e('
').appendTo(S),O=e('
').appendTo(M),N=e('
').appendTo(O),P=e('
').appendTo(O),L=e('
').appendTo(M),j=e('
').appendTo(L),A=e('
').appendTo(j),F=e('
').appendTo(j),D=y(e(this),t.hideTransparency),D.initEvents(),D.updateColor(),D.$el.appendTo(V),D.val(g(B.val()||_)[3]),R=O.height(),I=O.width(),H=!1,Y=!1,W=!0,U=[0,0,.5],P.bind("mousedown",function(t){1==t.which&&(H=!0,e(document).bind("mouseup",r),n(t),t.preventDefault())}),P.bind("mousemove",function(e){H&&(n(e),e.preventDefault())}),e(D).on("change",function(){if(z)return void x();k.call(this,e(this).val()||_,D.val())}.bind(this)),e(D).on("afterChange",function(){e(this).focus()}.bind(this)),L.bind("mousedown",function(t){1==t.which&&(Y=!0,e(document).bind("mouseup",w),v(t),t.preventDefault())}),e(document).bind("mousemove",function(e){Y&&(v(e),e.preventDefault())}),e(''+window.t("Custom color...")+"").appendTo(V).bind("click",function(){var t,n=e(this).is(".active");n||S.css({minWidth:q.width()+"px",minHeight:q.height()+"px"}),e(this)[n?"removeClass":"addClass"]("active"),z=e(this).is(".active"),S.css({display:n?"none":"block"}),q.css({display:n?"block":"none"}),n?B.removeData("tvcolorpicker-custom-color"):(R=O.height(),I=O.width(), -t=m(B.val()||_),U=f(t),N.css({left:~~(U[0]*I)+"px",top:~~((1-U[1])*R)+"px"}),A.css({top:~~((1-U[2])*R)+"px"}),j.css({backgroundColor:p(d(c(U[0],U[1],1)))}))}),V.append(e(C.call(this,b,{addClass:"tvcolorpicker-user"})).addClass("tvcolorpicker-user-swatches")),e(document.body).append(V),E(B,V,t),V}function O(){e(".tvcolorpicker-popup").removeClass("opened").remove(),e(D).off("change"),e(D).off("afterChange"),e(N).data("tvcolorpicker",null),e(N).each(function(){var t,n=e(this).data("tvcolorpicker-custom-color");n&&(x(n)&&e(this).trigger("customcolorchange",[b]),e(this).data("tvcolorpicker-custom-color",null)),t=e(this).data("tvcolorpicker-previous-color"),t&&t!=e(this).val()&&e(this).trigger("change"),e(this).removeData("tvcolorpicker-previous-color")})}var D,N;return w=e.extend({},r.options,w||{}),N=this,w&&"customColors"in w&&n(w.customColors),this.each(function(){function n(){var e=t(a.val());S.call(a,e)}var r,o,i,a=e(this);a.val(t(a.val())),r=null,o=!1,a.addClass("tvcolorpicker-widget").attr("autocomplete","off").attr("readonly",!0),i=function(){a.data("tvcolorpicker")||(O.call(a),r=M.call(a,w),a.data("tvcolorpicker-custom-color",null),a.data("tvcolorpicker",r),a.data("tvcolorpicker-previous-color",a.val()),r.bind("mousedown click",function(t){e(t.target).parents().andSelf().is(r)&&(a.focus(),o=!0,setTimeout(function(){o=!1},0))}))},a.on("touchstart",i),a.focus(i),O.call(a),a.bind("blur",function(e){o?e.stopPropagation():O.call(a)}),a.change(function(e){n()}),n()})}var v,b,_;if(!e)throw Error("This program cannot be run in DOS mode");r.setCustomColors=n,e.fn.tvcolorpicker=r,v=10,b=[],_="rgb(14, 15, 16)",r.options={direction:"down",offset:0,drift:0}}(window.jQuery)},function(e,t,n){e.exports=n(535).default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default={processors:{},addPostProcessor:function(e){this.processors[e.name]=e},handle:function(e,t,n,r,o){var i=this;return e.forEach(function(e){i.processors[e]&&(t=i.processors[e].process(t,n,r,o))}),t}}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e){return e.interpolation={unescapeSuffix:"HTML"},e.interpolation.prefix=e.interpolationPrefix||"__",e.interpolation.suffix=e.interpolationSuffix||"__",e.interpolation.escapeValue=e.escapeInterpolation||!1,e.interpolation.nestingPrefix=e.reusePrefix||"$t(",e.interpolation.nestingSuffix=e.reuseSuffix||")",e}function i(e){return e.resStore&&(e.resources=e.resStore),e.ns&&e.ns.defaultNs?(e.defaultNS=e.ns.defaultNs,e.ns=e.ns.namespaces):e.defaultNS=e.ns||"translation",e.fallbackToDefaultNS&&e.defaultNS&&(e.fallbackNS=e.defaultNS),e.saveMissing=e.sendMissing,e.saveMissingTo=e.sendMissingTo||"current",e.returnNull=!e.fallbackOnNull,e.returnEmptyString=!e.fallbackOnEmpty,e.returnObjects=e.returnObjectTrees,e.joinArrays="\n",e.returnedObjectHandler=e.objectTreeKeyHandler,e.parseMissingKeyHandler=e.parseMissingKey,e.appendNamespaceToMissingKey=!0,e.nsSeparator=e.nsseparator,e.keySeparator=e.keyseparator, -"sprintf"===e.shortcutFunction&&(e.overloadTranslationOptionHandler=function(e){var t,n=[];for(t=1;t-1?t:e}function p(e,t){t=t||{};var n=t.body;if("string"==typeof e)this.url=e;else{if(e.bodyUsed)throw new TypeError("Already read");this.url=e.url,this.credentials=e.credentials,t.headers||(this.headers=new o(e.headers)),this.method=e.method,this.mode=e.mode,n||null==e._bodyInit||(n=e._bodyInit,e.bodyUsed=!0)}if(this.credentials=t.credentials||this.credentials||"omit",!t.headers&&this.headers||(this.headers=new o(t.headers)), -this.method=d(t.method||this.method||"GET"),this.mode=t.mode||this.mode||null,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&n)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(n)}function h(e){var t=new FormData;return e.trim().split("&").forEach(function(e){var n,r,o;e&&(n=e.split("="),r=n.shift().replace(/\+/g," "),o=n.join("=").replace(/\+/g," "),t.append(decodeURIComponent(r),decodeURIComponent(o)))}),t}function m(e){var t=new o;return e.split("\r\n").forEach(function(e){var n,r=e.split(":"),o=r.shift().trim();o&&(n=r.join(":").trim(),t.append(o,n))}),t}function g(e,t){t||(t={}),this.type="default",this.status="status"in t?t.status:200,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in t?t.statusText:"OK",this.headers=new o(t.headers),this.url=t.url||"",this._initBody(e)}var y,v,b,_,w,x;e.fetch||(y={searchParams:"URLSearchParams"in e,iterable:"Symbol"in e&&"iterator"in Symbol,blob:"FileReader"in e&&"Blob"in e&&function(){try{return new Blob,!0}catch(e){return!1}}(),formData:"FormData"in e,arrayBuffer:"ArrayBuffer"in e},y.arrayBuffer&&(v=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],b=function(e){return e&&DataView.prototype.isPrototypeOf(e)},_=ArrayBuffer.isView||function(e){return e&&v.indexOf(Object.prototype.toString.call(e))>-1}),o.prototype.append=function(e,r){e=t(e),r=n(r);var o=this.map[e];o||(o=[],this.map[e]=o),o.push(r)},o.prototype.delete=function(e){delete this.map[t(e)]},o.prototype.get=function(e){var n=this.map[t(e)];return n?n[0]:null},o.prototype.getAll=function(e){return this.map[t(e)]||[]},o.prototype.has=function(e){return this.map.hasOwnProperty(t(e))},o.prototype.set=function(e,r){this.map[t(e)]=[n(r)]},o.prototype.forEach=function(e,t){Object.getOwnPropertyNames(this.map).forEach(function(n){this.map[n].forEach(function(r){e.call(t,r,n,this)},this)},this)},o.prototype.keys=function(){var e=[];return this.forEach(function(t,n){e.push(n)}),r(e)},o.prototype.values=function(){var e=[];return this.forEach(function(t){e.push(t)}),r(e)},o.prototype.entries=function(){var e=[];return this.forEach(function(t,n){e.push([n,t])}),r(e)},y.iterable&&(o.prototype[Symbol.iterator]=o.prototype.entries),w=["DELETE","GET","HEAD","OPTIONS","POST","PUT"],p.prototype.clone=function(){return new p(this,{body:this._bodyInit})},f.call(p.prototype),f.call(g.prototype),g.prototype.clone=function(){return new g(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new o(this.headers),url:this.url})},g.error=function(){var e=new g(null,{status:0,statusText:""});return e.type="error",e},x=[301,302,303,307,308],g.redirect=function(e,t){if(-1===x.indexOf(t))throw new RangeError("Invalid status code");return new g(null,{status:t,headers:{location:e}})},e.Headers=o,e.Request=p,e.Response=g,e.fetch=function(e,t){return new Promise(function(n,r){ -var o=new p(e,t),i=new XMLHttpRequest;i.onload=function(){var e,t={status:i.status,statusText:i.statusText,headers:m(i.getAllResponseHeaders()||"")};t.url="responseURL"in i?i.responseURL:t.headers.get("X-Request-URL"),e="response"in i?i.response:i.responseText,n(new g(e,t))},i.onerror=function(){r(new TypeError("Network request failed"))},i.ontimeout=function(){r(new TypeError("Network request failed"))},i.open(o.method,o.url,!0),"include"===o.credentials&&(i.withCredentials=!0),"responseType"in i&&y.blob&&(i.responseType="blob"),o.headers.forEach(function(e,t){i.setRequestHeader(t,e)}),i.send(void 0===o._bodyInit?null:o._bodyInit)})},e.fetch.polyfill=!0)}("undefined"!=typeof self?self:this)},function(e,t,n){"use strict";(function(t){if(t._babelPolyfill)throw Error("only one instance of babel/polyfill is allowed");t._babelPolyfill=!0,n(422),n(428),n(430),n(432),n(433),n(434),n(435),n(437),n(438),n(439),n(440),n(441),n(442),n(443),n(444),n(446),n(448),n(449),n(450),n(451),n(452),n(453),n(454),n(455),n(456),n(457),n(458),n(459),n(460),n(461),n(462),n(463),n(464),n(465),n(466),n(467),n(468),n(469),n(471),n(472),n(474),n(475),n(476),n(478),n(479),n(480),n(482),n(484),n(487),n(488),n(489),n(490),n(492),n(495),n(497),n(498),n(499),n(501),n(502),n(503),n(504),n(505),n(506),n(507),n(508),n(509),n(511),n(512),n(513),n(514),n(515),n(516),e.exports=n(95)}).call(t,n(78))},function(e,t,n){"use strict";var r,o,i=n(18),a=n(51),s=n(55),u=n(4),l=n(96),c=n(180).KEY,f=n(36),d=n(181),p=n(115),h=n(114),m=n(20),g=n(252),y=n(423),v=n(424),b=n(425),_=n(255),w=n(16),x=n(62),k=n(113),T=n(80),S=n(141),C=n(427),E=n(99),M=n(37),O=n(98),D=E.f,N=M.f,P=C.f,L=i.Symbol,j=i.JSON,A=j&&j.stringify,F="prototype",R=m("_hidden"),I=m("toPrimitive"),H={}.propertyIsEnumerable,Y=d("symbol-registry"),W=d("symbols"),U=d("op-symbols"),z=Object[F],B="function"==typeof L,V=i.QObject,q=!V||!V[F]||!V[F].findChild,$=s&&f(function(){return 7!=S(N({},"a",{get:function(){return N(this,"a",{value:7}).a}})).a})?function(e,t,n){var r=D(z,t);r&&delete z[t],N(e,t,n),r&&e!==z&&N(z,t,r)}:N,K=function(e){var t=W[e]=S(L[F]);return t._k=e,t},G=B&&"symbol"==typeof L.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof L},J=function(e,t,n){return e===z&&J(U,t,n),w(e),t=k(t,!0),w(n),a(W,t)?(n.enumerable?(a(e,R)&&e[R][t]&&(e[R][t]=!1),n=S(n,{enumerable:T(0,!1)})):(a(e,R)||N(e,R,T(1,{})),e[R][t]=!0),$(e,t,n)):N(e,t,n)},X=function(e,t){w(e);for(var n,r=b(t=x(t)),o=0,i=r.length;i>o;)J(e,n=r[o++],t[n]);return e},Q=function(e,t){return void 0===t?S(e):X(S(e),t)},Z=function(e){var t=H.call(this,e=k(e,!0));return!(this===z&&a(W,e)&&!a(U,e))&&(!(t||!a(this,e)||!a(W,e)||a(this,R)&&this[R][e])||t)},ee=function(e,t){if(e=x(e),t=k(t,!0),e!==z||!a(W,t)||a(U,t)){var n=D(e,t);return!n||!a(W,t)||a(e,R)&&e[R][t]||(n.enumerable=!0),n}},te=function(e){for(var t,n=P(x(e)),r=[],o=0;n.length>o;)a(W,t=n[o++])||t==R||t==c||r.push(t);return r},ne=function(e){for(var t,n=e===z,r=P(n?U:x(e)),o=[],i=0;r.length>i;)!a(W,t=r[i++])||n&&!a(z,t)||o.push(W[t]);return o};for(B||(L=function(){ -var e,t;if(this instanceof L)throw TypeError("Symbol is not a constructor!");return e=h(arguments.length>0?arguments[0]:void 0),t=function(n){this===z&&t.call(U,n),a(this,R)&&a(this[R],e)&&(this[R][e]=!1),$(this,e,T(1,n))},s&&q&&$(z,e,{configurable:!0,set:t}),K(e)},l(L[F],"toString",function(){return this._k}),E.f=ee,M.f=J,n(185).f=C.f=te,n(116).f=Z,n(140).f=ne,s&&!n(137)&&l(z,"propertyIsEnumerable",Z,!0),g.f=function(e){return K(m(e))}),u(u.G+u.W+u.F*!B,{Symbol:L}),r="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),o=0;r.length>o;)m(r[o++]);for(r=O(m.store),o=0;r.length>o;)y(r[o++]);u(u.S+u.F*!B,"Symbol",{for:function(e){return a(Y,e+="")?Y[e]:Y[e]=L(e)},keyFor:function(e){if(G(e))return v(Y,e);throw TypeError(e+" is not a symbol!")},useSetter:function(){q=!0},useSimple:function(){q=!1}}),u(u.S+u.F*!B,"Object",{create:Q,defineProperty:J,defineProperties:X,getOwnPropertyDescriptor:ee,getOwnPropertyNames:te,getOwnPropertySymbols:ne}),j&&u(u.S+u.F*(!B||f(function(){var e=L();return"[null]"!=A([e])||"{}"!=A({a:e})||"{}"!=A(Object(e))})),"JSON",{stringify:function(e){if(void 0!==e&&!G(e)){for(var t,n,r=[e],o=1;arguments.length>o;)r.push(arguments[o++]);return t=r[1],"function"==typeof t&&(n=t),!n&&_(t)||(t=function(e,t){if(n&&(t=n.call(this,e,t)),!G(t))return t}),r[1]=t,A.apply(j,r)}}}),L[F][I]||n(79)(L[F],I,L[F].valueOf),p(L,"Symbol"),p(Math,"Math",!0),p(i.JSON,"JSON",!0)},function(e,t,n){var r=n(18),o=n(95),i=n(137),a=n(252),s=n(37).f;e.exports=function(e){var t=o.Symbol||(o.Symbol=i?{}:r.Symbol||{});"_"==e.charAt(0)||e in t||s(t,e,{value:a.f(e)})}},function(e,t,n){var r=n(98),o=n(62);e.exports=function(e,t){for(var n,i=o(e),a=r(i),s=a.length,u=0;s>u;)if(i[n=a[u++]]===t)return n}},function(e,t,n){var r=n(98),o=n(140),i=n(116);e.exports=function(e){var t,n,a,s,u=r(e),l=o.f;if(l)for(t=l(e),n=i.f,a=0;t.length>a;)n.call(e,s=t[a++])&&u.push(s);return u}},function(e,t,n){var r=n(37),o=n(16),i=n(98);e.exports=n(55)?Object.defineProperties:function(e,t){o(e);for(var n,a=i(t),s=a.length,u=0;s>u;)r.f(e,n=a[u++],t[n]);return e}},function(e,t,n){var r=n(62),o=n(185).f,i={}.toString,a="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],s=function(e){try{return o(e)}catch(e){return a.slice()}};e.exports.f=function(e){return a&&"[object Window]"==i.call(e)?s(e):o(r(e))}},function(e,t,n){var r=n(4);r(r.S+r.F,"Object",{assign:n(429)})},function(e,t,n){"use strict";var r=n(98),o=n(140),i=n(116),a=n(100),s=n(182),u=Object.assign;e.exports=!u||n(36)(function(){var e={},t={},n=Symbol(),r="abcdefghijklmnopqrst";return e[n]=7,r.split("").forEach(function(e){t[e]=e}),7!=u({},e)[n]||Object.keys(u({},t)).join("")!=r})?function(e,t){for(var n,u,l,c,f,d=a(e),p=arguments.length,h=1,m=o.f,g=i.f;p>h;)for(n=s(arguments[h++]),u=m?r(n).concat(m(n)):r(n),l=u.length,c=0;l>c;)g.call(n,f=u[c++])&&(d[f]=n[f]);return d}:u},function(e,t,n){var r=n(4);r(r.S,"Object",{is:n(431)})},function(e,t){e.exports=Object.is||function(e,t){ -return e===t?0!==e||1/e==1/t:e!=e&&t!=t}},function(e,t,n){var r=n(4);r(r.S,"Object",{setPrototypeOf:n(186).set})},function(e,t,n){var r=n(37).f,o=n(80),i=n(51),a=Function.prototype,s=/^\s*function ([^ (]*)/,u="name",l=Object.isExtensible||function(){return!0};u in a||n(55)&&r(a,u,{configurable:!0,get:function(){try{var e=this,t=(""+e).match(s)[1];return i(e,u)||!l(e)||r(e,u,o(5,t)),t}catch(e){return""}}})},function(e,t,n){"use strict";var r=n(29),o=n(117),i=n(20)("hasInstance"),a=Function.prototype;i in a||n(37).f(a,i,{value:function(e){if("function"!=typeof this||!r(e))return!1;if(!r(this.prototype))return e instanceof this;for(;e=o(e);)if(this.prototype===e)return!0;return!1}})},function(e,t,n){"use strict";var r=n(4),o=n(36),i=n(436),a=1..toPrecision;r(r.P+r.F*(o(function(){return"1"!==a.call(1,void 0)})||!o(function(){a.call({})})),"Number",{toPrecision:function(e){var t=i(this,"Number#toPrecision: incorrect invocation!");return void 0===e?a.call(t):a.call(t,e)}})},function(e,t,n){var r=n(81);e.exports=function(e,t){if("number"!=typeof e&&"Number"!=r(e))throw TypeError(t);return+e}},function(e,t,n){var r=n(4);r(r.S,"Number",{EPSILON:Math.pow(2,-52)})},function(e,t,n){var r=n(4),o=n(18).isFinite;r(r.S,"Number",{isFinite:function(e){return"number"==typeof e&&o(e)}})},function(e,t,n){var r=n(4);r(r.S,"Number",{isInteger:n(257)})},function(e,t,n){var r=n(4);r(r.S,"Number",{isNaN:function(e){return e!=e}})},function(e,t,n){var r=n(4),o=n(257),i=Math.abs;r(r.S,"Number",{isSafeInteger:function(e){return o(e)&&i(e)<=9007199254740991}})},function(e,t,n){var r=n(4);r(r.S,"Number",{MAX_SAFE_INTEGER:9007199254740991})},function(e,t,n){var r=n(4);r(r.S,"Number",{MIN_SAFE_INTEGER:-9007199254740991})},function(e,t,n){var r=n(4),o=n(445);r(r.S+r.F*(Number.parseFloat!=o),"Number",{parseFloat:o})},function(e,t,n){var r=n(18).parseFloat,o=n(258).trim;e.exports=1/r(n(187)+"-0")!=-1/0?function(e){var t=o(e+"",3),n=r(t);return 0===n&&"-"==t.charAt(0)?-0:n}:r},function(e,t,n){var r=n(4),o=n(447);r(r.S+r.F*(Number.parseInt!=o),"Number",{parseInt:o})},function(e,t,n){var r=n(18).parseInt,o=n(258).trim,i=n(187),a=/^[\-+]?0[xX]/;e.exports=8!==r(i+"08")||22!==r(i+"0x16")?function(e,t){var n=o(e+"",3);return r(n,t>>>0||(a.test(n)?16:10))}:r},function(e,t,n){var r=n(4),o=n(259),i=Math.sqrt,a=Math.acosh;r(r.S+r.F*!(a&&710==Math.floor(a(Number.MAX_VALUE))&&a(1/0)==1/0),"Math",{acosh:function(e){return(e=+e)<1?NaN:e>94906265.62425156?Math.log(e)+Math.LN2:o(e-1+i(e-1)*i(e+1))}})},function(e,t,n){function r(e){return isFinite(e=+e)&&0!=e?e<0?-r(-e):Math.log(e+Math.sqrt(e*e+1)):e}var o=n(4),i=Math.asinh;o(o.S+o.F*!(i&&1/i(0)>0),"Math",{asinh:r})},function(e,t,n){var r=n(4),o=Math.atanh;r(r.S+r.F*!(o&&1/o(-0)<0),"Math",{atanh:function(e){return 0==(e=+e)?e:Math.log((1+e)/(1-e))/2}})},function(e,t,n){var r=n(4),o=n(188);r(r.S,"Math",{cbrt:function(e){return o(e=+e)*Math.pow(Math.abs(e),1/3)}})},function(e,t,n){var r=n(4);r(r.S,"Math",{clz32:function(e){return(e>>>=0)?31-Math.floor(Math.log(e+.5)*Math.LOG2E):32}})},function(e,t,n){ -var r=n(4),o=Math.exp;r(r.S,"Math",{cosh:function(e){return(o(e=+e)+o(-e))/2}})},function(e,t,n){var r=n(4),o=n(189);r(r.S+r.F*(o!=Math.expm1),"Math",{expm1:o})},function(e,t,n){var r=n(4),o=n(188),i=Math.pow,a=i(2,-52),s=i(2,-23),u=i(2,127)*(2-s),l=i(2,-126),c=function(e){return e+1/a-1/a};r(r.S,"Math",{fround:function(e){var t,n,r=Math.abs(e),i=o(e);return ru||n!=n?i*(1/0):i*n)}})},function(e,t,n){var r=n(4),o=Math.abs;r(r.S,"Math",{hypot:function(e,t){for(var n,r,i=0,a=0,s=arguments.length,u=0;a0?(r=n/u,i+=r*r):i+=n;return u===1/0?1/0:u*Math.sqrt(i)}})},function(e,t,n){var r=n(4),o=Math.imul;r(r.S+r.F*n(36)(function(){return-5!=o(4294967295,5)||2!=o.length}),"Math",{imul:function(e,t){var n=65535,r=+e,o=+t,i=n&r,a=n&o;return 0|i*a+((n&r>>>16)*a+i*(n&o>>>16)<<16>>>0)}})},function(e,t,n){var r=n(4);r(r.S,"Math",{log10:function(e){return Math.log(e)/Math.LN10}})},function(e,t,n){var r=n(4);r(r.S,"Math",{log1p:n(259)})},function(e,t,n){var r=n(4);r(r.S,"Math",{log2:function(e){return Math.log(e)/Math.LN2}})},function(e,t,n){var r=n(4);r(r.S,"Math",{sign:n(188)})},function(e,t,n){var r=n(4),o=n(189),i=Math.exp;r(r.S+r.F*n(36)(function(){return-2e-17!=!Math.sinh(-2e-17)}),"Math",{sinh:function(e){return Math.abs(e=+e)<1?(o(e)-o(-e))/2:(i(e-1)-i(-e-1))*(Math.E/2)}})},function(e,t,n){var r=n(4),o=n(189),i=Math.exp;r(r.S,"Math",{tanh:function(e){var t=o(e=+e),n=o(-e);return t==1/0?1:n==1/0?-1:(t-n)/(i(e)+i(-e))}})},function(e,t,n){var r=n(4);r(r.S,"Math",{trunc:function(e){return(e>0?Math.floor:Math.ceil)(e)}})},function(e,t,n){var r=n(4),o=n(139),i=String.fromCharCode,a=String.fromCodePoint;r(r.S+r.F*(!!a&&1!=a.length),"String",{fromCodePoint:function(e){for(var t,n=[],r=arguments.length,a=0;r>a;){if(t=+arguments[a++],o(t,1114111)!==t)throw RangeError(t+" is not a valid code point");n.push(t<65536?i(t):i(55296+((t-=65536)>>10),t%1024+56320))}return n.join("")}})},function(e,t,n){var r=n(4),o=n(62),i=n(63);r(r.S,"String",{raw:function(e){for(var t=o(e.raw),n=i(t.length),r=arguments.length,a=[],s=0;n>s;)a.push(t[s++]+""),s=t.length?{value:void 0,done:!0}:(e=r(t,n),this._i+=e.length,{value:e,done:!1})})},function(e,t,n){"use strict";var r=n(4),o=n(260)(!1);r(r.P,"String",{codePointAt:function(e){return o(this,e)}})},function(e,t,n){"use strict";var r=n(4),o=n(63),i=n(191),a="endsWith",s=""[a];r(r.P+r.F*n(192)(a),"String",{endsWith:function(e){var t=i(this,e,a),n=arguments.length>1?arguments[1]:void 0,r=o(t.length),u=void 0===n?r:Math.min(o(n),r),l=e+"";return s?s.call(t,l,u):t.slice(u-l.length,u)===l}})},function(e,t,n){var r=n(29),o=n(81),i=n(20)("match");e.exports=function(e){var t;return r(e)&&(void 0!==(t=e[i])?!!t:"RegExp"==o(e))}},function(e,t,n){"use strict";var r=n(4),o=n(191),i="includes";r(r.P+r.F*n(192)(i),"String",{ -includes:function(e){return!!~o(this,e,i).indexOf(e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){var r=n(4);r(r.P,"String",{repeat:n(473)})},function(e,t,n){"use strict";var r=n(138),o=n(82);e.exports=function(e){var t=o(this)+"",n="",i=r(e);if(i<0||i==1/0)throw RangeError("Count can't be negative");for(;i>0;(i>>>=1)&&(t+=t))1&i&&(n+=t);return n}},function(e,t,n){"use strict";var r=n(4),o=n(63),i=n(191),a="startsWith",s=""[a];r(r.P+r.F*n(192)(a),"String",{startsWith:function(e){var t=i(this,e,a),n=o(Math.min(arguments.length>1?arguments[1]:void 0,t.length)),r=e+"";return s?s.call(t,r,n):t.slice(n,n+r.length)===r}})},function(e,t,n){var r=Date.prototype,o="Invalid Date",i="toString",a=r[i],s=r.getTime;new Date(NaN)+""!=o&&n(96)(r,i,function(){var e=s.call(this);return e===e?a.call(this):o})},function(e,t,n){var r=n(20)("toPrimitive"),o=Date.prototype;r in o||n(79)(o,r,n(477))},function(e,t,n){"use strict";var r=n(16),o=n(113),i="number";e.exports=function(e){if("string"!==e&&e!==i&&"default"!==e)throw TypeError("Incorrect hint");return o(r(this),e!=i)}},function(e,t,n){"use strict";var r=n(68),o=n(4),i=n(100),a=n(262),s=n(263),u=n(63),l=n(264),c=n(265);o(o.S+o.F*!n(193)(function(e){Array.from(e)}),"Array",{from:function(e){var t,n,o,f,d=i(e),p="function"==typeof this?this:Array,h=arguments.length,m=h>1?arguments[1]:void 0,g=void 0!==m,y=0,v=c(d);if(g&&(m=r(m,h>2?arguments[2]:void 0,2)),void 0==v||p==Array&&s(v))for(t=u(d.length),n=new p(t);t>y;y++)l(n,y,g?m(d[y],y):d[y]);else for(f=v.call(d),n=new p;!(o=f.next()).done;y++)l(n,y,g?a(f,m,[o.value,y],!0):o.value);return n.length=y,n}})},function(e,t,n){"use strict";var r=n(4),o=n(264);r(r.S+r.F*n(36)(function(){function e(){}return!(Array.of.call(e)instanceof e)}),"Array",{of:function(){for(var e=0,t=arguments.length,n=new("function"==typeof this?this:Array)(t);t>e;)o(n,e,arguments[e++]);return n.length=t,n}})},function(e,t,n){var r=n(4);r(r.P,"Array",{copyWithin:n(481)}),n(101)("copyWithin")},function(e,t,n){"use strict";var r=n(100),o=n(139),i=n(63);e.exports=[].copyWithin||function(e,t){var n=r(this),a=i(n.length),s=o(e,a),u=o(t,a),l=arguments.length>2?arguments[2]:void 0,c=Math.min((void 0===l?a:o(l,a))-u,a-s),f=1;for(u0;)u in n?n[s]=n[u]:delete n[s],s+=f,u+=f;return n}},function(e,t,n){var r=n(4);r(r.P,"Array",{fill:n(483)}),n(101)("fill")},function(e,t,n){"use strict";var r=n(100),o=n(139),i=n(63);e.exports=function(e){for(var t=r(this),n=i(t.length),a=arguments.length,s=o(a>1?arguments[1]:void 0,n),u=a>2?arguments[2]:void 0,l=void 0===u?n:o(u,n);l>s;)t[s++]=e;return t}},function(e,t,n){"use strict";var r=n(4),o=n(267)(5),i="find",a=!0;i in[]&&Array(1)[i](function(){a=!1}),r(r.P+r.F*a,"Array",{find:function(e){return o(this,e,arguments.length>1?arguments[1]:void 0)}}),n(101)(i)},function(e,t,n){var r=n(486);e.exports=function(e,t){return new(r(e))(t)}},function(e,t,n){var r=n(29),o=n(255),i=n(20)("species");e.exports=function(e){var t;return o(e)&&(t=e.constructor, -"function"!=typeof t||t!==Array&&!o(t.prototype)||(t=void 0),r(t)&&null===(t=t[i])&&(t=void 0)),void 0===t?Array:t}},function(e,t,n){"use strict";var r=n(4),o=n(267)(6),i="findIndex",a=!0;i in[]&&Array(1)[i](function(){a=!1}),r(r.P+r.F*a,"Array",{findIndex:function(e){return o(this,e,arguments.length>1?arguments[1]:void 0)}}),n(101)(i)},function(e,t,n){n(194)("Array")},function(e,t,n){"use strict";var r=n(101),o=n(268),i=n(142),a=n(62);e.exports=n(190)(Array,"Array",function(e,t){this._t=a(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,n=this._i++;return!e||n>=e.length?(this._t=void 0,o(1)):"keys"==t?o(0,n):"values"==t?o(0,e[n]):o(0,[n,e[n]])},"values"),i.Arguments=i.Array,r("keys"),r("values"),r("entries")},function(e,t,n){n(55)&&"g"!=/./g.flags&&n(37).f(RegExp.prototype,"flags",{configurable:!0,get:n(491)})},function(e,t,n){"use strict";var r=n(16);e.exports=function(){var e=r(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},function(e,t,n){"use strict";var r,o,i,a,s,u,l,c,f,d,p,h,m,g,y,v,b,_=n(137),w=n(18),x=n(68),k=n(266),T=n(4),S=n(29),C=n(97),E=n(195),M=n(196),O=n(493),D=n(269).set,N=n(494)(),P="Promise",L=w.TypeError,j=w.process,A=w[P];j=w.process,r="process"==k(j),o=function(){},u=!!function(){try{var e=A.resolve(1),t=(e.constructor={})[n(20)("species")]=function(e){e(o,o)};return(r||"function"==typeof PromiseRejectionEvent)&&e.then(o)instanceof t}catch(e){}}(),l=function(e,t){return e===t||e===A&&t===s},c=function(e){var t;return!(!S(e)||"function"!=typeof(t=e.then))&&t},f=function(e){return l(A,e)?new d(e):new a(e)},d=a=function(e){var t,n;this.promise=new e(function(e,r){if(void 0!==t||void 0!==n)throw L("Bad Promise constructor");t=e,n=r}),this.resolve=C(t),this.reject=C(n)},p=function(e){try{e()}catch(e){return{error:e}}},h=function(e,t){if(!e._n){e._n=!0;var n=e._c;N(function(){for(var r=e._v,o=1==e._s,i=0,a=function(t){var n,i,a=o?t.ok:t.fail,s=t.resolve,u=t.reject,l=t.domain;try{a?(o||(2==e._h&&y(e),e._h=1),!0===a?n=r:(l&&l.enter(),n=a(r),l&&l.exit()),n===t.promise?u(L("Promise-chain cycle")):(i=c(n))?i.call(n,s,u):s(n)):u(r)}catch(e){u(e)}};n.length>i;)a(n[i++]);e._c=[],e._n=!1,t&&!e._h&&m(e)})}},m=function(e){D.call(w,function(){var t,n,o,i=e._v;if(g(e)&&(t=p(function(){r?j.emit("unhandledRejection",i,e):(n=w.onunhandledrejection)?n({promise:e,reason:i}):(o=w.console)&&o.error&&o.error("Unhandled promise rejection",i)}),e._h=r||g(e)?2:1),e._a=void 0,t)throw t.error})},g=function(e){if(1==e._h)return!1;for(var t,n=e._a||e._c,r=0;n.length>r;)if(t=n[r++],t.fail||!g(t.promise))return!1;return!0},y=function(e){D.call(w,function(){var t;r?j.emit("rejectionHandled",e):(t=w.onrejectionhandled)&&t({promise:e,reason:e._v})})},v=function(e){var t=this;t._d||(t._d=!0,t=t._w||t,t._v=e,t._s=2,t._a||(t._a=t._c.slice()),h(t,!0))},b=function(e){var t,n=this;if(!n._d){n._d=!0,n=n._w||n;try{if(n===e)throw L("Promise can't be resolved itself");(t=c(e))?N(function(){var r={_w:n,_d:!1};try{t.call(e,x(b,r,1),x(v,r,1))}catch(e){ -v.call(r,e)}}):(n._v=e,n._s=1,h(n,!1))}catch(e){v.call({_w:n,_d:!1},e)}}},u||(A=function(e){E(this,A,P,"_h"),C(e),i.call(this);try{e(x(b,this,1),x(v,this,1))}catch(e){v.call(this,e)}},i=function(e){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1},i.prototype=n(197)(A.prototype,{then:function(e,t){var n=f(O(this,A));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=r?j.domain:void 0,this._c.push(n),this._a&&this._a.push(n),this._s&&h(this,!1),n.promise},catch:function(e){return this.then(void 0,e)}}),d=function(){var e=new i;this.promise=e,this.resolve=x(b,e,1),this.reject=x(v,e,1)}),T(T.G+T.W+T.F*!u,{Promise:A}),n(115)(A,P),n(194)(P),s=n(95)[P],T(T.S+T.F*!u,P,{reject:function(e){var t=f(this);return(0,t.reject)(e),t.promise}}),T(T.S+T.F*(_||!u),P,{resolve:function(e){if(e instanceof A&&l(e.constructor,this))return e;var t=f(this);return(0,t.resolve)(e),t.promise}}),T(T.S+T.F*!(u&&n(193)(function(e){A.all(e).catch(o)})),P,{all:function(e){var t=this,n=f(t),r=n.resolve,o=n.reject,i=p(function(){var n=[],i=0,a=1;M(e,!1,function(e){var s=i++,u=!1;n.push(void 0),a++,t.resolve(e).then(function(e){u||(u=!0,n[s]=e,--a||r(n))},o)}),--a||r(n)});return i&&o(i.error),n.promise},race:function(e){var t=this,n=f(t),r=n.reject,o=p(function(){M(e,!1,function(e){t.resolve(e).then(n.resolve,r)})});return o&&r(o.error),n.promise}})},function(e,t,n){var r=n(16),o=n(97),i=n(20)("species");e.exports=function(e,t){var n,a=r(e).constructor;return void 0===a||void 0==(n=r(a)[i])?t:o(n)}},function(e,t,n){var r=n(18),o=n(269).set,i=r.MutationObserver||r.WebKitMutationObserver,a=r.process,s=r.Promise,u="process"==n(81)(a);e.exports=function(){var e,t,n,l,c,f,d=function(){var r,o;for(u&&(r=a.domain)&&r.exit();e;){o=e.fn,e=e.next;try{o()}catch(r){throw e?n():t=void 0,r}}t=void 0,r&&r.enter()};return u?n=function(){a.nextTick(d)}:i?(l=!0,c=document.createTextNode(""),new i(d).observe(c,{characterData:!0}),n=function(){c.data=l=!l}):s&&s.resolve?(f=s.resolve(),n=function(){f.then(d)}):n=function(){o.call(r,d)},function(r){var o={fn:r,next:void 0};t&&(t.next=o),e||(e=o,n()),t=o}}},function(e,t,n){"use strict";var r=n(271);e.exports=n(272)("Map",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{get:function(e){var t=r.getEntry(this,e);return t&&t.v},set:function(e,t){return r.def(this,0===e?0:e,t)}},r,!0)},function(e,t,n){var r=n(29),o=n(186).set;e.exports=function(e,t,n){var i,a=t.constructor;return a!==n&&"function"==typeof a&&(i=a.prototype)!==n.prototype&&r(i)&&o&&o(e,i),e}},function(e,t,n){"use strict";var r=n(271);e.exports=n(272)("Set",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return r.def(this,e=0===e?0:e,e)}},r)},function(e,t,n){var r=n(4),o=n(97),i=n(16),a=(n(18).Reflect||{}).apply,s=Function.apply;r(r.S+r.F*!n(36)(function(){a(function(){})}),"Reflect",{apply:function(e,t,n){var r=o(e),u=i(n);return a?a(r,t,u):s.call(r,t,u)}})},function(e,t,n){ -var r=n(4),o=n(141),i=n(97),a=n(16),s=n(29),u=n(36),l=n(500),c=(n(18).Reflect||{}).construct,f=u(function(){function e(){}return!(c(function(){},[],e)instanceof e)}),d=!u(function(){c(function(){})});r(r.S+r.F*(f||d),"Reflect",{construct:function(e,t){var n,r,u,p,h;if(i(e),a(t),n=arguments.length<3?e:i(arguments[2]),d&&!f)return c(e,t,n);if(e==n){switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3])}return r=[null],r.push.apply(r,t),new(l.apply(e,r))}return u=n.prototype,p=o(s(u)?u:Object.prototype),h=Function.apply.call(e,p,t),s(h)?h:p}})},function(e,t,n){"use strict";var r=n(97),o=n(29),i=n(270),a=[].slice,s={},u=function(e,t,n){if(!(t in s)){for(var r=[],o=0;o=n.length)return{value:void 0,done:!0}}while(!((e=n[t._i++])in t._t));return{value:e,done:!1}}),r(r.S,"Reflect",{enumerate:function(e){return new i(e)}})},function(e,t,n){function r(e,t){var n,s,c=arguments.length<3?e:arguments[2];return l(e)===c?e[t]:(n=o.f(e,t))?a(n,"value")?n.value:void 0!==n.get?n.get.call(c):void 0:u(s=i(e))?r(s,t,c):void 0}var o=n(99),i=n(117),a=n(51),s=n(4),u=n(29),l=n(16);s(s.S,"Reflect",{get:r})},function(e,t,n){var r=n(99),o=n(4),i=n(16);o(o.S,"Reflect",{getOwnPropertyDescriptor:function(e,t){return r.f(i(e),t)}})},function(e,t,n){var r=n(4),o=n(117),i=n(16);r(r.S,"Reflect",{getPrototypeOf:function(e){return o(i(e))}})},function(e,t,n){var r=n(4);r(r.S,"Reflect",{has:function(e,t){return t in e}})},function(e,t,n){var r=n(4),o=n(16),i=Object.isExtensible;r(r.S,"Reflect",{isExtensible:function(e){return o(e),!i||i(e)}})},function(e,t,n){var r=n(4);r(r.S,"Reflect",{ownKeys:n(510)})},function(e,t,n){var r=n(185),o=n(140),i=n(16),a=n(18).Reflect;e.exports=a&&a.ownKeys||function(e){var t=r.f(i(e)),n=o.f;return n?t.concat(n(e)):t}},function(e,t,n){var r=n(4),o=n(16),i=Object.preventExtensions;r(r.S,"Reflect",{preventExtensions:function(e){o(e);try{return i&&i(e),!0}catch(e){return!1}}})},function(e,t,n){function r(e,t,n){var u,d,p=arguments.length<4?e:arguments[3],h=i.f(c(e),t);if(!h){if(f(d=a(e)))return r(d,t,n,p);h=l(0)} -return s(h,"value")?!(!1===h.writable||!f(p))&&(u=i.f(p,t)||l(0),u.value=n,o.f(p,t,u),!0):void 0!==h.set&&(h.set.call(p,n),!0)}var o=n(37),i=n(99),a=n(117),s=n(51),u=n(4),l=n(80),c=n(16),f=n(29);u(u.S,"Reflect",{set:r})},function(e,t,n){var r=n(4),o=n(186);o&&r(r.S,"Reflect",{setPrototypeOf:function(e,t){o.check(e,t);try{return o.set(e,t),!0}catch(e){return!1}}})},function(e,t,n){"use strict";var r=n(4),o=n(254)(!0);r(r.P,"Array",{includes:function(e){return o(this,e,arguments.length>1?arguments[1]:void 0)}}),n(101)("includes")},function(e,t,n){var r=n(4),o=n(273)(!1);r(r.S,"Object",{values:function(e){return o(e)}})},function(e,t,n){var r=n(4),o=n(273)(!0);r(r.S,"Object",{entries:function(e){return o(e)}})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),n(518),n(168),n(243),n(519),n(520)},function(e,t,n){var r,o;!function(){r=["jquery","./data","./disable-selection","./focusable","./form","./ie","./keycode","./labels","./jquery-1-7","./plugin","./safe-active-element","./safe-blur","./scroll-parent","./tabbable","./unique-id","./version"],void 0!==(o="function"==typeof r?r.call(t,n,t,e):r)&&(e.exports=o)}()},function(e,t,n){var r,o,i;!function(a){o=[n(13),n(75)],r=a,void 0!==(i="function"==typeof r?r.apply(t,o):r)&&(e.exports=i)}(function(e){return function(){function t(e,t,n){return[parseFloat(e[0])*(f.test(e[0])?t/100:1),parseFloat(e[1])*(f.test(e[1])?n/100:1)]}function n(t,n){return parseInt(e.css(t,n),10)||0}function r(t){var n=t[0];return 9===n.nodeType?{width:t.width(),height:t.height(),offset:{top:0,left:0}}:e.isWindow(n)?{width:t.width(),height:t.height(),offset:{top:t.scrollTop(),left:t.scrollLeft()}}:n.preventDefault?{width:0,height:0,offset:{top:n.pageY,left:n.pageX}}:{width:t.outerWidth(),height:t.outerHeight(),offset:t.offset()}}var o,i=Math.max,a=Math.abs,s=/left|center|right/,u=/top|center|bottom/,l=/[\+\-]\d+(\.[\d]+)?%?/,c=/^\w+/,f=/%$/,d=e.fn.position;e.position={scrollbarWidth:function(){if(void 0!==o)return o;var t,n,r=e("
"),i=r.children()[0];return e("body").append(r),t=i.offsetWidth,r.css("overflow","scroll"),n=i.offsetWidth,t===n&&(n=r[0].clientWidth),r.remove(),o=t-n},getScrollInfo:function(t){var n=t.isWindow||t.isDocument?"":t.element.css("overflow-x"),r=t.isWindow||t.isDocument?"":t.element.css("overflow-y"),o="scroll"===n||"auto"===n&&t.width0?"right":"center",vertical:s<0?"top":r>0?"bottom":"middle"};pi(a(r),a(s))?f.important="horizontal":f.important="vertical",o.using.call(this,e,f)}),u.offset(e.extend(S,{using:s}))})},e.ui.position={fit:{left:function(e,t){var n,r=t.within,o=r.isWindow?r.scrollLeft:r.offset.left,a=r.width,s=e.left-t.collisionPosition.marginLeft,u=o-s,l=s+t.collisionWidth-a-o;t.collisionWidth>a?u>0&&l<=0?(n=e.left+u+t.collisionWidth-a-o,e.left+=u-n):e.left=l>0&&u<=0?o:u>l?o+a-t.collisionWidth:o:u>0?e.left+=u:l>0?e.left-=l:e.left=i(e.left-s,e.left)},top:function(e,t){var n,r=t.within,o=r.isWindow?r.scrollTop:r.offset.top,a=t.within.height,s=e.top-t.collisionPosition.marginTop,u=o-s,l=s+t.collisionHeight-a-o;t.collisionHeight>a?u>0&&l<=0?(n=e.top+u+t.collisionHeight-a-o,e.top+=u-n):e.top=l>0&&u<=0?o:u>l?o+a-t.collisionHeight:o:u>0?e.top+=u:l>0?e.top-=l:e.top=i(e.top-s,e.top)}},flip:{left:function(e,t){var n,r,o=t.within,i=o.offset.left+o.scrollLeft,s=o.width,u=o.isWindow?o.scrollLeft:o.offset.left,l=e.left-t.collisionPosition.marginLeft,c=l-u,f=l+t.collisionWidth-s-u,d="left"===t.my[0]?-t.elemWidth:"right"===t.my[0]?t.elemWidth:0,p="left"===t.at[0]?t.targetWidth:"right"===t.at[0]?-t.targetWidth:0,h=-2*t.offset[0] -;c<0?((n=e.left+d+p+h+t.collisionWidth-s-i)<0||n0&&((r=e.left-t.collisionPosition.marginLeft+d+p+h-u)>0||a(r)0&&((n=e.top-t.collisionPosition.marginTop+p+h+m-u)>0||a(n)e?0:r.max")[0],h=e.each;p.style.cssText="background-color:rgba(1,1,1,.5)", -d.rgba=p.style.backgroundColor.indexOf("rgba")>-1,h(c,function(e,t){t.cache="_"+e,t.props.alpha={idx:3,type:"percent",def:1}}),l.fn=e.extend(l.prototype,{parse:function(o,a,s,u){if(o===t)return this._rgba=[null,null,null,null],this;(o.jquery||o.nodeType)&&(o=e(o).css(a),a=t);var f=this,d=e.type(o),p=this._rgba=[];return a!==t&&(o=[o,a,s,u],d="array"),"string"===d?this.parse(r(o)||i._default):"array"===d?(h(c.rgba.props,function(e,t){p[t.idx]=n(o[t.idx],t)}),this):"object"===d?(o instanceof l?h(c,function(e,t){o[t.cache]&&(f[t.cache]=o[t.cache].slice())}):h(c,function(t,r){var i=r.cache;h(r.props,function(e,t){if(!f[i]&&r.to){if("alpha"===e||null==o[e])return;f[i]=r.to(f._rgba)}f[i][t.idx]=n(o[e],t,!0)}),f[i]&&e.inArray(null,f[i].slice(0,3))<0&&(f[i][3]=1,r.from&&(f._rgba=r.from(f[i])))}),this):t},is:function(e){var t=l(e),n=!0,r=this;return h(c,function(e,o){var i,a=t[o.cache];return a&&(i=r[o.cache]||o.to&&o.to(r._rgba)||[],h(o.props,function(e,t){if(null!=a[t.idx])return n=a[t.idx]===i[t.idx]})),n}),n},_space:function(){var e=[],t=this;return h(c,function(n,r){t[r.cache]&&e.push(n)}),e.pop()},transition:function(e,t){var r=l(e),o=r._space(),i=c[o],a=0===this.alpha()?l("transparent"):this,s=a[i.cache]||i.to(a._rgba),u=s.slice();return r=r[i.cache],h(i.props,function(e,o){var i=o.idx,a=s[i],l=r[i],c=f[o.type]||{};null!==l&&(null===a?u[i]=l:(c.mod&&(l-a>c.mod/2?a+=c.mod:a-l>c.mod/2&&(a-=c.mod)),u[i]=n((l-a)*t+a,o)))}),this[o](u)},blend:function(t){if(1===this._rgba[3])return this;var n=this._rgba.slice(),r=n.pop(),o=l(t)._rgba;return l(e.map(n,function(e,t){return(1-r)*o[t]+r*e}))},toRgbaString:function(){var t="rgba(",n=e.map(this._rgba,function(e,t){return null==e?t>2?1:0:e});return 1===n[3]&&(n.pop(),t="rgb("),t+n.join()+")"},toHslaString:function(){var t="hsla(",n=e.map(this.hsla(),function(e,t){return null==e&&(e=t>2?1:0),t&&t<3&&(e=Math.round(100*e)+"%"),e});return 1===n[3]&&(n.pop(),t="hsl("),t+n.join()+")"},toHexString:function(t){var n=this._rgba.slice(),r=n.pop();return t&&n.push(~~(255*r)),"#"+e.map(n,function(e){return e=(e||0).toString(16),1===e.length?"0"+e:e}).join("")},toString:function(){return 0===this._rgba[3]?"transparent":this.toRgbaString()}}),l.fn.parse.prototype=l.fn,c.hsla.to=function(e){if(null==e[0]||null==e[1]||null==e[2])return[null,null,null,e[3]];var t,n,r=e[0]/255,o=e[1]/255,i=e[2]/255,a=e[3],s=Math.max(r,o,i),u=Math.min(r,o,i),l=s-u,c=s+u,f=.5*c;return t=u===s?0:r===s?60*(o-i)/l+360:o===s?60*(i-r)/l+120:60*(r-o)/l+240,n=0===l?0:f<=.5?l/c:l/(2-c),[Math.round(t)%360,n,f,null==a?1:a]},c.hsla.from=function(e){if(null==e[0]||null==e[1]||null==e[2])return[null,null,null,e[3]];var t=e[0]/360,n=e[1],r=e[2],i=e[3],a=r<=.5?r*(1+n):r+n-r*n,s=2*r-a;return[Math.round(255*o(s,a,t+1/3)),Math.round(255*o(s,a,t)),Math.round(255*o(s,a,t-1/3)),i]},h(c,function(r,o){var i=o.props,a=o.cache,u=o.to,c=o.from;l.fn[r]=function(r){if(u&&!this[a]&&(this[a]=u(this._rgba)),r===t)return this[a].slice();var o,s=e.type(r),f="array"===s||"object"===s?r:arguments,d=this[a].slice();return h(i,function(e,t){ -var r=f["object"===s?e:t.idx];null==r&&(r=d[t.idx]),d[t.idx]=n(r,t)}),c?(o=l(c(d)),o[a]=d,o):l(d)},h(i,function(t,n){l.fn[t]||(l.fn[t]=function(o){var i,a=e.type(o),u="alpha"===t?this._hsla?"hsla":"rgba":r,l=this[u](),c=l[n.idx];return"undefined"===a?c:("function"===a&&(o=o.call(this,c),a=e.type(o)),null==o&&n.empty?this:("string"===a&&(i=s.exec(o))&&(o=c+parseFloat(i[2])*("+"===i[1]?1:-1)),l[n.idx]=o,this[u](l)))})})}),l.hook=function(t){var n=t.split(" ");h(n,function(t,n){e.cssHooks[n]={set:function(t,o){var i,a,s="";if("transparent"!==o&&("string"!==e.type(o)||(i=r(o)))){if(o=l(i||o),!d.rgba&&1!==o._rgba[3]){for(a="backgroundColor"===n?t.parentNode:t;(""===s||"transparent"===s)&&a&&a.style;)try{s=e.css(a,"backgroundColor"),a=a.parentNode}catch(e){}o=o.blend(s&&"transparent"!==s?s:"_default")}o=o.toRgbaString()}try{t.style[n]=o}catch(e){}}},e.fx.step[n]=function(t){t.colorInit||(t.start=l(t.elem,n),t.end=l(t.end),t.colorInit=!0),e.cssHooks[n].set(t.elem,t.start.transition(t.end,t.pos))}})},l.hook(a),e.cssHooks.borderColor={expand:function(e){var t={};return h(["Top","Right","Bottom","Left"],function(n,r){t["border"+r+"Color"]=e}),t}},i=e.Color.names={aqua:"#00ffff",black:"#000000",blue:"#0000ff",fuchsia:"#ff00ff",gray:"#808080",green:"#008000",lime:"#00ff00",maroon:"#800000",navy:"#000080",olive:"#808000",purple:"#800080",red:"#ff0000",silver:"#c0c0c0",teal:"#008080",white:"#ffffff",yellow:"#ffff00",transparent:[null,null,null,0],_default:"#ffffff"}}(o),function(){function t(t){var n,r,o=t.ownerDocument.defaultView?t.ownerDocument.defaultView.getComputedStyle(t,null):t.currentStyle,i={};if(o&&o.length&&o[0]&&o[o[0]])for(r=o.length;r--;)n=o[r],"string"==typeof o[n]&&(i[e.camelCase(n)]=o[n]);else for(n in o)"string"==typeof o[n]&&(i[n]=o[n]);return i}function n(t,n){var r,o,a={};for(r in n)o=n[r],t[r]!==o&&(i[r]||!e.fx.step[r]&&isNaN(parseFloat(o))||(a[r]=o));return a}var r=["add","remove","toggle"],i={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};e.each(["borderLeftStyle","borderRightStyle","borderBottomStyle","borderTopStyle"],function(t,n){e.fx.step[n]=function(e){("none"!==e.end&&!e.setAttr||1===e.pos&&!e.setAttr)&&(o.style(e.elem,n,e.end),e.setAttr=!0)}}),e.fn.addBack||(e.fn.addBack=function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}),e.effects.animateClass=function(o,i,a,s){var u=e.speed(i,a,s);return this.queue(function(){var i,a=e(this),s=a.attr("class")||"",l=u.children?a.find("*").addBack():a;l=l.map(function(){return{el:e(this),start:t(this)}}),i=function(){e.each(r,function(e,t){o[t]&&a[t+"Class"](o[t])})},i(),l=l.map(function(){return this.end=t(this.el[0]),this.diff=n(this.start,this.end),this}),a.attr("class",s),l=l.map(function(){var t=this,n=e.Deferred(),r=e.extend({},u,{queue:!1,complete:function(){n.resolve(t)}});return this.el.animate(this.diff,r),n.promise()}),e.when.apply(e,l.get()).done(function(){i(),e.each(arguments,function(){var t=this.el;e.each(this.diff,function(e){t.css(e,"")})}), -u.complete.call(a[0])})})},e.fn.extend({addClass:function(t){return function(n,r,o,i){return r?e.effects.animateClass.call(this,{add:n},r,o,i):t.apply(this,arguments)}}(e.fn.addClass),removeClass:function(t){return function(n,r,o,i){return arguments.length>1?e.effects.animateClass.call(this,{remove:n},r,o,i):t.apply(this,arguments)}}(e.fn.removeClass),toggleClass:function(t){return function(n,r,o,i,a){return"boolean"==typeof r||void 0===r?o?e.effects.animateClass.call(this,r?{add:n}:{remove:n},o,i,a):t.apply(this,arguments):e.effects.animateClass.call(this,{toggle:n},r,o,i)}}(e.fn.toggleClass),switchClass:function(t,n,r,o,i){return e.effects.animateClass.call(this,{add:n,remove:t},r,o,i)}})}(),function(){function o(t,n,r,o){return e.isPlainObject(t)&&(n=t,t=t.effect),t={effect:t},null==n&&(n={}),e.isFunction(n)&&(o=n,r=null,n={}),("number"==typeof n||e.fx.speeds[n])&&(o=r,r=n,n={}),e.isFunction(r)&&(o=r,r=null),n&&e.extend(t,n),r=r||n.duration,t.duration=e.fx.off?0:"number"==typeof r?r:r in e.fx.speeds?e.fx.speeds[r]:e.fx.speeds._default,t.complete=o||n.complete,t}function i(t){return!(t&&"number"!=typeof t&&!e.fx.speeds[t])||("string"==typeof t&&!e.effects.effect[t]||(!!e.isFunction(t)||"object"==typeof t&&!t.effect))}function a(e,t){var n=t.outerWidth(),r=t.outerHeight(),o=/^rect\((-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto)\)$/,i=o.exec(e)||["",0,n,r,0];return{top:parseFloat(i[1])||0,right:"auto"===i[2]?n:parseFloat(i[2]),bottom:"auto"===i[3]?r:parseFloat(i[3]),left:parseFloat(i[4])||0}}e.expr&&e.expr.filters&&e.expr.filters.animated&&(e.expr.filters.animated=function(t){return function(n){return!!e(n).data(r)||t(n)}}(e.expr.filters.animated)),!1!==e.uiBackCompat&&e.extend(e.effects,{save:function(e,n){for(var r=0,o=n.length;r
").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0}),o={width:t.width(),height:t.height()},i=document.activeElement;try{i.id}catch(e){i=document.body}return t.wrap(r),(t[0]===i||e.contains(t[0],i))&&e(i).trigger("focus"),r=t.parent(),"static"===t.css("position")?(r.css({position:"relative"}),t.css({position:"relative"})):(e.extend(n,{position:t.css("position"),zIndex:t.css("z-index")}),e.each(["top","left","bottom","right"],function(e,r){n[r]=t.css(r),isNaN(parseInt(n[r],10))&&(n[r]="auto")}),t.css({position:"relative",top:0,left:0,right:"auto",bottom:"auto"})),t.css(o),r.css(n).show()},removeWrapper:function(t){var n=document.activeElement;return t.parent().is(".ui-effects-wrapper")&&(t.parent().replaceWith(t), -(t[0]===n||e.contains(t[0],n))&&e(n).trigger("focus")),t}}),e.extend(e.effects,{version:"1.12.1",define:function(t,n,r){return r||(r=n,n="effect"),e.effects.effect[t]=r,e.effects.effect[t].mode=n,r},scaledDimensions:function(e,t,n){if(0===t)return{height:0,width:0,outerHeight:0,outerWidth:0};var r="horizontal"!==n?(t||100)/100:1,o="vertical"!==n?(t||100)/100:1;return{height:e.height()*o,width:e.width()*r,outerHeight:e.outerHeight()*o,outerWidth:e.outerWidth()*r}},clipToBox:function(e){return{width:e.clip.right-e.clip.left,height:e.clip.bottom-e.clip.top,left:e.clip.left,top:e.clip.top}},unshift:function(e,t,n){var r=e.queue();t>1&&r.splice.apply(r,[1,0].concat(r.splice(t,n))),e.dequeue()},saveStyle:function(e){e.data(n,e[0].style.cssText)},restoreStyle:function(e){e[0].style.cssText=e.data(n)||"",e.removeData(n)},mode:function(e,t){var n=e.is(":hidden");return"toggle"===t&&(t=n?"show":"hide"),(n?"hide"===t:"show"===t)&&(t="none"),t},getBaseline:function(e,t){var n,r;switch(e[0]){case"top":n=0;break;case"middle":n=.5;break;case"bottom":n=1;break;default:n=e[0]/t.height}switch(e[1]){case"left":r=0;break;case"center":r=.5;break;case"right":r=1;break;default:r=e[1]/t.width}return{x:r,y:n}},createPlaceholder:function(n){var r,o=n.css("position"),i=n.position();return n.css({marginTop:n.css("marginTop"),marginBottom:n.css("marginBottom"),marginLeft:n.css("marginLeft"),marginRight:n.css("marginRight")}).outerWidth(n.outerWidth()).outerHeight(n.outerHeight()),/^(static|relative)/.test(o)&&(o="absolute",r=e("<"+n[0].nodeName+">").insertAfter(n).css({display:/^(inline|ruby)/.test(n.css("display"))?"inline-block":"block",visibility:"hidden",marginTop:n.css("marginTop"),marginBottom:n.css("marginBottom"),marginLeft:n.css("marginLeft"),marginRight:n.css("marginRight"),float:n.css("float")}).outerWidth(n.outerWidth()).outerHeight(n.outerHeight()).addClass("ui-effects-placeholder"),n.data(t+"placeholder",r)),n.css({position:o,left:i.left,top:i.top}),r},removePlaceholder:function(e){var n=t+"placeholder",r=e.data(n);r&&(r.remove(),e.removeData(n))},cleanUp:function(t){e.effects.restoreStyle(t),e.effects.removePlaceholder(t)},setTransition:function(t,n,r,o){return o=o||{},e.each(n,function(e,n){var i=t.cssUnit(n);i[0]>0&&(o[n]=i[0]*r+i[1])}),o}}),e.fn.extend({effect:function(){function t(t){function o(){u.removeData(r),e.effects.cleanUp(u),"hide"===n.mode&&u.hide(),s()}function s(){e.isFunction(l)&&l.call(u[0]),e.isFunction(t)&&t()}var u=e(this);n.mode=f.shift(),!1===e.uiBackCompat||a?"none"===n.mode?(u[c](),s()):i.call(u[0],n,o):(u.is(":hidden")?"hide"===c:"show"===c)?(u[c](),s()):i.call(u[0],n,s)}var n=o.apply(this,arguments),i=e.effects.effect[n.effect],a=i.mode,s=n.queue,u=s||"fx",l=n.complete,c=n.mode,f=[],d=function(t){var n=e(this),o=e.effects.mode(n,c)||a;n.data(r,!0),f.push(o),a&&("show"===o||o===a&&"hide"===o)&&n.show(),a&&"none"===o||e.effects.saveStyle(n),e.isFunction(t)&&t()};return e.fx.off||!i?c?this[c](n.duration,l):this.each(function(){l&&l.call(this)}):!1===s?this.each(d).each(t):this.queue(u,d).queue(u,t)}, -show:function(e){return function(t){if(i(t))return e.apply(this,arguments);var n=o.apply(this,arguments);return n.mode="show",this.effect.call(this,n)}}(e.fn.show),hide:function(e){return function(t){if(i(t))return e.apply(this,arguments);var n=o.apply(this,arguments);return n.mode="hide",this.effect.call(this,n)}}(e.fn.hide),toggle:function(e){return function(t){if(i(t)||"boolean"==typeof t)return e.apply(this,arguments);var n=o.apply(this,arguments);return n.mode="toggle",this.effect.call(this,n)}}(e.fn.toggle),cssUnit:function(t){var n=this.css(t),r=[];return e.each(["em","px","%","pt"],function(e,t){n.indexOf(t)>0&&(r=[parseFloat(n),t])}),r},cssClip:function(e){return e?this.css("clip","rect("+e.top+"px "+e.right+"px "+e.bottom+"px "+e.left+"px)"):a(this.css("clip"),this)},transfer:function(t,n){var r=e(this),o=e(t.to),i="fixed"===o.css("position"),a=e("body"),s=i?a.scrollTop():0,u=i?a.scrollLeft():0,l=o.offset(),c={top:l.top-s,left:l.left-u,height:o.innerHeight(),width:o.innerWidth()},f=r.offset(),d=e("
").appendTo("body").addClass(t.className).css({top:f.top-s,left:f.left-u,height:r.innerHeight(),width:r.innerWidth(),position:i?"fixed":"absolute"}).animate(c,t.duration,t.easing,function(){d.remove(),e.isFunction(n)&&n()})}}),e.fx.step.clip=function(t){t.clipInit||(t.start=e(t.elem).cssClip(),"string"==typeof t.end&&(t.end=a(t.end,t.elem)),t.clipInit=!0),e(t.elem).cssClip({top:t.pos*(t.end.top-t.start.top)+t.start.top,right:t.pos*(t.end.right-t.start.right)+t.start.right,bottom:t.pos*(t.end.bottom-t.start.bottom)+t.start.bottom,left:t.pos*(t.end.left-t.start.left)+t.start.left})}}(),function(){var t={};e.each(["Quad","Cubic","Quart","Quint","Expo"],function(e,n){t[n]=function(t){return Math.pow(t,e+2)}}),e.extend(t,{Sine:function(e){return 1-Math.cos(e*Math.PI/2)},Circ:function(e){return 1-Math.sqrt(1-e*e)},Elastic:function(e){return 0===e||1===e?e:-Math.pow(2,8*(e-1))*Math.sin((80*(e-1)-7.5)*Math.PI/15)},Back:function(e){return e*e*(3*e-2)},Bounce:function(e){for(var t,n=4;e<((t=Math.pow(2,--n))-1)/11;);return 1/Math.pow(4,3-n)-7.5625*Math.pow((3*t-2)/22-e,2)}}),e.each(t,function(t,n){e.easing["easeIn"+t]=n,e.easing["easeOut"+t]=function(e){return 1-n(1-e)},e.easing["easeInOut"+t]=function(e){return e<.5?n(2*e)/2:1-n(-2*e+2)/2}})}(),e.effects})},function(e,t,n){"use strict";!function(e){function t(t){var n,r;"string"==typeof t.data&&(n=t.handler,r=t.data.toLowerCase().split(" "),t.handler=function(t){var o,i,a,s,u,l;if(this===t.target||!/textarea|select/i.test(t.target.nodeName)&&"text"!==t.target.type)for(o="keypress"!==t.type&&e.hotkeys.specialKeys[t.which],i=String.fromCharCode(t.which).toLowerCase(),a="",s={},t.ctrlKey&&"ctrl"!==o&&(a+="ctrl+"),t.altKey&&"alt"!==o&&(a+="alt+"),t.metaKey&&!t.ctrlKey&&"meta"!==o&&(a+="meta+"),t.shiftKey&&"shift"!==o&&(a+="shift+"),o?s[a+o]=!0:(s[a+i]=!0,s[a+e.hotkeys.shiftNums[i]]=!0,"shift+"===a&&(s[e.hotkeys.shiftNums[i]]=!0)),u=0,l=r.length;u","/":"?","\\":"|"}},e.each(["keydown","keyup","keypress"],function(){e.event.special[this]={add:t}})}(jQuery)},function(e,t,n){var r,o,i;!function(n,a){"object"==typeof t&&t&&"string"!=typeof t.nodeName?a(t):(o=[t],r=a,void 0!==(i="function"==typeof r?r.apply(t,o):r)&&(e.exports=i))}(0,function(e){function t(e){return"function"==typeof e}function n(e){return g(e)?"array":typeof e}function r(e){return e.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function o(e,t){return null!=e&&"object"==typeof e&&t in e}function i(e,t){return y.call(e,t)}function a(e){return!i(v,e)}function s(e){return(e+"").replace(/[&<>"'`=\/]/g,function(e){return b[e]})}function u(t,n){function o(){if(p&&!h)for(;d.length;)delete u[d.pop()];else d=[];p=!1,h=!1}function i(e){if("string"==typeof e&&(e=e.split(w,2)),!g(e)||2!==e.length)throw Error("Invalid tags: "+e);m=RegExp(r(e[0])+"\\s*"),y=RegExp("\\s*"+r(e[1])),v=RegExp("\\s*"+r("}"+e[1]))}var s,u,d,p,h,m,y,v,b,S,C,E,M,O,D,N,P;if(!t)return[];for(s=[],u=[],d=[],p=!1,h=!1,i(n||e.tags),b=new f(t);!b.eos();){if(S=b.pos,E=b.scanUntil(m))for(N=0,P=E.length;N0?s[s.length-1][4]:i;break;default:a.push(t)}return i}function f(e){this.string=e,this.tail=e,this.pos=0}function d(e,t){this.view=e,this.cache={".":this.view},this.parent=t}function p(){this.cache={}}var h,m=Object.prototype.toString,g=Array.isArray||function(e){return"[object Array]"===m.call(e)},y=RegExp.prototype.test,v=/\S/,b={ -"&":"&","<":"<",">":">",'"':""","'":"'","/":"/","`":"`","=":"="},_=/\s*/,w=/\s+/,x=/\s*=/,k=/\s*\}/,T=/#|\^|\/|>|\{|&|=|!/;f.prototype.eos=function(){return""===this.tail},f.prototype.scan=function(e){var t,n=this.tail.match(e);return n&&0===n.index?(t=n[0],this.tail=this.tail.substring(t.length),this.pos+=t.length,t):""},f.prototype.scanUntil=function(e){var t,n=this.tail.search(e);switch(n){case-1:t=this.tail,this.tail="";break;case 0:t="";break;default:t=this.tail.substring(0,n),this.tail=this.tail.substring(n)}return this.pos+=t.length,t},d.prototype.push=function(e){return new d(e,this)},d.prototype.lookup=function(e){var n,r,i,a,s,u=this.cache;if(u.hasOwnProperty(e))n=u[e];else{for(r=this,s=!1;r;){if(e.indexOf(".")>0)for(n=r.view,i=e.split("."),a=0;null!=n&&a"===i?a=this.renderPartial(o,t,n,r):"&"===i?a=this.unescapedValue(o,t):"name"===i?a=this.escapedValue(o,t):"text"===i&&(a=this.rawValue(o)),void 0!==a&&(l+=a);return l},p.prototype.renderSection=function(e,n,r,o){function i(e){return u.render(e,n,r)}var a,s,u=this,l="",c=n.lookup(e[1]);if(c){if(g(c))for(a=0,s=c.length;a "+o.stack+")

"):window.__tv_js_errors.push(e+" (found at "+t+", line "+n+" at time "+a+")"),i)try{i.apply(window,arguments)}catch(e){}}}()},function(e,t,n){var r,o,i;!function(a){o=[n(13)],r=a,void 0!==(i="function"==typeof r?r.apply(t,o):r)&&(e.exports=i)}(function(e){function t(e){return s.raw?e:encodeURIComponent(e)}function n(e){return s.raw?e:decodeURIComponent(e)}function r(e){return t(s.json?JSON.stringify(e):e+"")}function o(e){0===e.indexOf('"')&&(e=e.slice(1,-1).replace(/\\"/g,'"').replace(/\\\\/g,"\\"));try{return e=decodeURIComponent(e.replace(a," ")),s.json?JSON.parse(e):e}catch(e){}}function i(t,n){var r=s.raw?t:o(t);return e.isFunction(n)?n(r):r}var a=/\+/g,s=e.cookie=function(o,a,u){var l,c,f,d,p,h,m,g,y;if(void 0!==a&&!e.isFunction(a))return u=e.extend({},s.defaults,u),"number"==typeof u.expires&&(l=u.expires,c=u.expires=new Date,c.setTime(+c+864e5*l)),document.cookie=t(o)+"="+r(a)+(u.expires?"; expires="+u.expires.toUTCString():"")+(u.path?"; path="+u.path:"")+(u.domain?"; domain="+u.domain:"")+(u.secure?"; secure":"");for(f=o?void 0:{},d=document.cookie?document.cookie.split("; "):[],p=0,h=d.length;pn)&&(r.top%1n)||(o=Math.round(parseFloat(c.css("margin-left")))||0,i=Math.round(parseFloat(c.css("margin-top")))||0,c.css({"margin-left":o+"px","margin-top":i+"px"}), -a=l.getBoundingClientRect(),s=-a.left%1,s>0&&(s-=1),s<-.5&&(s+=1),u=-a.top%1,u>0&&(u-=1),u<-.5&&(u+=1),c.css({"margin-left":o+s+"px","margin-top":i+u+"px"})))}),this}}(jQuery)},function(e,t,n){"use strict";!function(e,t){function n(){this._state=[],this._defaults={classHolder:"sbHolder",classHolderDisabled:"sbHolderDisabled",classHolderOpen:"sbHolderOpen",classSelector:"sbSelector",classOptions:"sbOptions",classGroup:"sbGroup",classSub:"sbSub",classDisabled:"sbDisabled",classToggleOpen:"sbToggleOpen",classToggle:"sbToggle",classSeparator:"sbSeparator",useCustomPrependWithSelector:"",customPrependSelectorClass:"",speed:200,slidesUp:!1,effect:"slide",onChange:null,beforeOpen:null,onOpen:null,onClose:null}}function r(t,n,r,o){function i(){n.removeClass(t.settings.customPrependSelectorClass),t._lastSelectorPrepend&&(t._lastSelectorPrepend.remove(),delete t._lastSelectorPrepend),r.data("custom-option-prepend")&&(t.settings.customPrependSelectorClass&&n.addClass(t.settings.customPrependSelectorClass),t._lastSelectorPrepend=e(r.data("custom-option-prepend")).clone(),n[t.settings.useCustomPrependWithSelector](t._lastSelectorPrepend))}t.settings.useCustomPrependWithSelector&&(o?t._onAttachCallback=i:i())}var o="selectbox",i=!1,a=!0;e.extend(n.prototype,{_refreshSelectbox:function(e,t){if(!e)return i;var n=this._getInst(e);return null==n?i:(this._fillList(e,n,t),a)},_isOpenSelectbox:function(e){return e?this._getInst(e).isOpen:i},_isDisabledSelectbox:function(e){return e?this._getInst(e).isDisabled:i},_attachSelectbox:function(t,n){function r(){var t,n=this.attr("id").split("_")[1];for(t in u._state)t!==n&&u._state.hasOwnProperty(t)&&e(":input[sb='"+t+"']")[0]&&u._closeSelectbox(e(":input[sb='"+t+"']")[0])}function a(n){s.children().each(function(r){var o,i=e(this);if(i.is(":selected")){if(38==n&&r>0)return o=e(s.children()[r-1]),u._changeSelectbox(t,o.val(),o.text()),!1;if(40==n&&r",{id:"sbHolder_"+l.uid,class:l.settings.classHolder}),m=s.data("selectbox-css"),m&&c.css(m),f=e("",{id:"sbSelector_"+l.uid,href:"#",class:l.settings.classSelector,click:function(n){n.preventDefault(),n.stopPropagation(),r.apply(e(this),[]);var o=e(this).attr("id").split("_")[1];u._state[o]?u._closeSelectbox(t):(u._openSelectbox(t),d.focus())},keyup:function(e){a(e.keyCode)}}),d=e("",{id:"sbToggle_"+l.uid,href:"#",class:l.settings.classToggle,click:function(n){n.preventDefault(),n.stopPropagation(),r.apply(e(this),[]);var o=e(this).attr("id").split("_")[1];u._state[o]?u._closeSelectbox(t):(u._openSelectbox(t),d.focus())},keyup:function(e){a(e.keyCode)}}),e('
').appendTo(d),d.appendTo(c),p=e("