{"version":3,"file":"js/chartiq-43a9de2d.js","mappings":";;AAwtDA;AACA;AAEA;;;;AAmDA;;;;;AAfA;;;AALA;;AA4pBA;AACA;AASA;AACA;;AAcA;AACA;AACA;AAEA;AA2BA;;AAmTA;AACA;;;;;;;;;;;;AAaA;;;;;;;;;;;;;;;;;;;;;;;;;;ACtoFA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAoTA;;;;;;;AAkMA;;;;AA2EA;;;;;;;;;;;;;;;;;;;;;;;;;;AA0GA;;;;;;;;;;;;;;;;;AA+VA;;;;;;;;;;;;;AA6HA;;;;;;;;;;;;;;;AAkxBA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgxBA;AAipBA;AACA;AACA;;;;;AAWA;;;;;;;;;;;;;;;AAqEA;;;;;;;;;;;;;;;;;;;;;AAsNA;;;;;;;;;;;;;;;;AA2qBA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAkQA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAkQA;;;;;;;;;;;;;;;AA8FA;;;;;;AAqPA;;;;;;;;AAwKA;;;;;;AAiqBA;;;;;;;;;;;;;;;;;;;;;;;;;AAiuBA;;;;AAkfA;;;;;;;;;;;AAk1CA;;;;;;;;;;AAiGA;;;;;AAsdA;;;AAoCA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAilBA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAy9BA;;;;;;;;;;;;;;;;;AAmYA;;;;;;;;;;;;;;;AA+HA;;;;;;;;;;AAylCA;;;;;;;;;;;;;;AAqPA;;;;;;;;;;;;;AA8FA;;;;;;;AA8gBA;AAkqBA;AACA;AAEA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA+CA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0yBA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACtmdA","sources":["webpack:///../node_modules/chartiq/js/addOns.js","webpack:///../node_modules/chartiq/js/components.js","webpack:///../node_modules/chartiq/js/standard.js"],"sourcesContent":["/**!\n *\t8.7.0\n *\tGeneration date: 2024-05-31T12:44:23.686Z\n *\tClient name: euroland as\n *\tPackage Type: Technical Analysis e98f22c\n *\tLicense type: annual\n *\tExpiration date: \"2025/06/01\"\n *\tDomain lock: [\"127.0.0.1\",\"localhost\",\"euroland.com\",\"eurolandir.cn\",\"eurolandir.com\"]\n *\tFeatures: TypeScript Definitions,SignalIQ\n */\n\n/***********************************************************!\n * Copyright © 2023 S&P Global All rights reserved\n*************************************************************/\n/*************************************! DO NOT MAKE CHANGES TO THIS LIBRARY FILE!! !*************************************\n* If you wish to overwrite default functionality, create a separate file with a copy of the methods you are overwriting *\n* and load that file right after the library has been loaded, but before the chart engine is instantiated. *\n* Directly modifying library files will prevent upgrades and the ability for ChartIQ to support your solution. *\n*************************************************************************************************************************/\n/* eslint-disable no-extra-parens */\n\n\nimport {CIQ as __CIQ_} from \"../js/chartiq.js\";\n\n\nlet __js_addons_standard_dataLoader_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Loads static data from uploaded files into the chart for easier consumption.\n * @param {object} params Configuration parameters.\n * @param {CIQ.ChartEngine} params.stx A reference to the chart engine that contains the chart for\n * \t\twhich the DataLoader is created.\n * @constructor\n * @name CIQ.DataLoader\n * @since 8.4.0\n */\nclass DataLoader {\n\tconstructor(params) {\n\t\tconst { stx } = params;\n\t\tif (!stx) {\n\t\t\tconsole.warn(\"The DataLoader requires an stx parameter\");\n\t\t\treturn;\n\t\t}\n\n\t\tthis.stx = stx;\n\t\tthis.cssRequired = true;\n\n\t\tstx.dataLoader = this;\n\t\tif (CIQ.UI) {\n\t\t\tCIQ.UI.observeProperty(\"uiContext\", stx, ({ value: uiContext }) => {\n\t\t\t\tif (!uiContext) return;\n\t\t\t\tsetTimeout(this.subscribeToChanges, 0, uiContext);\n\t\t\t\tsetTimeout(this.registerHotKeys, 0, uiContext);\n\t\t\t});\n\t\t}\n\t}\n\n\t/**\n\t * Formats data into OHLC format readable by the {@link CIQ.ChartEngine}\n\t * @param {CIQ.CSVReader} dataObj CIQ.CSVReader which contains the parsed data\n\t * @param {FormData} dataOptions FormData options that get the name of the imported data\n\t * @memberof CIQ.DataLoader\n\t */\n\tformatData(dataObj, dataOptions) {\n\t\tconst { defaultPlotField } = this.stx.chart;\n\t\tconst { results, fields } = dataObj;\n\t\tconst { name } = dataOptions;\n\n\t\tconst dtIdx = fields.indexOf(\"DT\");\n\t\tconst dateIdx = fields.indexOf(\"Date\");\n\t\tconst nameIdx = fields.indexOf(name);\n\n\t\tconst useField = nameIdx > -1;\n\t\tlet usedFields = [dtIdx > -1 ? dtIdx : dateIdx];\n\t\tif (useField) usedFields.push(fields.indexOf(name));\n\t\tresults.data = results.map((row) => {\n\t\t\tconst entry = {};\n\t\t\trow.split(\",\").forEach((col, idx) => {\n\t\t\t\tif (useField && usedFields.indexOf(idx) === -1) return;\n\t\t\t\tlet f = fields[idx];\n\t\t\t\tlet c;\n\t\t\t\ttry {\n\t\t\t\t\tc = JSON.parse(col);\n\t\t\t\t} catch (e) {\n\t\t\t\t\tc = col;\n\t\t\t\t}\n\t\t\t\tlet parsedCol = f === \"DT\" || f === \"Date\" ? c : Number.parseFloat(c);\n\t\t\t\tentry[fields[idx]] = parsedCol;\n\n\t\t\t\t// If we're using the \"name\" to signify we want to add a series\n\t\t\t\t// then take the value of the series and set it the defaultPlotField.\n\t\t\t\t// Otherwise we end up trying to plot the defaultPlotField instead of the \"name\"\n\t\t\t\tif (idx === nameIdx) {\n\t\t\t\t\tdelete entry[fields[idx]];\n\t\t\t\t\tentry[defaultPlotField] = parsedCol;\n\t\t\t\t}\n\t\t\t});\n\t\t\treturn entry;\n\t\t});\n\t}\n\n\t/**\n\t * Imports data from a {@link CIQ.CSVReader} and loads it into the chart based on FormData parameters.\n\t * @param {CIQ.CSVReader} dataObj CIQ.CSVReader that contains parsed data\n\t * @memberof CIQ.DataLoader\n\t */\n\timportData(dataObj) {\n\t\tconst self = this;\n\t\tconst { stx } = this;\n\n\t\tconst opt = Object.fromEntries(dataObj.formData.entries());\n\t\tlet { color, display, name, panel, periodicity } = opt;\n\t\tperiodicity = JSON.parse(periodicity);\n\n\t\tthis.formatData(dataObj, opt);\n\t\tconst { results } = dataObj;\n\t\tconst { data } = results;\n\n\t\tconst symbolObject = {\n\t\t\tsymbol: name,\n\t\t\tstatic: true\n\t\t};\n\t\tconst params = {\n\t\t\tdata,\n\t\t\tsymbolObject,\n\t\t\tpanel: panel === \"true\" ? true : undefined,\n\t\t\tcolor\n\t\t};\n\n\t\tif (display === \"secondary\") {\n\t\t\tstx.addSeries(name, params, function () {\n\t\t\t\tlet series = stx.getSeries({ symbol: name })[0];\n\t\t\t\tconst tick = stx.tickFromDate(series.endPoints.end);\n\t\t\t\tstx.chart.scroll =\n\t\t\t\t\tstx.chart.dataSet.length - 1 - tick + stx.chart.maxTicks;\n\t\t\t\tself.registerDataWarnings(true);\n\t\t\t});\n\t\t} else {\n\t\t\tstx.quoteDriver.pause(name);\n\t\t\tstx.loadChart(symbolObject, { masterData: data, periodicity }, () => {\n\t\t\t\tself.registerDataWarnings();\n\t\t\t});\n\t\t}\n\t}\n\n\t/**\n\t * Registers and cleans up warnings about when data will be removed on users actions\n\t * @param {boolean} series When true adds tear downs for series.\n\t * @memberof DataLoader#\n\t */\n\tregisterDataWarnings(series) {\n\t\tconst { stx } = this;\n\t\tconst warningEvt = stx.addEventListener(\"menu\", ({ stx, menu }) => {\n\t\t\tif (\n\t\t\t\tmenu === stx.container.ownerDocument.querySelector(\"cq-menu.ciq-period\")\n\t\t\t) {\n\t\t\t\tstx.dispatch(\"notification\", {\n\t\t\t\t\tmessage: \"Changing Periodicity may lose loaded data\",\n\t\t\t\t\tdisplayTime: 3\n\t\t\t\t});\n\t\t\t}\n\t\t});\n\t\tlet seriesInj, highlightInj;\n\t\tif (series) {\n\t\t\tseriesInj = stx.append(\"removeSeries\", removeWarnings);\n\t\t\thighlightInj = stx.append(\"deleteHighlighed\", removeWarnings);\n\t\t}\n\n\t\tstx.addEventListener(\"periodicity\", ({ stx, differentData }) => {\n\t\t\tconst statics = stx.getSymbols({ static: true });\n\t\t\tif (statics && differentData) {\n\t\t\t\tstatics.forEach((symbol) => {\n\t\t\t\t\tstx.removeSeries(symbol, stx.chart);\n\t\t\t\t\tremoveWarnings();\n\t\t\t\t});\n\t\t\t}\n\t\t});\n\n\t\tstx.addEventListener(\"newChart\", () => {\n\t\t\tremoveWarnings();\n\t\t});\n\n\t\tfunction removeWarnings() {\n\t\t\tif (!stx.getSymbols({ static: true }).length) {\n\t\t\t\tstx.removeEventListener(warningEvt);\n\t\t\t\tif (series) {\n\t\t\t\t\tstx.removeInjection(seriesInj);\n\t\t\t\t\tstx.removeInjection(highlightInj);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tregisterHotKeys(uiContext) {\n\t\tconst hotKeys = CIQ.getFromNS(uiContext.config, \"hotkeyConfig.hotkeys\");\n\t\tif (!hotKeys) return;\n\n\t\tlet hotKey = hotKeys.find(({ action }) => action === \"dataLoader\");\n\t\tif (hotKey)\n\t\t\thotKey.action = () => {\n\t\t\t\tuiContext.getAdvertised(\"Channel\").write(null, \"dataLoader\", true);\n\t\t\t};\n\t}\n\n\tsubscribeToChanges(uiContext) {\n\t\tconst { stx } = uiContext;\n\t\tconst base = CIQ.UI.BaseComponent.prototype;\n\n\t\tbase.channelSubscribe(\n\t\t\t\"channel.dataLoader\",\n\t\t\t(value) => {\n\t\t\t\tlet val = value\n\t\t\t\t\t? { type: \"dataLoader\", params: { stx, context: uiContext } }\n\t\t\t\t\t: {};\n\n\t\t\t\tbase.channelWrite(\"channel.dialog\", val, stx);\n\t\t\t},\n\t\t\tstx\n\t\t);\n\t}\n}\n\n/**\n * Helper class to read loaded web files with a FileReader.\n * @constructor\n * @name CIQ.CSVReader\n * @param {external:File} file Web file that the CSVReader should parse.\n * @since 8.4.0\n */\nclass CSVReader {\n\tconstructor(file) {\n\t\tconst reader = new FileReader();\n\t\t/**\n\t\t * @type {external:FileReader}\n\t\t * @alias reader\n\t\t * @memberof CIQ.CSVReader\n\t\t * @instance\n\t\t */\n\t\tthis.reader = reader;\n\t\t/**\n\t\t * @type {external:File}\n\t\t * @alias file\n\t\t * @memberof CIQ.CSVReader\n\t\t * @instance\n\t\t */\n\t\tthis.file = file;\n\t}\n\n\t/**\n\t * Asynchronously parse a File with the FileReader.\n\t * Determines the linebreak and splits into arrays for fields and data.\n\t * On resolve returns the results of the file split based on identified line break.\n\t * @param {external:File} file File to passed to the FileReader and parsed.\n\t * @memberof CIQ.CSVReader\n\t * @async\n\t * @return {Promise}\n\t */\n\tasync parse(file) {\n\t\tconst { reader } = this;\n\t\treturn new Promise((res, rej) => {\n\t\t\treader.readAsText(file);\n\n\t\t\treader.onload = (e) => {\n\t\t\t\tconst raw = this.splitResults(reader.result);\n\t\t\t\tconst fields = raw.shift(); // remove fields so they aren't reparsed\n\t\t\t\tconst quoted = !!fields.match(/\"/);\n\t\t\t\tconst splitter = quoted ? new RegExp(/,(?=\")/) : new RegExp(/,/);\n\t\t\t\tthis.fields = fields.split(splitter).map((field) => {\n\t\t\t\t\tlet f;\n\t\t\t\t\ttry {\n\t\t\t\t\t\tf = JSON.parse(field);\n\t\t\t\t\t} catch (e) {\n\t\t\t\t\t\tf = field;\n\t\t\t\t\t}\n\t\t\t\t\treturn f;\n\t\t\t\t});\n\t\t\t\tif (raw[raw.length - 1] === \"\") raw.pop(); // remove any trailing newline\n\t\t\t\tthis.results = raw;\n\t\t\t\tres(raw);\n\t\t\t};\n\n\t\t\treader.onerror = (e) => {\n\t\t\t\tconsole.warn(e);\n\t\t\t\trej(e);\n\t\t\t};\n\t\t});\n\t}\n\n\t/**\n\t * Determines the line break on the File by checking for carriage and newLine return.\n\t * Progressively reads 5% ofthe file until it finds a value.\n\t * @param {string} data Raw parsed values from the FileReader\n\t * @memberof CIQ.CSVReader\n\t * @returns string Identified line break in the file which will be used to split results\n\t */\n\tdetermineLineBreak(data) {\n\t\tconst { length } = data;\n\t\tconst carriage = \"\\r\\n\";\n\t\tconst newLine = \"\\n\";\n\t\tlet pct = Math.floor(length * 0.05); // take first 5% of the string\n\t\tlet start = 0;\n\t\tlet lbreak;\n\t\tdo {\n\t\t\tconst sub = data.substring(start, pct);\n\t\t\tif (sub.indexOf(carriage) > -1) lbreak = carriage;\n\t\t\telse if (sub.indexOf(newLine) > -1) lbreak = newLine;\n\t\t\telse start += pct;\n\t\t} while (!lbreak);\n\t\treturn lbreak;\n\t}\n\n\t/**\n\t * Splits data from the FileReader based on determined linebreak.\n\t * @param {string} data Parsed data from FileReader\n\t * @memberof CIQ.CSVReader\n\t * @returns string[] Split data from the FileReader\n\t */\n\tsplitResults(data) {\n\t\treturn data.split(this.determineLineBreak(data));\n\t}\n}\n\nCIQ.CSVReader = CIQ.CSVReader || CSVReader;\nCIQ.DataLoader = CIQ.DataLoader || DataLoader;\n\n/**\n * Native Web File API. Files are an implementation of the Blob Object. From MDN:\n > The File interface provides information about files and allows JavaScript in a web page to access their content.\n >\n > File objects are generally retrieved from a FileList object returned as a result of a user selecting files using the `` element, from a drag and drop operation's DataTransfer object, or from the mozGetAsFile() API on an HTMLCanvasElement.\n >\n > A File object is a specific kind of a Blob, and can be used in any context that a Blob can. In particular, FileReader, URL.createObjectURL(), createImageBitmap(), and XMLHttpRequest.send() accept both Blobs and Files.\n *\n * @external File\n * @see [File](https://developer.mozilla.org/en-US/docs/Web/API/File) at Mozilla Developer Network.\n */\n/**\n * Web API that will asynchronously read File or Blob Objects. From MDN:\n >The FileReader object lets web applications asynchronously read the contents of files (or raw data buffers) stored on the user's computer, using File or Blob objects to specify the file or data to read.\n >\n > File objects may be obtained from a FileList object returned as a result of a user selecting files using the `` element, from a drag and drop operation's DataTransfer object, or from the mozGetAsFile() API on an HTMLCanvasElement.\n >\n > FileReader can only access the contents of files that the user has explicitly selected, either using an HTML `` element or by drag and drop. It cannot be used to read a file by pathname from the user's file system. To read files on the client's file system by pathname, use the File System Access API. To read server-side files, use standard Ajax solutions, with CORS permission if reading cross-domain.\n\n\n * @external FileReader\n * @see [FileReader](https://developer.mozilla.org/en-US/docs/Web/API/FileReader) at Mozilla Developer Network.\n */\n\n};\n\n\nlet __js_addons_standard_extendedHours_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Use this constructor to initialize filtering and visualization styles of extended hours by the use of shading and delimitation lines.\n *\n * Extended hours can be toggled using the Ctrl+Alt+X keystroke combination (see the\n * `extendedHours` action in `hotkeyConfig.hotkeys` in *js/defaultConfiguration.js*).\n *\n * Requires *addOns.js*.\n *\n * This visualization will only work if data for the corresponding sessions is provided from your quote feed and the market definitions have the corresponding entries.\n * See {@link CIQ.Market} for details on how to define extended (non-default) hours.\n *\n * By default all extended hour sessions are disabled unless explicitly enabled using {@link CIQ.ExtendedHours.prepare} or {@link CIQ.ExtendedHours.set}.\n *\n * All possible market sessions needed to be shaded at any given time should be enabled at once with this method.\n *\n * Your fetch should load the required data based on the `params.stx.layout.extended` and `params.stx.layout.marketSessions` settings.\n *\n * Remember that when `params.filter` is set to true, this module performs a filter of already loaded masterData when {@link CIQ.ExtendedHours.set} is invoked,\n * rather than calling {@link CIQ.ChartEngine#loadChart} to reload the data from the server every time you enable or disable this feature.\n * So you must always return all requested sessions on your fetch responses if this flag is set.\n *\n * CSS info:\n * - The styles for the shading of each session is determined by the corresponding CSS class in the form of \"stx_market_session.\"+session_name (Example: `stx_market_session.pre`)\n * - The divider line is determined by the CSS class \"stx_market_session.divider\".\n *\n * **Important:** This module must be initialized before {@link CIQ.ChartEngine#importLayout} or the sessions will not be able to be restored.\n *\n * Example:\n * \n *\n * @param {object} params The constructor parameters.\n * @param {CIQ.ChartEngine} [params.stx] The chart object.\n * @param {boolean} [params.filter] Setting to true performs a filter of masterData when\n * \t\t{@link CIQ.ExtendedHours.set} is invoked, rather than calling\n * \t\t{@link CIQ.ChartEngine#loadChart} to reload the data from the server.\n * @param {string} [params.menuContextClass] A CSS class name used to query the menu DOM\n * \t\telement that contains the UI control for the extended hours add-on. In a multi-chart\n * \t\tdocument, the add-on is available only on charts that have a menu DOM element with\n * \t\tthe value for `menuContextClass` as a class attribute.\n *\n * @constructor\n * @name CIQ.ExtendedHours\n * @since\n * - 06-2016-02\n * - 3.0.0 Changed argument to an object to support `filter`.\n * - 3.0.0 No longer necessary to explicitly call new Chart to reload data. Instead call {@link CIQ.ExtendedHours.set} function.\n * - 5.0.0 No longer necessary to explicitly set `stx.layout.marketSessions` or `1stx.layout.extended` to manage sessions; instead call {@link CIQ.ExtendedHours.prepare} or {@link CIQ.ExtendedHours.set}.\n * - 8.0.0 Added `params.menuContextClass`.\n *\n * @example\n * // Call this only once to initialize the market sessions display manager.\n * new CIQ.ExtendedHours({stx:stxx, filter:true});\n *\n * // By default all sessions are disabled unless explicitly enabled.\n * // This forces the extended hours sessions [\"pre\",\"post\"] to be enabled when the chart is initially loaded.\n * stxx.extendedHours.prepare(true);\n *\n * // Now display your chart.\n * stxx.loadChart(stxx.chart.symbol, {}, function() {});\n *\n * @example\n * // Once your chart is displayed, you can call this from any UI interface to turn on extended hours.\n * stx.extendedHours.set(true);\n *\n * // Or call this from any UI interface to turn off extended hours.\n * stx.extendedHours.set(false);\n *\n * @example\n * // CSS entries for a session divider and sessions named \"pre\" and \"post\".\n * .stx_market_session.divider {\n * background-color: rgba(0,255,0,0.8);\n * width: 1px;\n * }\n * .stx_market_session.pre {\n * background-color: rgba(255,255,0,0.1);\n * }\n * .stx_market_session.post {\n * background-color: rgba(0,0,255,0.2);\n * }\n */\nCIQ.ExtendedHours =\n\tCIQ.ExtendedHours ||\n\tfunction (params) {\n\t\tvar stx = params.stx;\n\t\tthis.filter = params.filter;\n\t\tif (!stx) {\n\t\t\t// backwards compatibility\n\t\t\tstx = params;\n\t\t\tthis.filter = false;\n\t\t}\n\t\tvar styles = {};\n\t\tthis.stx = stx;\n\t\tthis.stx.extendedHours = this;\n\t\tthis.cssRequired = true;\n\n\t\tstx.addEventListener(\"theme\", function (tObject) {\n\t\t\t// reinitialize the session colors after a theme change\n\t\t\tstyles = {};\n\t\t\tfor (var sess in stx.layout.marketSessions) {\n\t\t\t\tif (!styles.session) styles.session = {};\n\t\t\t\tstyles.session[sess] = stx.canvasStyle(\"stx_market_session \" + sess);\n\t\t\t}\n\t\t});\n\n\t\tstx.addEventListener(\"symbolChange\", function (tObject) {\n\t\t\t// check if extended hours exists for this security\n\t\t\tif (\n\t\t\t\ttObject.action == \"master\" &&\n\t\t\t\tstx.layout.extended &&\n\t\t\t\t!(stx.chart.market.market_def && stx.chart.market.sessions.length)\n\t\t\t) {\n\t\t\t\tCIQ.alert(\"There are no Extended Hours for this instrument.\");\n\t\t\t}\n\t\t});\n\n\t\tif (CIQ.UI) {\n\t\t\tCIQ.UI.KeystrokeHub.addHotKeyHandler(\n\t\t\t\t\"extendedHours\",\n\t\t\t\t({ stx }) => {\n\t\t\t\t\tstx.container.ownerDocument.body.keystrokeHub.context.advertised.Layout.setExtendedHours();\n\t\t\t\t},\n\t\t\t\tstx\n\t\t\t);\n\t\t}\n\n\t\t/**\n\t\t * Prepares the extended hours settings and classes for the session names enumerated in the arguments without actually displaying or loading the data.\n\t\t *\n\t\t * This method can be used to force a particular session to load by default by calling it before {@link CIQ.ChartEngine#loadChart}.\n\t\t * Otherwise the chart will be loaded with all sessions disabled until {@link CIQ.ExtendedHours.set} is invoked.\n\t\t *\n\t\t * {@link CIQ.ChartEngine#importLayout} will also call this method to ensure the sessions are restored as previously saved.\n\t\t *\n\t\t * @param {boolean} enable Set to turn on/off the extended-hours visualization.\n\t\t * @param {array} sessions The sessions to visualize when enable is true. Any sessions previously visualized will be disabled. If set to null, will default to [\"pre\",\"post\"].\n\t\t * @memberof CIQ.ExtendedHours#\n\t\t * @alias prepare\n\t\t * @since 5.0.0\n\t\t */\n\t\tthis.prepare = function (enable, sessions) {\n\t\t\tstx.layout.extended = enable;\n\t\t\tfor (var sess in stx.layout.marketSessions) {\n\t\t\t\tstyles.session = {};\n\t\t\t\tstx.chart.market.disableSession(sess);\n\t\t\t}\n\t\t\tstx.layout.marketSessions = {};\n\t\t\tif (enable) {\n\t\t\t\tif (!sessions) sessions = [\"pre\", \"post\"];\n\t\t\t\tif (sessions.length) {\n\t\t\t\t\tfor (var s = 0; s < sessions.length; s++) {\n\t\t\t\t\t\tstx.layout.marketSessions[sessions[s]] = true;\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tstx.layout.marketSessions = sessions;\n\t\t\t\t}\n\t\t\t}\n\t\t\tfor (sess in stx.layout.marketSessions) {\n\t\t\t\tif (!styles.session) styles.session = {};\n\t\t\t\tstyles.session[sess] = stx.canvasStyle(\"stx_market_session \" + sess);\n\t\t\t\tstx.chart.market.disableSession(sess, true);\n\t\t\t}\n\t\t};\n\n\t\t/**\n\t\t * gathers and renders the extended hours for the preset session names enumerated in prepare().\n\t\t * @param {function} cb Optional callback function to be invoked once chart is reloaded with extended hours data.\n\t\t * @memberof CIQ.ExtendedHours#\n\t\t * @alias complete\n\t\t * @private\n\t\t * @since 5.0.0\n\t\t */\n\t\tthis.complete = function (cb) {\n\t\t\tstx.changeOccurred(\"layout\");\n\t\t\tif (!stx.chart.market.market_def) {\n\t\t\t\t// possibly a 24 hours Market. Not necessarily an error but nothing to do for ExtendedHours\n\t\t\t\tif (cb) cb();\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tif (this.filter) {\n\t\t\t\tstx.createDataSet();\n\t\t\t\tstx.draw();\n\t\t\t\tif (cb) cb();\n\t\t\t} else {\n\t\t\t\tstx.loadChart(stx.chart.symbol, cb);\n\t\t\t}\n\t\t};\n\n\t\t/**\n\t\t * Turns on or off extended hours for the session names enumerated in the arguments.\n\t\t * @param {boolean} enable Set to turn on/off the extended-hours visualization.\n\t\t * @param {array} sessions The sessions to visualize when enable is true. Any sessions previously visualized will be disabled. If set to null, will default to [\"pre\",\"post\"].\n\t\t * @param {function} cb Optional callback function to be invoked once chart is reloaded with extended hours data.\n\t\t * @memberof CIQ.ExtendedHours#\n\t\t * @alias set\n\t\t */\n\t\tthis.set = function (enable, sessions, cb) {\n\t\t\tthis.prepare(enable, sessions);\n\t\t\tthis.complete(cb);\n\t\t};\n\n\t\t// This injection shades the after hours portion of the chart for each yaxis.\n\t\t// Only the panel to which the yaxis belongs will get shading.\n\t\t// This means yaxes of overlays will bypass the shading block.\n\t\tthis.stx.append(\"drawYAxis\", function (panel, parameters) {\n\t\t\tif (!this.layout.extended) return;\n\t\t\tif (\n\t\t\t\tpanel.yAxis != parameters.yAxis ||\n\t\t\t\tpanel.shareChartXAxis === false ||\n\t\t\t\tpanel.hidden\n\t\t\t)\n\t\t\t\treturn;\n\t\t\tvar chart = panel.chart;\n\t\t\tif (CIQ.ChartEngine.isDailyInterval(this.layout.interval)) return;\n\t\t\tstyles.divider = this.canvasStyle(\"stx_market_session divider\");\n\t\t\tif (styles.session) {\n\t\t\t\tvar m = chart.market;\n\t\t\t\tvar ranges = [];\n\t\t\t\tvar range = {};\n\t\t\t\tvar nextBoundary, thisSession;\n\t\t\t\tfor (var i = 0; i < chart.dataSegment.length; i++) {\n\t\t\t\t\tvar ds = chart.dataSegment[i];\n\t\t\t\t\tif (!ds || !ds.DT) continue;\n\t\t\t\t\tvar c = null;\n\t\t\t\t\tif (m.market_def) {\n\t\t\t\t\t\tif (!nextBoundary || nextBoundary <= ds.DT) {\n\t\t\t\t\t\t\tthisSession = m.getSession(ds.DT);\n\t\t\t\t\t\t\tvar filterSession =\n\t\t\t\t\t\t\t\tthisSession !== \"\" &&\n\t\t\t\t\t\t\t\t(!this.layout.marketSessions ||\n\t\t\t\t\t\t\t\t\t!this.layout.marketSessions[thisSession]);\n\t\t\t\t\t\t\tnextBoundary = m[filterSession ? \"getNextOpen\" : \"getNextClose\"](\n\t\t\t\t\t\t\t\tds.DT\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tvar s = styles.session[thisSession];\n\t\t\t\t\tif (s) c = s.backgroundColor;\n\t\t\t\t\tif (range.color && range.color != c) {\n\t\t\t\t\t\tranges.push({\n\t\t\t\t\t\t\tstart: range.start,\n\t\t\t\t\t\t\tend: range.end,\n\t\t\t\t\t\t\tcolor: range.color\n\t\t\t\t\t\t});\n\t\t\t\t\t\trange = {};\n\t\t\t\t\t}\n\t\t\t\t\tif (c) {\n\t\t\t\t\t\tvar cw = this.layout.candleWidth;\n\t\t\t\t\t\tif (ds.candleWidth) cw = ds.candleWidth;\n\t\t\t\t\t\trange.end = this.pixelFromBar(i, chart) + cw / 2;\n\t\t\t\t\t\tif (!range.start && range.start !== 0)\n\t\t\t\t\t\t\trange.start = range.end - cw + 1;\n\t\t\t\t\t\trange.color = c;\n\t\t\t\t\t} else {\n\t\t\t\t\t\trange = {};\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (range.start || range.start === 0)\n\t\t\t\t\tranges.push({\n\t\t\t\t\t\tstart: range.start,\n\t\t\t\t\t\tend: range.end,\n\t\t\t\t\t\tcolor: range.color\n\t\t\t\t\t});\n\t\t\t\tvar noDashes = CIQ.isTransparent(styles.divider.backgroundColor);\n\t\t\t\tvar dividerLineWidth = styles.divider.width.replace(/px/g, \"\");\n\t\t\t\tvar dividerStyle = {\n\t\t\t\t\ty0: panel.bottom,\n\t\t\t\t\ty1: panel.top,\n\t\t\t\t\tcolor: styles.divider.backgroundColor,\n\t\t\t\t\ttype: \"line\",\n\t\t\t\t\tcontext: chart.context,\n\t\t\t\t\tconfineToPanel: panel,\n\t\t\t\t\tpattern: \"dashed\",\n\t\t\t\t\tlineWidth: dividerLineWidth,\n\t\t\t\t\tdeferStroke: true\n\t\t\t\t};\n\t\t\t\tthis.startClip(panel.name);\n\t\t\t\tchart.context.beginPath();\n\t\t\t\tif (stx.highlightedDraggable) chart.context.globalAlpha *= 0.3;\n\t\t\t\tfor (i = 0; i < ranges.length; i++) {\n\t\t\t\t\tchart.context.fillStyle = ranges[i].color;\n\t\t\t\t\tif (!noDashes && ranges[i].start > chart.left)\n\t\t\t\t\t\tthis.plotLine(\n\t\t\t\t\t\t\tCIQ.extend(\n\t\t\t\t\t\t\t\t{ x0: ranges[i].start, x1: ranges[i].start },\n\t\t\t\t\t\t\t\tdividerStyle\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t);\n\t\t\t\t\tchart.context.fillRect(\n\t\t\t\t\t\tranges[i].start,\n\t\t\t\t\t\tpanel.top,\n\t\t\t\t\t\tranges[i].end - ranges[i].start,\n\t\t\t\t\t\tpanel.bottom - panel.top\n\t\t\t\t\t);\n\t\t\t\t\tif (!noDashes && ranges[i].end < chart.right)\n\t\t\t\t\t\tthis.plotLine(\n\t\t\t\t\t\t\tCIQ.extend({ x0: ranges[i].end, x1: ranges[i].end }, dividerStyle)\n\t\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t\tchart.context.stroke();\n\t\t\t\tthis.endClip();\n\t\t\t}\n\t\t});\n\t};\n\n};\n\n\nlet __js_addons_standard_fullScreen_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Creates an add-on that sets the chart UI to full-screen mode. In full-screen mode, a class\n * `full-screen` is added to the context element used for styling. In addition, elements with the\n * class `full-screen-hide` are hidden. Elements with the class `full-screen-show` that are\n * normally hidden are shown.\n *\n * Requires *addOns.js*.\n *\n * ![Full-screen display](./img-Full-Screen-Chart.png)\n *\n * @param {object} params Configuration parameters.\n * @param {CIQ.ChartEngine} [params.stx] The chart object.\n *\n * @constructor\n * @name CIQ.FullScreen\n * @since 7.3.0\n *\n * @example\n * new CIQ.FullScreen({ stx: stxx });\n */\nCIQ.FullScreen =\n\tCIQ.FullScreen ||\n\tfunction (params) {\n\t\tif (!params) params = {};\n\t\tif (!params.stx) {\n\t\t\tconsole.warn(\"The Full Screen addon requires an stx parameter\");\n\t\t\treturn;\n\t\t}\n\t\t// Check for loading within an iframe from another origin\n\t\ttry {\n\t\t\tif (window.location.host !== window.top.location.host)\n\t\t\t\tthrow new Error(\n\t\t\t\t\twindow.location.host + \" does not match \" + window.top.location.host\n\t\t\t\t);\n\t\t} catch (exception) {\n\t\t\tconsole.warn(\"Full screen mode disabled.\");\n\t\t\treturn;\n\t\t}\n\t\tthis.stx = params.stx;\n\t\tthis.stx.fullScreen = this;\n\t\tthis.fullScreenButton = null;\n\t\tthis.fullScreenState = false;\n\n\t\t//Attaches FullScreen button to HTML DOM inside .chartSize element\n\t\tthis.addFullScreenButton = function () {\n\t\t\tif (this.stx.registerChartControl)\n\t\t\t\tthis.fullScreenButton = this.stx.registerChartControl(\n\t\t\t\t\t\"stx-full-screen\",\n\t\t\t\t\t\"Full Screen\",\n\t\t\t\t\t(function (self) {\n\t\t\t\t\t\treturn function (e) {\n\t\t\t\t\t\t\tself.fullScreenToggle(e);\n\t\t\t\t\t\t\te.stopPropagation();\n\t\t\t\t\t\t};\n\t\t\t\t\t})(this)\n\t\t\t\t);\n\t\t};\n\n\t\t//Click event handler for the Full Screen button.\n\t\tthis.fullScreenToggle = function (e) {\n\t\t\tvar doc = e.target.ownerDocument;\n\t\t\t// First check for availability of the requestFullScreen function\n\t\t\tif (\n\t\t\t\tdoc.documentElement.requestFullscreen ||\n\t\t\t\tdoc.documentElement.webkitRequestFullscreen ||\n\t\t\t\tdoc.documentElement.mozRequestFullscreen ||\n\t\t\t\tdoc.documentElement.msRequestFullscreen\n\t\t\t) {\n\t\t\t\t// Check if full screen is already enabled\n\t\t\t\tif (this.getFullScreenElement(doc)) {\n\t\t\t\t\tif (doc.exitFullscreen) doc.exitFullscreen();\n\t\t\t\t\telse if (doc.webkitExitFullscreen) doc.webkitExitFullscreen();\n\t\t\t\t\telse if (doc.mozCancelFullScreen) doc.mozCancelFullScreen();\n\t\t\t\t\telse if (doc.msExitFullscreen) doc.msExitFullscreen();\n\t\t\t\t} else {\n\t\t\t\t\t// requestFullscreen methods need to be checked for again here because the browser will not allow the method to be stored in a local var\n\t\t\t\t\tif (doc.documentElement.requestFullscreen)\n\t\t\t\t\t\tdoc.documentElement.requestFullscreen();\n\t\t\t\t\telse if (doc.documentElement.webkitRequestFullscreen)\n\t\t\t\t\t\tdoc.documentElement.webkitRequestFullscreen();\n\t\t\t\t\telse if (doc.documentElement.mozRequestFullscreen)\n\t\t\t\t\t\tdoc.documentElement.mozRequestFullscreen();\n\t\t\t\t\telse if (doc.documentElement.msRequestFullscreen)\n\t\t\t\t\t\tdoc.documentElement.msRequestFullscreen();\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t//If the full screen api isn't available, manually trigger the fullScreen styling\n\t\t\t\tthis.fullScreenState = !this.fullScreenState;\n\t\t\t\tthis.fullScreenRender();\n\t\t\t}\n\t\t};\n\n\t\t// Append/remove full-screen class to context or body and update button state\n\t\tthis.fullScreenRender = function () {\n\t\t\tvar containerElement = null;\n\t\t\tcontainerElement = this.stx.container.closest(\n\t\t\t\t\"*[cq-context], cq-context, body\"\n\t\t\t);\n\t\t\tif (containerElement) {\n\t\t\t\tif (this.fullScreenState === true) {\n\t\t\t\t\tif (this.fullScreenButton)\n\t\t\t\t\t\tthis.fullScreenButton.classList.add(\"active\");\n\t\t\t\t\tcontainerElement.classList.add(\"full-screen\");\n\t\t\t\t} else {\n\t\t\t\t\tif (this.fullScreenButton)\n\t\t\t\t\t\tthis.fullScreenButton.classList.remove(\"active\");\n\t\t\t\t\tcontainerElement.classList.remove(\"full-screen\");\n\t\t\t\t}\n\t\t\t\t// Trigger a resize event to update the chart size\n\t\t\t\twindow.dispatchEvent(new Event(\"resize\"));\n\t\t\t}\n\t\t};\n\n\t\t//Handle full screen change\n\t\tthis.onFullScreenChange = function (e) {\n\t\t\tif (this.getFullScreenElement(e.target.ownerDocument)) {\n\t\t\t\tthis.fullScreenState = true;\n\t\t\t} else {\n\t\t\t\tthis.fullScreenState = false;\n\t\t\t}\n\t\t\tthis.fullScreenRender();\n\t\t};\n\n\t\tthis.getFullScreenElement = function (doc) {\n\t\t\treturn (\n\t\t\t\tdoc.fullscreenElement ||\n\t\t\t\tdoc.webkitCurrentFullScreenElement ||\n\t\t\t\tdoc.mozFullScreenElement ||\n\t\t\t\tdoc.msFullscreenElement\n\t\t\t);\n\t\t};\n\n\t\tvar self = this;\n\t\t[\n\t\t\t\"fullscreenchange\",\n\t\t\t\"webkitfullscreenchange\",\n\t\t\t\"mozfullscreenchange\",\n\t\t\t\"MSFullscreenChange\"\n\t\t].forEach(function (ev) {\n\t\t\tself.stx.container.ownerDocument.addEventListener(\n\t\t\t\tev,\n\t\t\t\tself.onFullScreenChange.bind(self)\n\t\t\t);\n\t\t});\n\n\t\t// Add the FullScreen button to chartControls\n\t\tthis.addFullScreenButton();\n\t};\n\n};\n\n\nlet __js_addons_standard_inactivityTimer_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Add-On that puts the chart into \"sleep mode\" after a period of inactivity.\n *\n * Requires *addOns.js*.\n *\n * In sleep mode, a class \"ciq-sleeping\" will be added to the body. This will dim out the chart.\n * Sleep mode is ended when interaction with the chart is detected.\n *\n * @param {object} params Configuration parameters\n * @param {CIQ.ChartEngine} [params.stx] The chart object\n * @param {number} [params.minutes] Inactivity period in _minutes_. Set to 0 to disable the sleep mode.\n * @param {number} [params.interval] Sleeping quote update interval in _seconds_. During sleep mode, this is used for the update loop.\n * \t\t\t\t\t\t\t\t\tSet to non-zero positive number or defaults to 60.\n * @param {function} [params.wakeCB] Optional callback function after waking\n * @param {function} [params.sleepCB] Optional callback function after sleeping\n * @constructor\n * @name CIQ.InactivityTimer\n * @since 3.0.0\n * @example\n * \tnew CIQ.InactivityTimer({stx:stxx, minutes:30, interval:15}); //30 minutes of inactivity will put chart into sleep mode, updating every 15 seconds\n *\n */\nCIQ.InactivityTimer =\n\tCIQ.InactivityTimer ||\n\tfunction (params) {\n\t\tif (!params.minutes) return;\n\t\tif (!params.interval || params.interval < 0) params.interval = 60;\n\t\tthis.stx = params.stx;\n\t\tthis.timeout = params.minutes;\n\t\tthis.interval = params.interval;\n\t\tthis.wakeCB = params.wakeCB;\n\t\tthis.sleepCB = params.sleepCB;\n\t\tthis.sleepTimer = null;\n\t\tthis.sleeping = false;\n\t\tthis.last = new Date().getTime();\n\t\tthis.wakeChart = function (isPropagated) {\n\t\t\tclearTimeout(this.sleepTimer);\n\t\t\tthis.last = new Date().getTime();\n\t\t\tif (this.sleeping) {\n\t\t\t\tif (this.stx.quoteDriver) this.stx.quoteDriver.updateChartLoop();\n\t\t\t\tthis.sleeping = false;\n\t\t\t\tthis.stx.container.ownerDocument.body.classList.remove(\"ciq-sleeping\");\n\t\t\t\tif (!isPropagated) {\n\t\t\t\t\tCIQ.ChartEngine.registeredContainers.forEach(function (container) {\n\t\t\t\t\t\tif (params.stx !== container.stx && container.stx.inactivityTimer)\n\t\t\t\t\t\t\tcontainer.stx.inactivityTimer.wakeChart(true);\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\t\t\tthis.sleepTimer = setTimeout(\n\t\t\t\tthis.sleepChart.bind(this),\n\t\t\t\tthis.timeout * 60000\n\t\t\t);\n\t\t\tif (this.wakeCB) this.wakeCB();\n\t\t};\n\t\tthis.sleepChart = function (isPropagated) {\n\t\t\tif (!this.sleeping) {\n\t\t\t\tif (this.stx.quoteDriver)\n\t\t\t\t\tthis.stx.quoteDriver.updateChartLoop(this.interval);\n\t\t\t\tthis.sleeping = true;\n\t\t\t\tthis.stx.container.ownerDocument.body.classList.add(\"ciq-sleeping\");\n\t\t\t\tif (!isPropagated) {\n\t\t\t\t\tCIQ.ChartEngine.registeredContainers.forEach(function (container) {\n\t\t\t\t\t\tif (params.stx !== container.stx && container.stx.inactivityTimer)\n\t\t\t\t\t\t\tcontainer.stx.inactivityTimer.sleepChart(true);\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (this.sleepCB) this.sleepCB();\n\t\t};\n\n\t\tvar self = this;\n\t\tfunction wake() {\n\t\t\tself.wakeChart();\n\t\t}\n\n\t\t[\n\t\t\t\"mousemove\",\n\t\t\t\"mousedown\",\n\t\t\t\"touchstart\",\n\t\t\t\"touchmove\",\n\t\t\t\"pointerdown\",\n\t\t\t\"pointermove\",\n\t\t\t\"keydown\",\n\t\t\t\"wheel\"\n\t\t].forEach(function (ev) {\n\t\t\tself.stx.container.ownerDocument.addEventListener(ev, wake, {\n\t\t\t\tpassive: false\n\t\t\t});\n\t\t});\n\n\t\tthis.stx.inactivityTimer = this;\n\n\t\tthis.wakeChart();\n\t};\n\n};\n\n\nlet __js_addons_standard_rangeSlider_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Add-on that adds a range slider to the chart.\n *\n * The range slider allows the `dataSegment` to be selectable as a portion of the data set.\n *\n * The range slider can be toggled using the Ctrl+Alt+R keystroke combination (see the\n * `rangeSlider` action in `hotkeyConfig.hotkeys` in *js/defaultConfiguration.js*).\n *\n * Requires *addOns.js*.\n *\n * Also requires additional CSS. Add the following style sheet:\n * ```\n * \n * ```\n * or directly include this CSS:\n * ```\n * .stx_range_slider.shading {\n * background-color: rgba(128, 128, 128, 0.3);\n * border: solid 2px #0090b7;\n * width: 5px;\n * }\n * ```\n * Once instantiated, the range slider can be displayed or hidden by setting the `rangeSlider`\n * parameter of the primary chart's [layout object]{@link CIQ.ChartEngine#layout} and then issuing\n * a layout change event to trigger the new status. When initialing loading the chart, enable the\n * range slider in a callback function to prevent out‑of‑sequence issues. See the\n * examples below.\n *\n * A range slider is simply another chart. So you configure it and customize it using the same\n * parameters as you would the primary chart. The only difference is that the slider object is a\n * sub‑element of the primary chart, contained in the `slider.slider` object.\n *\n * For example, if you wanted to turn off the x-axis on the slider, assuming a chart instantiated\n * as `stxx`, you would execute:\n * ```\n * stxx.slider.slider.xaxisHeight = 0;\n * ```\n *\n * It is important to note that the range slider chart DOM element creates itself below the\n * primary chart container element, not inside the container. As such, all styling must be on a\n * parent `div` container rather than on the primary chart container itself to ensure styling is\n * shared between the chart and range slider containers.\n *\n * For example, do this:\n * ```\n *
\n *
\n *
\n *
\n * \n *
\n *
\n *
\n * ```\n *\n * not this:\n * ```\n *
\n *
\n *
\n *
\n *
\n * ```\n *\n * Range slider example:\n * \n *\n * @param {object} params Configuration parameters.\n * @param {CIQ.ChartEngine} [params.stx] The chart object.\n * @param {number} [params.height=\"95px\"] Height of the range slider panel. Must include a CSS\n * \t\tunit, such as \"px\".\n * @param {object} [params.yAxis] Y-axis parameters.\n * @param {number} [params.chartContainer] Handle to the main chart container. Defaults to\n * \t\t`stxx.container`.\n * @param {string} [params.menuContextClass] A CSS class name used to query the menu DOM element\n * \t\tthat contains the UI control for the range slider add-on. In a multi-chart document, the\n * \t\tadd-on is available only on charts that have a menu DOM element with the value for\n * \t\t`menuContextClass` as a class attribute.\n *\n * @constructor\n * @name CIQ.RangeSlider\n * @since\n * - 4.0.0\n * - 6.1.0 Added `params.yAxis`.\n * - 8.0.0 Added `params.menuContextClass`.\n *\n * @example\n * \n * \t\tCreate a range slider and enable it by default using the loadChart callback.\n * \n * const stxx = new CIQ.ChartEngine({ container: document.querySelector(\".chartContainer\") });\n *\n * stxx.attachQuoteFeed(quoteFeedSimulator,{ refreshInterval: 1, bufferSize: 200 });\n *\n * // Instantiate a range slider.\n * new CIQ.RangeSlider({ stx: stxx });\n *\n * function displayChart(){\n * stxx.loadChart(\"SPY\", null, function() {\n * // For smoother visualization, enable after the main chart has completed loading its data.\n * stxx.layout.rangeSlider = true; // Show the slider.\n * stxx.changeOccurred(\"layout\"); // Signal the change to force a redraw.\n * });\n * }\n *\n * @example\n * \n * \t\tCreate a range slider and enable/disable it using commands to be triggered from a menu.\n * \n * const stxx = new CIQ.ChartEngine({ container: document.querySelector(\".chartContainer\") });\n *\n * // Instantiate a range slider.\n * new CIQ.RangeSlider({ stx: stxx });\n *\n * // To display the slider from a menu use:\n * stxx.layout.rangeSlider = true; // Show the slider.\n * stxx.changeOccurred(\"layout\"); // Signal the change to force a redraw.\n *\n * // To hide the slider from a menu use:\n * stxx.layout.rangeSlider = false; // Hide the slider.\n * stxx.changeOccurred(\"layout\"); // Signal the change to force a redraw.\n */\nCIQ.RangeSlider =\n\tCIQ.RangeSlider ||\n\tfunction (params) {\n\t\tthis.cssRequired = true;\n\n\t\tvar stx = params.stx;\n\t\tstx.slider = this;\n\t\tvar sliderHeight = params.height ? params.height : \"95px\";\n\t\tvar chartContainer = params.chartContainer\n\t\t\t? params.chartContainer\n\t\t\t: params.stx.container;\n\n\t\tvar ciqSlider = document.createElement(\"div\");\n\t\tciqSlider.className = \"ciq-chart\";\n\t\tvar sliderContainer = document.createElement(\"div\");\n\t\tsliderContainer.className = \"chartContainer\";\n\t\tciqSlider.appendChild(sliderContainer);\n\t\tchartContainer.parentElement.parentElement.insertBefore(\n\t\t\tciqSlider,\n\t\t\tchartContainer.parentElement.nextSibling\n\t\t);\n\t\tObject.assign(ciqSlider.style, {\n\t\t\theight: sliderHeight,\n\t\t\tpaddingTop: \"5px\",\n\t\t\tdisplay: \"none\"\n\t\t});\n\t\tsliderContainer.style.height = \"100%\";\n\t\tsliderContainer.dimensionlessCanvas = true;\n\t\tvar self = (this.slider = new CIQ.ChartEngine({\n\t\t\tcontainer: sliderContainer,\n\t\t\tpreferences: { labels: false, whitespace: 0 }\n\t\t}));\n\t\tself.xaxisHeight = 30;\n\t\tself.manageTouchAndMouse = false;\n\t\tself.minimumCandleWidth = 0;\n\t\tself.chart.yaxisMarginMultiplier = 1;\n\t\tvar panel = self.chart.panel;\n\t\tvar subholder = panel.subholder;\n\t\tvar closeButton = panel.close;\n\t\tsubholder.style.cursor = \"ew-resize\";\n\t\tsubholder.classList.add(\"stx_range_slider\");\n\t\tif (closeButton) {\n\t\t\tcloseButton.style.display = \"inline\";\n\t\t\tCIQ.safeClickTouch(closeButton, function () {\n\t\t\t\tstx.layout.rangeSlider = false;\n\t\t\t\tstx.changeOccurred(\"layout\");\n\t\t\t});\n\t\t}\n\t\tvar yAxis = panel.yAxis;\n\t\tyAxis.drawCurrentPriceLabel = false;\n\t\tObject.defineProperty(yAxis, \"position\", {\n\t\t\tget: function () {\n\t\t\t\treturn stx.slider.yAxisPosition || stx.chart.panel.yAxis.position;\n\t\t\t},\n\t\t\tset: function (position) {\n\t\t\t\tstx.slider.yAxisPosition = position;\n\t\t\t}\n\t\t});\n\t\tconst { get, set } = Object.getOwnPropertyDescriptor(\n\t\t\tCIQ.ChartEngine.YAxis.prototype,\n\t\t\t\"width\"\n\t\t);\n\t\tObject.defineProperty(yAxis, \"width\", {\n\t\t\tget: function () {\n\t\t\t\treturn Math.max(get.call(yAxis), stx.chart.yAxis.width);\n\t\t\t},\n\t\t\tset: function (width) {\n\t\t\t\tset.call(yAxis, width);\n\t\t\t}\n\t\t});\n\t\tCIQ.extend(yAxis, params.yAxis);\n\t\tself.chart.baseline.userLevel = false;\n\t\tif (self.controls.home) self.controls.home.style.width = 0;\n\t\tself.initializeChart();\n\t\tif (CIQ.UI) {\n\t\t\tCIQ.UI.KeystrokeHub.addHotKeyHandler(\n\t\t\t\t\"rangeSlider\",\n\t\t\t\t({ stx }) => {\n\t\t\t\t\tstx.container.ownerDocument.body.keystrokeHub.context.advertised.Layout.setRangeSlider();\n\t\t\t\t},\n\t\t\t\tstx\n\t\t\t);\n\t\t\tCIQ.UI.observeProperty(\"breakpoint\", stx.chart, (obj) =>\n\t\t\t\tself.notifyBreakpoint(obj.value)\n\t\t\t);\n\t\t}\n\n\t\t/**\n\t\t * Dynamically updates the styling of the range slider.\n\t\t *\n\t\t * This method can be used to update CSS styles if you are injecting stylesheets using\n\t\t * JavaScript.\n\t\t *\n\t\t * @param {string} obj The CSS selector for which a style property is changed.\n\t\t * @param {string} attribute The style property changed in the CSS selector rule-set.\n\t\t * @param {string} value The value to apply to the CSS property.\n\t\t *\n\t\t * @alias updateStyles\n\t\t * @memberof CIQ.RangeSlider.prototype\n\t\t * @since 8.0.0\n\t\t *\n\t\t * @example\n\t\t * // Set the shading of the range slider.\n\t\t * stxx.slider.updateStyles(\n\t\t * 'stx_range_slider shading',\n\t\t * 'backgroundColor',\n\t\t * 'rgba(200, 50, 50, 0.45)'\n\t\t * );\n\t\t *\n\t\t * @example\n\t\t * // Set the color of the bars of the range slider to red.\n\t\t * stxx.slider.updateStyles(\n\t\t * 'stx_range_slider shading',\n\t\t * 'borderTopColor',\n\t\t * 'rgba(255, 0, 0)'\n\t\t * );\n\t\t */\n\t\tthis.updateStyles = function (obj, attribute, value) {\n\t\t\tstx.setStyle(obj, attribute, value);\n\t\t\tthis.style = stx.canvasStyle(\"stx_range_slider shading\");\n\t\t};\n\n\t\tthis.display = function (on) {\n\t\t\tif (stx.layout.rangeSlider !== on) {\n\t\t\t\t// do this the way it was intended\n\t\t\t\tstx.layout.rangeSlider = on;\n\t\t\t\tstx.changeOccurred(\"layout\");\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tciqSlider.style.display = on ? \"\" : \"none\";\n\t\t\tstx.resizeChart();\n\t\t\tciqSlider.ownerDocument.defaultView.dispatchEvent(new Event(\"resize\"));\n\t\t\tif (!on) return;\n\t\t\tself.resizeChart();\n\t\t\tself.initializeChart();\n\t\t\tthis.requestDraw();\n\t\t};\n\t\tthis.setSymbol = function (symbol) {\n\t\t\tself.chart.panel.display = self.chart.symbol = symbol;\n\t\t\tself.chart.symbolObject = { symbol: symbol };\n\t\t\tself.chart.market = stx.chart.market;\n\t\t\tself.setMainSeriesRenderer();\n\t\t\tself.resizeChart();\n\t\t\tthis.adjustRange(stx.chart);\n\t\t\tthis.requestDraw();\n\t\t};\n\t\tthis.acceptLayoutChange = function (layout) {\n\t\t\tvar doDraw = false;\n\t\t\tif (self.layout.rangeSlider !== layout.rangeSlider) {\n\t\t\t\tstx.slider.display(layout.rangeSlider);\n\t\t\t}\n\t\t\tvar relevantLayoutPropertiesForRedraw = [\n\t\t\t\t\"chartType\",\n\t\t\t\t\"aggregationType\",\n\t\t\t\t\"periodicity\",\n\t\t\t\t\"interval\",\n\t\t\t\t\"timeUnit\",\n\t\t\t\t\"chartScale\",\n\t\t\t\t\"rangeSlider\",\n\t\t\t\t\"flipped\",\n\t\t\t\t\"extended\",\n\t\t\t\t\"marketSessions\",\n\t\t\t\t\"kagi\",\n\t\t\t\t\"rangebars\",\n\t\t\t\t\"renko\",\n\t\t\t\t\"priceLines\",\n\t\t\t\t\"pandf\"\n\t\t\t];\n\t\t\trelevantLayoutPropertiesForRedraw.forEach(function (x) {\n\t\t\t\tif (!CIQ.equals(self.layout[x], layout[x])) {\n\t\t\t\t\tself.layout[x] = layout[x];\n\t\t\t\t\tdoDraw = true;\n\t\t\t\t}\n\t\t\t});\n\t\t\tif (!CIQ.trulyVisible(ciqSlider)) return;\n\t\t\tif (doDraw) {\n\t\t\t\tself.setMainSeriesRenderer();\n\t\t\t\tthis.requestDraw();\n\t\t\t}\n\t\t};\n\t\tthis.adjustRange = function (chart) {\n\t\t\tif (!chart.dataSet) return;\n\t\t\tif (!chart.endPoints || !chart.endPoints.begin) return;\n\t\t\tvar myChart = self.chart;\n\t\t\tif (!myChart.width) return;\n\t\t\tvar scrollOffset = 0,\n\t\t\t\tticksOffset = 0;\n\t\t\tif (stx.quoteDriver) {\n\t\t\t\tvar behaviorParams = {\n\t\t\t\t\tsymbol: chart.symbol,\n\t\t\t\t\tsymbolObject: chart.symbolObject,\n\t\t\t\t\tinterval: stx.layout.interval\n\t\t\t\t};\n\t\t\t\tif (\n\t\t\t\t\t(behaviorParams.interval == \"month\" ||\n\t\t\t\t\t\tbehaviorParams.interval == \"week\") &&\n\t\t\t\t\t!stx.dontRoll\n\t\t\t\t) {\n\t\t\t\t\tbehaviorParams.interval = \"day\";\n\t\t\t\t}\n\t\t\t\tvar behavior = stx.quoteDriver.getQuoteFeed(behaviorParams).behavior;\n\t\t\t\tif (behavior && behavior.bufferSize) {\n\t\t\t\t\tif (chart.moreAvailable) scrollOffset = behavior.bufferSize;\n\t\t\t\t\tif (stx.isHistoricalMode()) ticksOffset = behavior.bufferSize;\n\t\t\t\t}\n\t\t\t}\n\t\t\tmyChart.baseline.defaultLevel = chart.baseline.actualLevel;\n\t\t\tmyChart.scroll =\n\t\t\t\tMath.max(\n\t\t\t\t\t0,\n\t\t\t\t\tchart.dataSet.length -\n\t\t\t\t\t\tstx.tickFromDate(chart.endPoints.begin) -\n\t\t\t\t\t\tscrollOffset\n\t\t\t\t) + 1;\n\t\t\tself.setMaxTicks(myChart.scroll - ticksOffset + 2);\n\t\t};\n\t\tthis.copyData = function (chart) {\n\t\t\tif (!(chart.dataSet && chart.masterData)) return;\n\t\t\tvar myChart = self.chart;\n\t\t\tmyChart.masterData = self.masterData = chart.masterData.slice(0);\n\t\t\tmyChart.dataSet = chart.dataSet.slice(0);\n\t\t\tmyChart.state = chart.state;\n\t\t\tthis.requestDraw();\n\t\t};\n\t\tthis.calculateYAxisPosition = function () {\n\t\t\tvar panel = self.chart.panel;\n\t\t\tvar currentPosition = self.getYAxisCurrentPosition(panel.yAxis, panel);\n\t\t\tif (currentPosition != panel.yAxis.position)\n\t\t\t\tself.calculateYAxisPositions();\n\t\t};\n\t\tthis.drawSlider = function () {\n\t\t\tif (!CIQ.trulyVisible(ciqSlider)) return;\n\t\t\tif (!stx.chart.dataSet || !stx.chart.dataSet.length) return;\n\t\t\tvar style = this.style;\n\t\t\tif (!style)\n\t\t\t\tstyle = this.style = stx.canvasStyle(\"stx_range_slider shading\");\n\t\t\tvar chartPanel = stx.chart.panel,\n\t\t\t\tctx = self.chart.context,\n\t\t\t\tsegmentImage = self.chart.segmentImage || [],\n\t\t\t\thalfCandle = self.layout.candleWidth / 2;\n\t\t\tvar left = (self.tickLeft = Math.max(\n\t\t\t\tstx.tickFromPixel(chartPanel.left + halfCandle),\n\t\t\t\t0\n\t\t\t));\n\t\t\tvar right = (self.tickRight = Math.min(\n\t\t\t\tstx.tickFromPixel(chartPanel.right - halfCandle),\n\t\t\t\tstx.chart.dataSet.length - 1\n\t\t\t));\n\t\t\tvar pLeft = (self.pixelLeft =\n\t\t\t\tself.pixelFromTick(left) -\n\t\t\t\t(segmentImage[left] ? segmentImage[left].candleWidth / 2 : halfCandle));\n\t\t\tvar pRight = (self.pixelRight =\n\t\t\t\tself.pixelFromTick(right) +\n\t\t\t\t(segmentImage[right]\n\t\t\t\t\t? segmentImage[right].candleWidth / 2\n\t\t\t\t\t: halfCandle));\n\t\t\tvar leftBoundary = subholder.offsetLeft,\n\t\t\t\trightBoundary = leftBoundary + subholder.offsetWidth;\n\t\t\tctx.save();\n\t\t\tctx.beginPath();\n\t\t\tctx.fillStyle = style.backgroundColor;\n\t\t\tctx.fillRect(\n\t\t\t\tleftBoundary,\n\t\t\t\tsubholder.offsetTop,\n\t\t\t\tpLeft - leftBoundary,\n\t\t\t\tsubholder.offsetHeight\n\t\t\t);\n\t\t\tctx.fillRect(\n\t\t\t\trightBoundary,\n\t\t\t\tsubholder.offsetTop,\n\t\t\t\tpRight - rightBoundary,\n\t\t\t\tsubholder.offsetHeight\n\t\t\t);\n\t\t\tctx.strokeStyle = style.borderTopColor;\n\t\t\tctx.lineWidth = parseInt(style.borderWidth, 10);\n\t\t\tctx.moveTo(pLeft, subholder.offsetTop);\n\t\t\tctx.lineTo(pLeft, subholder.offsetTop + subholder.offsetHeight);\n\t\t\tctx.moveTo(pRight, subholder.offsetTop);\n\t\t\tctx.lineTo(pRight, subholder.offsetTop + subholder.offsetHeight);\n\t\t\tctx.stroke();\n\t\t\tctx.beginPath();\n\t\t\tctx.lineWidth = parseInt(style.width, 10);\n\t\t\tctx.lineCap = \"round\";\n\t\t\tctx.moveTo(pLeft, subholder.offsetTop + subholder.offsetHeight / 4);\n\t\t\tctx.lineTo(pLeft, subholder.offsetTop + (3 * subholder.offsetHeight) / 4);\n\t\t\tctx.moveTo(pRight, subholder.offsetTop + subholder.offsetHeight / 4);\n\t\t\tctx.lineTo(\n\t\t\t\tpRight,\n\t\t\t\tsubholder.offsetTop + (3 * subholder.offsetHeight) / 4\n\t\t\t);\n\t\t\tctx.stroke();\n\t\t\tctx.restore();\n\t\t};\n\t\tthis.requestDraw = function () {\n\t\t\tif (!this.drawRequested) {\n\t\t\t\tthis.drawRequested = setTimeout(() => {\n\t\t\t\t\tself.draw();\n\t\t\t\t\tthis.drawSlider();\n\t\t\t\t\tthis.drawRequested = clearTimeout(this.drawRequested);\n\t\t\t\t}, 100);\n\t\t\t}\n\t\t};\n\t\tstx.addEventListener(\"layout\", function (obj) {\n\t\t\tobj.stx.slider.acceptLayoutChange(obj.stx.layout);\n\t\t});\n\t\tstx.addEventListener(\"preferences\", function (obj) {\n\t\t\tconst { language } = obj.stx.preferences;\n\t\t\tif (CIQ.I18N && self.preferences.language != language) {\n\t\t\t\tCIQ.I18N.setLocale(self, language);\n\t\t\t}\n\t\t\tself.preferences.language = language;\n\t\t\tthis.slider.requestDraw();\n\t\t});\n\t\tstx.addEventListener(\"symbolChange\", function (obj) {\n\t\t\tif (obj.action == \"master\") obj.stx.slider.setSymbol(obj.symbol);\n\t\t});\n\t\tstx.addEventListener(\"symbolImport\", function (obj) {\n\t\t\tif (obj.action == \"master\") obj.stx.slider.setSymbol(obj.symbol);\n\t\t\tobj.stx.slider.acceptLayoutChange(obj.stx.layout);\n\t\t});\n\t\tstx.addEventListener(\"theme\", function (obj) {\n\t\t\tself.clearPixelCache();\n\t\t\tself.styles = {};\n\t\t\tself.container.style.backgroundColor = \"\";\n\t\t\tif (CIQ.ThemeHelper) {\n\t\t\t\tvar helper = new CIQ.ThemeHelper({ stx: obj.stx });\n\t\t\t\thelper.params.stx = self;\n\t\t\t\thelper.update();\n\t\t\t}\n\t\t});\n\t\tstx.append(\"createDataSet\", function (...args) {\n\t\t\tconst [, , { animationEntry } = {}] = args || [];\n\t\t\tif (animationEntry) return;\n\t\t\tthis.slider.adjustRange(this.chart);\n\t\t\tthis.slider.copyData(this.chart);\n\t\t});\n\t\tstx.append(\"draw\", function ({ animationEntry } = {}) {\n\t\t\tif (animationEntry || !CIQ.trulyVisible(ciqSlider)) return;\n\t\t\tif (!self.chart.dataSet) return;\n\t\t\tthis.slider.calculateYAxisPosition();\n\t\t\tthis.slider.adjustRange(this.chart);\n\t\t\tthis.slider.requestDraw();\n\t\t});\n\t\tstx.prepend(\"resizeChart\", function () {\n\t\t\tvar ciqChart = chartContainer.parentElement;\n\t\t\tif (!ciqChart || !ciqChart.isConnected) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t\tvar chartArea = ciqChart.parentElement;\n\t\t\tvar totalHeightOfContainers = CIQ.elementDimensions(chartArea).height;\n\t\t\tvar chartContainers = chartArea.querySelectorAll(\".chartContainer\");\n\t\t\tArray.from(chartContainers).forEach(function (container) {\n\t\t\t\tif (container !== chartContainer && CIQ.trulyVisible(container)) {\n\t\t\t\t\ttotalHeightOfContainers -= CIQ.elementDimensions(\n\t\t\t\t\t\tcontainer.parentElement,\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tborder: 1,\n\t\t\t\t\t\t\tpadding: 1,\n\t\t\t\t\t\t\tmargin: 1\n\t\t\t\t\t\t}\n\t\t\t\t\t).height;\n\t\t\t\t}\n\t\t\t});\n\t\t\tciqChart.style.height = totalHeightOfContainers + \"px\";\n\t\t\tif (this.layout.rangeSlider) {\n\t\t\t\tciqSlider.style.display = \"\";\n\t\t\t\tself.resizeChart();\n\t\t\t\tself.initializeChart();\n\t\t\t\tthis.slider.requestDraw();\n\t\t\t} else {\n\t\t\t\tciqSlider.style.display = \"none\";\n\t\t\t}\n\t\t});\n\t\t[\"mousedown\", \"touchstart\", \"pointerdown\"].forEach(function (ev) {\n\t\t\tsubholder.addEventListener(\n\t\t\t\tev,\n\t\t\t\tfunction (e) {\n\t\t\t\t\tvar start = self.backOutX(e.pageX);\n\t\t\t\t\tif (!start && start !== 0) return; // wrong event\n\t\t\t\t\tstart -= e.target.offsetLeft;\n\t\t\t\t\tself.startDrag = start;\n\t\t\t\t\tself.startPixelLeft = self.pixelLeft;\n\t\t\t\t\tself.startPixelRight = self.pixelRight;\n\t\t\t\t\tvar style = stx.slider.style;\n\t\t\t\t\tif (!style)\n\t\t\t\t\t\tstyle = stx.slider.style = stx.canvasStyle(\n\t\t\t\t\t\t\t\"stx_range_slider shading\"\n\t\t\t\t\t\t);\n\t\t\t\t\tvar bw = parseInt(style.borderLeftWidth, 10);\n\t\t\t\t\tstart += this.offsetLeft;\n\t\t\t\t\tif (start < self.pixelRight - bw) self.needsLeft = true;\n\t\t\t\t\tif (start > self.pixelLeft + bw) self.needsRight = true;\n\t\t\t\t\tif (CIQ.touchDevice) return;\n\t\t\t\t\tif (self.needsLeft && self.needsRight) {\n\t\t\t\t\t\t// change to grab only if drag started from viewport\n\t\t\t\t\t\te.target.classList.add(\"stx-drag-chart\");\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\t{ passive: false }\n\t\t\t);\n\t\t});\n\t\t[\"mouseup\", \"mouseover\", \"touchend\", \"pointerup\"].forEach(function (ev) {\n\t\t\tsubholder.addEventListener(ev, function (e) {\n\t\t\t\tconst { which, type } = e;\n\t\t\t\tif (which === 1 && type !== \"pointerup\" && type !== \"mouseup\") return;\n\t\t\t\te.target.classList.remove(\"stx-drag-chart\");\n\t\t\t\tself.chart.panel.subholder.style.cursor = \"ew-resize\";\n\t\t\t\tself.startDrag = null;\n\t\t\t\tself.needsLeft = false;\n\t\t\t\tself.needsRight = false;\n\t\t\t});\n\t\t});\n\t\t[\"mousemove\", \"touchmove\", \"pointermove\"].forEach(function (ev) {\n\t\t\tsubholder.addEventListener(\n\t\t\t\tev,\n\t\t\t\tfunction (e) {\n\t\t\t\t\tif (!self.timeout) {\n\t\t\t\t\t\t// consolidate calls and execute on next tick\n\t\t\t\t\t\t// this prevents unnecessary calls that could otherwise build up based on mousemove\n\t\t\t\t\t\tself.timeout = setTimeout(() => {\n\t\t\t\t\t\t\tconst done = () => (self.timeout = clearTimeout(self.timeout));\n\n\t\t\t\t\t\t\tconst {\n\t\t\t\t\t\t\t\tstartDrag,\n\t\t\t\t\t\t\t\tstartPixelLeft,\n\t\t\t\t\t\t\t\tstartPixelRight,\n\t\t\t\t\t\t\t\tneedsLeft,\n\t\t\t\t\t\t\t\tneedsRight\n\t\t\t\t\t\t\t} = self;\n\t\t\t\t\t\t\tlet { tickLeft, tickRight } = self;\n\n\t\t\t\t\t\t\tif (!startDrag && startDrag !== 0) return done();\n\t\t\t\t\t\t\tconst { touches } = e;\n\t\t\t\t\t\t\tlet movement =\n\t\t\t\t\t\t\t\t(touches && touches.length\n\t\t\t\t\t\t\t\t\t? self.backOutX(touches[0].pageX)\n\t\t\t\t\t\t\t\t\t: self.backOutX(e.pageX)) - e.target.offsetLeft;\n\t\t\t\t\t\t\tif (!movement && movement !== 0) return done(); // wrong event\n\t\t\t\t\t\t\tmovement -= startDrag;\n\n\t\t\t\t\t\t\tif (needsLeft) {\n\t\t\t\t\t\t\t\tif (startPixelLeft + movement < self.chart.left)\n\t\t\t\t\t\t\t\t\tmovement = self.chart.left - startPixelLeft;\n\t\t\t\t\t\t\t\tif (\n\t\t\t\t\t\t\t\t\tneedsRight &&\n\t\t\t\t\t\t\t\t\tstartPixelRight + movement >= self.chart.right\n\t\t\t\t\t\t\t\t) {\n\t\t\t\t\t\t\t\t\tmovement = self.chart.right - startPixelRight;\n\t\t\t\t\t\t\t\t\tif (!self.isHome()) movement += self.layout.candleWidth / 2; // force a right scroll\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\ttickLeft = self.tickFromPixel(startPixelLeft + movement);\n\t\t\t\t\t\t\t\tif (needsRight)\n\t\t\t\t\t\t\t\t\ttickRight = tickLeft + self.tickRight - self.tickLeft;\n\t\t\t\t\t\t\t} else if (needsRight) {\n\t\t\t\t\t\t\t\ttickRight = Math.min(\n\t\t\t\t\t\t\t\t\tself.tickFromPixel(startPixelRight + movement),\n\t\t\t\t\t\t\t\t\tstx.chart.dataSet.length - 1\n\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t} else return done();\n\n\t\t\t\t\t\t\tlet newCandleWidth = stx.chart.width / (tickRight - tickLeft + 1);\n\t\t\t\t\t\t\tif (\n\t\t\t\t\t\t\t\ttickRight >= tickLeft &&\n\t\t\t\t\t\t\t\t((needsLeft && needsRight) ||\n\t\t\t\t\t\t\t\t\tnewCandleWidth >= stx.minimumCandleWidth)\n\t\t\t\t\t\t\t) {\n\t\t\t\t\t\t\t\tself.tickLeft = tickLeft;\n\t\t\t\t\t\t\t\tself.tickRight = tickRight;\n\t\t\t\t\t\t\t\tstx.chart.scroll = stx.chart.dataSet.length - tickLeft;\n\t\t\t\t\t\t\t\tif (!needsLeft || !needsRight) {\n\t\t\t\t\t\t\t\t\tstx.setCandleWidth(newCandleWidth);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tstx.micropixels = 0;\n\t\t\t\t\t\t\t\tstx.draw();\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tdone();\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\t{ passive: false }\n\t\t\t);\n\t\t});\n\t\tthis.adjustRange(stx.chart);\n\t\tthis.copyData(stx.chart);\n\t\tstx.draw();\n\t};\n\n};\n\n\nlet __js_addons_standard_shortcuts_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Displays a legend of keyboard shortcuts and the actions the shortcuts perform.\n *\n * Delegates display of the legend to the\n * [cq-floating-window]{@link WebComponents.cq-floating-window} web component by dispatching a\n * \"floatingWindow\" event (see\n * [floatingWindowEventListener]{@link CIQ.ChartEngine~floatingWindowEventListener}).\n *\n * Creates the legend from keyboard shortcut specifications contained in a configuration object;\n * for example, the default chart configuration object (see the {@tutorial Chart Configuration}\n * tutorial).\n *\n * The keyboard shortcuts legend can be toggled using the Ctrl+Alt+K keystroke combination (see the\n * `shortcuts` action in `hotkeyConfig.hotkeys` in *js/defaultConfiguration.js*).\n *\n * Requires *addOns.js*.\n *\n * @param {object} params The constructor parameters.\n * @param {CIQ.ChartEngine} params.stx The chart engine instance for which the keyboard shortcuts\n * \t\tlegend is created.\n * @param {object} params.config A configuration object that includes specifications for hot keys\n * \t\tand drawing tool keyboard shortcuts. Typically, this object is the chart configuration\n * \t\tobject. See the {@tutorial Chart Configuration} tutorial for the data format for keyboard\n * \t\tshortcuts.\n * @param {number} [params.width=\"580\"] The width of the floating window that contains the\n * \t\tkeyboard shortcuts legend.\n * @param {boolean} [params.windowForEachChart=true] A flag that indicates whether each chart\n * \t\tinstance in a multi-chart document has its own keyboard shortcuts legend. If false, all\n * \t\tcharts share the same legend.\n *\n * @constructor\n * @name CIQ.Shortcuts\n * @since 8.2.0\n *\n * @example\n * new CIQ.Shortcuts(\n * stx: stxx,\n * config: {\n * drawingTools: [{ label: \"line\", shortcut: \"l\" }],\n * hotkeyConfig: {\n * hotkeys: [{ label: \"Pan chart up\", action: \"up\", commands: [\"ArrowUp\", \"Up\"] }]\n * }\n * }\n * );\n */\nCIQ.Shortcuts =\n\tCIQ.Shortcuts ||\n\tfunction ({ stx, width = 580, windowForEachChart = true, config } = {}) {\n\t\tif (!stx) {\n\t\t\tconsole.warn(\"The Shortcuts addon requires an stx parameter\");\n\t\t\treturn;\n\t\t}\n\t\t/**\n\t\t * The chart engine instance for which the keyboard shortcuts legend is created.\n\t\t *\n\t\t * @type {CIQ.ChartEngine}\n\t\t * @memberof CIQ.Shortcuts#\n\t\t * @alias stx\n\t\t * @since 8.2.0\n\t\t */\n\t\tthis.stx = stx;\n\t\t/**\n\t\t * Width of the floating window that contains the keyboard shortcuts legend.\n\t\t *\n\t\t * @type {number}\n\t\t * @memberof CIQ.Shortcuts#\n\t\t * @alias width\n\t\t * @since 8.2.0\n\t\t */\n\t\tthis.width = width;\n\t\t/**\n\t\t * In a multi-chart document, indicates whether each chart has its own keyboard shortcuts\n\t\t * legend. If false, all charts share the same legend.\n\t\t *\n\t\t * @type {boolean}\n\t\t * @memberof CIQ.Shortcuts#\n\t\t * @alias windowForEachChart\n\t\t * @since 8.2.0\n\t\t */\n\t\tthis.windowForEachChart = windowForEachChart;\n\t\tthis.content = this.getShortcutContent(config);\n\n\t\tthis.ensureMessagingAvailable(stx);\n\t\tthis.enableUI(stx);\n\t\tthis.cssRequired = true;\n\n\t\tstx.shortcuts = this;\n\n\t\tif (CIQ.UI) {\n\t\t\tCIQ.UI.KeystrokeHub.addHotKeyHandler(\n\t\t\t\t\"shortcuts\",\n\t\t\t\t({ stx, options }) => {\n\t\t\t\t\tstx.container.ownerDocument.body.keystrokeHub.context.advertised.Layout.showShortcuts();\n\t\t\t\t},\n\t\t\t\tstx\n\t\t\t);\n\t\t}\n\t\tconst container = this.stx.container.closest(\"cq-context\");\n\t\tconst mo = new MutationObserver(\n\t\t\t() => (this.content = this.getShortcutContent(config))\n\t\t);\n\t\tmo.observe(container, { attributes: true });\n\t\tthis.mo = mo;\n\t};\n\n/**\n * Enables the keyboard shortcuts legend user interface.\n *\n * Adds a `showShortCuts` function to the {@link CIQ.UI.Layout} helper. The `showShortCuts`\n * function calls this class's [toggle]{@link CIQ.Shortcuts#toggle} function to show and hide the\n * keyboard shortcuts legend. Call `showShortCuts` in your application's user interface (see\n * example).\n *\n * This function is called when the add-on is instantiated.\n *\n * @param {CIQ.ChartEngine} stx The chart engine that provides the UI context for the keyboard\n * \t\tshortcuts legend.\n *\n * @memberof CIQ.Shortcuts#\n * @alias enableUI\n * @since 8.2.0\n *\n * @example Create a button that shows and hides the keyboard shortcuts legend.\n * \n */\nCIQ.Shortcuts.prototype.enableUI = function (stx) {\n\tif (!(stx && CIQ.UI)) return;\n\tsetTimeout(() => {\n\t\tconst layout = stx.uiContext.getAdvertised(\"Layout\");\n\t\tlayout.showShortcuts = (node, value) => this.toggle(value);\n\t});\n};\n\n/**\n * Ensures that an instance of the [cq-floating-window]{@link WebComponents.cq-floating-window}\n * web component is available to handle event messaging and create the shortcuts legend floating\n * window.\n *\n * This function is called when the add-on is instantiated.\n *\n * @param {CIQ.ChartEngine} stx The chart engine that provides the UI context, which contains the\n * [cq-floating-window]{@link WebComponents.cq-floating-window} web component.\n *\n * @memberof CIQ.Shortcuts#\n * @alias ensureMessagingAvailable\n * @since 8.2.0\n */\nCIQ.Shortcuts.prototype.ensureMessagingAvailable = function (stx) {\n\tsetTimeout(() => {\n\t\tconst contextContainer = stx.uiContext.topNode;\n\t\tconst floatingWindow = Array.from(\n\t\t\tcontextContainer.querySelectorAll(\"cq-floating-window\")\n\t\t).find((el) => el.closest(\"cq-context\") === contextContainer);\n\n\t\tif (!floatingWindow) {\n\t\t\tcontextContainer.append(document.createElement(\"cq-floating-window\"));\n\t\t}\n\t});\n};\n\n/**\n * Creates the contents of the keyboard shortcuts legend based on specifications contained in a\n * configuration object. The contents are displayed in a\n * [cq-floating-window]{@link WebComponents.cq-floating-window} web component.\n *\n * This function is called when the add-on is instantiated.\n *\n * @param {object} config A configuration object that includes specifications for drawing tool\n * \t\tkeyboard shortcuts and hot keys. Typically, this object is the chart configuration object\n * \t\t(see the {@tutorial Chart Configuration} tutorial).\n * @return {string} The keyboard shortcuts legend as HTML.\n *\n * @memberof CIQ.Shortcuts#\n * @alias getShortcutContent\n * @since 8.2.0\n */\nCIQ.Shortcuts.prototype.getShortcutContent = function (config) {\n\tconst drawingToolShortcuts = (config.drawingTools || [])\n\t\t.filter((tool) => tool.shortcut)\n\t\t.map(\n\t\t\t({ label, shortcut }) =>\n\t\t\t\t`
\n\t\t\t\t\t
${label}
\n\t\t\t\t\t
Alt + ${shortcut.toUpperCase()}
\n\t\t\t\t
`\n\t\t)\n\t\t.join(\"\");\n\n\t// Alt + key combination produces unpredictable accent characters depending on keyboard mapping\n\t// default hotkeys include them for better coverage, avoid displaying them in legend\n\tconst isAscii = (str) => str.charCodeAt(str.length - 1) < 127;\n\tconst wrapKeys = (str) =>\n\t\tstr === \" + \"\n\t\t\t? \"+\"\n\t\t\t: str\n\t\t\t\t\t.split(\"+\")\n\t\t\t\t\t.map((el) => (el && el !== \" \" ? \"\" + el + \"\" : \"\"))\n\t\t\t\t\t.join(\" + \");\n\n\tconst commandsToString = (commands) => {\n\t\treturn commands\n\t\t\t.map((command) => command.replace(/Arrow|Key|Digit|^ | $/g, \"\"))\n\t\t\t.map((command) => command.replace(/\\+/, \" + \"))\n\t\t\t.reduce(\n\t\t\t\t(acc, command) =>\n\t\t\t\t\t!acc.includes(command) && isAscii(command)\n\t\t\t\t\t\t? acc.concat(command)\n\t\t\t\t\t\t: acc,\n\t\t\t\t[]\n\t\t\t)\n\t\t\t.map(wrapKeys)\n\t\t\t.join(\"
\");\n\t};\n\n\tconst container = this.stx.container.closest(\"cq-context\");\n\tif (!container) {\n\t\tthis.mo.disconnect();\n\t\treturn;\n\t}\n\tconst extensionAvailable = (name) =>\n\t\tcontainer.hasAttribute(name.toLowerCase() + \"-active\");\n\tconst hotkeys = ((config.hotkeyConfig && config.hotkeyConfig.hotkeys) || [])\n\t\t.map(({ label, action, commands, extension }) => {\n\t\t\tif (extension && !extensionAvailable(extension)) {\n\t\t\t\treturn \"\";\n\t\t\t}\n\t\t\treturn `
${\n\t\t\t\tlabel || action\n\t\t\t}
${commandsToString(commands)}
`;\n\t\t})\n\t\t.join(\"\");\n\n\treturn `\n\t\t
\n\t\t\t
\n\t\t\t\t
Drawing tools shortcuts
\n\t\t\t\t
${drawingToolShortcuts}
\n\t\t\t
\n\t\t\t
\n\t\t\t
\n\t\t\t\t
Hotkeys
\n\t\t\t\t
${hotkeys}
\n\t\t\t
\n\t\t
\n\t`;\n};\n\n/**\n * Opens and closes the floating window that contains the keyboard shortcuts legend.\n *\n * @param {boolean} [value] If true, the window is opened. If false, the window is closed.\n * \t\tIf not provided, the window state is toggled. That is, the window is opened if it is\n * \t\tcurrently closed; closed, if it is currently open.\n *\n * @memberof CIQ.Shortcuts#\n * @alias toggle\n * @since 8.2.0\n */\nCIQ.Shortcuts.prototype.toggle = function (value) {\n\tthis.stx.dispatch(\"floatingWindow\", {\n\t\ttype: \"shortcut\",\n\t\ttitle: \"Shortcuts\",\n\t\tcontent: this.content,\n\t\tcontainer: this.stx.uiContext.topNode,\n\t\tonClose: () => (this.closed = true),\n\t\twidth: this.width,\n\t\tstatus: value,\n\t\ttag: this.windowForEachChart ? undefined : \"shortcut\"\n\t});\n};\n\n};\n\n\nlet __js_addons_standard_tableView_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Creates an overlay that displays the visible chart data segment as a table.\n *\n * The overlay includes controls that enable users to copy the table data to the clipboard or\n * download the data as a character-separated values (CSV) file. See\n * {@link TableViewBuilder.dataToCsv} for the default separator character.\n *\n * The table view can be opened using the Alt+K keystroke combination and closed using the Escape\n * key (see the `tableView` action in `hotkeyConfig.hotkeys` in *js/defaultConfiguration.js*).\n *\n * Requires *addOns.js*.\n *\n * @param {object} params Configuration parameters.\n * @param {CIQ.ChartEngine} params.stx A reference to the chart engine that contains the chart for\n * \t\twhich the table view is created.\n * @param {string} [params.minColumnWidth=\"84px\"] The minimum width (including units) of the\n * \t\ttable columns. **Note:** The units can be any CSS unit acceptable by the CSS `calc`\n * \t\tfunction.\n * @param {number} [params.coverUIMaxWidth=400] The chart width (in pixels) below which the table\n * \t\tview covers the entire chart, including user interface elements (symbol input field,\n * \t\tmenus, etc.). For example, if the value of this parameter is 1000, the table view covers\n * \t\tthe entire chart area if the chart width is <= 999 pixels.\n * @param {string} [params.coverContainer] A CSS selector used to obtain the DOM element that\n * \t\tultimately contains the table view; for example, \".chartContainer\".\n * @param {boolean} [params.usePreviousCloseForChange=true] Indicates whether the closing price of\n * \t\tthe previous data point should be used instead of the opening price of the current data\n * \t\tpoint to determine the amount of change for the current data point; that is,\n * \t\t(current close - previous close) or (current close - current open).\n *\n * @constructor\n * @name CIQ.TableView\n * @since 8.1.0\n *\n * @example\n * new CIQ.TableView({ stx: stxx });\n */\nCIQ.TableView =\n\tCIQ.TableView ||\n\tfunction ({\n\t\tstx,\n\t\tminColumnWidth = \"84px\",\n\t\tcoverUIMaxWidth = 400,\n\t\tcoverContainer,\n\t\tusePreviousCloseForChange = true\n\t} = {}) {\n\t\tif (!stx) {\n\t\t\tconsole.warn(\"The TableView addon requires an stx parameter\");\n\t\t\treturn;\n\t\t}\n\n\t\t/**\n\t\t * The chart engine instance that contains the chart for which the table view is created.\n\t\t *\n\t\t * @type CIQ.ChartEngine\n\t\t * @memberof CIQ.TableView#\n\t\t * @alias stx\n\t\t * @since 8.1.0\n\t\t */\n\t\tthis.stx = stx;\n\t\t/**\n\t\t * Toggle to display and hide additional table view columns, such as % Change and Volume.\n\t\t *\n\t\t * **Note:** Data in the additional columns might not be present in the chart view because\n\t\t * the data is calculated (for example, % Change) or is not part of the standard chart\n\t\t * display (for example, Volume — which can be displayed with the\n\t\t * [Volume Chart]{@link CIQ.Studies.createVolumeChart} study).\n\t\t *\n\t\t * @type boolean\n\t\t * @memberof CIQ.TableView#\n\t\t * @alias viewAdditionalColumns\n\t\t * @since 8.1.0\n\t\t */\n\t\tthis.viewAdditionalColumns = false;\n\t\t/**\n\t\t * Minimum width of the table view columns, including units. The units can be any CSS\n\t\t * unit acceptable by the CSS `calc` function.\n\t\t *\n\t\t * @type string\n\t\t * @memberof CIQ.TableView#\n\t\t * @alias minColumnWidth\n\t\t * @since 8.1.0\n\t\t */\n\t\tthis.minColumnWidth = minColumnWidth;\n\t\t/**\n\t\t * The chart width in pixels below which the table view covers the entire chart, including\n\t\t * user interface elements, such as the menus and footer.\n\t\t *\n\t\t * @type number\n\t\t * @memberof CIQ.TableView#\n\t\t * @alias coverUIMaxWidth\n\t\t * @since 8.1.0\n\t\t */\n\t\tthis.coverUIMaxWidth = coverUIMaxWidth;\n\t\t/**\n\t\t * A CSS selector used to obtain the DOM element that hosts the table view.\n\t\t *\n\t\t * @type string\n\t\t * @memberof CIQ.TableView#\n\t\t * @alias coverContainer\n\t\t * @since 8.1.0\n\t\t */\n\t\tthis.coverContainer = coverContainer;\n\t\t/**\n\t\t * If true, the closing price of the previous data point is used instead of the opening\n\t\t * price of the current data point to determine the amount of change for the current data\n\t\t * point.\n\t\t *\n\t\t * @type boolean\n\t\t * @memberof CIQ.TableView#\n\t\t * @alias usePreviousCloseForChange\n\t\t * @since 8.1.0\n\t\t */\n\t\tthis.usePreviousCloseForChange = usePreviousCloseForChange;\n\t\t/**\n\t\t * A reference to the {@link TableViewBuilder} namespace for access to the namespace\n\t\t * static methods.\n\t\t *\n\t\t * @type TableViewBuilder\n\t\t * @memberof CIQ.TableView#\n\t\t * @alias builder\n\t\t * @since 8.1.0\n\t\t */\n\t\tthis.builder = TableViewBuilder;\n\n\t\tthis.listeners = [];\n\n\t\tstx.tableView = this;\n\t\tthis.cssRequired = true;\n\n\t\tif (CIQ.UI) {\n\t\t\tCIQ.UI.observeProperty(\"uiContext\", stx, ({ value: uiContext }) => {\n\t\t\t\tif (!uiContext) return;\n\n\t\t\t\tsetTimeout(() => {\n\t\t\t\t\tthis.subscribeToChanges(uiContext);\n\n\t\t\t\t\t// Updated hotkey alias if available to action\n\t\t\t\t\tconst tableViewKeyEntry = CIQ.getFromNS(\n\t\t\t\t\t\tuiContext.config,\n\t\t\t\t\t\t\"hotkeyConfig.hotkeys\",\n\t\t\t\t\t\t[]\n\t\t\t\t\t).find(({ action }) => action === \"tableView\");\n\t\t\t\t\tif (tableViewKeyEntry) {\n\t\t\t\t\t\ttableViewKeyEntry.action = () => {\n\t\t\t\t\t\t\tconst { tableView } =\n\t\t\t\t\t\t\t\tuiContext.topNode.ownerDocument.body.keystrokeHub.context.stx;\n\t\t\t\t\t\t\tif (tableView) {\n\t\t\t\t\t\t\t\ttableView.toggle();\n\t\t\t\t\t\t\t\treturn true;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t};\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t});\n\t\t}\n\t\tsetTimeout(() => {\n\t\t\t// allow uiContext creation first\n\t\t\tthis.setup({ minColumnWidth, coverUIMaxWidth, coverContainer });\n\t\t});\n\t};\n\n/**\n * Sets up the dialog and toolbar for the table view.\n * @param {object} config Setup configuration\n * @memberof CIQ.TableView\n * @since 8.7.0\n */\nCIQ.TableView.prototype.setup = function (config) {\n\tconst { stx } = this;\n\tconst cover = this.builder.getChartCover(stx, config);\n\tconst toolbar = this.builder.createToolbar(stx, config);\n\tcover.append(toolbar);\n\tcover.style.display = \"none\";\n\n\tstx.addEventListener(\"symbolChange\", () => {\n\t\tif (this.view) {\n\t\t\tthis.close();\n\t\t\tthis.builder.createTable(stx, config);\n\t\t\tthis.dialog.focus();\n\t\t}\n\t});\n\n\tthis.dialog = cover;\n\tthis.toolbar = {\n\t\tsymbol: toolbar.querySelector(\".ciq-data-table-title\"),\n\t\tcopyBtn: toolbar.querySelector(\".ciq-data-table-copy\"),\n\t\tdownloadBtn: toolbar.querySelector(\".ciq-data-table-download\"),\n\t\tadditional: toolbar.querySelector(\".ciq-data-table-additionalColumns\")\n\t};\n};\n\n/**\n * Displays the table view.\n *\n * @param {object} [params] Configuration parameters.\n * @param {object} [params.config] Table column information.\n * @param {function} [params.onClose] Callback function to execute on closing the table view. The\n * \t\tcallback enables synchronization of state in the application when the table view is\n * \t\tclosed.\n *\n * @memberof CIQ.TableView#\n * @alias open\n * @since 8.1.0\n */\nCIQ.TableView.prototype.open = function (params) {\n\tif (params) {\n\t\tthis.params = params;\n\t}\n\tconst { config = {}, onClose } = this.params || {};\n\tif (this.view) {\n\t\tthis.close(false);\n\t}\n\tthis.onClose = onClose;\n\tthis.builder.createTable(this.stx, config);\n\tif (!this.dialog) return;\n\tconst { stx } = this;\n\tconst close = this.close.bind(this);\n\n\t// Set the dialog as an active modal, this will disable the main tab key handler\n\t// and tie us into the main escape key handler.\n\tconst keystrokeHub = this.dialog.ownerDocument.body.keystrokeHub;\n\tif (keystrokeHub) keystrokeHub.addActiveModal(this);\n\n\tsetTimeout(() => (this.removeCloseListener = getCloseListener(this)));\n\n\tfunction getCloseListener(self) {\n\t\tconst contextNode = stx.uiContext.topNode;\n\t\tconst body = contextNode.ownerDocument.body;\n\t\tconst withinTable = (el) => el.closest(\".ciq-data-table-container\");\n\n\t\tconst closeHandler = ({ target }) => !withinTable(target) && close();\n\t\tcontextNode.addEventListener(\"click\", closeHandler);\n\t\tconst handleKeydown = (e) => {\n\t\t\tconst { tableView } = body.keystrokeHub.context.stx;\n\t\t\tif (!tableView) return;\n\t\t\tif (e.code === \"Escape\") {\n\t\t\t\ttableView.close();\n\t\t\t\te.preventDefault();\n\t\t\t} else {\n\t\t\t\t// Handle all other keys using keyboard navigation functions in BaseComponent\n\t\t\t\tif (!CIQ.UI || !CIQ.UI.BaseComponent) return;\n\t\t\t\tconst componentProxy = CIQ.UI.BaseComponent.prototype;\n\t\t\t\tconst items = tableView.view.querySelectorAll(\"button\");\n\n\t\t\t\tif (e.code === \"Tab\") {\n\t\t\t\t\tlet { shiftKey } = e || {};\n\t\t\t\t\tcomponentProxy.focusNextItem(items, shiftKey, true);\n\t\t\t\t\tconst focused = componentProxy.findFocused(items);\n\t\t\t\t\t// The highlightItem context must have a keyboardNavigation property\n\t\t\t\t\tif (focused[0])\n\t\t\t\t\t\tcomponentProxy.highlightItem.call(\n\t\t\t\t\t\t\t{ keyboardNavigation: body.keystrokeHub },\n\t\t\t\t\t\t\tfocused[0]\n\t\t\t\t\t\t);\n\t\t\t\t} else if (e.code === \"Enter\") {\n\t\t\t\t\tconst focused = componentProxy.findFocused(items);\n\t\t\t\t\tif (focused[0]) componentProxy.clickItem(focused[0], e);\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t\tbody.addEventListener(\"keydown\", handleKeydown);\n\n\t\t// Use modal functionality available in menu\n\t\tconst uiManager = CIQ.getFn(\"UI.getUIManager\")(contextNode);\n\t\tif (uiManager) {\n\t\t\t// Menu item requires show and hide providing no-op functions\n\t\t\tself.view.show = self.view.hide = function () {};\n\t\t\tuiManager.openMenu(self.view, {});\n\t\t}\n\t\treturn () => {\n\t\t\tcontextNode.removeEventListener(\"click\", closeHandler);\n\t\t\tbody.removeEventListener(\"keydown\", handleKeydown);\n\t\t\tif (uiManager) uiManager.closeMenu(self.view);\n\t\t};\n\t}\n};\n\n/**\n * Closes the table view.\n *\n * @param {boolean} [notify=true] Indicates whether the `onClose` callback function is set (see\n * \t\t[open]{@link CIQ.TableView#open}).\n *\n * @memberof CIQ.TableView#\n * @alias close\n * @since 8.1.0\n */\nCIQ.TableView.prototype.close = function (notify = true) {\n\tlet body;\n\tthis.dialog.style.display = \"none\";\n\tif (this.view) {\n\t\tbody = this.view.ownerDocument.body;\n\t\tthis.view.remove();\n\t\tthis.view = null;\n\t}\n\tif (notify && this.onClose) {\n\t\tthis.onClose();\n\t}\n\n\tif (this.removeCloseListener) {\n\t\tthis.removeCloseListener();\n\t\tthis.removeCloseListener = null;\n\t}\n\n\t// Remove the table view as an active modal in keyboard navigation\n\tif (body && body.keystrokeHub) {\n\t\tlet { tabActiveModals } = body.keystrokeHub;\n\t\tlet modalIdx = tabActiveModals.indexOf(this);\n\t\tif (modalIdx > -1) {\n\t\t\ttabActiveModals.splice(modalIdx, 1);\n\t\t}\n\t\tbody.keystrokeHub.highlightAlign();\n\t}\n};\n\n/**\n * Opens the table view if it is closed. Closes the table view if it is open.\n *\n * @memberof CIQ.TableView#\n * @alias toggle\n * @since 8.1.0\n */\nCIQ.TableView.prototype.toggle = function () {\n\tthis[this.view ? \"close\" : \"open\"]();\n\t// DO NOT move this into open method!\n\t// You don't want to change focus when toggling additional columns\n\tif (!this.view) this.dialog.focus();\n};\n\n/**\n * Subscribes to changes in the table view component communication channel, which enables other\n * components to open and close the table view.\n *\n * @param {CIQ.UI.Context} uiContext The user interface context of the table view. Provides the\n * \t\tcommunication channel path that identifies the table view channel.\n * @param {string} [channelPath] Specifies the channel path if the path is not available in the\n * \t\tcontext configuration provided by `uiContext`.\n *\n * @memberof CIQ.TableView#\n * @alias subscribeToChanges\n * @since 8.1.0\n */\nCIQ.TableView.prototype.subscribeToChanges = function (\n\tuiContext,\n\tchannelPath = \"channels.tableView\"\n) {\n\tconst { channelSubscribe, channelWrite } = CIQ.UI.BaseComponent.prototype;\n\tconst { channels: { tableView = channelPath } = {} } = uiContext.config || {};\n\tconst { stx } = this;\n\n\tchannelSubscribe(\n\t\ttableView,\n\t\t(value) => {\n\t\t\tif (value) {\n\t\t\t\tstx.tableView.open({\n\t\t\t\t\tonClose: () => {\n\t\t\t\t\t\tchannelWrite(tableView, false, stx);\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t\t// DO NOT move this into open method!\n\t\t\t\t// You don't want to change focus when toggling additional columns\n\t\t\t\tstx.tableView.dialog.focus();\n\t\t\t} else {\n\t\t\t\tstx.tableView.close();\n\t\t\t}\n\t\t},\n\t\tstx\n\t);\n};\n\n/**\n * Namespace for {@link CIQ.TableView} creation–related properties and functions.\n *\n * @namespace\n * @name TableViewBuilder\n * @since 8.1.0\n */\nfunction TableViewBuilder() {}\n\n/**\n * The column header configuration for the table view.\n *\n * Can be used for rearranging the column order, removing columns, and updating labels.\n *\n * **Note:** Adding new columns has no effect.\n *\n * @type Object.\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.colHeaders = {\n\tdate: { label: \"Date\", alias: \"DT\" },\n\topen: { label: \"Open\" },\n\thigh: { label: \"High\" },\n\tlow: { label: \"Low\" },\n\tclose: { label: \"Close\" },\n\tpctChange: { label: \"% Change\", cls: \"ciq-extra\" },\n\tpctChangeVsAvg: { label: \"% Change vs Average\", cls: \"ciq-extra\" },\n\tvolume: { label: \"Volume\", cls: \"ciq-extra\" }\n};\n\n/**\n * Number of decimal places to display for percent formatted columns\n *\n * @type number\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.percentDecimalPlaces = 2;\n\n/**\n * Creates the toolbar cover elements of the table view.\n *\n * The toolbar contains buttons for copying and saving the table data and for displaying\n * additional table columns.\n * @param {CIQ.ChartEngine} stx A reference to the chart engine that contains the chart for which\n * \t\tthe table view is created.\n * @param {object} [config] Configuration parameters.\n * @param {function} [config.fileNameFormatter] Formats the name of the file that contains the\n * \t\tdownloaded table data.\n * @returns {HTMLElement} toolbar Constructed toolbar container element.\n * @memberof TableViewBuilder\n * @since 8.7.0\n */\nTableViewBuilder.createToolbar = function (stx, config = {}) {\n\tconst self = this;\n\tconst { symbolDisplay, symbol } = stx.chart;\n\tconst { builder } = stx.tableView;\n\tconst { dataToCsv, downloadCsv, getFilenameFormatter } = builder;\n\tconst { fileNameFormatter = getFilenameFormatter(stx) } = config;\n\n\tconst colHeaders = Object.assign({}, this.colHeaders);\n\n\tconst toolbar = builder.getCoverToolbar({\n\t\tsymbol: symbolDisplay || symbol,\n\t\tviewAdditionalColumns: stx.tableView.viewAdditionalColumns,\n\t\tcopyFn,\n\t\tdownloadFn,\n\t\ttoggleAdditionalColumnsFn: (e) => {\n\t\t\tconst { tableView } = stx;\n\t\t\ttableView.viewAdditionalColumns = !tableView.viewAdditionalColumns;\n\t\t\ttableView.open();\n\t\t},\n\t\tcloseFn: () => stx.tableView.close()\n\t});\n\treturn toolbar;\n\n\tfunction copyFn() {\n\t\tconst contentEl = document.createElement(\"textArea\");\n\t\tstx.container.ownerDocument.body.appendChild(contentEl);\n\t\tcontentEl.textContent = dataToCsv(self.currentTable, {\n\t\t\tcolHeaders,\n\t\t\tcolSeparator: \",\"\n\t\t});\n\t\tcontentEl.select();\n\t\tstx.container.ownerDocument.execCommand(\"copy\");\n\t\tcontentEl.remove();\n\t\tstx.dispatch(\"notification\", \"copytoclipboard\");\n\t}\n\n\tfunction downloadFn() {\n\t\tconst csvData = dataToCsv(self.currentTable, {\n\t\t\tcolHeaders,\n\t\t\tcolSeparator: \",\"\n\t\t});\n\t\tconst fileName = fileNameFormatter(csvData);\n\t\tdownloadCsv(csvData, fileName, stx);\n\t}\n};\n\n/**\n * Creates a table view as an HTMLElement overlay over a chart container. The table view displays\n * a snapshot of the visible chart data segment.\n *\n * The overlay contains buttons for copying and saving the table data and for displaying\n * additional table columns.\n *\n * @param {CIQ.ChartEngine} stx A reference to the chart engine that contains the chart for which\n * \t\tthe table view is created.\n * @param {object} [config] Configuration parameters.\n * @param {function} [config.dateFormatter] Formats table date fields.\n * @param {function} [config.valueFormatter] Formats table values.\n * @param {function} [config.volumeFormatter] Formats the table volume field.\n * @param {function} [config.fileNameFormatter] Formats the name of the file that contains the\n * \t\tdownloaded table data.\n * @param {string} [config.minColumnWidth=\"84px\"] The minimum width (including units) of the\n * \t\ttable columns. **Note:** The units can be any CSS unit acceptable by the CSS `calc`\n * \t\tfunction.\n * @return {HTMLElement}\n *\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.createTable = function (stx, config = {}) {\n\tif (!stx.chart || !stx.chart.dataSegment) return;\n\n\tconst { tableView } = stx;\n\tconst { builder } = tableView;\n\tconst {\n\t\tgetChartData,\n\t\tdataToHtml,\n\t\tgetDateFormatter,\n\t\tgetValueFormatter,\n\t\tgetVolumeFormatter,\n\t\tgetSeriesDataNames,\n\t\tgetStudyDataNames\n\t} = builder;\n\n\tconst colHeaders = Object.assign({}, this.colHeaders);\n\n\tif (!stx.chart.highLowBars) {\n\t\tdelete colHeaders.open;\n\t\tdelete colHeaders.high;\n\t\tdelete colHeaders.low;\n\t}\n\n\tif (!tableView.viewAdditionalColumns) {\n\t\tfor (let key in colHeaders) {\n\t\t\tif (colHeaders[key].cls) {\n\t\t\t\tdelete colHeaders[key];\n\t\t\t}\n\t\t}\n\t}\n\n\tconst labels = Object.values(colHeaders).map((item) => item.label);\n\n\tconst seriesNames = getSeriesDataNames(stx);\n\tseriesNames.forEach((item) => (colHeaders[item] = { label: item }));\n\n\tconst studyNames = getStudyDataNames(stx);\n\tstudyNames.forEach((item) => {\n\t\tif (!labels.includes(item)) colHeaders[item] = { label: item };\n\t});\n\n\tconst additionalDataFields = seriesNames.concat(studyNames);\n\n\tconst {\n\t\tdateFormatter = getDateFormatter(stx),\n\t\tvalueFormatter = getValueFormatter(stx),\n\t\tpercentFormatter = getValueFormatter(stx, this.percentDecimalPlaces),\n\t\tvolumeFormatter = getVolumeFormatter(stx),\n\t\tminColumnWidth = \"84px\"\n\t} = config;\n\n\tconst arr = getChartData(stx, {\n\t\tdateFormatter,\n\t\tvalueFormatter,\n\t\tpercentFormatter,\n\t\tvolumeFormatter,\n\t\tadditionalDataFields\n\t});\n\n\t// Save reference to the tableData for devs to inspect/use just in case\n\tthis.currentTable = arr;\n\n\tconst cover = tableView.dialog;\n\tcover.style.display = \"\";\n\tconst { symbolDisplay, symbol } = stx.chart;\n\tconst displayedSymbol = `Symbol: ${symbolDisplay || symbol}`;\n\ttableView.toolbar.symbol.innerText = displayedSymbol;\n\ttableView.toolbar.symbol.setAttribute(\"aria-label\", displayedSymbol);\n\n\tsetTimeout(() => {\n\t\tconst htmlTable = dataToHtml(arr, { colHeaders, minColumnWidth });\n\t\tcover.appendChild(htmlTable);\n\t\ttableView.view = htmlTable;\n\t\tconst scrollbarStyling = CIQ.getFromNS(\n\t\t\tstx,\n\t\t\t\"uiContext.config.scrollbarStyling\"\n\t\t);\n\t\tif (scrollbarStyling) {\n\t\t\tscrollbarStyling.refresh(cover.querySelector(\"tbody\"));\n\t\t\tscrollbarStyling.refresh(cover.querySelector(\".ciq-data-table-wrapper\"), {\n\t\t\t\tsuppressScrollY: true\n\t\t\t});\n\t\t}\n\t\tif (stx.translateUI) stx.translateUI(cover);\n\t\tcover.classList.remove(\"loading\");\n\t});\n\n\treturn cover;\n};\n\n/**\n * Creates an HTML table containing the chart data and column headers (see\n * {@link TableViewBuilder.colHeaders}).\n *\n * @param {object[]} data The chart data.\n * @param {object} params Configuration parameters.\n * @param {Object.} params.colHeaders The column\n * \t\theaders as defined in {@link TableViewBuilder.colHeaders}.\n * @param {string} [params.minColumnWidth] The minimum width of the table columns, including units.\n * \t\t**Note:** The units can be any CSS unit acceptable by the CSS `calc` function.\n * @return {HTMLElement} A table containing the chart data and column headers.\n *\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.dataToHtml = function (data, { colHeaders, minColumnWidth }) {\n\tconst keyLength = Object.keys(colHeaders).length;\n\tconst colWidth = `calc((100% - ${10 + keyLength * 4}px ) / ${keyLength})`;\n\tconst tableHeader = Object.entries(colHeaders).map(([, { label }], index) => {\n\t\treturn `${label.replace(\"(\", \" (\")}`;\n\t});\n\n\tconst tableRows = data.map((row) => {\n\t\tconst htmlRow = Object.keys(colHeaders)\n\t\t\t.map((key, index) => {\n\t\t\t\tconst value = row[key];\n\t\t\t\treturn index === 0\n\t\t\t\t\t? `${value}`\n\t\t\t\t\t: `${value}`;\n\t\t\t})\n\t\t\t.join(\"\");\n\t\treturn `${htmlRow}`;\n\t});\n\n\tconst tableWrapper = document.createElement(\"div\");\n\ttableWrapper.classList.add(\"ciq-data-table-wrapper\");\n\tconst minWidth = minColumnWidth\n\t\t? `calc(${keyLength} * ${minColumnWidth})`\n\t\t: \"\";\n\ttableWrapper.innerHTML = `\n\t\t\n\t\t${tableHeader.join(\"\")}\n\t\t${tableRows.join(\"\")}\n\t\t
`;\n\treturn tableWrapper;\n};\n\n/**\n * Transforms the chart data into a character-separated values (CSV) file, including column headers.\n *\n * @param {object[]} data The chart data.\n * @param {object} params Configuration parameters.\n * @param {Object.} params.colHeaders The column\n * \t\theaders as defined in {@link TableViewBuilder.colHeaders}.\n * @param {string} params.colSeparator=\"\\t\" The column separator for the CSV format.\n * @return {string} The column headers and chart data as a CSV file.\n *\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.dataToCsv = function (\n\tdata,\n\t{ colHeaders, colSeparator = \"\\t\" }\n) {\n\tconst tableHeader = Object.entries(colHeaders)\n\t\t.map(([, { label }]) => `\"${label}\"`)\n\t\t.join(colSeparator);\n\n\tconst columns = Object.entries(colHeaders).map(\n\t\t(arr) => arr[1].alias || arr[0]\n\t);\n\tconst tableRows = data.map((row) => {\n\t\treturn columns\n\t\t\t.map((key) => `\"${key === \"DT\" ? row[key].toISOString() : row[key]}\"`)\n\t\t\t.join(colSeparator);\n\t});\n\n\treturn `${tableHeader}\\n${tableRows.reverse().join(\"\\n\")}`;\n};\n\n/**\n * Downloads the table view as a character-separated values (CSV) file.\n *\n * @param {string} csvString The table view in the form of character-separated data.\n * @param {string} filename The name given to the download file.\n * @param {CIQ.ChartEngine} [stx] The chart engine\n *\n * @memberof TableViewBuilder\n * @since\n * - 8.1.0\n * - 8.5.0 Added optional `stx` parameter to aid in specifying document to download from.\n */\nTableViewBuilder.downloadCsv = function (\n\tcsvString,\n\tfilename = \"filename\",\n\tstx = null\n) {\n\tconst blob = new Blob([csvString], { type: \"text/csv;charset=utf-8;\" });\n\n\tconst a = document.createElement(\"a\");\n\ta.href = window.URL.createObjectURL(blob, { type: \"text/plain\" });\n\ta.download = `${filename}.csv`;\n\ta.style.display = \"none\";\n\tconst doc = ((stx || {}).container || {}).ownerDocument || document;\n\tdoc.body.appendChild(a);\n\ta.click();\n\tdoc.body.removeChild(a);\n};\n\n/**\n * Extracts OHLC (open, high, low, close) data from the chart.\n *\n * @param {CIQ.ChartEngine} stx A reference to the chart engine that contains the chart from which\n * \t\tthe data is extracted.\n * @param {object} params Configuration parameters.\n * @param {function} [params.dateFormatter] Formats date fields.\n * @param {function} [params.valueFormatter] Formats OHLC and other values.\n * @param {function} [params.percentFormatter] Formats percent fields.\n * @param {function} [params.volumeFormatter] Formats the volume field.\n * @param {string[]} [params.additionalDataFields] An array of additional data field names for\n * \t\tcomparison series and study data.\n * @return {object[]} The formatted chart data.\n *\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.getChartData = function (\n\tstx,\n\t{\n\t\tdateFormatter,\n\t\tvalueFormatter,\n\t\tpercentFormatter,\n\t\tvolumeFormatter,\n\t\tadditionalDataFields\n\t}\n) {\n\tconst data = stx.chart.dataSegment.filter((item) => item !== null);\n\tconst { usePreviousCloseForChange } = stx.tableView;\n\tlet out = [];\n\tlet length = 0;\n\tconst avgPctChange =\n\t\tdata.reduce((acc, { Close, iqPrevClose, Open }) => {\n\t\t\tconst Base = usePreviousCloseForChange ? iqPrevClose : Open;\n\t\t\tif (\n\t\t\t\ttypeof Close === \"undefined\" ||\n\t\t\t\tNumber.isNaN(Close) ||\n\t\t\t\ttypeof Base === \"undefined\" ||\n\t\t\t\tNumber.isNaN(Base)\n\t\t\t) {\n\t\t\t\treturn acc;\n\t\t\t}\n\t\t\tlength++;\n\t\t\treturn acc + (Close - Base) / Base;\n\t\t}, 0) / length;\n\tdata.forEach((item, index) => {\n\t\tconst { DT, displayDate, High, Low, Open, Close, iqPrevClose, Volume } =\n\t\t\titem;\n\t\tconst Base = usePreviousCloseForChange ? iqPrevClose : Open;\n\t\tconst pctChange = (Close - Base) / Base;\n\t\tconst date =\n\t\t\tdisplayDate ||\n\t\t\t(stx.displayZone\n\t\t\t\t? CIQ.convertTimeZone(DT, stx.dataZone, stx.displayZone)\n\t\t\t\t: DT);\n\t\tconst obj = {\n\t\t\tDT,\n\t\t\tdate: dateFormatter(date),\n\t\t\topen: valueFormatter(Open),\n\t\t\tclose: valueFormatter(Close),\n\t\t\tchange: valueFormatter(Close - Base),\n\t\t\tpctChange: percentFormatter(pctChange * 100),\n\t\t\tpctChangeVsAvg: percentFormatter((pctChange - avgPctChange) * 100),\n\t\t\thigh: valueFormatter(High),\n\t\t\tlow: valueFormatter(Low),\n\t\t\tvolume: volumeFormatter(Volume)\n\t\t};\n\t\tadditionalDataFields.forEach((fieldName) => {\n\t\t\tlet value = item[fieldName];\n\t\t\tif (value == null) {\n\t\t\t\tobj[fieldName] = \"\";\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tif (typeof value === \"object\") {\n\t\t\t\tvalue = value.Close;\n\t\t\t}\n\t\t\tobj[fieldName] = valueFormatter(value);\n\t\t});\n\n\t\tout.push(obj);\n\t});\n\tout.sort((a, b) => b.DT - a.DT);\n\treturn out;\n};\n\n/**\n * Creates a function that formats table view date fields.\n *\n * @param {CIQ.ChartEngine} stx A reference to the chart engine that contains the chart for which\n * \t\tthe date fields are formatted.\n * @return {function} A date formatter.\n *\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.getDateFormatter = function (stx) {\n\treturn (dt, panel) => {\n\t\tif (!dt) return \"\";\n\n\t\treturn CIQ.displayableDate(stx, stx.chart, dt, true);\n\t};\n};\n\n/**\n * Creates a function that formats table view value fields.\n *\n * @param {CIQ.ChartEngine} stx A reference to the chart engine that contains the chart for which\n * \t\tthe value fields are formatted.\n * @param {number} [decimalPlaces] Number of decimal places to use, overrides any auto-detection of decimal places in data.\n * @return {function} A value formatter.\n *\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.getValueFormatter = function (stx, decimalPlaces) {\n\tconst {\n\t\tchart: { panel, yAxis },\n\t\tlayout: { chartScale }\n\t} = stx;\n\tlet formatValue;\n\n\tif (yAxis.originalPriceFormatter && yAxis.originalPriceFormatter.func) {\n\t\tformatValue = (value) =>\n\t\t\tyAxis.originalPriceFormatter.func(stx, panel, value, decimalPlaces);\n\t} else if (\n\t\tyAxis.priceFormatter &&\n\t\tchartScale != \"percent\" &&\n\t\tchartScale != \"relative\"\n\t) {\n\t\tformatValue = (value) =>\n\t\t\tyAxis.priceFormatter(stx, panel, value, decimalPlaces);\n\t} else {\n\t\tformatValue = (value) => stx.formatYAxisPrice(value, panel, decimalPlaces);\n\t}\n\n\treturn (value) => formatValue(value).replace(/^-*0\\.0*$/, \"0\"); // display 0.00 as 0\n};\n\n/**\n * Creates a function that formats the table view volume field.\n *\n * @param {CIQ.ChartEngine} stx A reference to the chart engine that contains the chart for which\n * \t\tthe volume field is formatted.\n * @return {function} A volume field formatter.\n *\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.getVolumeFormatter = function (stx) {\n\treturn (num) => {\n\t\tif (num == null) return \"\";\n\n\t\tif (stx.internationalizer) {\n\t\t\treturn stx.internationalizer.priceFormatters[0].format(num);\n\t\t}\n\n\t\tconst num_parts = num.toString().split(\".\");\n\t\tnum_parts[0] = CIQ.commas(num_parts[0]);\n\t\treturn num_parts[0];\n\t};\n};\n\n/**\n * Creates a function that creates and formats a file name from the chart symbol and table view\n * data.\n *\n * @param {CIQ.ChartEngine} stx A reference to the chart engine that contains the chart whose\n * \t\tsymbol and data is included in the file name.\n * @return {function} A function that creates and formats a file name.\n *\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.getFilenameFormatter = function (stx) {\n\treturn (csvData) => {\n\t\tconst symbol = stx.chart.symbolDisplay || stx.chart.symbol;\n\t\tlet firstDate, lastDate;\n\t\tif (csvData) {\n\t\t\tconst rows = csvData.split(\"\\n\");\n\t\t\tif (rows.length > 1) {\n\t\t\t\t[, firstDate = \"\"] = rows[rows.length - 1].match(/^\"([^\"]*)\"/) || [];\n\t\t\t\t[, lastDate = \"\"] = rows[1].match(/^\"([^\"]*)\"/) || [];\n\t\t\t\tfirstDate = CIQ.yyyymmddhhmmssmmm(new Date(firstDate));\n\t\t\t\tlastDate = CIQ.yyyymmddhhmmssmmm(new Date(lastDate));\n\t\t\t}\n\t\t}\n\t\treturn `${symbol}${firstDate ? ` (${firstDate} _ ${lastDate})` : \"\"}`;\n\t};\n};\n\n/**\n * Creates and attaches an HTML container element to the DOM. The element covers the chart and\n * contains the table view.\n *\n * @param {CIQ.ChartEngine} stx A reference to the chart engine that contains the chart over which\n * \t\tthe cover is placed.\n * @param {object} params Configuration parameters.\n * @param {number} [params.coverUIMaxWidth] The width of the chart (in pixels) below which the\n * \t\tcover element overlays the entire chart, including user interface elements.\n * @param {string} [params.coverContainer] A CSS selector used to obtain the DOM element that\n * \t\tserves as the parent element of the cover element; for example, \".chartContainer\".\n * @return {HTMLElement} The cover element.\n *\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.getChartCover = function (\n\tstx,\n\t{ coverUIMaxWidth, coverContainer }\n) {\n\tconst parentElement =\n\t\t(coverContainer &&\n\t\t\tstx.container.ownerDocument.querySelector(coverContainer)) ||\n\t\t(stx.uiContext && stx.container.offsetWidth < coverUIMaxWidth\n\t\t\t? stx.uiContext.topNode\n\t\t\t: stx.container.parentElement.parentElement);\n\n\tconst cover = document.createElement(\"div\");\n\tObject.assign(cover.style, { top: 0, left: 0, right: 0, bottom: 0 });\n\n\tcover.classList.add(\"ciq-data-table-container\", \"loading\");\n\tcover.setAttribute(\"role\", \"dialog\");\n\tcover.setAttribute(\"aria-label\", \"Data Table\");\n\tcover.setAttribute(\"tabindex\", 0);\n\n\tconst spinner = document.createElement(\"div\");\n\tspinner.classList.add(\"ciq-spinner-wrapper\");\n\tspinner.innerHTML = ``;\n\n\tcover.appendChild(spinner);\n\n\tparentElement.appendChild(cover);\n\treturn cover;\n};\n\n/**\n * Creates a toolbar containing the table title and controls used to copy and download the table\n * data and add additional table columns.\n *\n * @param {object} params Function parameters.\n * @param {string} params.symbol An instrument symbol, which is used as the table title in the\n * \t\ttoolbar. Should be the symbol of the chart main series.\n * @param {boolean} params.viewAdditionalColumns Toggle that specifies whether the label for the\n * \t\tadditional columns button should indicate that additional columns will be shown or hidden.\n * \t\tIf this parameter is true, the label indicates additional table columns will be shown; if\n * \t\tfalse, hidden.\n * @param {function} [params.copyFn] Event handler for selection of the copy control.\n * @param {function} [params.downloadFn] Event handler for selection of the download control.\n * @param {function} [params.toggleAdditionalColumnsFn] Event handler for selection of the\n * \t\tadditional column control.\n * @param {function} [params.closeFn] Event handler for selection of the table view close (X)\n * \t\tcontrol.\n * @return {HTMLElement} The toolbar, containing title and controls.\n *\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.getCoverToolbar = function ({\n\tsymbol,\n\tviewAdditionalColumns,\n\tcopyFn,\n\tdownloadFn,\n\ttoggleAdditionalColumnsFn,\n\tcloseFn\n}) {\n\tconst toolBar = document.createElement(\"div\");\n\ttoolBar.classList.add(\"ciq-data-table-toolbar\");\n\ttoolBar.innerHTML = `\n\t\t
\n\t\t\n\t\t\n\t\t
\n\t\t\t\n\t\t
\n\t\t\n\t`;\n\tconst titleEl = toolBar.querySelector(\".ciq-data-table-title\");\n\ttitleEl.textContent = symbol;\n\ttitleEl.setAttribute(\"aria-label\", symbol);\n\ttitleEl.setAttribute(\"role\", \"heading\");\n\n\tconst btnCopy = toolBar.querySelector(\".ciq-data-table-copy\");\n\tif (copyFn) {\n\t\tbtnCopy.addEventListener(\"click\", copyFn);\n\t} else {\n\t\tbtnCopy.style.display = \"none\";\n\t}\n\n\tconst btnDownload = toolBar.querySelector(\".ciq-data-table-download\");\n\tif (downloadFn) {\n\t\tbtnDownload.addEventListener(\"click\", function () {\n\t\t\tbtnDownload.blur();\n\t\t\tdownloadFn();\n\t\t});\n\t} else {\n\t\tbtnDownload.style.display = \"none\";\n\t}\n\n\tconst btnAdditionalColumns = toolBar.querySelector(\n\t\t\".ciq-data-table-additionalColumns\"\n\t);\n\tif (toggleAdditionalColumnsFn) {\n\t\tbtnAdditionalColumns.addEventListener(\"click\", toggleAdditionalColumnsFn);\n\t} else {\n\t\tbtnAdditionalColumns.style.display = \"none\";\n\t}\n\n\ttoolBar.close = closeFn;\n\n\treturn toolBar;\n};\n\n/**\n * Label for the copy button on the table view toolbar.\n *\n * @type string\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.copyLabel = \"Copy\";\n\n/**\n * Label for the download button on the table view toolbar.\n *\n * @type string\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.downloadLabel = \"Download\";\n\n/**\n * Gets the label of the additional columns button on the table view toolbar.\n *\n * @param {boolean} viewingAdditionalColumns If this parameter is true, the label should indicate\n * \t\tadditional table columns will be shown; if false, hidden.\n * @return {string} The button label.\n *\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.getAdditionalColumnLabel = function (\n\tviewingAdditionalColumns\n) {\n\treturn `${\n\t\tviewingAdditionalColumns ? \"- \" : \"+ \"\n\t}Additional columns`;\n};\n\n/**\n * Obtains the names of all studies that have data in the chart's visible data segment.\n *\n * @param {CIQ.ChartEngine} stx A reference to the chart engine that contains the chart studies.\n * @return {string[]} The names of all studies that are in the visible portion of the chart.\n *\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.getStudyDataNames = function (stx) {\n\treturn Object.values(stx.layout.studies || {})\n\t\t.filter((study) => !study.signalData || study.signalData.reveal)\n\t\t.map(getDataNames)\n\t\t.reduce((acc, item) => acc.concat(item), []);\n\n\tfunction getDataNames(study) {\n\t\treturn Object.keys(study.outputMap).filter(hasData);\n\t}\n\n\tfunction hasData(name) {\n\t\treturn stx.chart.dataSegment.some((data) => data && data[name]);\n\t}\n};\n\n/**\n * Obtains the symbols of all comparison series that have data in the chart's visible data\n * segment.\n *\n * @param {CIQ.ChartEngine} stx A reference to the chart engine that contains the comparison\n * \t\tseries.\n * @return {string[]} The names (symbols) of all comparison series that are in the visible\n * \t\tportion of the chart.\n *\n * @memberof TableViewBuilder\n * @since 8.1.0\n */\nTableViewBuilder.getSeriesDataNames = function (stx) {\n\treturn Object.values(stx.chart.seriesRenderers || {})\n\t\t.filter((item) => item.params.name !== \"_main_series\")\n\t\t.map((item) => {\n\t\t\treturn item.seriesParams.map(({ symbol }) => symbol);\n\t\t})\n\t\t.reduce((acc, item) => acc.concat(item), []);\n};\n\n/**\n * CIQ.UI.Context interface placeholder to be augmented in *componentUI.js* with properties.\n *\n * @tsinterface CIQ.UI~Context\n */\n\n};\n\n\nlet __js_addons_standard_tooltip_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nif (!CIQ.Marker) {\n\tconsole.error(\"tooltip addon requires first activating markers feature.\");\n} else {\n\t/**\n\t * Add-on that creates a detailed tooltip as the user's mouse hovers over data points on the\n\t * chart. The tooltip contains information such as the open, high, low, and close prices of\n\t * stock quotes.\n\t *\n\t * Tooltip example:\n\t * \n\t *\n\t * **Note:** Prior to version 8.2.0, the tooltip was directly linked to the crosshairs. The\n\t * crosshairs had to be active for the tooltip to be displayed.\n\t *\n\t * Requires *addOns.js* and *markers.js*, or the bundle *standard.js*.\n\t *\n\t * There can be only one `CIQ.Tooltip` per chart.\n\t *\n\t * Color and layout can be customized by overriding the CSS rule-sets defined for the\n\t * `stx-hu-tooltip` and related type selectors in *stx-chart.css*. Do not modify\n\t * *stx-chart.css*; create a separate style sheet file that overrides *stx-chart.css* in the\n\t * CSS cascade. See the example below.\n\t *\n\t * `CIQ.Tooltip` automatically creates its own HTML inside the chart container. Here is an\n\t * example of the structure (there will be one field tag per displayed element):\n\t * ```\n\t * \n\t * \n\t * \n\t * \n\t * \n\t * \n\t * ```\n\t * By default, the `stx-hu-tooltip-field` elements are inserted in the following order:\n\t * - DT\n\t * - Open\n\t * - High\n\t * - Low\n\t * - Close\n\t * - Volume\n\t * - series\n\t * - studies\n\t *\n\t * But the default layout can be changed. You can override the order of fields or change the\n\t * labels by manually inserting the HTML that the tooltip would otherwise have created for\n\t * that field. If no override HTML is found for a particular field, the default is used.\n\t * **Note:** This HTML must be placed inside the chart container.\n\t *\n\t * All of the code is provided in *addOns.js* and can be fully customized by copying the\n\t * source code from the library and overriding the functions with your changes. Be sure to\n\t * never modify a library file, as this will hinder upgrades.\n\t *\n\t * For example, concatenating the field name (e.g., \"Jaw\") with the study name (e.g.,\n\t * \"Alligator\" ) is the default behavior of the tooltip for displaying the value title. Feel\n\t * free to override this behavior by creating your own custom version of the `renderFunction()`\n\t * for the `CIQ.Tooltip`. To do this, copy the entire `CIQ.Tooltip` code (found in *addOns.js*)\n\t * and make the changes to your custom version. Load your custom version instead. Specifically,\n\t * look for the following code in the `renderFunction()` that pushes out the text for each\n\t * study field:\n\t * ```\n\t * let newFieldName = document.createElement(\"stx-hu-tooltip-field-name\");\n\t * newFieldName.innerHTML = this.translateIf(fieldName);\n\t * newField.appendChild(newFieldName);\n\t * ```\n\t * Replace `fieldName` with anything you want to use as the field title and push that instead.\n\t *\n\t * Visual Reference:
\n\t * ![stx-hu-tooltip](stx-hu-tooltip.png \"stx-hu-tooltip\")\n\t *\n\t * @param {object} tooltipParams The constructor parameters.\n\t * @param {CIQ.ChartEngine} [tooltipParams.stx] The chart object.\n\t * @param {boolean} [tooltipParams.ohl] Set to true to show OHL data (Close is always shown).\n\t * @param {boolean} [tooltipParams.volume] Set to true to show Volume.\n\t * @param {boolean} [tooltipParams.series] Set to true to show value of series.\n\t * @param {boolean} [tooltipParams.studies] Set to true to show value of studies.\n\t * @param {boolean} [tooltipParams.signalStudies] Set to true to show value of signalling studies\n\t * \t\teven when they are hidden.\n\t * @param {boolean} [tooltipParams.showOverBarOnly] Set to true to show the tooltip only when\n\t * \t\tthe mouse is over the primary line/bars.\n\t * @param {boolean} [tooltipParams.change] Set to true to show the change in daily value\n\t * \t\twhen the internal chart periodicity is a daily interval (see\n\t * \t\t{@link CIQ.ChartEngine.isDailyInterval}).\n\t * @param {boolean} [tooltipParams.interpolation] Set to true to show the estimated value when\n\t * \t\tthere is no data between bars. **Note:** A value of `null` is not considered missing\n\t * \t\tdata.\n\t * @param {boolean} [tooltipParams.useDataZone] Set to true to show the date in the `dataZone`\n\t * \t\ttime zone; false, to use the `displayZone` time zone (see\n\t * \t\t{@link CIQ.ChartEngine#setTimeZone}).\n\t * @param {boolean} [tooltipParams.showBarHighlight=true] Specifies whether the bar (data\n\t * \t\tpoint) the mouse is hovering over is highlighted. Applies to the floating tooltip only\n\t * \t\t(the dynamic tooltip points to the bar). If the crosshairs are active, this parameter\n\t * \t\tis ignored.\n\t *\n\t * @constructor\n\t * @name CIQ.Tooltip\n\t * @since\n\t * - 09-2016-19\n\t * - 5.0.0 Now `tooltipParams.showOverBarOnly` is available to show tooltip only when over the\n\t * \t\tprimary line/bars.\n\t * - 5.1.1 `tooltipParams.change` set to true to show the change in daily value when\n\t * \t\tdisplaying a daily interval.\n\t * - 6.2.5 New `tooltipParams.interpolation` flag to show estimated value for missing series\n\t * \t\tdata points.\n\t * - 7.0.0 New `tooltipParams.useDataZone` flag to show the date in either the `dataZone` or\n\t * \t\t`displayZone` date/time.\n\t * - 8.2.0 Decoupled `CIQ.Tooltip` from the crosshairs and added highlighting of the data\n\t * \t\tpoint (or bar) the mouse is hovering over. The new `tooltipParams.showBarHighlight`\n\t * \t\tparameter enables or disables the highlighting.\n\t * - 8.6.0 New `tooltipParams.signalStudies` flag to show the value of signaling studies\n\t * \t\teven when they are hidden.\n\t *\n\t * @example Add a tooltip to a chart:\n\t * // First declare your chart engine.\n\t * const stxx = new CIQ.ChartEngine({ container: document.querySelector(\".chartContainer\")[0] });\n\t *\n\t * // Then link the tooltip to that chart.\n\t * // Note how we've enabled OHL, Volume, Series and Studies.\n\t * new CIQ.Tooltip({ stx: stxx, ohl: true, volume: true, series: true, studies: true });\n\t *\n\t * @example Customize the order, layout, or text in tooltip labels:\n\t * // In this example, we've rearranged the HTML to display the Close field first, then the DT.\n\t * // We are also labeling the DT 'Date/Time' and the Close 'Last'.\n\t * // The rest of the fields are displayed in their default order.\n\t *\n\t * \n\t * \n\t * Last\n\t * \n\t * \n\t * \n\t * Date/Time\n\t * \n\t * \n\t * \n\t *\n\t * @example Customize the CSS for the tooltip (see stx-chart.css):\n\t * stx-hu-tooltip {\n\t * position: absolute;\n\t * left: -50000px;\n\t * z-index: 30;\n\t * white-space: nowrap;\n\t * padding: 6px;\n\t * border: 1px solid gray;\n\t * background-color: rgba(42,81,208,.5);\n\t * color: white;\n\t * }\n\t *\n\t * stx-hu-tooltip-field {\n\t * display:table-row;\n\t * }\n\t *\n\t * stx-hu-tooltip-field-name {\n\t * display:table-cell;\n\t * font-weight:bold;\n\t * padding-right:5px;\n\t * }\n\t *\n\t * stx-hu-tooltip-field-name:after {\n\t * content:':';\n\t * }\n\t *\n\t * stx-hu-tooltip-field-value {\n\t * display:table-cell;\n\t * text-align:right;\n\t * }\n\t */\n\tCIQ.Tooltip =\n\t\tCIQ.Tooltip ||\n\t\tfunction (tooltipParams) {\n\t\t\tif (!CIQ.Marker) {\n\t\t\t\tconsole.warn(\n\t\t\t\t\t\"CIQ.Tooltip addon requires CIQ.Marker module to be enabled.\"\n\t\t\t\t);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tthis.cssRequired = true;\n\n\t\t\tconst {\n\t\t\t\tstx,\n\t\t\t\tohl: showOhl,\n\t\t\t\tchange: showChange,\n\t\t\t\tvolume: showVolume,\n\t\t\t\tseries: showSeries,\n\t\t\t\tstudies: showStudies,\n\t\t\t\tsignalStudies: showSignalStudies,\n\t\t\t\tinterpolation: showInterpolation,\n\t\t\t\tshowOverBarOnly,\n\t\t\t\tshowBarHighlight = true,\n\t\t\t\tuseDataZone\n\t\t\t} = tooltipParams;\n\t\t\tconst { container } = stx.chart;\n\n\t\t\tlet node = container.querySelector(\"stx-hu-tooltip\");\n\t\t\tif (!node) {\n\t\t\t\tnode = document.createElement(\"stx-hu-tooltip\");\n\t\t\t\tcontainer.appendChild(node);\n\t\t\t}\n\n\t\t\tlet highlightEl = container.querySelector(\".stx-hu-tooltip-highlight\");\n\t\t\tif (!highlightEl) {\n\t\t\t\thighlightEl = document.createElement(\"div\");\n\t\t\t\thighlightEl.classList.add(\"stx-hu-tooltip-highlight\");\n\t\t\t\tcontainer.appendChild(highlightEl);\n\t\t\t}\n\n\t\t\tCIQ.Marker.Tooltip = function (params) {\n\t\t\t\tif (!this.className) this.className = \"CIQ.Marker.Tooltip\";\n\t\t\t\tthis.highlightEl = highlightEl;\n\t\t\t\tparams.label = \"tooltip\";\n\t\t\t\tCIQ.Marker.call(this, params);\n\t\t\t};\n\n\t\t\tCIQ.inheritsFrom(CIQ.Marker.Tooltip, CIQ.Marker, false);\n\n\t\t\tCIQ.Marker.Tooltip.sameBar = function (bar1, bar2) {\n\t\t\t\tif (!bar1 || !bar2) return false;\n\t\t\t\tif (+bar1.DT != +bar2.DT) return false;\n\t\t\t\tif (bar1.Close != bar2.Close) return false;\n\t\t\t\tif (bar1.Open != bar2.Open) return false;\n\t\t\t\tif (bar1.Volume != bar2.Volume) return false;\n\t\t\t\treturn true;\n\t\t\t};\n\n\t\t\tCIQ.Marker.Tooltip.placementFunction = function (params) {\n\t\t\t\tif (hideIfDisabled()) return;\n\t\t\t\tvar offset = 30;\n\t\t\t\tvar stx = params.stx;\n\t\t\t\tfor (var i = 0; i < params.arr.length; i++) {\n\t\t\t\t\tvar marker = params.arr[i];\n\t\t\t\t\tvar bar = stx.barFromPixel(stx.cx);\n\t\t\t\t\tvar quote = stx.chart.dataSegment[bar];\n\t\t\t\t\tvar goodBar;\n\t\t\t\t\tvar overBar = true;\n\t\t\t\t\tvar highPx, lowPx;\n\n\t\t\t\t\tif (quote != \"undefined\" && quote && quote.DT) {\n\t\t\t\t\t\tgoodBar = true;\n\t\t\t\t\t\tif (quote.High) highPx = stx.pixelFromPrice(quote.High);\n\t\t\t\t\t\tif (quote.Low) lowPx = stx.pixelFromPrice(quote.Low);\n\t\t\t\t\t\tif (!stx.chart.highLowBars) {\n\t\t\t\t\t\t\tif (quote.Close) {\n\t\t\t\t\t\t\t\thighPx = stx.pixelFromPrice(quote.Close) - 15;\n\t\t\t\t\t\t\t\tlowPx = stx.pixelFromPrice(quote.Close) + 15;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (showOverBarOnly && !(stx.cy >= highPx && stx.cy <= lowPx))\n\t\t\t\t\t\t\toverBar = false;\n\t\t\t\t\t}\n\n\t\t\t\t\tif (\n\t\t\t\t\t\t!(\n\t\t\t\t\t\t\tstx.insideChart &&\n\t\t\t\t\t\t\t!stx.openDialog &&\n\t\t\t\t\t\t\t!stx.activeDrawing &&\n\t\t\t\t\t\t\t!stx.grabbingScreen &&\n\t\t\t\t\t\t\tgoodBar &&\n\t\t\t\t\t\t\toverBar\n\t\t\t\t\t\t)\n\t\t\t\t\t) {\n\t\t\t\t\t\thighlightEl.style.display = \"none\";\n\t\t\t\t\t\tmarker.node.style.left = \"-50000px\";\n\t\t\t\t\t\tmarker.node.style.right = \"auto\";\n\t\t\t\t\t\tmarker.lastBar = {};\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\tif (\n\t\t\t\t\t\tCIQ.Marker.Tooltip.sameBar(\n\t\t\t\t\t\t\tstx.chart.dataSegment[bar],\n\t\t\t\t\t\t\tmarker.lastBar\n\t\t\t\t\t\t) &&\n\t\t\t\t\t\tbar != stx.chart.dataSegment.length - 1\n\t\t\t\t\t) {\n\t\t\t\t\t\tadjustSticky(marker);\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\n\t\t\t\t\tmarker.lastBar = stx.chart.dataSegment[bar];\n\t\t\t\t\tvar cw = marker.lastBar.candleWidth || stx.layout.candleWidth;\n\t\t\t\t\tif (\n\t\t\t\t\t\tparseInt(getComputedStyle(marker.node).width, 10) +\n\t\t\t\t\t\t\tstx.chart.panel.left +\n\t\t\t\t\t\t\toffset +\n\t\t\t\t\t\t\tcw <\n\t\t\t\t\t\tstx.backOutX(CIQ.ChartEngine.crosshairX)\n\t\t\t\t\t) {\n\t\t\t\t\t\tmarker.node.style.left = \"auto\";\n\t\t\t\t\t\tmarker.node.style.right =\n\t\t\t\t\t\t\tMath.round(\n\t\t\t\t\t\t\t\tcontainer.clientWidth - stx.pixelFromBar(bar) + offset\n\t\t\t\t\t\t\t) + \"px\";\n\t\t\t\t\t} else {\n\t\t\t\t\t\tmarker.node.style.left =\n\t\t\t\t\t\t\tMath.round(stx.pixelFromBar(bar) + offset) + \"px\";\n\t\t\t\t\t\tmarker.node.style.right = \"auto\";\n\t\t\t\t\t}\n\t\t\t\t\tvar height = parseInt(getComputedStyle(marker.node).height, 10);\n\t\t\t\t\tvar top = Math.round(\n\t\t\t\t\t\tstx.backOutY(CIQ.ChartEngine.crosshairY) - height / 2\n\t\t\t\t\t);\n\t\t\t\t\tif (top + height > stx.height) top = stx.height - height;\n\t\t\t\t\tif (top < 0) top = 0;\n\t\t\t\t\tmarker.node.style.top = top + \"px\";\n\t\t\t\t\tadjustSticky(marker);\n\t\t\t\t\tif (showBarHighlight && !stx.layout.crosshair) {\n\t\t\t\t\t\tconst candleWidth =\n\t\t\t\t\t\t\tmarker.lastBar.candleWidth || stx.layout.candleWidth;\n\t\t\t\t\t\tconst left = stx.pixelFromBar(bar) - candleWidth / 2;\n\t\t\t\t\t\tlet width = candleWidth;\n\n\t\t\t\t\t\tif (left + width > stx.chart.width) {\n\t\t\t\t\t\t\t// adjust width of last bar so it does not highlight past the edge of the chart into the y-axis\n\t\t\t\t\t\t\twidth = stx.chart.width - left;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\thighlightEl.style.display = \"block\";\n\t\t\t\t\t\thighlightEl.style.left = left + \"px\";\n\t\t\t\t\t\thighlightEl.style.width = width + \"px\";\n\t\t\t\t\t} else {\n\t\t\t\t\t\thighlightEl.style.display = \"none\";\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t// backwards compatibility\n\t\t\t\t// temporarily disable overXAxis, overYAxis so the crosshairs don't hide if touch device and over y-axis (this can happen\n\t\t\t\t// due to the offset which we apply)\n\t\t\t\tif (CIQ.touchDevice && stx.layout.crosshair) {\n\t\t\t\t\tvar overXAxis = stx.overXAxis,\n\t\t\t\t\t\toverYAxis = stx.overYAxis;\n\t\t\t\t\tstx.overXAxis = stx.overYAxis = false;\n\t\t\t\t\tstx.doDisplayCrosshairs();\n\t\t\t\t\tstx.overXAxis = overXAxis;\n\t\t\t\t\tstx.overYAxis = overYAxis;\n\t\t\t\t}\n\t\t\t};\n\n\t\t\tfunction hideIfDisabled() {\n\t\t\t\tconst { headsUp, crosshair } = stx.layout;\n\t\t\t\tconst isFloating =\n\t\t\t\t\t(headsUp && headsUp.floating) || headsUp === \"floating\";\n\n\t\t\t\tconst crosshairsOn =\n\t\t\t\t\tcrosshair &&\n\t\t\t\t\tstx.displayCrosshairs &&\n\t\t\t\t\t[\"static\", null, undefined].includes(headsUp); // backwards compatibility\n\n\t\t\t\tif (stx.huTooltip && !isFloating && !crosshairsOn) {\n\t\t\t\t\thideTooltip();\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\tfunction hideTooltip() {\n\t\t\t\tconst { huTooltip } = stx;\n\t\t\t\tconst { node } = huTooltip;\n\t\t\t\tif (!node) return;\n\t\t\t\tnode.style.left = \"-50000px\";\n\t\t\t\tnode.style.right = \"auto\";\n\t\t\t\thuTooltip.lastBar = {};\n\t\t\t\tif (huTooltip.highlightEl) huTooltip.highlightEl.style.display = \"none\";\n\t\t\t}\n\n\t\t\tfunction renderFunction() {\n\t\t\t\tvar stx = this;\n\t\t\t\t// the tooltip has not been initialized with this chart.\n\t\t\t\tif (hideIfDisabled()) return;\n\n\t\t\t\tvar bar = stx.barFromPixel(stx.cx),\n\t\t\t\t\tdata = stx.chart.dataSegment[bar];\n\t\t\t\tif (!data) {\n\t\t\t\t\thideTooltip();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tif (\n\t\t\t\t\tCIQ.Marker.Tooltip.sameBar(data, stx.huTooltip.lastBar) &&\n\t\t\t\t\tbar != stx.chart.dataSegment.length - 1\n\t\t\t\t) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tvar node = stx.huTooltip.node;\n\t\t\t\tArray.from(node.parentElement.querySelectorAll(\"[auto]\")).forEach(\n\t\t\t\t\tfunction (i) {\n\t\t\t\t\t\ti.remove();\n\t\t\t\t\t}\n\t\t\t\t);\n\t\t\t\tArray.from(\n\t\t\t\t\tnode.parentElement.querySelectorAll(\"stx-hu-tooltip-field-value\")\n\t\t\t\t).forEach(function (i) {\n\t\t\t\t\ti.innerHTML = \"\";\n\t\t\t\t});\n\n\t\t\t\tvar panel = stx.chart.panel;\n\t\t\t\tvar yAxis = panel.yAxis;\n\t\t\t\tvar dupMap = {};\n\t\t\t\tvar fields = [];\n\t\t\t\tfields.push({\n\t\t\t\t\tmember: \"DT\",\n\t\t\t\t\tdisplay: \"DT\",\n\t\t\t\t\tpanel: panel,\n\t\t\t\t\tyAxis: yAxis\n\t\t\t\t});\n\t\t\t\tfields.push({\n\t\t\t\t\tmember: \"Close\",\n\t\t\t\t\tdisplay: \"Close\",\n\t\t\t\t\tpanel: panel,\n\t\t\t\t\tyAxis: yAxis\n\t\t\t\t});\n\t\t\t\tdupMap.DT = dupMap.Close = 1;\n\t\t\t\tif (\n\t\t\t\t\tshowChange &&\n\t\t\t\t\tCIQ.ChartEngine.isDailyInterval(stx.layout.interval)\n\t\t\t\t) {\n\t\t\t\t\tfields.push({\n\t\t\t\t\t\tmember: \"Change\",\n\t\t\t\t\t\tdisplay: \"Change\",\n\t\t\t\t\t\tpanel: panel,\n\t\t\t\t\t\tyAxis: yAxis\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\tif (showOhl) {\n\t\t\t\t\tfields.push({\n\t\t\t\t\t\tmember: \"Open\",\n\t\t\t\t\t\tdisplay: \"Open\",\n\t\t\t\t\t\tpanel: panel,\n\t\t\t\t\t\tyAxis: yAxis\n\t\t\t\t\t});\n\t\t\t\t\tfields.push({\n\t\t\t\t\t\tmember: \"High\",\n\t\t\t\t\t\tdisplay: \"High\",\n\t\t\t\t\t\tpanel: panel,\n\t\t\t\t\t\tyAxis: yAxis\n\t\t\t\t\t});\n\t\t\t\t\tfields.push({\n\t\t\t\t\t\tmember: \"Low\",\n\t\t\t\t\t\tdisplay: \"Low\",\n\t\t\t\t\t\tpanel: panel,\n\t\t\t\t\t\tyAxis: yAxis\n\t\t\t\t\t});\n\t\t\t\t\tdupMap.Open = dupMap.High = dupMap.Low = 1;\n\t\t\t\t}\n\t\t\t\tif (showVolume) {\n\t\t\t\t\tfields.push({\n\t\t\t\t\t\tmember: \"Volume\",\n\t\t\t\t\t\tdisplay: \"Volume\",\n\t\t\t\t\t\tpanel: null,\n\t\t\t\t\t\tyAxis: null\n\t\t\t\t\t}); // null yAxis use raw value\n\t\t\t\t\tdupMap.Volume = 1;\n\t\t\t\t}\n\t\t\t\tif (showSeries) {\n\t\t\t\t\tvar renderers = stx.chart.seriesRenderers;\n\t\t\t\t\tfor (var renderer in renderers) {\n\t\t\t\t\t\tvar rendererToDisplay = renderers[renderer];\n\t\t\t\t\t\tif (rendererToDisplay === stx.mainSeriesRenderer) continue;\n\t\t\t\t\t\tpanel = stx.panels[rendererToDisplay.params.panel];\n\t\t\t\t\t\tyAxis = rendererToDisplay.params.yAxis;\n\t\t\t\t\t\tif (!yAxis && rendererToDisplay.params.shareYAxis)\n\t\t\t\t\t\t\tyAxis = panel.yAxis;\n\t\t\t\t\t\tfor (var id = 0; id < rendererToDisplay.seriesParams.length; id++) {\n\t\t\t\t\t\t\tvar seriesParams = rendererToDisplay.seriesParams[id];\n\t\t\t\t\t\t\t// if a series has a symbol and a field then it maybe a object chain\n\t\t\t\t\t\t\tvar sKey = seriesParams.symbol;\n\t\t\t\t\t\t\tvar subField = seriesParams.field;\n\t\t\t\t\t\t\tif (!sKey) sKey = subField;\n\t\t\t\t\t\t\telse if (subField && sKey != subField)\n\t\t\t\t\t\t\t\tsKey = CIQ.createObjectChainNames(sKey, subField)[0];\n\t\t\t\t\t\t\tvar display =\n\t\t\t\t\t\t\t\tseriesParams.display ||\n\t\t\t\t\t\t\t\tseriesParams.symbol ||\n\t\t\t\t\t\t\t\tseriesParams.field;\n\t\t\t\t\t\t\tif (sKey && !dupMap[display]) {\n\t\t\t\t\t\t\t\tfields.push({\n\t\t\t\t\t\t\t\t\tmember: sKey,\n\t\t\t\t\t\t\t\t\tdisplay: display,\n\t\t\t\t\t\t\t\t\tpanel: panel,\n\t\t\t\t\t\t\t\t\tyAxis: yAxis,\n\t\t\t\t\t\t\t\t\tisSeries: true\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\tdupMap[display] = 1;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (showStudies || showSignalStudies) {\n\t\t\t\t\tfor (var study in stx.layout.studies) {\n\t\t\t\t\t\tvar sd = stx.layout.studies[study];\n\t\t\t\t\t\tif (!showSignalStudies && sd.signalData && !sd.signalData.reveal)\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\tpanel = stx.panels[sd.panel];\n\t\t\t\t\t\tyAxis = panel && sd.getYAxis(stx);\n\t\t\t\t\t\tfor (var output in stx.layout.studies[study].outputMap) {\n\t\t\t\t\t\t\tif (output && !dupMap[output]) {\n\t\t\t\t\t\t\t\tfields.push({\n\t\t\t\t\t\t\t\t\tmember: output,\n\t\t\t\t\t\t\t\t\tdisplay: output,\n\t\t\t\t\t\t\t\t\tpanel: panel,\n\t\t\t\t\t\t\t\t\tyAxis: yAxis\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\tdupMap[output] = 1;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (!dupMap[study + \"_hist\"]) {\n\t\t\t\t\t\t\tfields.push({\n\t\t\t\t\t\t\t\tmember: study + \"_hist\",\n\t\t\t\t\t\t\t\tdisplay: study + \"_hist\",\n\t\t\t\t\t\t\t\tpanel: panel,\n\t\t\t\t\t\t\t\tyAxis: yAxis\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\tfields.push({\n\t\t\t\t\t\t\t\tmember: study + \"_hist1\",\n\t\t\t\t\t\t\t\tdisplay: study + \"_hist1\",\n\t\t\t\t\t\t\t\tpanel: panel,\n\t\t\t\t\t\t\t\tyAxis: yAxis\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\tfields.push({\n\t\t\t\t\t\t\t\tmember: study + \"_hist2\",\n\t\t\t\t\t\t\t\tdisplay: study + \"_hist2\",\n\t\t\t\t\t\t\t\tpanel: panel,\n\t\t\t\t\t\t\t\tyAxis: yAxis\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\tdupMap[study + \"_hist\"] = 1;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tfor (var f = 0; f < fields.length; f++) {\n\t\t\t\t\tvar obj = fields[f];\n\t\t\t\t\tvar name = obj.member;\n\t\t\t\t\tvar displayName = obj.display;\n\t\t\t\t\tvar isRecordDate = name == \"DT\";\n\t\t\t\t\tif (\n\t\t\t\t\t\tisRecordDate &&\n\t\t\t\t\t\t!useDataZone &&\n\t\t\t\t\t\t!CIQ.ChartEngine.isDailyInterval(stx.layout.interval)\n\t\t\t\t\t)\n\t\t\t\t\t\tname = \"displayDate\"; // display date is timezone adjusted\n\t\t\t\t\tpanel = obj.panel;\n\t\t\t\t\tyAxis = obj.yAxis;\n\t\t\t\t\tvar labelDecimalPlaces = null;\n\t\t\t\t\tif (yAxis) {\n\t\t\t\t\t\tif (!panel || panel !== panel.chart.panel) {\n\t\t\t\t\t\t\t// If a study panel, use yAxis settings to determine decimal places\n\t\t\t\t\t\t\tif (yAxis.decimalPlaces || yAxis.decimalPlaces === 0)\n\t\t\t\t\t\t\t\tlabelDecimalPlaces = yAxis.decimalPlaces;\n\t\t\t\t\t\t\telse if (yAxis.maxDecimalPlaces || yAxis.maxDecimalPlaces === 0)\n\t\t\t\t\t\t\t\tlabelDecimalPlaces = yAxis.maxDecimalPlaces;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// If a chart panel, then always display at least the number of decimal places as calculated by masterData (panel.chart.decimalPlaces)\n\t\t\t\t\t\t\t// but if we are zoomed to high granularity then expand all the way out to the y-axis significant digits (panel.yAxis.printDecimalPlaces)\n\t\t\t\t\t\t\tlabelDecimalPlaces = Math.max(\n\t\t\t\t\t\t\t\tyAxis.printDecimalPlaces,\n\t\t\t\t\t\t\t\tpanel.chart.decimalPlaces\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t//\t... and never display more decimal places than the symbol is supposed to be quoting at\n\t\t\t\t\t\t\tif (yAxis.maxDecimalPlaces || yAxis.maxDecimalPlaces === 0)\n\t\t\t\t\t\t\t\tlabelDecimalPlaces = Math.min(\n\t\t\t\t\t\t\t\t\tlabelDecimalPlaces,\n\t\t\t\t\t\t\t\t\tyAxis.maxDecimalPlaces\n\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tvar dsField = null;\n\t\t\t\t\t// account for object chains\n\t\t\t\t\tvar tuple = CIQ.existsInObjectChain(data, name);\n\t\t\t\t\tif (tuple) dsField = tuple.obj[tuple.member];\n\t\t\t\t\telse if (name == \"Change\") dsField = data.Close - data.iqPrevClose;\n\n\t\t\t\t\tvar fieldName = displayName.replace(/^(Result )(.*)/, \"$2\");\n\n\t\t\t\t\tif (\n\t\t\t\t\t\tshowInterpolation &&\n\t\t\t\t\t\tfields[f].isSeries &&\n\t\t\t\t\t\t(dsField === null || typeof dsField == \"undefined\")\n\t\t\t\t\t) {\n\t\t\t\t\t\t// do this only for additional series and not the main series\n\t\t\t\t\t\tvar seriesPrice = stx.valueFromInterpolation(\n\t\t\t\t\t\t\tbar,\n\t\t\t\t\t\t\tfieldName,\n\t\t\t\t\t\t\t\"Close\",\n\t\t\t\t\t\t\tpanel,\n\t\t\t\t\t\t\tyAxis\n\t\t\t\t\t\t);\n\t\t\t\t\t\tif (seriesPrice === null) break;\n\t\t\t\t\t\tdsField = seriesPrice;\n\t\t\t\t\t}\n\t\t\t\t\tif (\n\t\t\t\t\t\t(dsField || dsField === 0) &&\n\t\t\t\t\t\t(isRecordDate ||\n\t\t\t\t\t\t\ttypeof dsField !== \"object\" ||\n\t\t\t\t\t\t\tdsField.Close ||\n\t\t\t\t\t\t\tdsField.Close === 0)\n\t\t\t\t\t) {\n\t\t\t\t\t\tvar fieldValue = \"\";\n\t\t\t\t\t\tif (dsField.Close || dsField.Close === 0) dsField = dsField.Close;\n\t\t\t\t\t\tif (dsField.constructor == Number) {\n\t\t\t\t\t\t\tif (!yAxis) {\n\t\t\t\t\t\t\t\t// raw value\n\t\t\t\t\t\t\t\tfieldValue = dsField;\n\t\t\t\t\t\t\t\tvar intl = stx.internationalizer;\n\t\t\t\t\t\t\t\tif (intl) {\n\t\t\t\t\t\t\t\t\tvar l = intl.priceFormatters.length;\n\t\t\t\t\t\t\t\t\tvar decimalPlaces = CIQ.countDecimals(fieldValue);\n\t\t\t\t\t\t\t\t\tif (decimalPlaces >= l) decimalPlaces = l - 1;\n\t\t\t\t\t\t\t\t\tfieldValue =\n\t\t\t\t\t\t\t\t\t\tintl.priceFormatters[decimalPlaces].format(fieldValue);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t} else if (\n\t\t\t\t\t\t\t\tyAxis.originalPriceFormatter &&\n\t\t\t\t\t\t\t\tyAxis.originalPriceFormatter.func\n\t\t\t\t\t\t\t) {\n\t\t\t\t\t\t\t\t// in comparison mode with custom formatter\n\t\t\t\t\t\t\t\tfieldValue = yAxis.originalPriceFormatter.func(\n\t\t\t\t\t\t\t\t\tstx,\n\t\t\t\t\t\t\t\t\tpanel,\n\t\t\t\t\t\t\t\t\tdsField,\n\t\t\t\t\t\t\t\t\tlabelDecimalPlaces\n\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t} else if (\n\t\t\t\t\t\t\t\tyAxis.priceFormatter &&\n\t\t\t\t\t\t\t\tyAxis.priceFormatter != CIQ.Comparison.priceFormat\n\t\t\t\t\t\t\t) {\n\t\t\t\t\t\t\t\t// using custom formatter\n\t\t\t\t\t\t\t\tfieldValue = yAxis.priceFormatter(\n\t\t\t\t\t\t\t\t\tstx,\n\t\t\t\t\t\t\t\t\tpanel,\n\t\t\t\t\t\t\t\t\tdsField,\n\t\t\t\t\t\t\t\t\tlabelDecimalPlaces\n\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tfieldValue = stx.formatYAxisPrice(\n\t\t\t\t\t\t\t\t\tdsField,\n\t\t\t\t\t\t\t\t\tpanel,\n\t\t\t\t\t\t\t\t\tlabelDecimalPlaces,\n\t\t\t\t\t\t\t\t\tyAxis\n\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else if (dsField.constructor == Date) {\n\t\t\t\t\t\t\tif (\n\t\t\t\t\t\t\t\tisRecordDate &&\n\t\t\t\t\t\t\t\tstx.controls.floatDate &&\n\t\t\t\t\t\t\t\tstx.controls.floatDate.innerHTML\n\t\t\t\t\t\t\t) {\n\t\t\t\t\t\t\t\tif (stx.chart.xAxis.noDraw) fieldValue = \"N/A\";\n\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\tfieldValue = CIQ.displayableDate(stx, panel.chart, dsField);\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tfieldValue = CIQ.yyyymmdd(dsField);\n\t\t\t\t\t\t\t\tif (!CIQ.ChartEngine.isDailyInterval(stx.layout.interval)) {\n\t\t\t\t\t\t\t\t\tfieldValue += \" \" + dsField.toTimeString().substr(0, 8);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tfieldValue = dsField;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tvar dedicatedField = node.querySelector(\n\t\t\t\t\t\t\t'stx-hu-tooltip-field[field=\"' + fieldName + '\"]'\n\t\t\t\t\t\t);\n\n\t\t\t\t\t\tif (dedicatedField) {\n\t\t\t\t\t\t\tdedicatedField.querySelector(\n\t\t\t\t\t\t\t\t\"stx-hu-tooltip-field-value\"\n\t\t\t\t\t\t\t).innerHTML = fieldValue;\n\t\t\t\t\t\t\tvar fieldNameField = dedicatedField.querySelector(\n\t\t\t\t\t\t\t\t\"stx-hu-tooltip-field-name\"\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\tif (fieldNameField.innerHTML === \"\") {\n\t\t\t\t\t\t\t\tfieldNameField.innerHTML = fieldName;\n\t\t\t\t\t\t\t\tif (stx.translateUI) stx.translateUI(fieldNameField);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tvar newField = document.createElement(\"stx-hu-tooltip-field\");\n\t\t\t\t\t\t\tnewField.setAttribute(\"auto\", true);\n\t\t\t\t\t\t\tvar newFieldName = document.createElement(\n\t\t\t\t\t\t\t\t\"stx-hu-tooltip-field-name\"\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\tnewFieldName.innerHTML = stx.translateIf(fieldName);\n\t\t\t\t\t\t\tnewField.appendChild(newFieldName);\n\t\t\t\t\t\t\tvar newFieldValue = document.createElement(\n\t\t\t\t\t\t\t\t\"stx-hu-tooltip-field-value\"\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\tnewFieldValue.innerHTML = fieldValue;\n\t\t\t\t\t\t\tnewField.appendChild(newFieldValue);\n\t\t\t\t\t\t\tnode.appendChild(newField);\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tvar naField = node.querySelector(\n\t\t\t\t\t\t\t'stx-hu-tooltip-field[field=\"' + fieldName + '\"]'\n\t\t\t\t\t\t);\n\t\t\t\t\t\tif (naField) {\n\t\t\t\t\t\t\tvar naFieldNameField = naField.querySelector(\n\t\t\t\t\t\t\t\t\"stx-hu-tooltip-field-name\"\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\tif (naFieldNameField.innerHTML !== \"\")\n\t\t\t\t\t\t\t\tnaField.querySelector(\"stx-hu-tooltip-field-value\").innerHTML =\n\t\t\t\t\t\t\t\t\t\"n/a\";\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tstx.huTooltip.render();\n\t\t\t}\n\n\t\t\tfunction adjustSticky(marker) {\n\t\t\t\tif (marker.node.style.left === \"-50000px\") return;\n\t\t\t\tvar mSticky = stx.controls.mSticky;\n\t\t\t\tif (mSticky && mSticky.style.display !== \"none\") {\n\t\t\t\t\tvar newTop =\n\t\t\t\t\t\tCIQ.stripPX(marker.node.style.top) -\n\t\t\t\t\t\tCIQ.elementDimensions(mSticky, {\n\t\t\t\t\t\t\tpadding: true,\n\t\t\t\t\t\t\tborder: true,\n\t\t\t\t\t\t\tmargin: true\n\t\t\t\t\t\t}).height;\n\n\t\t\t\t\tif (newTop < 0) {\n\t\t\t\t\t\tmarker.node.style.top =\n\t\t\t\t\t\t\tCIQ.stripPX(marker.node.style.top) - newTop + \"px\";\n\t\t\t\t\t\tnewTop = 0;\n\t\t\t\t\t}\n\t\t\t\t\tvar style = mSticky.style;\n\t\t\t\t\tCIQ.efficientDOMUpdate(style, \"top\", newTop + \"px\");\n\t\t\t\t\tCIQ.efficientDOMUpdate(style, \"left\", marker.node.style.left);\n\t\t\t\t\tCIQ.efficientDOMUpdate(style, \"right\", marker.node.style.right);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tcontainer.addEventListener(\"mouseout\", hideTooltip);\n\n\t\t\tstx.append(\"mousemoveinner\", function () {\n\t\t\t\tadjustSticky(this.huTooltip);\n\t\t\t});\n\n\t\t\tstx.append(\"deleteHighlighted\", function () {\n\t\t\t\tthis.huTooltip.lastBar = {};\n\t\t\t\tthis.headsUpHR();\n\t\t\t});\n\t\t\tstx.append(\"headsUpHR\", renderFunction);\n\t\t\tstx.append(\"createDataSegment\", renderFunction);\n\t\t\tstx.huTooltip = new CIQ.Marker.Tooltip({\n\t\t\t\tstx: stx,\n\t\t\t\txPositioner: \"bar\",\n\t\t\t\tchartContainer: true,\n\t\t\t\tnode: node\n\t\t\t});\n\t\t};\n}\n\n};\n\n\nlet __js_addons_advanced_animation_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Add-On that animates the chart.\n *\n * Requires *addOns.js*.\n *\n * The chart is animated in three ways:\n * 1. The current price pulsates\n * 2. The current price appears to move smoothly from the previous price\n * 3. The chart's y-axis smoothly expands/contracts when a new high or low is reached\n *\n * The following chart types are supported: line, mountain, baseline_delta.\n *\n * Chart aggregations such as Kagi, Renko, Range Bars, etc. are not supported.\n *\n * **Animation displays more gracefully when updates are sent into the chart one at a time using {@link CIQ.ChartEngine#updateChartData}\n * instead of in batches using a [QuoteFeed]{@link CIQ.ChartEngine#attachQuoteFeed}. Sending data in batches will produce a ‘jumping’ effect.**\n *\n * By default, there will be a flashing beacon created using a canvas circle. If instead you want to use a custom animation beacon, you will be able to extend the functionality yourself as follows:\n * - In js/addOns.js, at the bottom of the CIQ.Animation function, there is an stx.append(\"draw\") function.\n * - Make a copy of this function so you can override the behavior.\n * - In there you will see it determine var x and y, which are the coordinates for the center of the beacon.\n * - At the bottom of this append function, we draw the beacon by using the Canvas arc() function to draw a circle and then fill() to make the circle solid.\n * - You can replace the canvas circle with an image using [CanvasRenderingContext2D.drawImage()](https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D#Drawing_images) .\n * - Example:\n *\n * ```\n * var image = document.getElementById('beacon'); // include a hidden image on your HTML\n * context.drawImage(image, x-10, y-10, 20, 20); // add the image on the canvas. Offset the x and y values by the radius of the beacon.\n * ```\n *\n * Animation Example \n *\n * You can disable animation after each different [chart type is activated]{@link CIQ.ChartEngine#setChartType} by calling:\n * ```\n * stxx.mainSeriesRenderer.supportsAnimation=false;\n * ```\n * Keep in mind that changing to a different chart type, may once again enable animation. You can override this by [adding an event listener]{@link CIQ.ChartEngine#addEventListener} on [layout changes]{@link CIQ.ChartEngine~layoutEventListener}.\n *\n * @param {object} config The constructor parameters\n * @param {CIQ.ChartEngine} config.stx The chart object\n * @param {object} [config.animationParameters] Configuration parameters\n * @param {boolean} [config.animationParameters.stayPut=false] Set to true for last tick to stay in position it was scrolled and have rest of the chart move backwards as new ticks are added instead of having new ticks advance forward and leave the rest of the chart in place.\n * @param {number} [config.animationParameters.ticksFromEdgeOfScreen=5] Number of ticks from the right edge the chart should stop moving forward so the last tick never goes off screen (only applicable if stayPut=false)\n * @param {number} [config.animationParameters.granularity=1000000] Set to a value that will give enough granularity for the animation. The larger the number the smaller the price jump between frames, which is good for charts that need a very slow smooth animation either because the price jumps between ticks are very small, or because the animation was set up to run over a large number of frames when instantiating the CIQ.EaseMachine.\n * @param {number} [config.animationParameters.tension=null] Splining tension for smooth curves around data points (range 0-1).\n * @param {CIQ.EaseMachine} config.easeMachine Override the default easeMachine. Default is `new CIQ.EaseMachine(\"easeOutCubic\", 1000);`\n * @constructor\n * @name CIQ.Animation\n * @since\n * - 3.0.0 Now part of *addOns.js*. Previously provided as a standalone *animation.js* file.\n * - 4.0.0 Beacon only flashes for line charts. On candles or bars, it is suppressed as it produces an unnatural effect.\n * - 7.0.2 Now takes one configuration object as its constructor. Must have a reference to a chart engine.\n * @example\n * \tnew CIQ.Animation({stx: stxx, animationParameters: {tension:0.3}}); //Default animation with splining tension of 0.3\n *\n */\nCIQ.Animation =\n\tCIQ.Animation ||\n\tfunction (config) {\n\t\tif (!config) throw new Error(\"Invalid constructor arguments.\");\n\t\tvar stx, animationParameters, easeMachine;\n\t\tif (config instanceof CIQ.ChartEngine) {\n\t\t\t// legacy constructor\n\t\t\tstx = arguments[0];\n\t\t\tanimationParameters = arguments[1];\n\t\t\teaseMachine = arguments[2];\n\t\t} else {\n\t\t\tstx = config.stx;\n\t\t\tanimationParameters = config.animationParameters;\n\t\t\teaseMachine = config.easeMachine;\n\t\t}\n\t\tif (!stx)\n\t\t\treturn console.warn(\n\t\t\t\t\"No CIQ.ChartEngine provided. Cannot properly create CIQ.Animation instance\"\n\t\t\t);\n\t\tthis.cssRequired = true;\n\t\tvar params = {\n\t\t\tstayPut: false,\n\t\t\tticksFromEdgeOfScreen: 5,\n\t\t\tgranularity: 1000000\n\t\t};\n\t\tanimationParameters = CIQ.extend(params, animationParameters);\n\n\t\tif (params.tension) stx.chart.tension = animationParameters.tension;\n\t\tstx.tickAnimator = easeMachine || new CIQ.EaseMachine(\"easeOutCubic\", 1000);\n\t\tvar scrollAnimator = new CIQ.EaseMachine(\"easeInOutCubic\", 1000);\n\n\t\tvar flashingColors = [\"#0298d3\", \"#19bcfc\", \"#5dcffc\", \"#9ee3ff\"];\n\t\tvar flashingColorIndex = 0;\n\t\tvar flashingColorThrottle = 20;\n\t\tvar flashingColorThrottleCounter = 0;\n\n\t\tvar filterSession = false;\n\t\tvar nextBoundary = null;\n\n\t\tfunction initMarketSessionFlags() {\n\t\t\tfilterSession = false;\n\t\t\tnextBoundary = null;\n\t\t}\n\n\t\tif (CIQ.UI) {\n\t\t\tCIQ.UI.observeProperty(\"animation\", stx.layout, ({ value }) => {\n\t\t\t\tif (params.tension) {\n\t\t\t\t\tstx.chart.tension = value ? animationParameters.tension : 0;\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\n\t\tstx.addEventListener([\"symbolChange\", \"layout\"], function (obj) {\n\t\t\tinitMarketSessionFlags();\n\t\t});\n\n\t\tstx.prepend(\n\t\t\t\"updateCurrentMarketData\",\n\t\t\tfunction (data, chart, symbol, params) {\n\t\t\t\tif (!chart) chart = this.chart;\n\t\t\t\tif (params && params.fromTrade && chart.closePendingAnimation) {\n\t\t\t\t\tparams.finalClose = chart.closePendingAnimation.Close;\n\t\t\t\t}\n\t\t\t}\n\t\t);\n\n\t\tstx.prepend(\"updateChartData\", function (appendQuotes, chart, params) {\n\t\t\tvar self = this;\n\t\t\tif (!chart) {\n\t\t\t\tchart = self.chart;\n\t\t\t}\n\t\t\tif (\n\t\t\t\t!chart ||\n\t\t\t\t!chart.defaultChartStyleConfig ||\n\t\t\t\tchart.defaultChartStyleConfig == \"none\" ||\n\t\t\t\t!this.layout.animation\n\t\t\t) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (params !== undefined) {\n\t\t\t\tif (params.animationEntry || params.secondarySeries) return;\n\t\t\t}\n\n\t\t\tif (!chart.dataSegment) return;\n\n\t\t\tfunction completeLastBar(record) {\n\t\t\t\tif (!chart.masterData) return;\n\t\t\t\tfor (var md = chart.masterData.length - 1; md >= 0; md--) {\n\t\t\t\t\tvar bar = chart.masterData[md];\n\t\t\t\t\tif (bar.Close || bar.Close === 0) {\n\t\t\t\t\t\tbar.Close = record.Close;\n\t\t\t\t\t\tif (record.LastSize) bar.LastSize = record.LastSize;\n\t\t\t\t\t\tif (record.LastTime) bar.LastTime = record.LastTime;\n\t\t\t\t\t\t// Reset properties to close if Open, High and Low have been added and changed during animation process\n\t\t\t\t\t\tif (record.Open === undefined && bar.Open !== undefined)\n\t\t\t\t\t\t\tbar.Open = record.Close;\n\t\t\t\t\t\tif (record.High === undefined && bar.High !== undefined)\n\t\t\t\t\t\t\tbar.High = record.Close;\n\t\t\t\t\t\tif (record.Low === undefined && bar.Low !== undefined)\n\t\t\t\t\t\t\tbar.Low = record.Close;\n\n\t\t\t\t\t\tself.updateCurrentMarketData(\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tClose: bar.Close,\n\t\t\t\t\t\t\t\tDT: bar.DT,\n\t\t\t\t\t\t\t\tLastSize: bar.LastSize,\n\t\t\t\t\t\t\t\tLastTime: bar.LastTime\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\tnull,\n\t\t\t\t\t\t\tnull,\n\t\t\t\t\t\t\t{ animationLastBar: true, fromTrade: true }\n\t\t\t\t\t\t);\n\t\t\t\t\t\tself.createDataSet(null, null, { appending: true });\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tfunction unanimateScroll() {\n\t\t\t\tif (chart.animatingHorizontalScroll) {\n\t\t\t\t\tchart.animatingHorizontalScroll = false;\n\t\t\t\t\tself.micropixels = self.nextMicroPixels = self.previousMicroPixels; // <-- Reset self.nextMicroPixels here\n\t\t\t\t\tchart.lastTickOffset = 0;\n\t\t\t\t}\n\t\t\t\tif (chart.closePendingAnimation) {\n\t\t\t\t\tcompleteLastBar(chart.closePendingAnimation);\n\t\t\t\t\tchart.closePendingAnimation = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\tvar tickAnimator = self.tickAnimator;\n\t\t\t// These chart types are the only types supported by animation\n\t\t\tvar supportedChartType =\n\t\t\t\tthis.mainSeriesRenderer && this.mainSeriesRenderer.supportsAnimation;\n\t\t\tif (supportedChartType) {\n\t\t\t\tif (!tickAnimator) {\n\t\t\t\t\tconsole.warn(\n\t\t\t\t\t\t\"Animation plug-in can not run because the tickAnimator has not been declared. See instructions in animation.js\"\n\t\t\t\t\t);\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\t// If symbol changes then reset all of our variables\n\t\t\t\tif (this.prevSymbol != chart.symbol) {\n\t\t\t\t\tthis.prevQuote = 0;\n\t\t\t\t\tchart.closePendingAnimation = null;\n\t\t\t\t\tthis.prevSymbol = chart.symbol;\n\t\t\t\t}\n\t\t\t\tunanimateScroll();\n\t\t\t\ttickAnimator.stop();\n\n\t\t\t\tif (appendQuotes.length > 1) {\n\t\t\t\t\t// Only the last quote can be be animated. First add all except the last without animation\n\t\t\t\t\tvar quotesExceptLastOne = appendQuotes.splice(\n\t\t\t\t\t\t0,\n\t\t\t\t\t\tappendQuotes.length - 1\n\t\t\t\t\t);\n\t\t\t\t\tvar firstSetParams = CIQ.clone(params);\n\n\t\t\t\t\tfirstSetParams.animationEntry = true;\n\t\t\t\t\tfirstSetParams.bypassGovernor = true;\n\t\t\t\t\tfirstSetParams.noCreateDataSet = false;\n\t\t\t\t\tfirstSetParams.appending = true;\n\t\t\t\t\tself.updateChartData(quotesExceptLastOne, chart, firstSetParams);\n\t\t\t\t}\n\t\t\t}\n\t\t\tvar newParams = CIQ.clone(params);\n\t\t\tif (!newParams) newParams = {};\n\t\t\tnewParams.animationEntry = true;\n\t\t\tnewParams.bypassGovernor = true;\n\t\t\tnewParams.noCreateDataSet = false;\n\t\t\tnewParams.appending = true;\n\t\t\t//newParams.allowReplaceOHL = true;\n\t\t\tnewParams.firstLoop = true;\n\t\t\tvar symbol = this.chart.symbol;\n\t\t\tvar period = this.layout.periodicity;\n\t\t\tvar interval = this.layout.interval;\n\t\t\tvar timeUnit = this.layout.timeUnit;\n\n\t\t\tfunction cb(quote, prevQuote, chartJustAdvanced) {\n\t\t\t\treturn function (newData) {\n\t\t\t\t\tvar newClose = newData.Close;\n\t\t\t\t\tif (\n\t\t\t\t\t\t!chart.dataSet.length ||\n\t\t\t\t\t\tsymbol != chart.symbol ||\n\t\t\t\t\t\tperiod != self.layout.periodicity ||\n\t\t\t\t\t\tinterval != self.layout.interval ||\n\t\t\t\t\t\ttimeUnit != self.layout.timeUnit\n\t\t\t\t\t) {\n\t\t\t\t\t\t//console.log (\"---- STOP animating: Old\",symbol,' New : ',chart.symbol, Date())\n\t\t\t\t\t\ttickAnimator.stop();\n\t\t\t\t\t\tunanimateScroll();\n\t\t\t\t\t\treturn; // changed symbols mid animation\n\t\t\t\t\t}\n\t\t\t\t\tvar q = CIQ.clone(quote);\n\t\t\t\t\tq.Adj_Close = null; // Don't use this, it will mess up our calculated close\n\t\t\t\t\tq.Close =\n\t\t\t\t\t\tMath.round(newClose * animationParameters.granularity) /\n\t\t\t\t\t\tanimationParameters.granularity; //<<------ IMPORTANT! Use 1000000 for small price increments, otherwise animation will be in increments of .0001\n\t\t\t\t\tif (chart.animatingHorizontalScroll) {\n\t\t\t\t\t\tself.micropixels = newData.micropixels;\n\t\t\t\t\t\tchart.lastTickOffset = newData.lineOffset;\n\t\t\t\t\t}\n\t\t\t\t\tnewParams.updateDataSegmentInPlace = !tickAnimator.hasCompleted;\n\t\t\t\t\t//console.log(\"animating: Old\",symbol,' New : ',chart.symbol);\n\t\t\t\t\tvar updateQuotes = [q];\n\t\t\t\t\t// Don't include previous quote if tick mode. It will append, duplicating the quote\n\t\t\t\t\tif (chartJustAdvanced && self.layout.interval !== \"tick\")\n\t\t\t\t\t\tupdateQuotes.unshift(prevQuote);\n\t\t\t\t\tself.updateChartData(updateQuotes, chart, newParams);\n\t\t\t\t\tnewParams.firstLoop = false;\n\t\t\t\t\tif (tickAnimator.hasCompleted) {\n\t\t\t\t\t\t//console.log( 'animator has completed') ;\n\t\t\t\t\t\t//self.pendingScrollAdvance=false;\n\t\t\t\t\t\t//var possibleYAxisChange = chart.animatingHorizontalScroll;\n\t\t\t\t\t\tunanimateScroll();\n\t\t\t\t\t\t/*if (possibleYAxisChange) { // <---- Logic no longer necessary\n\t\t\t\t\t\t // After completion, one more draw for good measure in case our\n\t\t\t\t\t\t // displayed high and low have changed, which would trigger\n\t\t\t\t\t\t // the y-axis animation\n\t\t\t\t\t\t setTimeout(function(){\n\t\t\t\t\t\t self.draw();\n\t\t\t\t\t\t }, 0);\n\t\t\t\t\t\t }*/\n\t\t\t\t\t}\n\t\t\t\t};\n\t\t\t}\n\t\t\tif (supportedChartType) {\n\t\t\t\tvar quote = appendQuotes[appendQuotes.length - 1];\n\t\t\t\tthis.prevQuote = this.currentQuote(\"Close\"); // <---- prevQuote logic has been changed to prevent forward/back jitter when more than one tick comes in between animations\n\t\t\t\tvar chartJustAdvanced = false; // When advancing, we need special logic to deal with the open\n\t\t\t\tvar dontScroll = false;\n\t\t\t\tif (!self.isHome()) {\n\t\t\t\t\tdontScroll = true;\n\t\t\t\t}\n\t\t\t\tif (!quote || !quote.Close || !this.prevQuote || !this.prevQuote.Close)\n\t\t\t\t\treturn false;\n\n\t\t\t\tif (this.extendedHours && chart.market.market_def) {\n\t\t\t\t\t// Filter out unwanted sessions\n\t\t\t\t\tvar dtToFilter = quote.DT;\n\t\t\t\t\tif (CIQ.ChartEngine.isDailyInterval(interval)) {\n\t\t\t\t\t\tfilterSession = !chart.market.isMarketDate(dtToFilter);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (!nextBoundary || nextBoundary <= dtToFilter) {\n\t\t\t\t\t\t\tvar session = chart.market.getSession(dtToFilter);\n\t\t\t\t\t\t\tfilterSession =\n\t\t\t\t\t\t\t\tsession !== \"\" &&\n\t\t\t\t\t\t\t\t(!this.layout.marketSessions ||\n\t\t\t\t\t\t\t\t\t!this.layout.marketSessions[session]);\n\t\t\t\t\t\t\tnextBoundary =\n\t\t\t\t\t\t\t\tchart.market[filterSession ? \"getNextOpen\" : \"getNextClose\"](\n\t\t\t\t\t\t\t\t\tdtToFilter\n\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif (filterSession) {\n\t\t\t\t\t\tthis.draw();\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tvar barSpan = period;\n\t\t\t\tif (interval == \"second\" || timeUnit == \"second\") barSpan *= 1000;\n\t\t\t\telse if (interval == \"minute\" || timeUnit == \"minute\") barSpan *= 60000;\n\t\t\t\tif (!isNaN(interval)) barSpan *= interval;\n\t\t\t\tif (interval == \"day\" || timeUnit == \"day\")\n\t\t\t\t\tchartJustAdvanced = quote.DT.getDate() != this.prevQuote.DT.getDate();\n\t\t\t\telse if (interval == \"week\" || timeUnit == \"week\")\n\t\t\t\t\tchartJustAdvanced =\n\t\t\t\t\t\tquote.DT.getDate() >= this.prevQuote.DT.getDate() + 7;\n\t\t\t\telse if (interval == \"month\" || timeUnit == \"month\")\n\t\t\t\t\tchartJustAdvanced =\n\t\t\t\t\t\tquote.DT.getMonth() != this.prevQuote.DT.getMonth();\n\t\t\t\telse\n\t\t\t\t\tchartJustAdvanced =\n\t\t\t\t\t\tquote.DT.getTime() >= this.prevQuote.DT.getTime() + barSpan;\n\n\t\t\t\tvar linearChart =\n\t\t\t\t\t!this.mainSeriesRenderer || !this.mainSeriesRenderer.standaloneBars;\n\n\t\t\t\tvar beginningOffset = 0;\n\t\t\t\tif (chartJustAdvanced) {\n\t\t\t\t\tif (this.animations.zoom.hasCompleted) {\n\t\t\t\t\t\tvar candleWidth = this.layout.candleWidth;\n\t\t\t\t\t\tif (chart.scroll <= chart.maxTicks) {\n\t\t\t\t\t\t\twhile (this.micropixels > 0) {\n\t\t\t\t\t\t\t\t// If micropixels is larger than a candle then scroll back further\n\t\t\t\t\t\t\t\tchart.scroll++;\n\t\t\t\t\t\t\t\tthis.micropixels -= candleWidth;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbeginningOffset = candleWidth * -1;\n\t\t\t\t\t\tif (chart.scroll <= chart.maxTicks) {\n\t\t\t\t\t\t\tthis.previousMicroPixels = this.micropixels;\n\t\t\t\t\t\t\tthis.nextMicroPixels = this.micropixels + candleWidth;\n\t\t\t\t\t\t\tif (\n\t\t\t\t\t\t\t\tchart.dataSegment.length <\n\t\t\t\t\t\t\t\t\tchart.maxTicks - animationParameters.ticksFromEdgeOfScreen &&\n\t\t\t\t\t\t\t\t!animationParameters.stayPut\n\t\t\t\t\t\t\t) {\n\t\t\t\t\t\t\t\tthis.nextMicroPixels = this.micropixels;\n\t\t\t\t\t\t\t\tif (\n\t\t\t\t\t\t\t\t\tchart.scroll >=\n\t\t\t\t\t\t\t\t\tchart.maxTicks -\n\t\t\t\t\t\t\t\t\t\tthis.preferences.whitespace / this.layout.candleWidth\n\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\tchart.scroll++;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tchart.animatingHorizontalScroll = linearChart; // When the chart advances we also animate the horizontal scroll by incrementing micropixels\n\t\t\t\t\t\t\tchart.previousDataSetLength = chart.dataSet.length;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif (!dontScroll) chart.scroll++;\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tchart.closePendingAnimation = {\n\t\t\t\t\tClose: quote.Close,\n\t\t\t\t\tOpen: quote.Open,\n\t\t\t\t\tHigh: quote.High,\n\t\t\t\t\tLow: quote.Low\n\t\t\t\t};\n\n\t\t\t\tvar start =\n\t\t\t\t\tchartJustAdvanced && !linearChart ? quote.Open : this.prevQuote.Close;\n\t\t\t\ttickAnimator.run(\n\t\t\t\t\tcb(quote, CIQ.clone(this.prevQuote), chartJustAdvanced),\n\t\t\t\t\t{\n\t\t\t\t\t\tClose: start,\n\t\t\t\t\t\tmicropixels: this.nextMicroPixels,\n\t\t\t\t\t\tlineOffset: beginningOffset\n\t\t\t\t\t},\n\t\t\t\t\t{ Close: quote.Close, micropixels: this.micropixels, lineOffset: 0 }\n\t\t\t\t);\n\t\t\t\treturn true; // bypass default behavior in favor of animation\n\t\t\t}\n\t\t});\n\n\t\tstx.prepend(\"renderYAxis\", function (chart) {\n\t\t\tif (this.grabbingScreen || !this.isHome() || !this.layout.animation) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t// When display style doesn't support animation\n\t\t\tvar supportedChartType =\n\t\t\t\tthis.mainSeriesRenderer && this.mainSeriesRenderer.supportsAnimation;\n\t\t\tif (!supportedChartType) return;\n\n\t\t\tvar panel = chart.panel;\n\t\t\tvar yAxis = panel.yAxis;\n\t\t\tif (CIQ.Comparison && yAxis.priceFormatter == CIQ.Comparison.priceFormat)\n\t\t\t\treturn; // too difficult to animate y-axis change when it changes on every tick due to percentage axis on comparison\n\n\t\t\tfunction closure(self) {\n\t\t\t\treturn function (values) {\n\t\t\t\t\tchart.animatedLow = values.low;\n\t\t\t\t\tchart.animatedHigh = values.high;\n\t\t\t\t\tself.draw();\n\t\t\t\t};\n\t\t\t}\n\t\t\t// initialize prev values\n\t\t\tif (!chart.prevLowValue && chart.prevLowValue !== 0) {\n\t\t\t\tchart.prevLowValue = chart.animatedLow = chart.lowValue;\n\t\t\t}\n\t\t\tif (!chart.prevHighValue && chart.prevHighValue !== 0) {\n\t\t\t\tchart.prevHighValue = chart.animatedHigh = chart.highValue;\n\t\t\t}\n\n\t\t\t// check for a change, if so we will spin off an animation\n\t\t\tif (!scrollAnimator.running) chart.animatingVerticalScroll = false;\n\t\t\tif (\n\t\t\t\tchart.prevLowValue >= chart.lowValue &&\n\t\t\t\tchart.prevHighValue <= chart.highValue\n\t\t\t) {\n\t\t\t\tif (chart.animatingVerticalScroll) {\n\t\t\t\t\tyAxis.highValue = chart.animatedHigh;\n\t\t\t\t\tyAxis.lowValue = chart.animatedLow;\n\t\t\t\t}\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tif (scrollAnimator.running) scrollAnimator.stop();\n\t\t\tif (!chart.lowValue && !chart.highValue) return; // chart just reset, don't animate yet\n\t\t\tvar prevLow = chart.prevLowValue,\n\t\t\t\tprevHigh = chart.prevHighValue;\n\t\t\tchart.prevLowValue = chart.lowValue;\n\t\t\tchart.prevHighValue = chart.highValue;\n\t\t\tchart.animatingVerticalScroll = true;\n\t\t\tscrollAnimator.run(\n\t\t\t\tclosure(this),\n\t\t\t\t{ low: prevLow, high: prevHigh },\n\t\t\t\t{ low: chart.lowValue, high: chart.highValue }\n\t\t\t);\n\n\t\t\tyAxis.lowValue = chart.animatedLow;\n\t\t\tyAxis.highValue = chart.animatedHigh;\n\t\t});\n\n\t\t/*stx.prepend(\"draw\", function() {\n\t\t\tif(this.chart.animatingVerticalScroll) {\n\t\t\t\tthis.renderYAxis(this.chart);\n\t\t\t\treturn true;\n\t\t\t}\n\t\t});*/\n\n\t\tstx.append(\"draw\", function () {\n\t\t\tif (filterSession) return;\n\t\t\tif (\n\t\t\t\tthis.chart.dataSet &&\n\t\t\t\tthis.chart.dataSet.length &&\n\t\t\t\tthis.mainSeriesRenderer &&\n\t\t\t\tthis.mainSeriesRenderer.supportsAnimation &&\n\t\t\t\tthis.layout.animation\n\t\t\t) {\n\t\t\t\tif (flashingColorThrottleCounter % flashingColorThrottle === 0) {\n\t\t\t\t\tflashingColorIndex++;\n\t\t\t\t\tflashingColorThrottleCounter = 0;\n\t\t\t\t}\n\t\t\t\tflashingColorThrottleCounter++;\n\n\t\t\t\tvar context = this.chart.context;\n\t\t\t\tvar panel = this.chart.panel;\n\t\t\t\tvar currentQuote = this.currentQuote(\"Close\");\n\t\t\t\tif (!currentQuote) return;\n\t\t\t\tvar price = currentQuote.Close;\n\t\t\t\tvar x = this.pixelFromTick(currentQuote.tick, this.chart);\n\t\t\t\tif (this.chart.lastTickOffset) x = x + this.chart.lastTickOffset;\n\t\t\t\tvar y = this.pixelFromPrice(price, panel);\n\t\t\t\tif (\n\t\t\t\t\tthis.chart.yAxis.left > x &&\n\t\t\t\t\tthis.chart.yAxis.top <= y &&\n\t\t\t\t\tthis.chart.yAxis.bottom >= y\n\t\t\t\t) {\n\t\t\t\t\tif (flashingColorIndex >= flashingColors.length)\n\t\t\t\t\t\tflashingColorIndex = 0;\n\t\t\t\t\tcontext.beginPath();\n\t\t\t\t\tcontext.moveTo(x, y);\n\t\t\t\t\tcontext.arc(\n\t\t\t\t\t\tx,\n\t\t\t\t\t\ty,\n\t\t\t\t\t\t2 + flashingColorIndex * 1.07,\n\t\t\t\t\t\t0,\n\t\t\t\t\t\tMath.PI * 2,\n\t\t\t\t\t\tfalse\n\t\t\t\t\t);\n\t\t\t\t\tcontext.fillStyle = flashingColors[flashingColorIndex];\n\t\t\t\t\tcontext.fill();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t};\n\n/**\n * CIQ.EaseMachine interface placeholder to be augmented in *standard.js* with properties.\n *\n * @tsinterface CIQ~EaseMachine\n */\n\n};\n\n\nlet __js_addons_advanced_continuousZoom_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Add-on that responds to the chart zoom action, changing periodicities as the number of ticks and/or candle width\n * hits a set boundary.\n *\n * Although this feature is available for all chart styles, it shows best on continuous renderings\n * such as lines and mountains vs. candles and bars. This is because some users may find the\n * changes in candle width that take place as the same range is displayed in a different\n * periodicity, inappropriate. The effect can be mitigated by increasing the number of boundaries\n * so periodicities change more often, preventing large candle width changes, and by using the\n * periodicity roll up feature instead of fetching new data from a quote feed. See examples.\n *\n * See {@link CIQ.ChartEngine#setPeriodicity} and {@link CIQ.ChartEngine#createDataSet}\n *\n * Requires *addOns.js*.\n *\n * The feature will not work without supplying at least one element within the periodicities array\n * and at least one property within the boundaries object.\n *\n * @param {object} params Configuration parameters.\n * @param {CIQ.ChartEngine} params.stx The chart object.\n * @param {array} params.periodicities Set this array with eligible periodicities in any order.\n * \t\tThese will be the periodicities which will be used by the continuous zooming once a\n * \t\tboundary is hit. The periodicities are objects with `period`, `interval`, and optional\n * \t\t`timeUnit` properties (see {@link CIQ.ChartEngine#setPeriodicity}).\n * @param {object} params.boundaries Optional boundary cases to trigger the periodicity change.\n * \t\tHitting a maximum boundary switches to the next larger periodicity; hitting a minimum\n * \t\tboundary switches to the next smaller periodicity.\n * @param {number} [params.boundaries.maxCandleWidth] Largest size of candle in pixels to display\n * \t\tbefore switching periodicity.\n * @param {number} [params.boundaries.minCandleWidth] Smallest size of candle in pixels to display\n * \t\tbefore switching periodicity.\n * @param {number} [params.boundaries.maxTicks] Most number of ticks to display before switching\n * \t\tperiodicity.\n * @param {number} [params.boundaries.minTicks] Least number of ticks to display before switching\n * \t\tperiodicity.\n *\n * @constructor\n * @name CIQ.ContinuousZoom\n * @since 7.0.0\n *\n * @example\n * new CIQ.ContinuousZoom({\n * stx: stxx,\n * periodicities: [\n * { period:1, interval:\"month\" },\n * { period:1, interval:\"day\" },\n * { period:2, interval:30 },\n * { period:1, interval:5 },\n * { period:15, interval:1, timeUnit:\"second\" },\n * { period:1, interval:1, timeUnit:\"second\" }\n * ],\n * boundaries: {\n * maxCandleWidth: 100,\n * minCandleWidth: 3,\n * maxTicks: 500,\n * minTicks: 10\n * }\n * });\n *\n * @example\n * // Smother periodicity change by rolling daily into weekly and monthly.\n * // Also try reusing the same interval data and have the chart roll it instead of fetching new data.\n * stxx.dontRoll = false;\n * new CIQ.ContinuousZoom({\n * stx: stxx,\n * periodicities: [\n * // Daily interval data\n * {period:1, interval:\"month\"},\n * {period:2, interval:\"week\"},\n * {period:1, interval:\"week\"},\n * {period:3, interval:\"day\"},\n * {period:1, interval:\"day\"},\n * // 30 minute interval data\n * {period:16, interval:30},\n * {period:8, interval:30},\n * {period:4, interval:30},\n * {period:2, interval:30},\n * // one minute interval data\n * {period:30, interval:1},\n * {period:15, interval:1},\n * {period:10, interval:1},\n * {period:5, interval:1},\n * {period:2, interval:1},\n * {period:1, interval:1},\n * // One second interval data\n * {period:30,interval:1, timeUnit:\"second\"},\n * {period:15,interval:1, timeUnit:\"second\"},\n * {period:5, interval:1, timeUnit:\"second\"},\n * {period:2, interval:1, timeUnit:\"second\"},\n * {period:1, interval:1, timeUnit:\"second\"},\n * ],\n * boundaries: {\n * maxCandleWidth: 15,\n * minCandleWidth: 3\n * }\n * });\n */\nCIQ.ContinuousZoom =\n\tCIQ.ContinuousZoom ||\n\tfunction (params) {\n\t\tthis.cssRequired = true;\n\t\tthis.update(params);\n\t\tthis.stx.continuousZoom = this;\n\n\t\t//Attaches SmartZoom button to HTML DOM inside .chartSize element\n\t\tthis.addSmartZoomButton = function () {\n\t\t\t// Don't add a button if one already exists\n\t\t\tvar smartZoomButton =\n\t\t\t\tthis.stx.registerChartControl &&\n\t\t\t\tthis.stx.registerChartControl(\n\t\t\t\t\t\"stx-smart-zoom\",\n\t\t\t\t\t\"SmartZoom (Alt + 0)\",\n\t\t\t\t\t(function (self) {\n\t\t\t\t\t\treturn function (e) {\n\t\t\t\t\t\t\tself.smartZoomToggle(e);\n\t\t\t\t\t\t\te.stopPropagation();\n\t\t\t\t\t\t};\n\t\t\t\t\t})(this)\n\t\t\t\t);\n\t\t\tif (smartZoomButton) {\n\t\t\t\t// Listen for a layout changed event and refresh the toggle state of the button\n\t\t\t\tthis.stx.addEventListener(\"layout\", function (event) {\n\t\t\t\t\tif (event.stx.layout.smartzoom === true) {\n\t\t\t\t\t\tsmartZoomButton.classList.add(\"active\");\n\t\t\t\t\t} else {\n\t\t\t\t\t\tsmartZoomButton.classList.remove(\"active\");\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t\t// Piggyback off of symbolImport event to detect smartzoom set to false from layout import\n\t\t\t\tthis.stx.addEventListener(\"symbolImport\", function (event) {\n\t\t\t\t\tif (event.stx.layout.smartzoom === false)\n\t\t\t\t\t\tsmartZoomButton.classList.remove(\"active\");\n\t\t\t\t});\n\t\t\t}\n\t\t};\n\n\t\t//Click event handler for the Smart Zoom button. Sets smartzoom property of layout to its inverse\n\t\tthis.smartZoomToggle = function (e) {\n\t\t\tthis.smartZoomEnable(!this.stx.layout.smartzoom);\n\t\t};\n\n\t\t//Sets smartzoom property of layout and notifies attached ChartEngine of change\n\t\tthis.smartZoomEnable = function (state) {\n\t\t\tthis.stx.layout.smartzoom = state;\n\t\t\tthis.stx.changeOccurred(\"layout\");\n\t\t};\n\n\t\t// Add the SmartZoom button to chartControls\n\t\tthis.addSmartZoomButton();\n\t\t// Enable SmartZoom by default\n\t\tthis.smartZoomEnable(true);\n\t};\n\n/**\n * Updates continuous zoom parameters\n * @param {object} params Configuration parameters. See constructor for details\n * @memberof CIQ.ContinuousZoom\n * @since 7.0.0\n * @private\n */\nCIQ.ContinuousZoom.prototype.update = function (params) {\n\tif (!params) params = {};\n\tthis.stx = params.stx;\n\tthis.periodicities = params.periodicities;\n\tthis.boundaries = params.boundaries;\n};\n\n/**\n * Potentially performs a continuous zoom after a zoom event\n * @param {boolean} [zoomOut] True for a zoomOut operation, otherwise zoomIn\n * @memberof CIQ.ContinuousZoom\n * @since 7.0.0\n * @private\n */\nCIQ.ContinuousZoom.prototype.execute = function (zoomOut) {\n\t// assign a weight to a periodicity setting, the higher the length, the higher the weight\n\tfunction valuate(periodicity) {\n\t\tvar period = periodicity.period || periodicity.periodicity,\n\t\t\tinterval = periodicity.interval,\n\t\t\ttimeUnit = periodicity.timeUnit || \"minute\";\n\t\tif (isNaN(interval)) {\n\t\t\ttimeUnit = interval;\n\t\t\tinterval = 1;\n\t\t}\n\t\tswitch (timeUnit) {\n\t\t\tcase \"month\":\n\t\t\t\tinterval *= 4.35; /* falls through */\n\t\t\tcase \"week\":\n\t\t\t\tinterval *= 7; /* falls through */\n\t\t\tcase \"day\":\n\t\t\t\tinterval *= 1440; /* falls through */\n\t\t\tcase \"minute\":\n\t\t\t\tinterval *= 60; /* falls through */\n\t\t\tcase \"second\":\n\t\t\t\tbreak;\n\t\t\tcase \"millisecond\":\n\t\t\t\tinterval /= 1000;\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\treturn null;\n\t\t}\n\t\treturn period * interval;\n\t}\n\tif (!this.stx || !this.stx.layout.smartzoom) return;\n\tvar periodicities = this.periodicities,\n\t\tboundaries = this.boundaries,\n\t\tstx = this.stx,\n\t\tlayout = stx.layout,\n\t\tchart = stx.chart;\n\tif (!periodicities || !boundaries) return;\n\n\tif (\n\t\t(!zoomOut &&\n\t\t\tboundaries.maxCandleWidth &&\n\t\t\tlayout.candleWidth > boundaries.maxCandleWidth) ||\n\t\t(zoomOut &&\n\t\t\tboundaries.minCandleWidth &&\n\t\t\tlayout.candleWidth < boundaries.minCandleWidth) ||\n\t\t(!zoomOut && boundaries.minTicks && chart.maxTicks < boundaries.minTicks) ||\n\t\t(zoomOut && boundaries.maxTicks && chart.maxTicks > boundaries.maxTicks)\n\t) {\n\t\tvar next = { value: zoomOut ? Number.MAX_VALUE : 0 };\n\t\tvar myValue = valuate(layout);\n\t\tfor (var p = 0; p < periodicities.length; p++) {\n\t\t\tvar value = valuate(periodicities[p]);\n\t\t\tif (\n\t\t\t\t(value > myValue && value < next.value && zoomOut) ||\n\t\t\t\t(value < myValue && value > next.value && !zoomOut)\n\t\t\t) {\n\t\t\t\tnext = { value: value, periodicity: periodicities[p] };\n\t\t\t}\n\t\t}\n\t\tvar newPeriodicity = next.periodicity;\n\t\tif (newPeriodicity) {\n\t\t\tstx.setRange({\n\t\t\t\tdtLeft: chart.xaxis[0].DT,\n\t\t\t\tdtRight: chart.xaxis[chart.xaxis.length - 1].DT,\n\t\t\t\tdontSaveRangeToLayout: true,\n\t\t\t\tperiodicity: newPeriodicity,\n\t\t\t\tpadding: stx.preferences.whitespace\n\t\t\t});\n\t\t}\n\t}\n};\n\n};\n\n\nlet __js_addons_advanced_outliers_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Creates the outliers add-on which scales the y-axis to the main trend, hiding outlier\n * values. Markers are placed at the location of the outlier values enabling the user to\n * restore the full extent of the y-axis by selecting the markers.\n *\n * Outliers show/hide can be toggled using the Ctrl+Alt+O keystroke combination (see the\n * `outliers` action in `hotkeyConfig.hotkeys` in *js/defaultConfiguration.js*).\n *\n * Requires *addOns.js*.\n *\n * ![Chart with hidden outliers](./img-Chart-with-Hidden-Outliers.png \"Chart with hidden outliers\")\n *\n * @param {object} params Configuration parameters.\n * @param {CIQ.ChartEngine} [params.stx] A reference to the chart object.\n * @param {number} [params.multiplier=3] Sets the threshold for outliers by multiplying the\n * \t\tnormal data range. The default value hides only extreme outliers.\n * @param {array} [params.altColors] An array of hexadecimal color values used to style\n * \t\toutlier markers when multiple y-axes share the same panel. Markers for the first\n * \t\tadditional y-axis are styled with the value at index 0; markers for the second\n * \t\tadditional y-axis, the value at index 1; and so forth. If not provided, a default\n * \t\tarray of colors is assigned.\n * @param {string} [params.menuContextClass] A CSS class name used to query the menu DOM element\n * \t\tthat contains the UI control for the outliers add-on. In a multi-chart document, the\n * \t\tadd-on is available only on charts that have a menu DOM element with the value for\n * \t\t`menuContextClass` as a class attribute.\n *\n * @constructor\n * @name CIQ.Outliers\n * @since\n * - 7.5.0\n * - 8.0.0 Added `params.altColors` and `params.menuContextClass`.\n *\n * @example\n * new CIQ.Outliers({ stx: stxx });\n */\nCIQ.Outliers =\n\tCIQ.Outliers ||\n\tfunction (params) {\n\t\tif (!params) params = {};\n\t\tif (!params.stx) {\n\t\t\tconsole.warn(\"The Outliers addon requires an stx parameter\");\n\t\t\treturn;\n\t\t}\n\t\t// Set default marker colors\n\t\tif (!Array.isArray(params.altColors)) {\n\t\t\tparams.altColors = [\n\t\t\t\t\"#323390\",\n\t\t\t\t\"#66308f\",\n\t\t\t\t\"#0073ba\",\n\t\t\t\t\"#f4932f\",\n\t\t\t\t\"#0056a4\",\n\t\t\t\t\"#00a99c\",\n\t\t\t\t\"#00a553\",\n\t\t\t\t\"#ea1d2c\",\n\t\t\t\t\"#e9088c\",\n\t\t\t\t\"#fff126\",\n\t\t\t\t\"#912a8e\",\n\t\t\t\t\"#ee652e\",\n\t\t\t\t\"#00afed\",\n\t\t\t\t\"#8ec648\"\n\t\t\t];\n\t\t}\n\t\tthis.stx = params.stx;\n\t\tthis.stx.outliers = this;\n\t\tthis.cssRequired = true;\n\n\t\tthis.multiplier = params.multiplier || 3; // Default to 3 for extreme outliers\n\t\tthis.altColors = params.altColors;\n\n\t\tthis.axisData = {};\n\n\t\t// Listen for a layout changed event and reset the markers\n\t\tthis.stx.addEventListener(\"layout\", function (event) {\n\t\t\tObject.keys(event.stx.outliers.axisData).forEach(\n\t\t\t\tfunction (key) {\n\t\t\t\t\tthis.removeAllMarkers(this.axisData[key]);\n\t\t\t\t\tdelete this.axisData[key];\n\t\t\t\t}.bind(event.stx.outliers)\n\t\t\t);\n\t\t});\n\n\t\tif (CIQ.UI) {\n\t\t\tCIQ.UI.KeystrokeHub.addHotKeyHandler(\n\t\t\t\t\"outliers\",\n\t\t\t\t({ stx }) => {\n\t\t\t\t\tstx.container.ownerDocument.body.keystrokeHub.context.advertised.Layout.setOutliers();\n\t\t\t\t},\n\t\t\t\tthis.stx\n\t\t\t);\n\t\t}\n\n\t\t/**\n\t\t * Checks for outlier values in `dataSet`, and adds outlier markers (data point markers\n\t\t * and axis markers) to `axis`.\n\t\t *\n\t\t * @param {array} dataSet An array of objects of the form `{value: Number, quote: Object}`.\n\t\t * \t\tEach object contains a value and its associated quote. The value is checked to\n\t\t * \t\tdetermine whether it is an outlier of the data set. When checking more than one\n\t\t * \t\tvalue for a quote (such as an OHLC quote), each value is included in a separate\n\t\t * \t\tobject; for example, `[{value: open, quote: quote}, {value: high, quote: quote},\n\t\t * \t\t{value: low, quote: quote}, {value: close, quote: quote}...]`.\n\t\t * @param {object} panel The panel where `dataSet` is rendered.\n\t\t * @param {object} axis The y-axis against which `dataSet` is rendered. **Note:** Charts\n\t\t * \t\tand panels can have multiple y-axes; each y-axis has its own set of outlier\n\t\t * \t\tmarkers based on the data rendered on the axis.\n\t\t * @return {array} A tuple consisting of the outlier minimum and maximum — or trend\n\t\t * \t\tminimum and maximum, if no outliers are found — to be handled by the\n\t\t * \t\t{@link CIQ.ChartEngine#determineMinMax} method. See the return value of the\n\t\t * \t\t[find]{@link CIQ.Outliers#find} function for a description of outlier and trend\n\t\t * \t\tminimum and maximum.\n\t\t *\n\t\t * @alias processDataSet\n\t\t * @memberOf CIQ.Outliers.prototype\n\t\t * @since 8.0.0\n\t\t */\n\t\tthis.processDataSet = function (dataSet, panel, axis) {\n\t\t\tif (!dataSet.length || dataSet.length <= 1) return false;\n\n\t\t\tvar result = [0, 0]; // Min/Max-axis values to return\n\n\t\t\t// Create an axis reference if one does not exist\n\t\t\tif (!this.axisData[axis.name]) {\n\t\t\t\tvar markerColor = \"\";\n\t\t\t\tvar axisDepth = -1;\n\t\t\t\t// Check for another axis using this panel\n\t\t\t\tObject.keys(this.axisData).forEach(\n\t\t\t\t\tfunction (key) {\n\t\t\t\t\t\tif (this.axisData[key].panel.name == panel.name) {\n\t\t\t\t\t\t\taxisDepth++;\n\t\t\t\t\t\t}\n\t\t\t\t\t}.bind(this)\n\t\t\t\t);\n\t\t\t\tif (axisDepth > -1 && axisDepth < this.altColors.length)\n\t\t\t\t\tmarkerColor = this.altColors[axisDepth];\n\n\t\t\t\tthis.axisData[axis.name] = {\n\t\t\t\t\taxis: axis,\n\t\t\t\t\tpanel: panel,\n\t\t\t\t\tdisplayState: \"none\",\n\t\t\t\t\tisFlipped: false,\n\t\t\t\t\toriginalZoom: axis.zoom,\n\t\t\t\t\tmarkerColor: markerColor,\n\t\t\t\t\tmarkers: {},\n\t\t\t\t\taxisMarkers: {}\n\t\t\t\t};\n\t\t\t}\n\n\t\t\tvar currentAxis = this.axisData[axis.name];\n\t\t\t// Attach the min/max values to the current axis data\n\t\t\tObject.assign(currentAxis, this.find(dataSet));\n\n\t\t\t// Update/add necessary markers\n\t\t\tthis.refreshMarkerArray(currentAxis);\n\n\t\t\t// Update marker display and labels\n\t\t\tthis.refreshMarkers(currentAxis);\n\n\t\t\t// Return either trendMin or outlierMin based on the axis displayState\n\t\t\tif (\n\t\t\t\t(currentAxis.displayState === \"low\" ||\n\t\t\t\t\tcurrentAxis.displayState === \"all\") &&\n\t\t\t\tcurrentAxis.outlierMin !== null\n\t\t\t)\n\t\t\t\tresult[0] = currentAxis.outlierMin;\n\t\t\telse result[0] = currentAxis.trendMin;\n\t\t\t// Return either trendMax or outlierMax based on the axis displayState\n\t\t\tif (\n\t\t\t\t(currentAxis.displayState === \"high\" ||\n\t\t\t\t\tcurrentAxis.displayState === \"all\") &&\n\t\t\t\tcurrentAxis.outlierMax !== null\n\t\t\t)\n\t\t\t\tresult[1] = currentAxis.outlierMax;\n\t\t\telse result[1] = currentAxis.trendMax;\n\n\t\t\treturn result;\n\t\t};\n\n\t\t/**\n\t\t * Finds the outliers contained in `dataSet`.\n\t\t *\n\t\t * **Note:** This function may be overridden to provide a custom algorithm for finding\n\t\t * outliers.\n\t\t *\n\t\t * @param {array} dataSet An array of objects of the form `{value: Number, quote: Object}`.\n\t\t * \t\tEach object contains a value and its associated quote. The value is checked to\n\t\t * \t\tdetermine whether it is an outlier of the data set. When checking more than one\n\t\t * \t\tvalue for a quote (such as an OHLC quote), each value is included in a separate\n\t\t * \t\tobject; for example, `[{value: open, quote: quote}, {value: high, quote: quote},\n\t\t * \t\t{value: low, quote: quote}, {value: close, quote: quote}...]`.\n\t\t * @return {object} An object of the form:\n\t\t * ```\n\t\t * {\n\t\t * \t// Minimum and maximum threshold values of dataSet to be considered an outlier.\n\t\t * \tminValue: null,\n\t\t * \tmaxValue: null,\n\t\t * \t// Mininum and maximum values of dataSet that are not considered outliers.\n\t\t * \t// Will be the least and greatest values in dataSet if no outliers are found.\n\t\t * \ttrendMin: null,\n\t\t * \ttrendMax: null,\n\t\t * \t// Minimum and maximum values of dataSet that are considered outliers.\n\t\t * \t// Will remain null if no outliers are found.\n\t\t * \toutlierMin: null,\n\t\t * \toutlierMax: null,\n\t\t * \t// Array of individual outlier information for marker placement, in the format {DT:DateTime, value:Number, position:String}\n\t\t * \t// (position is either 'high' or 'low').\n\t\t * \tactiveOutliers: []\n\t\t * }\n\t\t * ```\n\t\t *\n\t\t * @alias find\n\t\t * @memberOf CIQ.Outliers.prototype\n\t\t * @since\n\t\t * - 7.5.0\n\t\t * - 8.0.0 Added return value.\n\t\t */\n\t\tthis.find = function (dataSet) {\n\t\t\tif (!dataSet.length || dataSet.length <= 0) return;\n\n\t\t\tvar createMarkerPlaceholder = function (data, position) {\n\t\t\t\treturn {\n\t\t\t\t\tquote: data.quote,\n\t\t\t\t\tDT: data.quote.DT,\n\t\t\t\t\tvalue: data.value,\n\t\t\t\t\tposition: position\n\t\t\t\t};\n\t\t\t};\n\n\t\t\t// The minimum and maximum threshold values to be considered an outlier.\n\t\t\tvar minValue = null;\n\t\t\tvar maxValue = null;\n\t\t\t// min/max values of available data that are not considered outliers. Will be the least and greatest values in the available data if no outliers are found.\n\t\t\tvar trendMin = null;\n\t\t\tvar trendMax = null;\n\t\t\t// min/max values of available data that are considered outliers. Will remain null if no outlier is found.\n\t\t\tvar outlierMin = null;\n\t\t\tvar outlierMax = null;\n\t\t\t// Array of outlier information in the format\n\t\t\t// {DT:DateTime, value:Number, position:String}\n\t\t\tvar activeOutliers = [];\n\n\t\t\tvar dataSorted = dataSet.slice();\n\t\t\tdataSorted.sort(function (a, b) {\n\t\t\t\treturn a.value - b.value;\n\t\t\t});\n\t\t\tvar dataLength = dataSorted.length;\n\n\t\t\t// Outlier threshold values are defined as more than the interquartile range above the third quartile\n\t\t\t// or below the first quartile, of the sorted dataSet, multiplied by the value of the\n\t\t\t// stxx.outlierMultiplier property.\n\t\t\tvar q1 = dataSorted[Math.floor(dataLength / 4)].value;\n\t\t\tvar q3 = dataSorted[Math.floor(dataLength * (3 / 4))].value;\n\t\t\tvar iqr = q3 - q1;\n\n\t\t\tminValue = q1 - iqr * this.multiplier;\n\t\t\tmaxValue = q3 + iqr * this.multiplier;\n\n\t\t\t// Loop through the sorted data and find the outliers as well as the trend min/max\n\t\t\tfor (var idx = 0; idx < dataLength; idx++) {\n\t\t\t\t// Attack the array from both ends\n\t\t\t\tvar dataLow = dataSorted[idx];\n\t\t\t\tvar dataHigh = dataSorted[dataLength - (idx + 1)];\n\n\t\t\t\t// Find and mark outliers. Existing merkers will be refreshed in setMarker.\n\t\t\t\tif (dataLow.value <= minValue)\n\t\t\t\t\tactiveOutliers.push(createMarkerPlaceholder(dataLow, \"low\"));\n\t\t\t\tif (dataHigh.value >= maxValue)\n\t\t\t\t\tactiveOutliers.push(createMarkerPlaceholder(dataHigh, \"high\"));\n\n\t\t\t\t// Find the first low value that's less than or equal to outlier threshold min\n\t\t\t\tif (outlierMin === null && dataLow.value <= minValue)\n\t\t\t\t\toutlierMin = dataLow.value;\n\t\t\t\t// Find the first high value that's greater than or equal to outlier threshold max\n\t\t\t\tif (outlierMax === null && dataHigh.value >= maxValue)\n\t\t\t\t\toutlierMax = dataHigh.value;\n\n\t\t\t\t// Find the first low value that's greater than the outlier threshold min\n\t\t\t\tif (trendMin === null && dataLow.value > minValue)\n\t\t\t\t\ttrendMin = dataLow.value;\n\t\t\t\t// Find the first high value that's less than the outlier threshold max\n\t\t\t\tif (trendMax === null && dataHigh.value < maxValue)\n\t\t\t\t\ttrendMax = dataHigh.value;\n\n\t\t\t\t// No need to loop through the entire array. Once the trend min/max are found we're done.\n\t\t\t\tif (trendMin !== null && trendMax !== null) break;\n\t\t\t}\n\n\t\t\treturn {\n\t\t\t\tminValue: minValue,\n\t\t\t\tmaxValue: maxValue,\n\t\t\t\ttrendMin: trendMin,\n\t\t\t\ttrendMax: trendMax,\n\t\t\t\toutlierMin: outlierMin,\n\t\t\t\toutlierMax: outlierMax,\n\t\t\t\tactiveOutliers: activeOutliers\n\t\t\t};\n\t\t};\n\n\t\t/**\n\t\t * Updates the freshness status of outlier markers belonging to `targetAxis`.\n\t\t *\n\t\t * Sets the status to fresh if the markers represent data points in the `activeOutliers`\n\t\t * list of `targetAxis` or a marker is an axis marker for high or low outliers and high or\n\t\t * low outliers exist. (See the return value of the [find]{@link CIQ.Outliers#find}\n\t\t * function for a description of the `activeOutliers` list.)\n\t\t *\n\t\t * Adds new markers to `targetAxis` for data points in the `activeOutliers` list not\n\t\t * already represented by a marker (see [markOutlier]{@link CIQ.Outliers#markOutlier}).\n\t\t * Adds new axis markers if the data set rendered on `targetAxis` contains high or low\n\t\t * outliers and the respective axis marker does not exist (see\n\t\t * [markAxis]{@link CIQ.Outliers#markAxis}).\n\t\t *\n\t\t * Sets the status of all other markers belonging to `targetAxis` to stale, or unfresh\n\t\t * (these markers are ultimately removed).\n\t\t *\n\t\t * @param {object} targetAxis The y-axis for which the markers are refreshed.\n\t\t * \t\t**Note:** Charts and panels can have multiple y-axes, each with its own array of\n\t\t * \t\toutlier markers.\n\t\t *\n\t\t * @alias refreshMarkerArray\n\t\t * @memberOf CIQ.Outliers.prototype\n\t\t * @since 8.0.0\n\t\t */\n\t\tthis.refreshMarkerArray = function (targetAxis) {\n\t\t\tthis.deprecateMarkers(targetAxis); // If a marker isn't refreshed below, it will be deleted in the next call\n\n\t\t\tvar targetMarkers = targetAxis.markers;\n\t\t\ttargetAxis.activeOutliers.forEach(\n\t\t\t\tfunction (outlier) {\n\t\t\t\t\tvar quoteTime = outlier.DT.getTime().toString();\n\t\t\t\t\t// Add a quote marker if there isn't one already\n\t\t\t\t\tif (!targetMarkers[quoteTime]) {\n\t\t\t\t\t\ttargetMarkers[quoteTime] = {\n\t\t\t\t\t\t\tisFresh: true,\n\t\t\t\t\t\t\ttype: \"quote\",\n\t\t\t\t\t\t\tvalue: outlier.value,\n\t\t\t\t\t\t\tmarker: this.markOutlier(outlier, outlier.position, targetAxis)\n\t\t\t\t\t\t};\n\t\t\t\t\t}\n\t\t\t\t\t// Always refresh the status of the marker\n\t\t\t\t\ttargetMarkers[quoteTime].isFresh = true;\n\t\t\t\t}.bind(this)\n\t\t\t);\n\t\t\tif (targetAxis.outlierMax !== null) {\n\t\t\t\t// Add the high axis marker if there isn't one\n\t\t\t\tif (!targetMarkers.axisHigh) {\n\t\t\t\t\ttargetMarkers.axisHigh = {\n\t\t\t\t\t\tisFresh: true,\n\t\t\t\t\t\ttype: \"axis\",\n\t\t\t\t\t\tvalue: targetAxis.outlierMax,\n\t\t\t\t\t\tmarker: this.markAxis(\"high\", targetAxis)\n\t\t\t\t\t};\n\t\t\t\t}\n\t\t\t\t// Always refresh the status of the marker\n\t\t\t\ttargetMarkers.axisHigh.isFresh = true;\n\t\t\t}\n\t\t\tif (targetAxis.outlierMin !== null) {\n\t\t\t\t// Add the low axis marker if there isn't one\n\t\t\t\tif (!targetMarkers.axisLow) {\n\t\t\t\t\ttargetMarkers.axisLow = {\n\t\t\t\t\t\tisFresh: true,\n\t\t\t\t\t\ttype: \"axis\",\n\t\t\t\t\t\tvalue: targetAxis.outlierMin,\n\t\t\t\t\t\tmarker: this.markAxis(\"low\", targetAxis)\n\t\t\t\t\t};\n\t\t\t\t}\n\t\t\t\t// Always refresh the status of the marker\n\t\t\t\ttargetMarkers.axisLow.isFresh = true;\n\t\t\t}\n\t\t};\n\n\t\t/**\n\t\t * Sets the outlier display state, which determines whether to display outlier markers.\n\t\t *\n\t\t * @param {string} newState The intended display state; should be one of:\n\t\t *
    \n\t\t *\t\t
  • \"high\" — Show high outliers; hide high outlier markers.
  • \n\t\t *\t\t
  • \"low\" — Show low outliers; hide low outlier markers.
  • \n\t\t *\t\t
  • \"all\" — Show high and low outliers; hide high and low outlier markers.
  • \n\t\t *\t\t
  • \"none\" — Hide high and low outliers; show high and low outlier markers.
  • \n\t\t *
\n\t\t * If none of the above is provided, \"none\" is assumed.\n\t\t * @param {object} targetAxis The y-axis on which the outlier state is set. **Note:** A\n\t\t * \t\tchart or panel can have multiple y-axes.\n\t\t *\n\t\t * @alias setDisplayState\n\t\t * @memberOf CIQ.Outliers.prototype\n\t\t * @since\n\t\t * - 7.5.0\n\t\t * - 8.0.0 Added `targetAxis` parameter.\n\t\t */\n\t\tthis.setDisplayState = function (newState, targetAxis) {\n\t\t\tif (newState != \"high\" && newState != \"low\" && newState != \"all\")\n\t\t\t\tnewState = \"none\";\n\n\t\t\tvar displayState = newState;\n\t\t\t// Set the value of displayState to show the intended state, based on its existing state. This\n\t\t\t// allows the markers to toggle between states without concern for what is currently displayed.\n\t\t\t// For example: if the current display state is showing low outlier only, and the intent is to\n\t\t\t// now display high outliers as well, then the display state will change to 'all'.\n\t\t\t// This will toggle the high/low state off as well.\n\t\t\tif (targetAxis.displayState == \"all\" && newState == \"high\")\n\t\t\t\tdisplayState = \"low\";\n\t\t\telse if (targetAxis.displayState == \"all\" && newState == \"low\")\n\t\t\t\tdisplayState = \"high\";\n\t\t\telse if (targetAxis.displayState == \"high\" && newState == \"low\")\n\t\t\t\tdisplayState = \"all\";\n\t\t\telse if (targetAxis.displayState == \"low\" && newState == \"high\")\n\t\t\t\tdisplayState = \"all\";\n\t\t\telse if (targetAxis.displayState == newState) displayState = \"none\";\n\n\t\t\ttargetAxis.displayState = displayState;\n\t\t\t// Reset the axis zoom state\n\t\t\ttargetAxis.axis.zoom = targetAxis.originalZoom;\n\n\t\t\tthis.refreshMarkers(targetAxis);\n\t\t\tthis.stx.draw();\n\t\t};\n\n\t\t/**\n\t\t * Removes all markers from `targetAxis` that are no longer fresh; that is, markers that\n\t\t * do not represent data points in the current data set, or axis markers that are\n\t\t * irrelevant because high or low outliers no longer exist. Sets the status of all\n\t\t * remaining outlier markers to stale, or not fresh (the freshness status should\n\t\t * subsequently be reevaluated).\n\t\t *\n\t\t * @param {object} targetAxis The y-axis for which the markers are deprecated. **Note:**\n\t\t * \t\tA chart or panel can have multiple y-axes; each y-axis has its own outlier\n\t\t * \t\tmarkers based on the data rendered on the axis.\n\t\t *\n\t\t * @alias deprecateMarkers\n\t\t * @memberOf CIQ.Outliers.prototype\n\t\t * @since\n\t\t * - 7.5.0\n\t\t * - 8.0.0 Added `targetAxis` parameter.\n\t\t */\n\t\tthis.deprecateMarkers = function (targetAxis) {\n\t\t\tvar removeMarker = function (marker) {\n\t\t\t\tif (marker.marker && !marker.isFresh) {\n\t\t\t\t\tif (marker.marker.remove) marker.marker.remove();\n\t\t\t\t\tmarker.marker = null;\n\t\t\t\t} else {\n\t\t\t\t\tmarker.isFresh = false;\n\t\t\t\t}\n\t\t\t};\n\n\t\t\t// Handle the outlier markers\n\t\t\tObject.keys(targetAxis.markers).forEach(\n\t\t\t\tfunction (key) {\n\t\t\t\t\tremoveMarker(this.markers[key]);\n\t\t\t\t\t// Remove the marker property if its marker has been removed\n\t\t\t\t\tif (!this.markers[key].marker) {\n\t\t\t\t\t\tdelete this.markers[key];\n\t\t\t\t\t}\n\t\t\t\t}.bind(targetAxis)\n\t\t\t);\n\t\t};\n\n\t\t/**\n\t\t * Removes all outlier markers from `targetAxis`, including data point markers and y-axis\n\t\t * markers.\n\t\t *\n\t\t * @param {object} targetAxis The y-axis from which the markers are removed. **Note:**\n\t\t * \t\tCharts and panels can have multiple y-axes, each with its own outlier markers.\n\t\t *\n\t\t * @alias removeAllMarkers\n\t\t * @memberOf CIQ.Outliers.prototype\n\t\t * @since\n\t\t * - 7.5.0\n\t\t * - 8.0.0 Added `targetAxis` parameter.\n\t\t */\n\t\tthis.removeAllMarkers = function (targetAxis) {\n\t\t\tObject.keys(targetAxis.markers).forEach(function (key) {\n\t\t\t\tvar targetMarker = targetAxis.markers[key].marker;\n\t\t\t\tif (targetMarker) {\n\t\t\t\t\tif (targetMarker.remove) targetMarker.remove();\n\t\t\t\t\ttargetMarker = null;\n\t\t\t\t}\n\t\t\t\t// Remove the marker property if its marker has been removed\n\t\t\t\tif (!targetMarker) {\n\t\t\t\t\tdelete targetAxis.markers[key];\n\t\t\t\t}\n\t\t\t});\n\t\t};\n\n\t\t/**\n\t\t * Shows or hides outlier markers based on the display state.\n\t\t *\n\t\t * See [setDisplayState]{@link CIQ.Outliers#setDisplayState}.\n\t\t *\n\t\t * @alias updateMarkerVisibility\n\t\t * @memberOf CIQ.Outliers.prototype\n\t\t * @since 7.5.0\n\t\t */\n\t\tthis.updateMarkerVisibility = function () {\n\t\t\tObject.keys(this.markers).forEach(\n\t\t\t\tfunction (key) {\n\t\t\t\t\tif (\n\t\t\t\t\t\tthis.displayState == \"all\" ||\n\t\t\t\t\t\tthis.markers[key].marker.node.classList.contains(this.displayState)\n\t\t\t\t\t)\n\t\t\t\t\t\tthis.markers[key].marker.node.style.display = \"none\";\n\t\t\t\t\telse this.markers[key].marker.node.style.display = \"block\";\n\t\t\t\t}.bind(this)\n\t\t\t);\n\t\t};\n\n\t\t/**\n\t\t * Updates the position of the axis outlier marker represented by `node`.\n\t\t *\n\t\t * @param {HTMLElement} node The axis marker to position.\n\t\t * @param {object} targetAxis The y-axis on which the axis marker is positioned.\n\t\t *\n\t\t * @alias refreshAxisMarkers\n\t\t * @memberOf CIQ.Outliers.prototype\n\t\t * @since\n\t\t * - 7.5.0\n\t\t * - 8.0.0 Added `targetAxis` parameter.\n\t\t */\n\t\tthis.refreshAxisMarkers = function (node, targetAxis) {\n\t\t\tvar isHigh = false;\n\t\t\tvar positionClass = \"low\";\n\t\t\tif (node.classList.contains(\"high\")) {\n\t\t\t\tisHigh = true;\n\t\t\t\tpositionClass = \"high\";\n\t\t\t}\n\t\t\tvar posTop = targetAxis.axis.top;\n\t\t\t// Set the low marker of reverse the value if the axis is flipped\n\t\t\tif (\n\t\t\t\t(!targetAxis.isFlipped && !isHigh) ||\n\t\t\t\t(targetAxis.isFlipped && isHigh)\n\t\t\t) {\n\t\t\t\tposTop = targetAxis.axis.bottom - 50;\n\t\t\t}\n\t\t\t// Overlap the markers in the center for nano size because it's all or nothing at that size.\n\t\t\tif (node.classList.contains(\"nano\")) {\n\t\t\t\tposTop = targetAxis.axis.top + targetAxis.axis.height / 2 - 22;\n\t\t\t}\n\n\t\t\tvar xFormLeft = Math.floor(targetAxis.axis.left).toString() + \"px\";\n\t\t\tvar xFormTop = Math.floor(posTop).toString() + \"px\";\n\t\t\t// Use the vlaue property instead\n\t\t\tvar labelPrice = isHigh ? targetAxis.outlierMax : targetAxis.outlierMin;\n\n\t\t\t// Set marker positioning relative to the y-axis\n\t\t\tnode.style.transform = \"translate(\" + xFormLeft + \", \" + xFormTop + \")\";\n\t\t\tnode.querySelector(\".outlier-value\").innerText =\n\t\t\t\tthis.stx.formatYAxisPrice(labelPrice);\n\t\t\t// Apply .right class when axis is on the left to right position child elements\n\t\t\tif (xFormLeft === \"0px\") node.classList.add(\"right\");\n\t\t\telse node.classList.remove(\"right\");\n\t\t};\n\n\t\t/**\n\t\t * Updates the display styles of all outlier markers belonging to `targetAxis`, including\n\t\t * data point markers and axis markers. Shows the markers if outliers are hidden and the\n\t\t * marked outliers exceed the bounds of `targetAxis`. Flips the markers if `targetAxis`\n\t\t * has been inverted (see [flipMarkers]{@link CIQ.Outliers#flipMarkers}).\n\t\t *\n\t\t * @param {object} targetAxis The y-axis on which the markers are refreshed. **Note:**\n\t\t * \t\tCharts and panels can have multiple y-axes, each with its own outlier markers.\n\t\t *\n\t\t * @alias refreshMarkers\n\t\t * @memberOf CIQ.Outliers.prototype\n\t\t * @since 8.0.0\n\t\t */\n\t\tthis.refreshMarkers = function (targetAxis) {\n\t\t\tObject.keys(targetAxis.markers).forEach(\n\t\t\t\tfunction (targetAxis, key) {\n\t\t\t\t\tvar targetMarker = targetAxis.markers[key].marker;\n\t\t\t\t\tvar targetValue = targetAxis.markers[key].value;\n\t\t\t\t\tvar targetType = targetAxis.markers[key].type;\n\t\t\t\t\t// Check the marker value against the actual axis min/max. This accounts for yaxis scaling\n\t\t\t\t\t// in addition to the outlier display state.\n\t\t\t\t\tif (\n\t\t\t\t\t\t(targetValue > targetAxis.trendMax &&\n\t\t\t\t\t\t\ttargetAxis.axis.high >= targetValue) ||\n\t\t\t\t\t\t(targetValue < targetAxis.trendMin &&\n\t\t\t\t\t\t\ttargetAxis.axis.low <= targetValue)\n\t\t\t\t\t) {\n\t\t\t\t\t\tif (targetType == \"quote\") {\n\t\t\t\t\t\t\ttargetMarker.node.style.display = \"none\";\n\t\t\t\t\t\t} else if (targetType == \"axis\") {\n\t\t\t\t\t\t\ttargetMarker.node.classList.add(\"compress\");\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (targetType == \"quote\") {\n\t\t\t\t\t\t\ttargetMarker.node.style.display = \"block\";\n\t\t\t\t\t\t} else if (targetType == \"axis\") {\n\t\t\t\t\t\t\ttargetMarker.node.classList.remove(\"compress\");\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif (targetType == \"axis\") {\n\t\t\t\t\t\tthis.refreshAxisMarkers(targetMarker.node, targetAxis);\n\t\t\t\t\t}\n\n\t\t\t\t\t// Update the marker responsive style\n\t\t\t\t\tif (targetAxis.axis.height < 100)\n\t\t\t\t\t\ttargetMarker.node.classList.add(\"nano\");\n\t\t\t\t\telse targetMarker.node.classList.remove(\"nano\");\n\n\t\t\t\t\tif (targetAxis.axis.height < 250)\n\t\t\t\t\t\ttargetMarker.node.classList.add(\"micro\");\n\t\t\t\t\telse targetMarker.node.classList.remove(\"micro\");\n\t\t\t\t}.bind(this, targetAxis)\n\t\t\t);\n\n\t\t\t// Check for a change in the flipped state of the axis\n\t\t\tif (targetAxis.isFlipped !== targetAxis.axis.flipped)\n\t\t\t\tthis.flipMarkers(targetAxis);\n\t\t};\n\n\t\t/**\n\t\t * Places markers on the y-axis when high or low outliers exist.\n\t\t *\n\t\t * @param {string} position The position of the marker; either \"high\" or \"low\". If the\n\t\t * \t\tposition is \"high\", the marker is placed at the top of the axis; if \"low\", at the\n\t\t * \t\tbottom of the axis.\n\t\t * @param {object} targetAxis The y-axis on which the markers are placed. **Note:**\n\t\t * \t\tCharts and panels can have multiple y-axes, each with its own outlier markers.\n\t\t * @return {CIQ.Marker} The axis outlier marker, which is added to the display.\n\t\t *\n\t\t * @alias markAxis\n\t\t * @memberOf CIQ.Outliers.prototype\n\t\t * @since\n\t\t * - 7.5.0\n\t\t * - 8.0.0 Added `position` and `targetAxis` parameters and return value.\n\t\t */\n\t\tthis.markAxis = function (position, targetAxis) {\n\t\t\t// Create a marker positioned on the y-axis and return it.\n\t\t\tvar axisMarker = document.createElement(\"div\");\n\t\t\taxisMarker.classList.add(\"outlier-sticker\", \"axis\", \"mini\", position);\n\t\t\taxisMarker.innerHTML =\n\t\t\t\t'
';\n\n\t\t\tthis.matchYAxisStyle(axisMarker);\n\t\t\tthis.setMarkerColor(axisMarker, targetAxis.markerColor);\n\n\t\t\tvar activate = this.handleMarkerClick.bind(\n\t\t\t\tthis,\n\t\t\t\tposition,\n\t\t\t\ttargetAxis,\n\t\t\t\taxisMarker\n\t\t\t);\n\t\t\taxisMarker.addEventListener(\"click\", activate);\n\t\t\taxisMarker.addEventListener(\"touchend\", activate);\n\n\t\t\treturn new CIQ.Marker({\n\t\t\t\tstx: this.stx,\n\t\t\t\txPositioner: \"none\",\n\t\t\t\tyPositioner: \"none\",\n\t\t\t\tlabel: \"expand\",\n\t\t\t\tpermanent: true,\n\t\t\t\tchartContainer: true,\n\t\t\t\tnode: axisMarker\n\t\t\t});\n\t\t};\n\n\t\t/**\n\t\t * Adds an outlier marker to a tick (data point).\n\t\t *\n\t\t * @param {object} data Represents the tick that is marked as an outlier. Contains the\n\t\t * \t\toutlier value and its associated quote; for example,\n\t\t * \t\t`{value: Number, quote: Object}`.\n\t\t * @param {string} position The position of the marker; either \"high\" or \"low\". If the\n\t\t * \t\tposition is \"high\", the marker is placed at the top of the chart; if \"low\", at the\n\t\t * \t\tbottom of the chart.\n\t\t * @param {object} targetAxis The y-axis to which the marker is added. **Note:** A chart\n\t\t * \t\tor panel can have multiple y-axes; each y-axis has its own outlier markers.\n\t\t * @return {CIQ.Marker} The outlier marker, which is added to the display.\n\t\t *\n\t\t * @alias markOutlier\n\t\t * @memberOf CIQ.Outliers.prototype\n\t\t * @since\n\t\t * - 7.5.0\n\t\t * - 8.0.0 Added `targetAxis` parameter.\n\t\t */\n\t\tthis.markOutlier = function (data, position, targetAxis) {\n\t\t\tif (!data) return;\n\t\t\tif (!targetAxis) targetAxis = { panel: this.stx.panels.chart };\n\t\t\tposition = position || \"high\";\n\n\t\t\t// Create a marker\n\t\t\tvar outlierMarker = document.createElement(\"div\");\n\t\t\toutlierMarker.classList.add(\"outlier-sticker\", \"quote\", \"mini\", position);\n\t\t\toutlierMarker.innerHTML =\n\t\t\t\t'
' +\n\t\t\t\tthis.stx.formatYAxisPrice(data.value, targetAxis.panel) +\n\t\t\t\t\"\";\n\n\t\t\tthis.matchYAxisStyle(outlierMarker);\n\t\t\tthis.setMarkerColor(outlierMarker, targetAxis.markerColor);\n\n\t\t\tvar activate = this.handleMarkerClick.bind(\n\t\t\t\tthis,\n\t\t\t\tposition,\n\t\t\t\ttargetAxis,\n\t\t\t\toutlierMarker\n\t\t\t);\n\t\t\toutlierMarker.addEventListener(\"click\", activate);\n\t\t\toutlierMarker.addEventListener(\"touchend\", activate);\n\n\t\t\treturn new CIQ.Marker({\n\t\t\t\tstx: this.stx,\n\t\t\t\txPositioner: \"date\",\n\t\t\t\tyPositioner: position == \"high\" ? \"top\" : \"bottom\",\n\t\t\t\tx: data.quote.DT,\n\t\t\t\tpanelName: targetAxis.panel.name,\n\t\t\t\tnode: outlierMarker\n\t\t\t});\n\t\t};\n\n\t\t/**\n\t\t * Calls [setDisplayState]{@link CIQ.Outliers#setDisplayState} in response to selecting an\n\t\t * outlier marker.\n\t\t *\n\t\t * @param {string} position The position of the marker; either \"high\" or \"low\".\n\t\t * @param {object} targetAxis The y-axis that contains the selected marker. **Note:**\n\t\t * \t\tCharts and panels can have multiple y-axes; each y-axis has its own outlier\n\t\t * \t\tmarkers.\n\t\t * @param {HTMLElement} targetNode The selected outlier marker DOM node.\n\t\t *\n\t\t * @alias handleMarkerClick\n\t\t * @memberOf CIQ.Outliers.prototype\n\t\t * @since 8.0.0\n\t\t */\n\t\tthis.handleMarkerClick = function (position, targetAxis, targetNode) {\n\t\t\tif (targetNode.classList.contains(\"nano\")) position = \"all\"; // not concerned about differentiation between high and low at the nano size\n\t\t\tthis.setDisplayState(position, targetAxis);\n\t\t\tthis.stx.draw();\n\t\t};\n\n\t\t/**\n\t\t * Sets the CSS style properties of the y-axis outlier marker to match the CSS styling of\n\t\t * the y-axis itself.\n\t\t *\n\t\t * @param {HTMLElement} node The y-axis marker to style.\n\t\t *\n\t\t * @alias matchYAxisStyle\n\t\t * @memberOf CIQ.Outliers.prototype\n\t\t * @since 7.5.0\n\t\t */\n\t\tthis.matchYAxisStyle = function (node) {\n\t\t\t// Apply styles from the yAxis\n\t\t\tif (this.stx.styles.stx_yaxis) {\n\t\t\t\tvar styles = this.stx.styles.stx_yaxis;\n\t\t\t\tnode.style.fontSize = styles.fontSize;\n\t\t\t\tnode.style.fontFamily = styles.fontFamily;\n\t\t\t\tnode.style.color = styles.color;\n\t\t\t\tnode.style.borderColor = styles.color;\n\t\t\t}\n\t\t};\n\n\t\t/**\n\t\t * Applies a background color to an outlier data point marker.\n\t\t *\n\t\t * @param {HTMLElement} node The outlier marker DOM node to which the background color is\n\t\t * \t\tapplied.\n\t\t * @param {string} color The hexadecimal color value set as the node background color.\n\t\t *\n\t\t * @alias setMarkerColor\n\t\t * @memberOf CIQ.Outliers.prototype\n\t\t * @since 8.0.0\n\t\t */\n\t\tthis.setMarkerColor = function (node, color) {\n\t\t\tif (color == \"\") return;\n\t\t\t//Set marker color\n\t\t\tvar markerPills = node.querySelectorAll(\".pill\");\n\t\t\tfor (var markerIdx = 0; markerIdx < markerPills.length; markerIdx++) {\n\t\t\t\tmarkerPills[markerIdx].style.backgroundColor = color;\n\t\t\t}\n\t\t};\n\n\t\t/**\n\t\t * Repositions outlier markers from the top of the display to the bottom (or vice versa)\n\t\t * when the associated y-axis has been flipped (inverted).\n\t\t *\n\t\t * @param {object} targetAxis The y-axis that has been flipped.\n\t\t *\n\t\t * @alias flipMarkers\n\t\t * @memberOf CIQ.Outliers.prototype\n\t\t * @since 8.0.0\n\t\t */\n\t\tthis.flipMarkers = function (targetAxis) {\n\t\t\ttargetAxis.isFlipped = targetAxis.axis.flipped;\n\n\t\t\tObject.keys(targetAxis.markers).forEach(\n\t\t\t\tfunction (targetAxis, key) {\n\t\t\t\t\tvar targetMarker = targetAxis.markers[key].marker;\n\t\t\t\t\tvar targetValue = targetAxis.markers[key].value;\n\t\t\t\t\tvar targetType = targetAxis.markers[key].type;\n\t\t\t\t\t// Check for flipped state and add/remove flipped class\n\t\t\t\t\tif (targetAxis.isFlipped) {\n\t\t\t\t\t\ttargetMarker.node.classList.add(\"flipped\");\n\t\t\t\t\t} else {\n\t\t\t\t\t\ttargetMarker.node.classList.remove(\"flipped\");\n\t\t\t\t\t}\n\n\t\t\t\t\t// Set Y positioning of quote markers\n\t\t\t\t\tif (targetType == \"quote\") {\n\t\t\t\t\t\tif (targetValue > targetAxis.trendMax) {\n\t\t\t\t\t\t\t// High marker\n\t\t\t\t\t\t\tif (targetAxis.isFlipped)\n\t\t\t\t\t\t\t\ttargetMarker.params.yPositioner = \"bottom\";\n\t\t\t\t\t\t\telse targetMarker.params.yPositioner = \"top\";\n\t\t\t\t\t\t} else if (targetValue < targetAxis.trendMin) {\n\t\t\t\t\t\t\t// Low marker\n\t\t\t\t\t\t\tif (targetAxis.isFlipped) targetMarker.params.yPositioner = \"top\";\n\t\t\t\t\t\t\telse targetMarker.params.yPositioner = \"bottom\";\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}.bind(this, targetAxis)\n\t\t\t);\n\t\t};\n\n\t\tvar originalDetermineMinMax =\n\t\t\tCIQ.ChartEngine.prototype.determineMinMax.bind(this.stx);\n\t\t/**\n\t\t * Overrides the default `CIQ.ChartEngine.prototype.determineMinMax` function when the\n\t\t * Outliers add-on is active. Injects the local {@link CIQ.Outliers#processDataSet}\n\t\t * function as a data filter and passes the filter along to the original `determineMinMax`\n\t\t * function (see below).\n\t\t *\n\t\t * @param {array} quotes The array of quotes (typically\n\t\t * \t\t`CIQ.ChartEngine.chart.dataSegment`) to evaluate for minimum and maximum values.\n\t\t * @param {array} fields A list of fields to compare.\n\t\t * @param {boolean|array} [sum] If true, then compute maximum sum rather than the maximum\n\t\t * \t\tsingle value across all fields. If an array, compute sum over just the fields in\n\t\t * \t\tthe array.\n\t\t * @param {boolean} [bypassTransform] If true, bypass any transformations.\n\t\t * @param {number} [length] Specifies how many elements of the quotes array to process.\n\t\t * @param {boolean} [checkArray] If true, the type of the value used to determine the\n\t\t * \t\tmin/max is checked to ascertain whether it is an array; if so, the first element\n\t\t * \t\tof the array is retrieved for use in the min/max determination.\n\t\t * @param {CIQ.ChartEngine.Panel} [panel] A reference to the panel rendering the quotes.\n\t\t * @param {CIQ.ChartEngine.YAxis} [axis] A reference to the y-axis rendered for the quotes.\n\t\t * @param {array} [filters] Array of functions to process the min/max values before\n\t\t * \treturning. Filter functions must return a valid min/max tuple or false.\n\t\t * @return {function} A reference to the original\n\t\t * \t\t`CIQ.ChartEngine.prototype.determineMinMax` library function.\n\t\t *\n\t\t * @memberof CIQ.ChartEngine\n\t\t * @since\n\t\t * - 7.5.0\n\t\t * - 8.0.0 Allow the `sum` parameter to be an array of valid fields to sum over.\n\t\t * \t\tAdded the `panel`, `axis`, and `filters` parameters.\n\t\t * @private\n\t\t */\n\t\tCIQ.ChartEngine.prototype.determineMinMax = function (\n\t\t\tquotes,\n\t\t\tfields,\n\t\t\tsum,\n\t\t\tbypassTransform,\n\t\t\tlength,\n\t\t\tcheckArray,\n\t\t\tpanel,\n\t\t\taxis,\n\t\t\tfilters\n\t\t) {\n\t\t\tif (!filters) filters = [];\n\t\t\tif (panel && axis && this.layout.outliers)\n\t\t\t\tfilters.push(this.outliers.processDataSet.bind(this.outliers));\n\t\t\treturn originalDetermineMinMax(\n\t\t\t\tquotes,\n\t\t\t\tfields,\n\t\t\t\tsum,\n\t\t\t\tbypassTransform,\n\t\t\t\tlength,\n\t\t\t\tcheckArray,\n\t\t\t\tpanel,\n\t\t\t\taxis,\n\t\t\t\tfilters\n\t\t\t);\n\t\t};\n\t};\n\n/**\n * CIQ.Marker interface placeholder to be augmented in *standard.js* with properties.\n *\n * @tsinterface CIQ~Marker\n */\n\n};\n\n\nlet __js_addons_advanced_plotComplementer_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Creates an add-on that enables a series to complement another series.\n *\n * ![Plot Complementer](./img-Data-Forecasting.png)\n *\n * The complementary series is a permanent fixture of the series which it complements. It moves\n * in tandem with the series, and gets removed with the series. In all other respects, though, it\n * behaves like its own series. It shows separately in the panel legend and plots using its own\n * renderer.\n *\n * Charts can have multiple `PlotComplementer` instances. Each instance is attached to the chart\n * engine as a member of a `PlotComplementer` collection.\n *\n * Multiple `PlotComplementer` instances can be associated with a time series. To link a\n * `PlotComplementer` to a series, specify the series instrument in the `params.filter` function.\n * See `[setQuoteFeed]{@link CIQ.PlotComplementer#setQuoteFeed}`.\n *\n * **Note:** The series created by this add-on is not exported with the layout, since it is\n * created in tandem with the series it complements. Currently, this feature works only with\n * non-comparison series.\n *\n * Requires *addOns.js*.\n *\n * @param {object} params Configuration parameters.\n * @param {CIQ.ChartEngine} params.stx The chart object.\n * @param {string} [params.id] Unique key used by the add-on to identify itself. If not supplied,\n * \t\ta random key is chosen.\n * @param {object} [params.quoteFeed] Attaches the quote feed to the quote driver to satisfy any\n * \t\tquote requests for any series created by the add-on.\n * @param {object} [params.behavior] Used as the behavior for the quote feed supplied in this\n * \t\tparameter list.\n * @param {function} [params.filter] Used as the filter for the quote feed supplied in this\n * \t\tparameter list. See `[setQuoteFeed]{@link CIQ.PlotComplementer#setQuoteFeed}`.\n * @param {object} [params.decorator] Container object for the `symbol` and `display` properties.\n * \t\tThe `decorator` provides the label (`symbol`) for the complementary series and a short\n * \t\tdescription (`display`) that is appended to the label; for example:\n * ```\n * decorator: {symbol:\"_fcst\", display:\" Forecast\"}\n * ```\n * @param {string} [params.decorator.symbol] Adds this string onto the ID when creating the\n * \t\tcomplementary series. Otherwise, a unique ID is used.\n * @param {string} [params.decorator.display] Customizes the display value of the series.\n * @param {object} [params.renderingParameters={chartType: \"line\", width: 1, opacity: 0.5}] A\n * \t\tcollection of parameters that override the default rendering parameters. The\n * \t\t`renderingParameters` object can be set or changed at any time. The default parameters\n * \t\tcan be restored by calling {@link CIQ.PlotComplementer#resetRenderingParameters}.\n * \t\t

Here are a few examples of rendering parameters:

\n * ```\n * // Assuming a PlotComplementer declared as \"forecaster\":\n * forecaster.renderingParameters = {chartType:\"scatterplot\", opacity:0.5, field:\"Certainty\"}\n * forecaster.renderingParameters = {chartType:\"histogram\", border_color:\"transparent\", opacity:0.3}\n * forecaster.renderingParameters = {chartType:\"channel\", opacity:0.5, pattern:\"dotted\"}\n * forecaster.renderingParameters = {chartType:\"candle\", opacity:0.5, color:\"blue\", border_color:\"blue\"}\n * ```\n *\n * @constructor\n * @name CIQ.PlotComplementer\n * @since 7.3.0\n *\n * @example Forecasting\n * let forecaster = new CIQ.PlotComplementer({\n * stx:stxx,\n * id:\"forecast\",\n * quoteFeed: fcstFeed.quoteFeedForecastSimulator,\n * behavior: {refreshInterval:60},\n * decorator: {symbol:\"_fcst\", display:\" Forecast\"},\n * renderingParameters: {chartType:\"channel\", opacity:0.5, pattern:\"dotted\"}\n * });\n */\nCIQ.PlotComplementer =\n\tCIQ.PlotComplementer ||\n\tfunction (params) {\n\t\tvar stx = params.stx;\n\t\tvar unique = CIQ.uniqueID();\n\t\tif (!params.decorator) params.decorator = {};\n\t\tvar symbolDecorator = params.decorator.symbol || \"_\" + unique;\n\t\tvar displayDecorator = params.decorator.display || \" (addl)\";\n\t\tif (!stx.plotComplementers) stx.plotComplementers = [];\n\t\tstx.plotComplementers.push(this);\n\n\t\tthis.id = params.id || unique;\n\n\t\tthis.defaultRenderingParameters = {\n\t\t\tchartType: \"line\",\n\t\t\twidth: 1,\n\t\t\topacity: 0.5\n\t\t};\n\n\t\tif (params.renderingParameters)\n\t\t\tthis.defaultRenderingParameters = params.renderingParameters;\n\n\t\tvar self = this;\n\t\tfunction addSeries(stx, symbol, parameters, id) {\n\t\t\tfunction verifyQuoteFeed(stx) {\n\t\t\t\tif (!stx.quoteDriver) return;\n\t\t\t\tif (!params.quoteFeed) return;\n\t\t\t\tfor (var qf = 0; qf < stx.quoteDriver.quoteFeeds.length; qf++) {\n\t\t\t\t\tif (stx.quoteDriver.quoteFeeds[qf].engine == params.quoteFeed) return;\n\t\t\t\t}\n\t\t\t\treturn \"err\";\n\t\t\t}\n\t\t\tif (verifyQuoteFeed(stx) == \"err\") return;\n\t\t\tif (!id) id = symbol;\n\t\t\tif (stx.isEquationChart(symbol)) return;\n\t\t\tif (!parameters) parameters = {};\n\t\t\tif (parameters.isComparison) return;\n\t\t\tif (id && id.indexOf(symbolDecorator) == -1) {\n\t\t\t\tvar fId = id + symbolDecorator,\n\t\t\t\t\tfSymbol = symbol + symbolDecorator;\n\t\t\t\tvar masterRenderer = stx.getRendererFromSeries(id);\n\t\t\t\tvar myParms = CIQ.extend(\n\t\t\t\t\t{\n\t\t\t\t\t\tdisplay: symbol + displayDecorator,\n\t\t\t\t\t\tname: fId,\n\t\t\t\t\t\tsymbol: fSymbol,\n\t\t\t\t\t\tsymbolObject: {\n\t\t\t\t\t\t\tsymbol: fSymbol,\n\t\t\t\t\t\t\tgenerator: self.id,\n\t\t\t\t\t\t\tmasterSymbol: symbol\n\t\t\t\t\t\t},\n\t\t\t\t\t\toverChart: false,\n\t\t\t\t\t\tgapDisplayStyle: true,\n\t\t\t\t\t\tpermanent: true,\n\t\t\t\t\t\tpanel: parameters.panel,\n\t\t\t\t\t\tyAxis: parameters.yAxis,\n\t\t\t\t\t\tshareYAxis: true,\n\t\t\t\t\t\tloadData: !!self.quoteFeed,\n\t\t\t\t\t\tdependentOf: masterRenderer\n\t\t\t\t\t\t\t? masterRenderer.params.name\n\t\t\t\t\t\t\t: stx.mainSeriesRenderer.params.name\n\t\t\t\t\t},\n\t\t\t\t\tself.renderingParameters\n\t\t\t\t);\n\t\t\t\tif (!myParms.color) myParms.color = parameters.color || \"auto\";\n\t\t\t\tstx.addSeries(fId, myParms, function (error, obj) {\n\t\t\t\t\tif (error) stx.removeSeries(fId, stx.chart);\n\t\t\t\t\tif (stx.chart.seriesRenderers[fId]) {\n\t\t\t\t\t\tstx.chart.seriesRenderers[fId].params.display = myParms.display;\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\n\t\tfunction removeSeries(stx, id, chart) {\n\t\t\tif (id && id.indexOf(symbolDecorator) == -1)\n\t\t\t\tstx.removeSeries(id + symbolDecorator, chart);\n\t\t}\n\n\t\tfunction symbolChange(obj) {\n\t\t\tif (obj.action == \"master\") {\n\t\t\t\tif (!obj.prevSymbol) obj.prevSymbol = obj.symbol;\n\t\t\t\tremoveSeries(obj.stx, obj.prevSymbol, obj.stx.chart);\n\t\t\t\taddSeries(obj.stx, obj.symbol);\n\t\t\t} else if (obj.action == \"add-series\") {\n\t\t\t\tremoveSeries(obj.stx, obj.id, obj.stx.chart);\n\t\t\t\taddSeries(obj.stx, obj.symbol, obj.parameters, obj.id);\n\t\t\t} else if (obj.action == \"remove-series\") {\n\t\t\t\tremoveSeries(obj.stx, obj.id, obj.stx.chart);\n\t\t\t}\n\t\t}\n\n\t\tstx.addEventListener(\"symbolChange\", symbolChange);\n\t\tstx.addEventListener(\"symbolImport\", symbolChange);\n\n\t\t/**\n\t\t * Resets the `PlotComplementer` rendering values to the default settings.\n\t\t *\n\t\t * Default settings can be provided in the parameters passed to the `PlotComplementer` constructor. If no settings are\n\t\t * provided to the constructor, `PlotComplementer` uses the following defaults: `{ chartType:\"line\", width:1, opacity:0.5 }`.\n\t\t *\n\t\t * The rendering parameters may be set anytime after creating `PlotComplementer`; for example, to set an ad-hoc rendering\n\t\t * right before adding a series.\n\t\t *\n\t\t * @alias resetRenderingParameters\n\t\t * @memberof CIQ.PlotComplementer.prototype\n\t\t * @since 7.3.0\n\t\t */\n\t\tthis.resetRenderingParameters = function () {\n\t\t\tthis.renderingParameters = this.defaultRenderingParameters;\n\t\t};\n\n\t\t/**\n\t\t * Sets a quote feed for the `PlotComplementer`.\n\t\t *\n\t\t * Automatically called when a quote feed is provided in the constructor argument. If a\n\t\t * quote feed or `behavior` object is not specified in `params`, this function returns\n\t\t * without doing anything.\n\t\t *\n\t\t * @param {object} params Configuration parameters.\n\t\t * @param {object} params.quoteFeed Quote feed to attach to the quote driver to satisfy\n\t\t * \t\tany quote requests for any series created by the add-on. This quote feed is like\n\t\t * \t\tany time series quote feed object. See the\n\t\t * \t\t[Data Integration Overview]{@tutorial DataIntegrationOverview}.\n\t\t * @param {object} params.behavior Behavior for the quote feed supplied in this parameter\n\t\t * \t\tlist. This object is like any `behavior` object associated with a quote feed.\n\t\t * \t\tSee {@link CIQ.ChartEngine#attachQuoteFeed} for more information on `behavior`\n\t\t * \t\tobjects.\n\t\t * @param {function} [params.filter] Filters the quote feed supplied in this parameter\n\t\t * \t\tlist. The filter function takes as an argument an object typically containing\n\t\t * \t\t`symbolObject`, `symbol`, and `interval` properties. The properties associate the\n\t\t * \t\t`PlotComplementer` with an instrument. If the `filter` function returns true, the\n\t\t * \t\t`PlotComplementer` quote feed is used for the instrument.\n\t\t * \t\t

This `filter` function is like the `filter` in basic quote feeds.\n\t\t * \t\tSee {@link CIQ.ChartEngine#attachQuoteFeed} for more information on quote feed\n\t\t * \t\t`filter` functions.

\n\t\t * @alias setQuoteFeed\n\t\t * @memberof CIQ.PlotComplementer.prototype\n\t\t * @since 7.3.0\n\t\t */\n\t\tthis.setQuoteFeed = function (params) {\n\t\t\tif (!params.quoteFeed || !params.behavior) return;\n\t\t\tvar behavior = CIQ.clone(params.behavior);\n\t\t\tbehavior.generator = this.id;\n\t\t\tvar existingFilter = params.filter;\n\t\t\tvar filter = function (params) {\n\t\t\t\tif (existingFilter && !existingFilter(params)) return false;\n\t\t\t\treturn params.symbolObject.generator == behavior.generator;\n\t\t\t};\n\t\t\tstx.attachQuoteFeed(params.quoteFeed, behavior, filter);\n\t\t\tthis.quoteFeed = params.quoteFeed;\n\t\t};\n\n\t\tthis.setQuoteFeed(params);\n\t\tthis.resetRenderingParameters();\n\t};\n\n};\n\n\nlet _exports = {CIQ:__CIQ_};\nexport {__js_addons_standard_dataLoader_ as dataLoader};\nexport {__js_addons_standard_extendedHours_ as extendedHours};\nexport {__js_addons_standard_fullScreen_ as fullScreen};\nexport {__js_addons_standard_inactivityTimer_ as inactivityTimer};\nexport {__js_addons_standard_rangeSlider_ as rangeSlider};\nexport {__js_addons_standard_shortcuts_ as shortcuts};\nexport {__js_addons_standard_tableView_ as tableView};\nexport {__js_addons_standard_tooltip_ as tooltip};\nexport {__js_addons_advanced_animation_ as animation};\nexport {__js_addons_advanced_continuousZoom_ as continuousZoom};\nexport {__js_addons_advanced_outliers_ as outliers};\nexport {__js_addons_advanced_plotComplementer_ as plotComplementer};\n\nexport {__CIQ_ as CIQ};\n\n/* global __TREE_SHAKE__ */\nif (typeof __TREE_SHAKE__ === \"undefined\" || !__TREE_SHAKE__) {\n\t_exports.CIQ.activateImports(\n\t\t__js_addons_standard_dataLoader_,\n\t\t__js_addons_standard_extendedHours_,\n\t\t__js_addons_standard_fullScreen_,\n\t\t__js_addons_standard_inactivityTimer_,\n\t\t__js_addons_standard_rangeSlider_,\n\t\t__js_addons_standard_shortcuts_,\n\t\t__js_addons_standard_tableView_,\n\t\t__js_addons_standard_tooltip_,\n\t\t__js_addons_advanced_animation_,\n\t\t__js_addons_advanced_continuousZoom_,\n\t\t__js_addons_advanced_outliers_,\n\t\t__js_addons_advanced_plotComplementer_,\n\t\tnull\n\t);\n}","/**!\n *\t8.7.0\n *\tGeneration date: 2024-05-31T12:44:23.686Z\n *\tClient name: euroland as\n *\tPackage Type: Technical Analysis e98f22c\n *\tLicense type: annual\n *\tExpiration date: \"2025/06/01\"\n *\tDomain lock: [\"127.0.0.1\",\"localhost\",\"euroland.com\",\"eurolandir.cn\",\"eurolandir.com\"]\n *\tFeatures: TypeScript Definitions,SignalIQ\n */\n\n/***********************************************************!\n * Copyright © 2023 S&P Global All rights reserved\n*************************************************************/\n/*************************************! DO NOT MAKE CHANGES TO THIS LIBRARY FILE!! !*************************************\n* If you wish to overwrite default functionality, create a separate file with a copy of the methods you are overwriting *\n* and load that file right after the library has been loaded, but before the chart engine is instantiated. *\n* Directly modifying library files will prevent upgrades and the ability for ChartIQ to support your solution. *\n*************************************************************************************************************************/\n/* eslint-disable no-extra-parens */\n\n\nimport {CIQ as __CIQ_} from \"../js/componentUI.js\";\n\n\nlet __js_webcomponents_abstractMarker_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * The abstract marker web component ``.\n *\n * An encapsulation of a complex marker which can contain HTML, video, images, CSS, and\n * animations.\n *\n * The component can be extended with additional markup types specified as values of the\n * `cq-type` attribute.\n *\n * @namespace WebComponents.cq-abstract-marker\n * @since 7.5.0\n *\n * @example\n * Abstract markers can be anything you want them to be — even a helicopter!\n *
\n *
\n *
\n *
\n *
\n *
\n *
\n *
\n *
\n *
\n *
\n *
\n *
\n *
\n *
\n *
\n *
\n *
\n *
This is an example of a complex marker which can contain HTML, video, images, CSS, and animations.
\n *
\n *
\n *
\n *
\n *
\n */\nclass AbstractMarker extends CIQ.UI.BaseComponent {\n\t/**\n\t * Obtains the type of markup for the component. Called when the tag is instantiated.\n\t *\n\t * @alias connectedCallback\n\t * @memberof WebComponents.cq-abstract-marker\n\t * @private\n\t * @since 7.5.0\n\t */\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tsuper.connectedCallback();\n\t\tthis.init();\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, AbstractMarker);\n\t\tthis.constructor = AbstractMarker;\n\t}\n\n\t/**\n\t * Initializes the component.\n\t *\n\t * @alias init\n\t * @memberof WebComponents.cq-abstract-marker\n\t * @since 7.5.0\n\t */\n\tinit() {\n\t\tthis.type = this.getAttribute(\"cq-type\") || \"helicopter\";\n\t\tconst { markups } = this.constructor;\n\t\tthis.addDefaultMarkup(this, markups[this.type]);\n\t}\n}\n\nAbstractMarker.markups = {\n\thelicopter: `\n\t\t
\n\t\t\t\n\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
This is an example of a complex marker which can contain html, video, images, css, and animations.
\n\t\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t
\n\t\t
\n\t\t`\n};\nCIQ.UI.addComponentDefinition(\"cq-abstract-marker\", AbstractMarker);\n\n};\n\n\nlet __js_webcomponents_advertisement_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nif (!CIQ.Marker) {\n\tconsole.error(\n\t\t\"advertisement component requires first activating markers feature.\"\n\t);\n} else {\n\t/**\n\t * Advertisement web component ``.\n\t *\n\t * Displays an advertisement banner as a \"marker\" (inside the chart, use CSS to position absolutely against the chart panel).\n\t * The advertisement should contain content that can be enabled by calling {@link CIQ.UI.Advertisement#show} based on your\n\t * business logic.\n\t *\n\t * The advertisement will automatically adjust the height to accommodate the content (assuming overflow-y: auto)\n\t * @namespace WebComponents.cq-advertisement\n\t * @example\n\t\t\n\t\t \n\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t
$1 Trades
\n\t\t\t\t\t
Use code Sample
\n\t\t\t\t\tClick to learn more\n\t\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t
$1 Trades
\n\t\t\t\t\tClick to learn more\n\t\t\t\t
\n\t\t\t
\n\t\t
\n\t *\n\t */\n\tclass Advertisement extends CIQ.UI.ModalTag {\n\t\tadoptedCallback() {\n\t\t\tsuper.adoptedCallback();\n\t\t\tCIQ.UI.flattenInheritance(this, Advertisement);\n\t\t}\n\n\t\t/**\n\t\t * Hides the advertisement and suppresses it for 24 hours by storing it in local storage.\n\t\t * If the selector itself changes however then the ad will reappear.\n\t\t * @memberof WebComponents.cq-advertisement\n\t\t */\n\t\tclose() {\n\t\t\tthis.node.css({ display: \"none\" });\n\t\t\tvar self = this;\n\t\t\tthis.nameValueStore.get(\"cq-advertisement\", function (err, ls) {\n\t\t\t\tif (err) return;\n\t\t\t\tvar future = new Date();\n\t\t\t\tif (!self.sleepAmount) self.sleepAmount = { units: 1, unitType: \"day\" };\n\t\t\t\tvar u = self.sleepAmount.units;\n\t\t\t\tvar ut = self.sleepAmount.unitType;\n\t\t\t\tif (ut == \"minute\") future.setMinutes(future.getMinutes() + u);\n\t\t\t\telse if (ut == \"hour\") future.setHours(future.getHours() + u);\n\t\t\t\telse if (ut == \"day\") future.setDate(future.getDate() + u);\n\t\t\t\telse if (ut == \"week\") future.setDate(future.getDate() + u * 7);\n\t\t\t\telse if (ut == \"month\") future.setMonth(future.getMonth() + u);\n\t\t\t\tvar ms = future.getTime();\n\t\t\t\tif (!ls || typeof ls != \"object\") ls = {};\n\t\t\t\tls[self.selector] = ms;\n\t\t\t\tself.nameValueStore.set(\"cq-advertisement\", ls);\n\t\t\t});\n\t\t}\n\n\t\tmakeMarker() {\n\t\t\tif (this.markerExists) return;\n\t\t\tCIQ.Marker({\n\t\t\t\tstx: this.context.stx,\n\t\t\t\txPositioner: \"none\",\n\t\t\t\tlabel: \"advertisement\",\n\t\t\t\tpermanent: true,\n\t\t\t\tnode: this.node[0]\n\t\t\t});\n\t\t\tthis.markerExists = true;\n\t\t}\n\n\t\tsetContext(context) {\n\t\t\tconst {\n\t\t\t\tconfig: { nameValueStore }\n\t\t\t} = context;\n\t\t\tthis.setNameValueStore(nameValueStore);\n\t\t}\n\n\t\tsetNameValueStore(nameValueStore) {\n\t\t\tif (!nameValueStore && CIQ.NameValueStore)\n\t\t\t\tnameValueStore = CIQ.NameValueStore;\n\n\t\t\tthis.nameValueStore = nameValueStore\n\t\t\t\t? new nameValueStore()\n\t\t\t\t: {\n\t\t\t\t\t\tget: function () {},\n\t\t\t\t\t\tset: function () {}\n\t\t\t\t };\n\t\t}\n\n\t\t/**\n\t\t * Sets the sleep time for this amount of time before re-displaying\n\t\t * @param {Number} units Units\n\t\t * @param {string} unitType Unit type. Value values \"minute\",\"hour\",\"day\",\"week\"\n\t\t * @memberof WebComponents.cq-advertisement\n\t\t */\n\t\tsetSleepAmount(units, unitType) {\n\t\t\tthis.sleepAmount = {\n\t\t\t\tunits: units,\n\t\t\t\tunitType: unitType\n\t\t\t};\n\t\t}\n\n\t\t/**\n\t\t * Show the advertisement. This should be a div inside of the web component.\n\t\t * @param {Selector} [selector] A selector. If none specified then the first div will be selected.\n\t\t * @param {Boolean} [ignoreSleep=false] If true then ignore sleep\n\t\t * @member! CIQ.UI.Advertisement\n\t\t */\n\t\tshow(selector, ignoreSleep = false) {\n\t\t\tif (this.selector) {\n\t\t\t\tvar priorContent = this.node.find(this.selector);\n\t\t\t\tpriorContent.removeClass(\"ciq-show\");\n\t\t\t}\n\t\t\tthis.selector = selector;\n\t\t\tif (!this.selector) {\n\t\t\t\tvar div = this.node.find(\"div:first-of-type\");\n\t\t\t\tthis.selector = \".\" + div.attr(\"class\");\n\t\t\t}\n\t\t\tthis.ignoreSleep = ignoreSleep;\n\t\t\tvar self = this;\n\t\t\tfunction doIt() {\n\t\t\t\tself.makeMarker();\n\t\t\t\tself.node.css({ display: \"block\" });\n\t\t\t\tvar content = self.node.find(self.selector);\n\t\t\t\tcontent.addClass(\"ciq-show\");\n\n\t\t\t\t// resize content\n\t\t\t\tself.node.css({ height: \"0px\" });\n\t\t\t\tsetTimeout(function () {\n\t\t\t\t\tself.node.css({ height: self.node[0].scrollHeight + \"px\" });\n\t\t\t\t}, 0);\n\t\t\t}\n\t\t\tif (!ignoreSleep) {\n\t\t\t\tthis.nameValueStore.get(\"cq-advertisement\", function (err, ls) {\n\t\t\t\t\tif (err) return;\n\t\t\t\t\tif (!ls || typeof ls != \"object\") ls = {};\n\t\t\t\t\tvar ms = ls[self.selector];\n\t\t\t\t\tif (ms && ms > Date.now()) return; // still surpressed\n\t\t\t\t\tdoIt();\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tdoIt();\n\t\t\t}\n\t\t}\n\n\t\t/**\n\t\t * Call this to force the advertisement to monitor the nameValueStore for updates. It will do this by\n\t\t * polling. This is useful when running in multiple windows, do that if the advertisement is closed in one\n\t\t * window then it will automatically close in the other windows.\n\t\t * @param {Number} [ms=1000] Number of milliseconds to poll.\n\t\t * @memberof WebComponents.cq-advertisement\n\t\t */\n\t\twatchForRemoteClose(ms) {\n\t\t\tif (!ms) ms = 1000;\n\t\t\tvar self = this;\n\t\t\tsetInterval(function () {\n\t\t\t\tif (self.node.css(\"display\") == \"none\") return; // already closed, do nothing\n\t\t\t\tself.nameValueStore.get(\"cq-advertisement\", function (err, ls) {\n\t\t\t\t\tif (err) return;\n\t\t\t\t\tif (!ls || typeof ls != \"object\") ls = {};\n\t\t\t\t\tvar ms = ls[self.selector];\n\t\t\t\t\tif (ms && ms > Date.now()) self.close();\n\t\t\t\t});\n\t\t\t}, ms);\n\t\t}\n\t}\n\n\tCIQ.UI.addComponentDefinition(\"cq-advertisement\", Advertisement);\n}\n\n};\n\n\nlet __js_webcomponents_aggregationDialog_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Aggregation Dialog web component ``.\n *\n * @namespace WebComponents.cq-aggregation-dialog\n */\nclass AggregationDialog extends CIQ.UI.DialogContentTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, AggregationDialog);\n\t\tthis.constructor = AggregationDialog;\n\t}\n\n\t/**\n\t * Opens the nearest {@link WebComponents.cq-dialog} to display your dialog.\n\t * @alias open\n\t * @memberof WebComponents.cq-aggregation-dialog\n\t */\n\topen(params) {\n\t\tthis.addDefaultMarkup();\n\t\tsuper.open(params);\n\t\tvar stx = this.context.stx;\n\t\tvar aggregationType = params.aggregationType;\n\t\tvar map = {\n\t\t\tkagi: {\n\t\t\t\ttitle: \"Set Reversal Percentage\"\n\t\t\t},\n\t\t\trenko: {\n\t\t\t\ttitle: \"Set Brick Size\"\n\t\t\t},\n\t\t\tlinebreak: {\n\t\t\t\ttitle: \"Set Price Lines\"\n\t\t\t},\n\t\t\trangebars: {\n\t\t\t\ttitle: \"Set Range\"\n\t\t\t},\n\t\t\tpandf: {\n\t\t\t\ttitle: \"Set Point & Figure Parameters\"\n\t\t\t}\n\t\t};\n\t\tif (stx.layout.aggregationType != aggregationType)\n\t\t\tstx.setAggregationType(aggregationType);\n\n\t\tvar entry = map[aggregationType];\n\t\tvar node = this.node;\n\t\tnode.find(\".title\").text(stx.translateIf(entry.title));\n\n\t\tfor (var type in map) {\n\t\t\tnode\n\t\t\t\t.find(\".ciq\" + type)\n\t\t\t\t.css(aggregationType === type ? { display: \"\" } : { display: \"none\" });\n\t\t}\n\t\tnode.find(\".ciq\" + aggregationType + \" input\").each(function () {\n\t\t\tvar name = this.name;\n\t\t\tif (name == \"box\" || name == \"reversal\") name = \"pandf.\" + name;\n\t\t\tvar tuple = CIQ.deriveFromObjectChain(stx.layout, name);\n\t\t\tif (tuple && (tuple.obj[tuple.member] || tuple.obj[tuple.member] === 0)) {\n\t\t\t\tthis.value = tuple.obj[tuple.member];\n\t\t\t} else if (stx.chart.defaultChartStyleConfig[this.name]) {\n\t\t\t\tthis.value = stx.chart.defaultChartStyleConfig[this.name];\n\t\t\t}\n\t\t});\n\t}\n}\n\nAggregationDialog.markup = `\n\t\t

\n\t\t\n\t\t
\n\t\t\t
\n\t\t\t\tEnter value and hit \"Enter\"\n\t\t\t\t

\n\t\t\t\t\t\n\t\t\t\t

\n\t\t\t
\n\t\t\t
\n\t\t\t\tEnter value and hit \"Enter\"\n\t\t\t\t

\n\t\t\t\t\t\n\t\t\t\t

\n\t\t\t
\n\t\t\t
\n\t\t\t\tEnter value and hit \"Enter\"\n\t\t\t\t

\n\t\t\t\t\t\n\t\t\t\t

\n\t\t\t
\n\t\t\t
\n\t\t\t\tEnter value and hit \"Enter\"\n\t\t\t\t

\n\t\t\t\t\t\n\t\t\t\t

\n\t\t\t
\n\t\t\t
\n\t\t\t\tEnter box size and hit \"Enter\"\n\t\t\t\t

\n\t\t\t\t\t\n\t\t\t\t

\n\t\t\t\t

\n\t\t\t\t\tEnter reversal and hit \"Enter\"\n\t\t\t\t

\n\t\t\t\t

\n\t\t\t\t\t\n\t\t\t\t

\n\t\t\t
\n\t\t\t

or

\n\t\t\t
Auto Select
\n\t\t
\n\n\t`;\nCIQ.UI.addComponentDefinition(\"cq-aggregation-dialog\", AggregationDialog);\n\n};\n\n\nlet __js_webcomponents_attribution_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nif (!CIQ.Marker) {\n\tconsole.error(\n\t\t\"attribution component requires first activating markers feature.\"\n\t);\n} else {\n\t/**\n\t * Attribution web component ``.\n\t *\n\t * This will put a node inside a panel to attribute the data.\n\t * Both the main chart panel (for quotes) and a study panel can use an attribution.\n\t *\n\t * @namespace WebComponents.cq-attribution\n\t * @since 2016-07-16\n\t * @example\n\t * \n\t * \t\n\t * \n\t */\n\tclass Attribution extends CIQ.UI.ModalTag {\n\t\tconstructor() {\n\t\t\tsuper();\n\t\t\t/**\n\t\t\t * Contains the attribution messages.\n\t\t\t *\n\t\t\t * Override or augment the following properties of the `messages` object:\n\t\t\t * - `sources` — An object that contains properties whose values populate\n\t\t\t * ``.\n\t\t\t * - `exchanges` — An object that contains properties whose values populate\n\t\t\t * ``.\n\t\t\t *\n\t\t\t * For quotes, the source should match the quote source. For studies, the source should\n\t\t\t * match the study type. If there is no matching source property, the associated\n\t\t\t * component has no text.\n\t\t\t *\n\t\t\t * @type {object}\n\t\t\t * @alias messages\n\t\t\t * @memberof WebComponents.cq-attribution#\n\t\t\t * @example Default object.\n\t\t\t * {\n\t\t\t *\tsources: {\n\t\t\t *\t\tsimulator: \"Simulated data.\",\n\t\t\t *\t\tdemo: \"Demo data.\",\n\t\t\t *\t\txignite: 'Market Data by Xignite.',\n\t\t\t *\t\tfis_mm: 'Market Data by FIS MarketMap.',\n\t\t\t *\t\tTwiggs: 'Twiggs MF Formula courtesy IncredibleCharts.'\n\t\t\t *\t},\n\t\t\t *\texchanges: {\n\t\t\t *\t\tRANDOM: \"Data is randomized.\",\n\t\t\t *\t\t\"REAL-TIME\": \"Data is real-time.\",\n\t\t\t *\t\tDELAYED: \"Data delayed 15 min.\",\n\t\t\t *\t\tRATES: \"Yield data latest from source, bid/ask simulated.\",\n\t\t\t *\t\tBATS: \"BATS BZX real-time.\",\n\t\t\t *\t\tEOD: \"End of day data.\"\n\t\t\t *\t}\n\t\t\t * @example Override or augment the messages object.\n\t\t\t * var messages =document.querySelector(\"cq-attribution\").messages;\n\t\t\t * messages.exchanges.CUSTOMEX='Text for custom exchange';\n\t\t\t * messages.sources.CUSTOMSOURCE='Text for custom source';\n\t\t\t * @example Set the attribution object on your quote feed for the above override.\n\t\t\t * cb({\n\t\t\t * quotes:[--array of quote elements here--],\n\t\t\t * attribution: { source: \"CUSTOMSOURCE\", exchange: \"CUSTOMEX\" }\n\t\t\t * });\n\t\t\t */\n\t\t\tthis.messages = {\n\t\t\t\tsources: {\n\t\t\t\t\tsimulator: \"Simulated data.\",\n\t\t\t\t\tdemo: \"Demo data.\",\n\t\t\t\t\txignite:\n\t\t\t\t\t\t'Market Data by Xignite.',\n\t\t\t\t\tfis_mm:\n\t\t\t\t\t\t'Market Data by FIS MarketMap.',\n\t\t\t\t\tTwiggs:\n\t\t\t\t\t\t'Twiggs MF Formula courtesy IncredibleCharts.'\n\t\t\t\t},\n\t\t\t\texchanges: {\n\t\t\t\t\tRANDOM: \"Data is randomized.\",\n\t\t\t\t\t\"REAL-TIME\": \"Data is real-time.\",\n\t\t\t\t\tDELAYED: \"Data delayed 15 min.\",\n\t\t\t\t\tRATES: \"Yield data latest from source, bid/ask simulated.\",\n\t\t\t\t\tBATS: \"BATS BZX real-time.\",\n\t\t\t\t\tEOD: \"End of day data.\"\n\t\t\t\t}\n\t\t\t};\n\t\t}\n\n\t\tadoptedCallback() {\n\t\t\tsuper.adoptedCallback();\n\t\t\tCIQ.UI.flattenInheritance(this, Attribution);\n\t\t\tthis.constructor = Attribution;\n\t\t}\n\n\t\tinsert(stx, panel) {\n\t\t\tif (!CIQ.Marker) return;\n\t\t\tvar attrib = CIQ.UI.makeFromTemplate(this.template);\n\t\t\tattrib.marker = new CIQ.Marker({\n\t\t\t\tstx: stx,\n\t\t\t\tnode: attrib[0],\n\t\t\t\txPositioner: \"none\",\n\t\t\t\tyPositioner: \"none\",\n\t\t\t\tlabel: \"component\",\n\t\t\t\tpanelName: panel,\n\t\t\t\tpermanent: true\n\t\t\t});\n\t\t\treturn attrib;\n\t\t}\n\n\t\tsetContext(context) {\n\t\t\tthis.addDefaultMarkup();\n\t\t\tthis.template = this.node.find(\"template\");\n\t\t\tthis.marker = this.insert(context.stx, \"chart\");\n\t\t\tvar self = this;\n\t\t\tthis.addInjection(\"append\", \"createDataSet\", function () {\n\t\t\t\treturn self.displayAttribution(this);\n\t\t\t});\n\t\t\tthis.displayAttribution();\n\t\t}\n\n\t\t/**\n\t\t * Displays an attribution on the chart. Attributions are messages about the chart data\n\t\t * source.\n\t\t *\n\t\t * Called automatically whenever the data set is modified, but may also be called on\n\t\t * demand.\n\t\t *\n\t\t * @param {CIQ.ChartEngine} [stx] The chart engine for which the attribution is displayed.\n\t\t * \t\tDefaults to the chart engine contained in the context.\n\t\t *\n\t\t * @alias displayAttribution\n\t\t * @memberof WebComponents.cq-attribution#\n\t\t * @since 8.3.0\n\t\t */\n\t\tdisplayAttribution(stx) {\n\t\t\tif (!stx) stx = this.context.stx;\n\t\t\tvar chart = stx.chart;\n\t\t\tvar layout = stx.layout;\n\t\t\tvar chartAttrib = this.marker;\n\t\t\tvar source, exchange;\n\t\t\tif (chart.attribution) {\n\t\t\t\tsource = this.messages.sources[chart.attribution.source];\n\t\t\t\texchange = this.messages.exchanges[chart.attribution.exchange];\n\t\t\t\tif (!source) source = \"\";\n\t\t\t\tif (!exchange) exchange = \"\";\n\t\t\t\tif (source + exchange != chartAttrib.attr(\"lastAttrib\")) {\n\t\t\t\t\tchartAttrib.find(\"cq-attrib-source\").html(source);\n\t\t\t\t\tchartAttrib.find(\"cq-attrib-quote-type\").html(exchange);\n\t\t\t\t\tif (stx.translateUI) stx.translateUI(chartAttrib[0]);\n\t\t\t\t\tchartAttrib.attr(\"lastAttrib\", source + exchange);\n\t\t\t\t}\n\t\t\t}\n\t\t\tfor (var study in layout.studies) {\n\t\t\t\tvar sd = layout.studies[study];\n\t\t\t\tvar type = sd.type;\n\t\t\t\tif (this.messages.sources[type]) {\n\t\t\t\t\tif (sd.attribution) {\n\t\t\t\t\t\tif (sd.attribution.marker.params.panelName == sd.panel) continue; // already have an attribution\n\t\t\t\t\t}\n\t\t\t\t\tsource = this.messages.sources[type] || \"\";\n\t\t\t\t\texchange = this.messages.exchanges[type] || \"\";\n\t\t\t\t\tvar attrib = this.insert(stx, sd.panel);\n\t\t\t\t\tattrib.find(\"cq-attrib-source\").html(source);\n\t\t\t\t\tattrib.find(\"cq-attrib-quote-type\").html(exchange);\n\t\t\t\t\tif (stx.translateUI) stx.translateUI(attrib[0]);\n\t\t\t\t\tsd.attribution = attrib;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tAttribution.markup = `\n\t\t\n\t`;\n\tCIQ.UI.addComponentDefinition(\"cq-attribution\", Attribution);\n}\n\n};\n\n\nlet __js_webcomponents_chartInstructions_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * This element contains hidden text that can be read aloud by a screen reader to announce chart features or instructions.\n * By default the text is not visible to a user but is listed in the accessbility tree.\n *\n * If you would like to provide custom instructions, pass in your own text in a `

` tag.\n * @memberof CIQ.UI.WebComponents\n * @since 8.7.0\n */\nclass ChartInstructions extends CIQ.UI.ContextTag {\n\tsetContext() {\n\t\tthis.addDefaultMarkup();\n\t\tthis.content = this.querySelector(\"span\") || this.firstElementChild;\n\t\tthis.instructions = this.querySelector(\"p\") || this.content;\n\n\t\tconst { config: { hotkeyConfig = {} } = {} } = this.context;\n\n\t\tif (hotkeyConfig.hotkeys) {\n\t\t\tconst keyConfigs = hotkeyConfig.hotkeys.filter((conf) => conf.ariaLabel);\n\t\t\tthis.setHotKeyCommands(keyConfigs);\n\t\t}\n\t}\n\n\t/**\n\t * Filtered hotKey configurations from defaultConfiguration based on ariaLabel property.\n\t * This will create new entries for the hotkeys and add\n\t * their instructions to the text content already provided.\n\t * @param {object[]} configurations Hotkey configs from the config.hotKeyConfig hotkeys\n\t */\n\tsetHotKeyCommands(configurations) {\n\t\tconst list = document.createElement(\"UL\");\n\t\tthis.instructions.innerText +=\n\t\t\t\" The following is a list of keyboard commands available to interact with the chart.\";\n\t\tconst elements = configurations.map((configuration) => {\n\t\t\tconst { commands, label, ariaLabel } = configuration;\n\t\t\tconst combos = [];\n\t\t\tcommands.forEach((command) =>\n\t\t\t\tcombos.push(\n\t\t\t\t\tcommand\n\t\t\t\t\t\t.split(\"+\")\n\t\t\t\t\t\t.map((key) => key.replace(\"Key\", \"\"))\n\t\t\t\t\t\t.join(\" + \")\n\t\t\t\t)\n\t\t\t);\n\t\t\tconst formattedCombos =\n\t\t\t\tcombos.length > 1 ? combos.join(\" or \") : combos[0];\n\t\t\treturn `${label}. ${ariaLabel}. Hotkeys press ${formattedCombos}. `;\n\t\t});\n\n\t\telements.forEach((element) => {\n\t\t\tconst item = document.createElement(\"LI\");\n\t\t\titem.innerText = element;\n\t\t\tlist.append(item);\n\t\t});\n\t\tthis.content.append(list);\n\t}\n}\n\nChartInstructions.markup = `\n\n\t

ChartIQ interactive chart component. Instructions for use with screen readers.

\n\n`;\n\nCIQ.UI.addComponentDefinition(\"cq-chart-instructions\", ChartInstructions);\n\n};\n\n\nlet __js_webcomponents_chartLegend_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * The chart legend web component ``.\n *\n * An encapsulation of the markup for the chart (or study) legend.\n *\n * Use the `cq-marker` attribute to ensure that the legend floats inside the chart. Set the\n * optional `cq-panel-only` attribute so that only studies from the panel containing the\n * legend are displayed. Set the optional `cq-clone-to-panels` attribute to create a legend\n * on each panel.\n *\n * The legend shows both studies and comparisons, so the `cq-content-keys` attribute should\n * include `cq-label` for studies and `cq-comparison-label` for comparisons.\n *\n * @namespace WebComponents.cq-chart-legend\n * @since 7.5.0\n *\n * @example\n * \n * \n * \n * \n * \n * \n * \n * \n */\nclass ChartLegend extends CIQ.UI.ContextTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, ChartLegend);\n\t\tthis.constructor = ChartLegend;\n\t}\n\n\t/**\n\t * Adds the default markup.\n\t *\n\t * @alias setContext\n\t * @memberof WebComponents.cq-chart-legend\n\t * @since 7.5.0\n\t */\n\tsetContext() {\n\t\tif (this.contextSet) return;\n\t\tthis.contextSet = true;\n\t\tthis.addDefaultMarkup();\n\t}\n}\n\nChartLegend.markup = `\n\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t`;\nCIQ.UI.addComponentDefinition(\"cq-chart-legend\", ChartLegend);\n\n};\n\n\nlet __js_webcomponents_chartTitle_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Chart Title web component ``.\n *\n * Note, if the `cq-marker` is added to the element, and it is placed within the\n * chartArea, the element will sit above the chart bars.\n *\n * `` will display `chart.symbol`.
\n * `` will display the `chart.symbolDisplay`. See {@link CIQ.ChartEngine.Chart#symbolDisplay} for details on how to set this value.\n *\n * Set attribute `cq-browser-tab` to true to get the stock symbol and latest price to update in the browser tab.\n *\n * Set member `previousClose` to the prior day's closing price in order to calculate and display change.\n * If `previousClose` is not set, then `iqPrevClose` from the `dataSet` will be the default.
\n * Remember data is loaded asynchronously.\n * Be sure to reset this value once your initial data has been loaded by using the {@link CIQ.ChartEngine.loadChart} callback function.\n * ```\n * stx.loadChart(symbol, parameters, function(){\n * document.querySelector(\"cq-chart-title\").previousClose = yesterdays-closing-price;\n * }\n * ```\n *\n * The `cq-animate` attribute in the `cq-current-price` element can be used to change the price color to red or green based on the previous value.\n * Setting the attribute to \"fade\" will introduce a transition effect on the price which, while attractive, uses considerable CPU when there are rapid updates.\n * @namespace WebComponents.cq-chart-title\n * @example\n * \n * \t\n * \t\n * \t\t\n * \t\t\n * \t\t\t
()\n * \t\t
\n * \t
\n *
\n *\n * @example\n * //You can set a more descriptive name by using http://documentation.chartiq.com/CIQ.ChartEngine.Chart.html#symbolDisplay\n * // and then enabling that on the tile.\n *\n * //In your HTML file look for:\n * \n * //and replace it with :\n * \n *\n * //In your quote feed add the following line:\n * params.stx.chart.symbolDisplay=response.fullName;\n *\n * //Like so:\n * quotefeed.fetchInitialData=function (symbol, suggestedStartDate, suggestedEndDate, params, cb) {\n * var queryUrl = this.url; // using filter:true for after hours\n *\n * CIQ.postAjax(queryUrl, null, function(status, response){\n * // process the HTTP response from the datafeed\n * if(status==200){ // if successful response from datafeed\n * params.stx.chart.symbolDisplay=response.fullName; // specify response name\n * var newQuotes = quotefeed.formatChartData(response);\n * cb({quotes:newQuotes, moreAvailable:true, attribution:{source:\"simulator\", exchange:\"RANDOM\"}}); // return the fetched data; init moreAvailable to enable pagination\n * } else { // else error response from datafeed\n * cb({error:(response?response:status)});\t// specify error in callback\n * }\n * });\n * };\n *\n * @since\n * - 06-15-16\n * - 4.0.0 Browser tab now updates with stock symbol and latest price using `cq-browser-tab` attribute.\n * - 6.3.0 Negative close values are \"N/A\" change percentage.\n * - 6.3.0 Child tag `` is now optional.\n */\n\nclass ChartTitle extends CIQ.UI.ModalTag {\n\tget displayExchange() {\n\t\treturn this.getAttribute(\"display-exchange\");\n\t}\n\n\tconstructor() {\n\t\tsuper();\n\t\t/**\n\t\t * Keep this value up to date in order to calculate change from yesterday's close\n\t\t * @type {Float}\n\t\t * @alias previousClose\n\t\t * @memberof WebComponents.cq-chart-title\n\t\t */\n\t\tthis.previousClose = null;\n\t}\n\n\t/**\n\t * Begins the Title helper. This observes the chart and updates the title elements as necessary.\n\t * @alias begin\n\t * @memberof WebComponents.cq-chart-title\n\t */\n\tbegin() {\n\t\tconst self = this;\n\n\t\tthis.addInjection(\"append\", \"createDataSet\", function () {\n\t\t\tself.update();\n\t\t});\n\t\tthis.update();\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, ChartTitle);\n\t\tthis.constructor = ChartTitle;\n\t}\n\n\tdisconnectedCallback() {\n\t\tif (this.context) {\n\t\t\tCIQ.UI.unobserveProperty(\n\t\t\t\t\"symbolObject\",\n\t\t\t\tthis.context.stx.chart,\n\t\t\t\tthis.listener\n\t\t\t);\n\t\t}\n\t\tsuper.disconnectedCallback();\n\t}\n\n\tinitialize(params) {\n\t\tthis.params = params ? params : {};\n\t\tif (typeof this.params.autoStart == \"undefined\")\n\t\t\tthis.params.autoStart = true;\n\t\tthis.marker = null;\n\n\t\tif (this.params.autoStart) this.begin();\n\t}\n\n\tsetContext(context) {\n\t\tvar self = this,\n\t\t\tstx = this.context.stx;\n\n\t\tthis.addDefaultMarkup();\n\n\t\tthis.symbolDiv = this.querySelector(\"cq-symbol\");\n\t\tthis.symbolDescriptionDiv = this.querySelector(\"cq-symbol-description\");\n\t\tthis.currentPriceDiv = this.querySelector(\"cq-current-price\");\n\t\tthis.todaysChangeDiv = this.querySelector(\"cq-todays-change\");\n\t\tthis.todaysChangePctDiv = this.querySelector(\"cq-todays-change-pct\");\n\t\tthis.chartPriceDiv = this.querySelector(\"cq-chart-price\");\n\t\tthis.changeDiv = this.querySelector(\"cq-change\");\n\t\tthis.exchangeDiv = this.querySelector(\".exchange\");\n\t\tthis.listener = function (obj) {\n\t\t\tconst { exchangeDiv } = self;\n\t\t\tself.previousClose = stx.mostRecentClose(\"iqPrevClose\");\n\t\t\tif (exchangeDiv) {\n\t\t\t\tconst {\n\t\t\t\t\tvalue: { exchDisp }\n\t\t\t\t} = obj;\n\t\t\t\tif (self.displayExchange && exchDisp) {\n\t\t\t\t\texchangeDiv.innerText = `Exchange: ${exchDisp}`;\n\t\t\t\t} else if (obj.value.static) {\n\t\t\t\t\texchangeDiv.innerText = \"STATIC\";\n\t\t\t\t} else {\n\t\t\t\t\texchangeDiv.innerText = \"\";\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t\tCIQ.UI.observeProperty(\"symbolObject\", stx.chart, this.listener);\n\t\tthis.initialize();\n\t}\n\n\t/**\n\t * Updates the values in the node\n\t * @alias update\n\t * @memberof WebComponents.cq-chart-title\n\t */\n\tupdate() {\n\t\tconst { stx } = this.context;\n\t\tconst {\n\t\t\tchart: { symbol, symbolDisplay },\n\t\t\tinternationalizer\n\t\t} = stx;\n\n\t\tconst {\n\t\t\tsymbolDiv,\n\t\t\tsymbolDescriptionDiv,\n\t\t\texchangeDiv,\n\t\t\tcurrentPriceDiv,\n\t\t\tchangeDiv,\n\t\t\tchartPriceDiv,\n\t\t\ttodaysChangeDiv,\n\t\t\ttodaysChangePctDiv\n\t\t} = this;\n\t\tvar doUpdateBrowserTab =\n\t\t\t[\"false\", \"0\", null].indexOf(this.getAttribute(\"cq-browser-tab\")) == -1;\n\t\tvar wrapper = this.closest(\"cq-context-wrapper\");\n\t\tvar isActiveChart =\n\t\t\t!wrapper || (wrapper && wrapper.classList.contains(\"active\"));\n\t\tif (!isActiveChart) doUpdateBrowserTab = false;\n\t\tconst doUpdatePrice = chartPriceDiv && currentPriceDiv;\n\t\tlet priceChanged = false;\n\t\tlet symbolChanged = false;\n\n\t\tlet show = !symbol ? \"remove\" : \"add\";\n\t\tthis.classList[show](\"stx-show\");\n\n\t\tif (symbolDiv.innerText !== symbol) {\n\t\t\tsymbolDiv.innerText = symbol;\n\t\t\tsymbolChanged = true;\n\t\t}\n\n\t\tif (\n\t\t\tsymbolDescriptionDiv &&\n\t\t\tsymbolDescriptionDiv.innerText !== (symbolDisplay || symbol)\n\t\t)\n\t\t\tsymbolDescriptionDiv.innerText = symbolDisplay || symbol;\n\n\t\tif (stx.isHistoricalModeSet) {\n\t\t\tif (currentPriceDiv.innerText !== \"\") currentPriceDiv.innerText = \"\";\n\t\t\tchangeDiv.style.display = \"none\";\n\t\t\t// only change the display so that you don't wreck the line spacing and parens\n\t\t\treturn;\n\t\t}\n\n\t\tlet todaysChange = \"\",\n\t\t\ttodaysChangePct = 0,\n\t\t\ttodaysChangeDisplay = \"\";\n\t\tconst currentQuote = stx.getFirstLastDataRecord(\n\t\t\tstx.chart.dataSet,\n\t\t\t\"Close\",\n\t\t\ttrue\n\t\t);\n\t\tlet currentPrice = \"\";\n\t\tlet textPrice = \"\";\n\t\tif (currentQuote) currentPrice = currentQuote.Close;\n\t\tif (doUpdatePrice) {\n\t\t\tif (currentPrice !== \"\")\n\t\t\t\ttextPrice = stx.formatYAxisPrice(\n\t\t\t\t\tcurrentPrice,\n\t\t\t\t\tstx.chart.panel,\n\t\t\t\t\tstx.chart.decimalPlaces\n\t\t\t\t);\n\t\t\tlet oldPrice = parseFloat(currentPriceDiv.innerText);\n\t\t\tif (currentPriceDiv.innerText !== textPrice) {\n\t\t\t\tcurrentPriceDiv.innerText = textPrice;\n\t\t\t\tpriceChanged = true;\n\t\t\t\tvar attr = this.currentPriceDiv.getAttribute(\"cq-animate\");\n\t\t\t\tif (typeof attr != \"undefined\") {\n\t\t\t\t\tCIQ.UI.animatePrice(\n\t\t\t\t\t\tcurrentPriceDiv,\n\t\t\t\t\t\tcurrentPrice,\n\t\t\t\t\t\toldPrice,\n\t\t\t\t\t\tattr == \"fade\"\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (\n\t\t\t(doUpdatePrice || doUpdateBrowserTab) &&\n\t\t\tsymbol &&\n\t\t\t(symbolChanged || priceChanged)\n\t\t) {\n\t\t\t// Default to iqPrevClose if the developer hasn't set this.previousClose\n\t\t\tlet previousClose = currentQuote && currentQuote.iqPrevClose;\n\t\t\tif (!previousClose && previousClose !== 0)\n\t\t\t\tpreviousClose = this.previousClose;\n\n\t\t\tif (changeDiv && (currentPrice || currentPrice == 0)) {\n\t\t\t\ttodaysChange = CIQ.fixPrice(currentPrice - previousClose);\n\t\t\t\ttodaysChangePct = (todaysChange / previousClose) * 100;\n\t\t\t\tif (previousClose <= 0 || currentPrice < 0) {\n\t\t\t\t\ttodaysChangeDisplay = \"N/A\";\n\t\t\t\t} else if (internationalizer) {\n\t\t\t\t\ttodaysChangeDisplay = internationalizer.percent2.format(\n\t\t\t\t\t\ttodaysChangePct / 100\n\t\t\t\t\t);\n\t\t\t\t} else {\n\t\t\t\t\ttodaysChangeDisplay = todaysChangePct.toFixed(2) + \"%\";\n\t\t\t\t}\n\t\t\t\tchangeDiv.style.display = \"\";\n\t\t\t} else if (changeDiv) {\n\t\t\t\tchangeDiv.style.display = \"none\";\n\t\t\t}\n\n\t\t\tconst todaysChangeAbs = Math.abs(todaysChange);\n\t\t\tconst txtChange = stx.formatYAxisPrice(\n\t\t\t\ttodaysChangeAbs,\n\t\t\t\tstx.chart.panel,\n\t\t\t\tstx.chart.decimalPlaces\n\t\t\t);\n\t\t\tif (todaysChangeAbs) {\n\t\t\t\tif (todaysChangeDiv.innerText !== txtChange)\n\t\t\t\t\ttodaysChangeDiv.innerText = txtChange;\n\t\t\t}\n\t\t\tif (todaysChangePctDiv) {\n\t\t\t\tif (todaysChangePctDiv.innerText !== todaysChangeDisplay)\n\t\t\t\t\ttodaysChangePctDiv.innerText = todaysChangeDisplay;\n\t\t\t}\n\t\t\tif (todaysChangeDisplay !== \"\" && todaysChange < 0) {\n\t\t\t\tchartPriceDiv.classList.add(\"stx-down\");\n\t\t\t} else {\n\t\t\t\tchartPriceDiv.classList.remove(\"stx-down\");\n\t\t\t}\n\t\t\tif (todaysChangeDisplay !== \"\" && todaysChange > 0) {\n\t\t\t\tchartPriceDiv.classList.add(\"stx-up\");\n\t\t\t} else {\n\t\t\t\tchartPriceDiv.classList.remove(\"stx-up\");\n\t\t\t}\n\n\t\t\tcurrentPrice = currentPrice !== undefined ? currentPrice : \"\";\n\t\t\ttodaysChange = todaysChange !== undefined ? todaysChange : \"\";\n\n\t\t\t// These strange characters create some spacing so that the title appears\n\t\t\t// correctly in a browser tab\n\t\t\tthis.title =\n\t\t\t\tsymbol + \" \\u200b \\u200b \" + textPrice + \" \\u200b \\u200b \\u200b \";\n\t\t\tif (todaysChange > 0) {\n\t\t\t\tthis.title += \"\\u25b2 \" + txtChange;\n\t\t\t} else if (todaysChange < 0) {\n\t\t\t\tthis.title += \"\\u25bc \" + txtChange;\n\t\t\t}\n\t\t\tif (doUpdateBrowserTab) {\n\t\t\t\tthis.ownerDocument.title = this.title;\n\t\t\t}\n\t\t}\n\t}\n}\n\nChartTitle.markup = `\n\t\t\n\t\t\n\t\t\t1D\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\t
\n\t\t\t\t (\n\t\t\t\t)\n\t\t\t
\n\t\t
\n\t\t
\n\t`;\nCIQ.UI.addComponentDefinition(\"cq-chart-title\", ChartTitle);\n\n};\n\n\nlet __js_webcomponents_chartcontrolGroup_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\n\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Creates a `` web component. The chart control group is a wrapper element for\n * chart UI controls, enabling the controls to be placed on top of the chart.\n *\n * **Note:** The `cq-marker` attribute must be added to the element to place it within the chart area.\n * The element will sit above the chart bars.\n *\n * @namespace WebComponents.cq-chartcontrol-group\n * @example\n\t\n\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\tALL\n\t\t\t\t\t\tSTOCKS\n\t\t\t\t\t\tFX\n\t\t\t\t\t\tINDEXES\n\t\t\t\t\t\tFUNDS\n\t\t\t\t\t\tFUTURES\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\n\t\tDraw\n\t\tCrosshair\n\t\t\n\t\t\t1D\n\t\t\t\n\t\t\t\t1 D\n\t\t\t\t1 W\n\t\t\t\t1 Mo\n\t\t\t\t\n\t\t\t\t1 Min\n\t\t\t\t5 Min\n\t\t\t\t10 Min\n\t\t\t\t15 Min\n\t\t\t\t30 Min\n\t\t\t\t1 Hour\n\t\t\t\t4 Hour\n\t\t\t\t\n\t\t\t\t1 Sec\n\t\t\t\t10 Sec\n\t\t\t\t30 Sec\n\t\t\t\t\n\t\t\t\t250 MSec\n\t\t\t\n\t\t\n\t\n *\n * @since 7.3.0\n */\nclass ChartcontrolGroup extends CIQ.UI.ModalTag {\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tsuper.connectedCallback();\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, ChartcontrolGroup);\n\t\tthis.constructor = ChartcontrolGroup;\n\t}\n\n\tsetContext(context) {\n\t\tthis.addDefaultMarkup();\n\t\tvar node = this.node;\n\n\t\t// Prevent interaction events from propagating through the panel to the chart\n\t\tnode[0].addEventListener(\n\t\t\t\"touchstart\",\n\t\t\tfunction (event) {\n\t\t\t\tevent.stopPropagation();\n\t\t\t},\n\t\t\t{ passive: false }\n\t\t);\n\t\tnode[0].addEventListener(\"mousedown\", function (event) {\n\t\t\tevent.stopPropagation();\n\t\t});\n\n\t\t// Set focus on the input field when tapped to invoke\n\t\t// on-screen keyboard.\n\t\tvar input = node.find(\"input\");\n\t\tCIQ.UI.stxtap(input[0], function () {\n\t\t\tthis.focus();\n\t\t});\n\t}\n}\n\nChartcontrolGroup.markup = `\n\t\t\n\t\t\t\n\t\t\n\t\tDraw\n\t\tCrosshair\n\t\tTable View\n\t\t\n\t\t\t1D\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\n\t`;\nCIQ.UI.addComponentDefinition(\"cq-chartcontrol-group\", ChartcontrolGroup);\n\n};\n\n\nlet __js_webcomponents_clickable_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Clickable web component ``.\n *\n * When tapped/clicked, this component can run a method on any other component. Set the\n * `cq-selector` attribute to a selector for the other component. Set `cq-method` to the method\n * to run on that component. The parameter provided to the method is an object that contains\n * the context (if available) for this clickable component (\"context\") and a reference to the\n * component (\"caller\").\n *\n * For example:\n * ```html\n * Settings\n * ```\n * runs\n * ```js\n * document.querySelector(\"cq-sample-dialog\").open({context: this.context, caller: this});\n * ```\n *\n * @namespace WebComponents.cq-clickable\n * @since 3.0.9\n */\nclass Clickable extends CIQ.UI.ContextTag {\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tsuper.connectedCallback();\n\t\tvar self = this;\n\n\t\tCIQ.UI.stxtap(this, function () {\n\t\t\tself.runMethod();\n\t\t});\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, Clickable);\n\t}\n\n\t/**\n\t * Runs a method on the clickable component.\n\t *\n\t * @alias runMethod\n\t * @memberof WebComponents.cq-clickable\n\t */\n\trunMethod() {\n\t\tvar selector = this.node.attr(\"cq-selector\");\n\t\tvar method = this.node.attr(\"cq-method\");\n\n\t\tconst { context } = this;\n\t\tif (/-dialog/.test(selector) && method === \"open\" && context.config) {\n\t\t\tconst channel =\n\t\t\t\t(context.config.channels || {}).dialog || \"channel.dialog\";\n\n\t\t\tthis.channelWrite(\n\t\t\t\tchannel,\n\t\t\t\t{\n\t\t\t\t\ttype: selector.replace(/cq-|-dialog/g, \"\"),\n\t\t\t\t\tparams: { context, caller: this }\n\t\t\t\t},\n\t\t\t\tcontext.stx\n\t\t\t);\n\t\t\treturn;\n\t\t}\n\n\t\tvar clickable = this;\n\t\tthis.ownerDocument.querySelectorAll(selector).forEach(function (i) {\n\t\t\tif (i[method])\n\t\t\t\ti[method].call(i, {\n\t\t\t\t\tcontext: clickable.context,\n\t\t\t\t\tcaller: clickable\n\t\t\t\t});\n\t\t});\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-clickable\", Clickable);\n\n};\n\n\nlet __js_webcomponents_close_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Close web component ``.\n *\n * cq-close web component will close its containing (parent or up) component\n * by calling its close() method\n * @namespace WebComponents.cq-close\n * @example\n * \n * \t\t\n * \t\t\n * \n *\n */\nclass Close extends CIQ.UI.BaseComponent {\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tvar self = this;\n\t\tfunction closure(e) {\n\t\t\tself.tap();\n\t\t\te.stopPropagation();\n\t\t}\n\t\tCIQ.UI.stxtap(this, closure);\n\t\tsuper.connectedCallback();\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, Close);\n\t}\n\n\t/**\n\t * @alias tap\n\t * @memberof WebComponents.cq-close\n\t */\n\ttap() {\n\t\tCIQ.UI.containerExecute(this, \"close\");\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-close\", Close);\n\n};\n\n\nlet __js_webcomponents_comparison_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Symbol comparison component ``.\n *\n * Add attribute `cq-marker` to have the component insert itself as a marker on the chart.\n *\n * For `cq-comparison-keys`:\n * - Add `attribute cq-panel-only` to have the component show only series in the panel\n * - Add `attribute cq-all-series` to have the component show even non-comparison series in the legend\n *\n * **Note:**\n * - By default, the comparison web component will not connect gaps in the data to indicate data points are missing due to discrepancies between marker hours or due to thinly traded instruments. If you want it to behave differently, you will need to override these defaults.\n * Do not make the changes directly on *components.js*, but rather create a separate file with a copy of the methods you are overwriting and load that file right after the *components.js* file is loaded, but before any web components are instantiated. This allows for easier upgrades.\n * Look for the `addSeries` call and use the `gapDisplayStyle` parameter (or any other required parameter) as outlined in {@link CIQ.ChartEngine#addSeries}.\n *\n * - To adjust the comparison's automatic color selector, set `document.querySelector('cq-comparison').swatchColors` to an array of colors.\n * To adjust colors from the color picker popup, execute:\n * ```\n * const picker = document.querySelector('cq-color-picker');\n * picker.params.colorMap=[[row 1 of colors],[row 2 of colors],[row 3 of colors],[etc.]]\n * picker.initialize();\n * ```\n *\n * You can use `cq-swatch` rather than `cq-comparison-swatch` to allow user to change the series color.\n *\n * @namespace WebComponents.cq-comparison\n *\n * @example\n * document.querySelector('cq-comparison').swatchColors=[\"rgb(142, 198, 72)\"];\n * const picker = document.querySelector('cq-color-picker');\n * picker.params.colorMap=[[\"#ffffff\", \"#e1e1e1\", \"#cccccc\", \"#b7b7b7\", \"#a0a0a5\", \"#898989\", \"#707070\", \"#626262\", \"#555555\", \"#464646\", \"#363636\", \"#262626\", \"#1d1d1d\", \"#000000\"]];\n * picker.initialize();\n *\n * @example\n * \n * \n * \n * Compare...\n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * ALL\n * STOCKS\n * FX\n * INDEXES\n * FUNDS\n * FUTURES\n * \n * \n * \n * \n * \n * \n * ADD\n * \n * \n * \n * \n * \n * \n *\n * @since 7.3.0 Added the ability to set series color using `cq-swatch`.\n */\nclass Comparison extends CIQ.UI.ModalTag {\n\tconstructor() {\n\t\tsuper();\n\t\tthis.swatchColors = [];\n\t\tthis.loading = [];\n\t}\n\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tsuper.connectedCallback();\n\t\tthis.swatchColors = [\n\t\t\t\"#8ec648\",\n\t\t\t\"#00afed\",\n\t\t\t\"#ee652e\",\n\t\t\t\"#912a8e\",\n\t\t\t\"#fff126\",\n\t\t\t\"#e9088c\",\n\t\t\t\"#ea1d2c\",\n\t\t\t\"#00a553\",\n\t\t\t\"#00a99c\",\n\t\t\t\"#0056a4\",\n\t\t\t\"#f4932f\",\n\t\t\t\"#0073ba\",\n\t\t\t\"#66308f\",\n\t\t\t\"#323390\"\n\t\t];\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, Comparison);\n\t}\n\n\t/**\n\t * Initializes all the children UI elements that make up ``.\n\t * @alias configureUI\n\t * @memberof WebComponents.cq-comparison#\n\t */\n\tconfigureUI() {\n\t\tvar node = this.node;\n\t\tvar addNew = node.find(\"cq-accept-btn\");\n\t\tthis.template = node.find(\"*[cq-comparison-item]\");\n\t\tvar swatchColors = node.find(\"cq-swatch\").attr(\"cq-colors\");\n\t\tif (swatchColors) this.swatchColors = swatchColors.split(\",\");\n\t\tfor (var i = 0; i < this.swatchColors.length; i++) {\n\t\t\tthis.swatchColors[i] = CIQ.convertToNativeColor(this.swatchColors[i]);\n\t\t}\n\t\tvar lookup = node.find(\"cq-lookup\");\n\t\tif (lookup.length)\n\t\t\tlookup[0].setCallback(\n\t\t\t\t(function (self) {\n\t\t\t\t\treturn function () {\n\t\t\t\t\t\tself.selectItem.apply(self, arguments);\n\t\t\t\t\t};\n\t\t\t\t})(this)\n\t\t\t);\n\t\tCIQ.UI.stxtap(addNew[0], function (e) {\n\t\t\tlookup[0].forceInput();\n\t\t\te.stopPropagation();\n\t\t});\n\n\t\t// Add the keystroke claim\n\t\tthis.addClaim(this);\n\n\t\tconst keystrokeHub = this.ownerDocument.body.keystrokeHub;\n\t\tif (!keystrokeHub) return;\n\n\t\tlet menu = this.querySelector(\"cq-menu.cq-comparison-new\");\n\t\tif (menu) {\n\t\t\t// Extend the internal menu's hide function so we can do some cleanup\n\t\t\tlet menuHide = menu.hide.bind(menu);\n\t\t\tmenu.hide = () => {\n\t\t\t\t//const keystrokeHub = document.body.keystrokeHub;\n\t\t\t\t// Treat the legend like a modal so keyboard navigation is returned after using colorPicker\n\t\t\t\tkeystrokeHub.removeActiveModal(this);\n\t\t\t\tkeystrokeHub.tabOrderSelect();\n\t\t\t\tmenuHide();\n\t\t\t};\n\t\t}\n\n\t\t// Add a stxtap handler to the component strictly for keyboard navigation\n\t\tCIQ.UI.stxtap(this, function (e) {\n\t\t\tif (this.keyboardNavigation) {\n\t\t\t\t// Open the menu automatically\n\t\t\t\tif (menu) menu.open();\n\t\t\t\t// Treat the legend like a modal so keyboard navigation is returned after using colorPicker\n\t\t\t\tkeystrokeHub.addActiveModal(this);\n\t\t\t}\n\t\t\te.stopPropagation();\n\t\t});\n\t}\n\n\t/**\n\t * left and Right arrows will move between symbol lookup, color piker and \"Add\" button.\n\t * The attribute cq-focused will be added to the currently focused tag. This can then be\n\t * queried later, such as when a user hits enter.\n\t *\n\t * @param {CIQ.UI.KeystrokeHub} hub The hub that processed the key\n\t * @param {string} key Key that was stroked\n\t * @param {object} e The event object\n\t * @return {boolean}\n\t */\n\tkeyStroke(hub, key, e) {\n\t\tif (!this.keyboardNavigation) return;\n\t\tconst items = this.querySelectorAll(\n\t\t\t\"cq-lookup, cq-swatch, cq-accept-btn, [keyboard-selectable='true']\"\n\t\t);\n\t\tif (!items.length) return;\n\t\tconst focused = this.findFocused(items);\n\t\tswitch (key) {\n\t\t\tcase \"Enter\":\n\t\t\t\tif (!focused[0]) return;\n\t\t\t\tthis.clickItem(focused[0], e, this);\n\t\t\t\tbreak;\n\t\t\tcase \"Tab\":\n\t\t\t\tif (focused[0] && focused[0].tagName == \"CQ-LOOKUP\") {\n\t\t\t\t\tthis.keyboardNavigation.disableKeyControlElement(focused[0], true);\n\t\t\t\t\thub.tabActiveElement.element.blur();\n\t\t\t\t\tfocused[0].overrideIsActive = true;\n\t\t\t\t}\n\t\t\t\tlet newFocused = this.focusNextItem(items, false, true);\n\t\t\t\tif (newFocused.tagName == \"CQ-LOOKUP\") {\n\t\t\t\t\tnewFocused.keyboardNavigation = this.keyboardNavigation;\n\t\t\t\t\tif (newFocused.onKeyboardSelection) newFocused.onKeyboardSelection();\n\t\t\t\t\tnewFocused.overrideIsActive = false;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase \"Esc\":\n\t\t\tcase \"Escape\":\n\t\t\t\tthis.removeFocused(items);\n\t\t\t\tlet menu = this.querySelector(\"cq-menu.cq-comparison-new\");\n\t\t\t\tif (menu) menu.hide();\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\te.preventDefault();\n\t\t\t\tbreak;\n\t\t}\n\t}\n\n\t/**\n\t * Triggers the comparison lookup component and passes keyboard control into the internal\n\t * [cq-lookup]{@link WebComponents.cq-lookup} element.\n\t *\n\t * Called when keyboard navigation activates this element by pressing Return/Enter.\n\t *\n\t * @alias onKeyboardSelection\n\t * @memberof WebComponents.cq-comparison#\n\t * @since 8.3.0\n\t */\n\tonKeyboardSelection() {\n\t\t// Pass control to the lookup component\n\t\tlet lookup = this.querySelector(\"cq-lookup\");\n\t\tlookup.setAttribute(\"cq-focused\", \"true\");\n\t\tlookup.overrideIsActive = false;\n\t\tlookup.keyboardNavigation = this.keyboardNavigation;\n\t\tif (lookup.onKeyboardSelection) lookup.onKeyboardSelection();\n\t}\n\n\t/**\n\t * Picks a color to display the new comparison as.\n\t * Loops through preset colors and picks the next one on the list.\n\t * If all colors are taken, then the last color will be repeated.\n\t * @alias pickSwatchColor\n\t * @memberof WebComponents.cq-comparison#\n\t */\n\tpickSwatchColor() {\n\t\tCIQ.UI.pickSwatchColor(this, this.querySelector(\"cq-swatch\"));\n\t}\n\n\tposition() {\n\t\tvar stx = this.context.stx;\n\t\tvar bar = stx.barFromPixel(stx.cx);\n\t\tthis.tick = stx.tickFromPixel(stx.cx);\n\t\tvar prices = stx.chart.xaxis[bar];\n\t\tvar self = this;\n\n\t\tfunction printValues() {\n\t\t\tvar key;\n\t\t\tself.timeout = null;\n\t\t\tfor (var s in stx.chart.series) {\n\t\t\t\tif (!key) key = self.node.find(\"cq-comparison-key\");\n\t\t\t\tvar price = key.find(\n\t\t\t\t\t'cq-comparison-item[cq-symbol=\"' + s + '\"] cq-comparison-tick-price'\n\t\t\t\t);\n\t\t\t\tif (price.text() !== \"\") price.text(\"\");\n\t\t\t\tif (price.length && prices && prices.data) {\n\t\t\t\t\tvar symbol = stx.chart.series[s].parameters.symbol;\n\t\t\t\t\tvar paddedPrice = stx.padOutPrice(prices.data[symbol]);\n\t\t\t\t\tif (price.text() !== paddedPrice) price.text(paddedPrice);\n\t\t\t\t\tvar pdSymbol = prices.data[symbol];\n\t\t\t\t\tif (pdSymbol !== null) {\n\t\t\t\t\t\tif (typeof pdSymbol === \"object\") pdSymbol = pdSymbol.Close;\n\t\t\t\t\t\tpaddedPrice = stx.padOutPrice(pdSymbol);\n\t\t\t\t\t\tif (price.text() !== paddedPrice) price.text(paddedPrice);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (this.tick != this.prevTick) {\n\t\t\tif (this.timeout) clearTimeout(this.timeout);\n\t\t\tvar ms = 0; // IE and FF struggle to keep up with the dynamic heads up.\n\t\t\tthis.timeout = setTimeout(printValues, ms);\n\t\t}\n\t\tthis.prevTick = this.tick; // We don't want to update the dom every pixel, just when we cross into a new candle\n\t}\n\n\t/**\n\t * Handles removing a series from the comparison.\n\t * @param {string} symbol Name of series as a string.\n\t * @param {object} series Object containing info on series.\n\t * @alias removeSeries\n\t * @memberof WebComponents.cq-comparison#\n\t */\n\tremoveSeries(symbol, series) {\n\t\tthis.context.stx.removeSeries(symbol);\n\t}\n\n\t/**\n\t * The legend gets re-rendered whenever we createDataSet() (wherein the series may have changed).\n\t * We re-render the entire thing each time, but we use a virtual DOM to determine whether\n\t * to actually change anything on the screen (so as to avoid unnecessary flickering)\n\t * @alias renderLegend\n\t * @memberof WebComponents.cq-comparison#\n\t */\n\trenderLegend() {\n\t\tfunction tapFunction(self, s, series) {\n\t\t\treturn function () {\n\t\t\t\tself.nomore = true;\n\t\t\t\tif (!series.parameters.permanent) self.removeSeries(s, series);\n\t\t\t\tself.modalEnd(); // tricky, we miss mouseout events when we remove items from under ourselves\n\t\t\t};\n\t\t}\n\t\tthis.pickSwatchColor();\n\t\tvar holder = this.closest(\".stx-holder\");\n\t\tvar key = CIQ.cqvirtual(this.querySelector(\"cq-comparison-key\"));\n\t\tif (!key) return;\n\t\tvar keyAppend = function (i) {\n\t\t\tkey.appendChild(i);\n\t\t};\n\t\tvar stx = this.context.stx;\n\t\tstx.getDefaultColor();\n\t\tvar panelOnly = key.hasAttribute(\"cq-panel-only\");\n\t\tvar comparisonOnly = !key.hasAttribute(\"cq-all-series\");\n\t\tfor (var r in stx.chart.seriesRenderers) {\n\t\t\tvar renderer = stx.chart.seriesRenderers[r];\n\t\t\tif (renderer == stx.mainSeriesRenderer) continue;\n\t\t\tif (comparisonOnly && !renderer.params.isComparison) continue;\n\t\t\tif (panelOnly && (!holder || renderer.params.panel != holder.panel.name))\n\t\t\t\tcontinue;\n\t\t\tfor (var s = 0; s < renderer.seriesParams.length; s++) {\n\t\t\t\tvar rSeries = renderer.seriesParams[s];\n\t\t\t\tvar frag = CIQ.UI.makeFromTemplate(this.template);\n\t\t\t\tvar comparisonSwatch = frag.find(\"cq-comparison-swatch\");\n\t\t\t\tvar swatch = frag.find(\"cq-swatch\");\n\t\t\t\tvar label = frag.find(\"cq-comparison-label\");\n\t\t\t\tvar description = frag.find(\"cq-comparison-description\");\n\t\t\t\tvar loader = frag.find(\"cq-comparison-loader\");\n\t\t\t\tvar btn = frag.find(\".ciq-close\");\n\t\t\t\tvar series = stx.chart.series[rSeries.id];\n\t\t\t\tvar seriesParameters = series.parameters;\n\t\t\t\tvar color = seriesParameters.color || renderer.colors[series.id].color;\n\t\t\t\tvar isAuto = color == \"auto\";\n\t\t\t\tif (isAuto) color = stx.defaultColor;\n\t\t\t\tcomparisonSwatch.css({ background: color });\n\t\t\t\tif (swatch.length) {\n\t\t\t\t\tswatch[0].seriesId = rSeries.id;\n\t\t\t\t\tswatch[0].setColor(color, false, isAuto);\n\t\t\t\t}\n\t\t\t\tif (seriesParameters.opacity) {\n\t\t\t\t\tcomparisonSwatch.css({ opacity: seriesParameters.opacity });\n\t\t\t\t\tswatch.css({ opacity: seriesParameters.opacity });\n\t\t\t\t}\n\t\t\t\tlabel.text(stx.translateIf(series.display));\n\t\t\t\tdescription.text(stx.translateIf(series.description));\n\t\t\t\tfrag.attr(\"cq-symbol\", series.id);\n\n\t\t\t\tvar symbol = seriesParameters.symbol;\n\t\t\t\tvar q = stx.mostRecentClose(symbol);\n\t\t\t\tif (q || q === 0) {\n\t\t\t\t\tvar price = frag.find(\"cq-comparison-price\");\n\t\t\t\t\tif (price.length) {\n\t\t\t\t\t\tprice.text(stx.padOutPrice(q));\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif (this.loading[seriesParameters.symbolObject.symbol])\n\t\t\t\t\tloader.addClass(\"stx-show\");\n\t\t\t\telse loader.removeClass(\"stx-show\");\n\n\t\t\t\tif (seriesParameters.error) frag.attr(\"cq-error\", true);\n\t\t\t\tif (!seriesParameters.color || seriesParameters.permanent) btn.hide();\n\t\t\t\telse {\n\t\t\t\t\tCIQ.UI.stxtap(btn[0], tapFunction(this, series.id, series));\n\t\t\t\t}\n\t\t\t\tArray.from(frag).forEach(keyAppend);\n\t\t\t}\n\t\t}\n\n\t\tvar legendParent = CIQ.climbUpDomTree(CIQ.cqrender(key), \"cq-study-legend\");\n\t\tlegendParent.forEach(function (i) {\n\t\t\tif (i.displayLegendTitle) i.displayLegendTitle();\n\t\t});\n\t}\n\n\t/**\n\t * Changes the color of a series; triggered if using [cq-swatch]{@link WebComponents.cq-swatch} to show the series color.\n\t *\n\t * @param {string} color New color.\n\t * @param {object} swatch Swatch from which the color setting is made.\n\t *\n\t * @alias setColor\n\t * @memberof WebComponents.cq-comparison#\n\t * @since 7.3.0\n\t */\n\tsetColor(color, swatch) {\n\t\tif (swatch.seriesId)\n\t\t\tthis.context.stx.modifySeries(swatch.seriesId, { color: color });\n\t}\n\n\t/**\n\t * Adds an injection to the ChartEngine that tracks the price of Comparisons.\n\t * @param {number} updatePrices\n\t * @alias startPriceTracker\n\t * @memberof WebComponents.cq-comparison#\n\t */\n\tstartPriceTracker(updatePrices) {\n\t\tvar self = this;\n\t\tthis.addInjection(\"append\", \"createDataSet\", function () {\n\t\t\tif (updatePrices) self.updatePrices();\n\t\t\tif (this.chart.dataSet && this.chart.dataSet.length) {\n\t\t\t\tif (self.node.attr(\"cq-show\") !== \"true\")\n\t\t\t\t\tself.node.attr(\"cq-show\", \"true\");\n\t\t\t} else if (self.hasAttribute(\"cq-show\")) self.removeAttribute(\"cq-show\");\n\t\t});\n\t}\n\n\tstartTickPriceTracker() {\n\t\tthis.prevTick = null;\n\t\tthis.addInjection(\n\t\t\t\"prepend\",\n\t\t\t\"headsUpHR\",\n\t\t\t(function (self) {\n\t\t\t\treturn function () {\n\t\t\t\t\tself.position();\n\t\t\t\t};\n\t\t\t})(this)\n\t\t);\n\t}\n\n\t/**\n\t * Fires whenever a new security is added as a comparison. Handles all the necessary events\n\t * to update the chart with the new comparison.\n\t *\n\t * @param {object} obj Contains information about the security.\n\t * @param {string} obj.symbol The symbol that identifies the security.\n\t *\n\t * @alias selectItem\n\t * @memberof WebComponents.cq-comparison#\n\t * @since 8.2.0 Removed the `context` parameter. The context is now accessed from the base\n\t * \t\tcomponent class.\n\t */\n\tselectItem(obj) {\n\t\tvar context = this.context;\n\t\tvar self = this;\n\t\tfunction cb(err, series) {\n\t\t\tif (err) {\n\t\t\t\tseries.parameters.error = true;\n\t\t\t}\n\t\t\tself.loading[series.parameters.symbolObject.symbol] = false;\n\t\t\tself.renderLegend();\n\t\t}\n\t\tvar swatch = this.node.find(\"cq-swatch\");\n\t\tvar color = \"auto\",\n\t\t\tpattern = null,\n\t\t\twidth = 1;\n\t\tif (swatch[0]) {\n\t\t\tvar style = swatch[0].style;\n\t\t\tcolor = style.backgroundColor;\n\t\t\tpattern = style.borderTopStyle;\n\t\t\twidth = style.width || 1;\n\t\t}\n\t\tvar stx = context.stx;\n\t\tthis.loading[obj.symbol] = true;\n\t\tvar params = {\n\t\t\tname: \"comparison \" + obj.symbol,\n\t\t\tsymbolObject: obj,\n\t\t\tisComparison: true,\n\t\t\tcolor: color,\n\t\t\tpattern: pattern,\n\t\t\twidth: width || 1,\n\t\t\tdata: { useDefaultQuoteFeed: true },\n\t\t\tforceData: true\n\t\t};\n\n\t\t// don't allow symbol if same as main chart, comparison already exists, or just white space\n\t\tvar exists = stx.getSeries({ symbolObject: obj });\n\t\tfor (var i = 0; i < exists.length; i++)\n\t\t\tif (exists[i].parameters.isComparison) {\n\t\t\t\tthis.loading[obj.symbol] = false;\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t// don't allow symbol if same as main chart or just white space\n\t\tif (\n\t\t\tobj.symbol &&\n\t\t\tobj.symbol.trim().length > 0 &&\n\t\t\t(!context.stx.chart.symbol ||\n\t\t\t\tcontext.stx.chart.symbol.toLowerCase() !== obj.symbol.toLowerCase())\n\t\t) {\n\t\t\tstx.addSeries(obj.symbol, params, cb);\n\t\t} else {\n\t\t\tthis.loading[obj.symbol] = false;\n\t\t}\n\t}\n\n\tsetContext(context) {\n\t\tthis.node.attr(\"cq-show\", \"true\");\n\t\t// if attribute cq-marker then detach and put ourselves in the chart holder\n\t\tthis.configureUI();\n\t\tvar self = this,\n\t\t\tstx = this.context.stx,\n\t\t\tchart = stx.chart;\n\t\tfunction renderIfChanged(obj) {\n\t\t\tself.renderLegend();\n\t\t}\n\t\t[\"layout\", \"symbolImport\", \"symbolChange\", \"theme\"].forEach(function (ev) {\n\t\t\tstx.addEventListener(ev, renderIfChanged);\n\t\t});\n\t\tthis.context.stx.append(\"modifySeries\", function () {\n\t\t\tself.renderLegend();\n\t\t});\n\t\tthis.renderLegend();\n\t\tif (!this.template.length) return;\n\t\tvar frag = CIQ.UI.makeFromTemplate(this.template);\n\t\tthis.startPriceTracker(frag.find(\"cq-comparison-price\").length);\n\t\tif (frag.find(\"cq-comparison-tick-price\")) {\n\t\t\tthis.startTickPriceTracker();\n\t\t}\n\t}\n\n\t/**\n\t * Loops thru `stxx.chart.series` to update the current price of all comparisons.\n\t * @alias updatePrices\n\t * @memberof WebComponents.cq-comparison#\n\t */\n\tupdatePrices() {\n\t\tvar key; // lazy eval this to prevent work when no comparisons exist\n\t\tvar stx = this.context.stx;\n\t\tvar historical = stx.isHistoricalModeSet;\n\t\tvar isDaily = CIQ.ChartEngine.isDailyInterval(stx.layout.interval);\n\t\tfor (var s in stx.chart.series) {\n\t\t\tif (!key) key = this.node.find(\"cq-comparison-key\");\n\t\t\tvar price = key.find(\n\t\t\t\t'cq-comparison-item[cq-symbol=\"' + s + '\"] cq-comparison-price'\n\t\t\t);\n\t\t\tif (price.length) {\n\t\t\t\tvar symbol = stx.chart.series[s].parameters.symbol;\n\t\t\t\tvar q = stx.chart.series[s].lastQuote;\n\t\t\t\tif (!q || !q.DT || (!q.Close && q.Close !== 0)) continue;\n\t\t\t\tif (\n\t\t\t\t\t!isDaily &&\n\t\t\t\t\tstx.chart.market &&\n\t\t\t\t\tstx.chart.market.getSession(q.DT) === null\n\t\t\t\t)\n\t\t\t\t\tcontinue; // don't update when no session\n\t\t\t\tvar newPrice = q.Close;\n\t\t\t\tvar field = stx.chart.series[s].parameters.subField || \"Close\";\n\t\t\t\tvar oldPrice = parseFloat(price.text());\n\t\t\t\tif (newPrice && (newPrice[field] || newPrice[field] === 0))\n\t\t\t\t\tnewPrice = newPrice[field];\n\t\t\t\tif (!newPrice && newPrice !== 0 && stx.chart.series[s].lastQuote)\n\t\t\t\t\tnewPrice = stx.chart.series[s].lastQuote[field];\n\t\t\t\tvar priceText = stx.padOutPrice(historical ? \"\" : newPrice);\n\t\t\t\tif (price.text() !== priceText) price.text(priceText);\n\t\t\t\tif (historical) return;\n\t\t\t\tif (typeof price.attr(\"cq-animate\") != \"undefined\")\n\t\t\t\t\tCIQ.UI.animatePrice(price, newPrice, oldPrice);\n\t\t\t}\n\t\t}\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-comparison\", Comparison);\n\n};\n\n\nlet __js_webcomponents_comparisonLookup_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * The comparison lookup web component ``.\n *\n * An encapsulation of the markup for the comparison lookup control, **+ Compare...**\n *\n * @namespace WebComponents.cq-comparison-lookup\n * @since 7.5.0\n *\n * @example\n * \n * \n * \n * Compare...\n * \n * \n * \n * \n * \n * \n * ADD\n * \n * \n * \n */\nclass ComparisonLookup extends CIQ.UI.ContextTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, ComparisonLookup);\n\t\tthis.constructor = ComparisonLookup;\n\t}\n\n\t/**\n\t * Adds the default markup.\n\t *\n\t * @alias setContext\n\t * @memberof WebComponents.cq-comparison-lookup\n\t * @since 7.5.0\n\t */\n\tsetContext() {\n\t\tif (this.contextSet) return;\n\t\tthis.contextSet = true;\n\t\tthis.addDefaultMarkup();\n\t}\n}\n\nComparisonLookup.markup = `\n\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\tCompare...\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\tADD\n\t\t\t\t\n\t\t\t\n\t\t\n\t`;\n\nCIQ.UI.addComponentDefinition(\"cq-comparison-lookup\", ComparisonLookup);\n\n};\n\n\nlet __js_webcomponents_cvpController_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Simple web component that allows data binding to arbitrary properties of\n * {@link CIQ.ChartEngine.currentVectorParameters}. Ideal for use as a drawing toolbar extension.\n *\n * @namespace WebComponents.cq-cvp-controller\n *\n * @example\n * \n *
\n *
Dev 1
\n * \n * \n * \n *
\n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n *
\n */\nclass CVPController extends CIQ.UI.ContextTag {\n\tget active() {\n\t\treturn this.context.stx.currentVectorParameters[\"active\" + this._scope];\n\t}\n\n\tset active(value) {\n\t\tthis.context.stx.currentVectorParameters[\"active\" + this._scope] = value;\n\t}\n\n\tget color() {\n\t\treturn this.context.stx.currentVectorParameters[\"color\" + this._scope];\n\t}\n\n\tset color(value) {\n\t\tthis.context.stx.currentVectorParameters[\"color\" + this._scope] = value;\n\t}\n\n\tget lineWidth() {\n\t\treturn this.context.stx.currentVectorParameters[\"lineWidth\" + this._scope];\n\t}\n\n\tset lineWidth(value) {\n\t\tthis.context.stx.currentVectorParameters[\"lineWidth\" + this._scope] = value;\n\t}\n\n\tget pattern() {\n\t\treturn this.context.stx.currentVectorParameters[\"pattern\" + this._scope];\n\t}\n\n\tset pattern(value) {\n\t\tthis.context.stx.currentVectorParameters[\"pattern\" + this._scope] = value;\n\t}\n\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\n\t\tObject.defineProperty(this, \"_scope\", {\n\t\t\tconfigurable: true,\n\t\t\tenumerable: false,\n\t\t\tvalue: this.getAttribute(\"cq-cvp-header\") || \"\",\n\t\t\twritable: false\n\t\t});\n\n\t\tvar tmpl = this.ownerDocument.querySelector(\n\t\t\t'template[cq-cvp-controller], template[cvp-controller=\"true\"]'\n\t\t);\n\n\t\tif (this.children.length === 0 && tmpl) {\n\t\t\tvar nodes = CIQ.UI.makeFromTemplate(tmpl, this);\n\t\t\tvar heading = this.querySelector(\".ciq-heading\");\n\t\t\tif (heading) {\n\t\t\t\theading.innerHTML = this._scope;\n\t\t\t}\n\t\t}\n\n\t\tsuper.connectedCallback();\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, CVPController);\n\t}\n\n\temit(eventName, value) {\n\t\tif (this.toolbar) {\n\t\t\tthis.toolbar.emit();\n\t\t} else {\n\t\t\tthis.dispatchEvent(\n\t\t\t\tnew CustomEvent(eventName, {\n\t\t\t\t\tbubbles: true,\n\t\t\t\t\tcancelable: true,\n\t\t\t\t\tdetail: value\n\t\t\t\t})\n\t\t\t);\n\t\t}\n\t}\n\n\tgetColor(activator) {\n\t\tvar node = CIQ.UI.$(activator.node || this.node.find(\"cq-line-color\"));\n\t\tvar color = this.color;\n\n\t\tif (color == \"transparent\" || color == \"auto\") {\n\t\t\tcolor = \"\";\n\t\t}\n\n\t\tnode.css({\n\t\t\tbackground: color\n\t\t});\n\n\t\tvar bgColor = CIQ.getBackgroundColor(this.parentNode);\n\t\tif (!color || Math.abs(CIQ.hsl(bgColor)[2] - CIQ.hsl(color)[2]) < 0.2) {\n\t\t\tvar border = CIQ.chooseForegroundColor(bgColor);\n\t\t\tnode.css({ border: \"solid \" + border + \" 1px\" });\n\t\t\tif (!color)\n\t\t\t\tnode.css({\n\t\t\t\t\tbackground:\n\t\t\t\t\t\t\"linear-gradient(to bottom right, \" +\n\t\t\t\t\t\tborder +\n\t\t\t\t\t\t\",\" +\n\t\t\t\t\t\tborder +\n\t\t\t\t\t\t\" 49%, \" +\n\t\t\t\t\t\tbgColor +\n\t\t\t\t\t\t\" 50%, \" +\n\t\t\t\t\t\tbgColor +\n\t\t\t\t\t\t\")\"\n\t\t\t\t});\n\t\t} else {\n\t\t\tnode.css({ border: \"\" });\n\t\t}\n\t}\n\n\tpickColor(activator) {\n\t\tvar node = CIQ.UI.$(activator.node);\n\t\tvar colorPicker = this.ownerDocument.querySelector(\"cq-color-picker\");\n\t\tvar cvpController = this;\n\t\tvar overrides = node.attr(\"cq-overrides\");\n\n\t\tif (!colorPicker)\n\t\t\treturn console.error(\n\t\t\t\t\"CVPController.prototype.pickColor: no available\"\n\t\t\t);\n\t\tif (overrides) activator.overrides = overrides.split(\",\");\n\n\t\tcolorPicker.callback = function (color) {\n\t\t\tcvpController.color = color;\n\t\t\tcvpController.getColor(activator);\n\t\t\tcvpController.emit(\"change\", {\n\t\t\t\tcolor: color\n\t\t\t});\n\t\t};\n\t\tactivator.context = this.context;\n\t\tcolorPicker.display(activator);\n\t}\n\n\tsetContext() {\n\t\tthis.setStyle();\n\t\tif (this.toolbar) this.toolbar.dirty(false);\n\t}\n\n\tsetStyle(activator, width, pattern) {\n\t\twidth = width || \"1\";\n\t\tpattern = pattern || \"dotted\";\n\n\t\tthis.lineWidth = parseInt(width, 10);\n\t\tthis.pattern = pattern;\n\n\t\tvar selection = this.node.find(\"*[cq-cvp-line-style]\");\n\n\t\tif (this.lineStyleClassName) {\n\t\t\tselection.removeClass(this.lineStyleClassName);\n\t\t}\n\n\t\tif (pattern && pattern !== \"none\") {\n\t\t\tthis.lineStyleClassName = \"ciq-\" + pattern + \"-\" + this.lineWidth;\n\t\t\tselection.addClass(this.lineStyleClassName);\n\t\t} else {\n\t\t\tthis.lineStyleClassName = null;\n\t\t}\n\n\t\tthis.emit(\"change\", {\n\t\t\tlineWidth: width,\n\t\t\tpattern: pattern\n\t\t});\n\t}\n\n\t/**\n\t * Update the component state with configuration. May be a drawing instance or\n\t * currentVectorParameters.\n\t *\n\t * @param {Object} config drawing instance or currentVectorParameters\n\t */\n\tsync(config) {\n\t\tvar active = config[\"active\" + this._scope];\n\t\tvar color = config[\"color\" + this._scope];\n\t\tvar lineWidth = config[\"lineWidth\" + this._scope];\n\t\tvar pattern = config[\"pattern\" + this._scope];\n\n\t\tvar className = \"ciq-active\";\n\t\tvar checkbox = this.node.find(\".ciq-checkbox\");\n\n\t\tif (active) {\n\t\t\tcheckbox.addClass(className);\n\t\t} else {\n\t\t\tcheckbox.removeClass(className);\n\t\t}\n\n\t\tthis.active = !!active;\n\t\tthis.color = color || \"\";\n\t\tthis.getColor({});\n\t\tthis.setStyle(null, lineWidth, pattern);\n\t}\n\n\ttoggleActive(activator) {\n\t\tvar node = CIQ.UI.$(activator.node);\n\t\tvar className = \"ciq-active\";\n\n\t\tif (this.active) {\n\t\t\tthis.active = false;\n\t\t\tnode.removeClass(className);\n\t\t} else {\n\t\t\tthis.active = true;\n\t\t\tnode.addClass(className);\n\t\t}\n\n\t\tthis.emit(\"change\", {\n\t\t\tactive: this.active\n\t\t});\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-cvp-controller\", CVPController);\n\n};\n\n\nlet __js_webcomponents_dataDialog_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n/**\n * Dialog form that allows users to upload CSV files to be loaded into the chart.\n * @namespace WebComponents.cq-data-dialog\n */\nclass DataDialog extends CIQ.UI.DialogContentTag {\n\tconstructor() {\n\t\tsuper();\n\t\tthis.fileMap = new Map();\n\t\tthis.swatchColors = CIQ.UI.defaultSwatchColors;\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, DataDialog);\n\t\tthis.constructor = DataDialog;\n\t}\n\n\t/**\n\t * Aborts the import of a file.\n\t * If that is the only file loaded then the form will reset to its default state.\n\t * @param {Event} e Submit event\n\t * @memberof WebComponents.cq-data-dialog\n\t */\n\tabortImport(e) {\n\t\tconst self = this;\n\t\tconst targetClose = e.target.nodeName === \"CQ-CLOSE\";\n\n\t\tconst fmf = [...this.fileMap.keys()];\n\t\tconst findIndexFn = (fname) => {\n\t\t\treturn (file) => file.name === fname;\n\t\t};\n\t\tfor (let fset of this.form.querySelectorAll(\"fieldset[name]\")) {\n\t\t\tlet fname = fset.getAttribute(\"fields\");\n\t\t\tif (e && e.target.getAttribute(\"fields\") !== fname && !targetClose)\n\t\t\t\tcontinue;\n\t\t\tlet idx = fmf.findIndex(findIndexFn(fname));\n\n\t\t\tthis.form.removeChild(fset.parentElement);\n\t\t\tthis.fileMap.delete(fmf[idx]);\n\t\t}\n\n\t\tif (targetClose) this.fileInput.value = \"\";\n\n\t\tif (!this.fileMap.size) {\n\t\t\tthis.fileInput.value = \"\";\n\t\t\tthis.loadDataBtn.style.display = \"inline-block\";\n\t\t\tthis.importBtn.style.display = \"none\";\n\t\t\tthis.querySelector(\"cq-section.loader\").style.display = \"flex\";\n\t\t\tthis.warn(\"\", \"\", true);\n\t\t\tCIQ.UI.containerExecute(this, \"resize\");\n\t\t}\n\n\t\tself.resetTabSelect();\n\t}\n\n\t/**\n\t * Closes dialog and resets it to the default state.\n\t * @memberof WebComponents.cq-data-dialog\n\t */\n\tclose() {\n\t\tthis.abortImport({ target: this.querySelector(\"cq-close\") });\n\t\tthis.channelWrite(\"channel.dataLoader\", false, this.context.stx);\n\t\tthis.loadDataBtn.style.display = this.fileInput.value ? \"none\" : \"inline\";\n\t\tthis.querySelector(\"cq-section.loader\").style.display = \"flex\";\n\t\tthis.warn(\"\", \"\", true);\n\t\tsuper.close();\n\t}\n\n\t/**\n\t * Gets FormData from fields and appends that data to the {@link CIQ.CSVReader}\n\t * @memberof WebComponents.cq-data-dialog\n\t */\n\tgetFormData() {\n\t\tconst appendFormData = (fieldSet, reader) => {\n\t\t\treturn (field) => {\n\t\t\t\tconst el = fieldSet.elements[field];\n\t\t\t\tlet value;\n\n\t\t\t\tif (el) {\n\t\t\t\t\tvalue = el.type === \"checkbox\" ? el.checked : el.value;\n\t\t\t\t} else {\n\t\t\t\t\tconst v = fieldSet.querySelector(`[name='${field}']`);\n\t\t\t\t\tif (v) value = v.value;\n\t\t\t\t}\n\n\t\t\t\treader.formData.append(field, value);\n\t\t\t};\n\t\t};\n\n\t\tfor (let entry of this.fileMap) {\n\t\t\tconst [file, reader] = entry;\n\t\t\tlet fieldSet = this.querySelector(`[name='${file.name}'] fieldset`);\n\n\t\t\treader.formData = new FormData();\n\t\t\t[\"name\", \"display\", \"periodicity\", \"panel\", \"color\"].forEach(\n\t\t\t\tappendFormData(fieldSet, reader)\n\t\t\t);\n\t\t}\n\t}\n\n\t/**\n\t * Hides the dialog without clearing data.\n\t * @memberof WebComponents.cq-data-dialog\n\t */\n\thide() {\n\t\tthis.channelWrite(\"channel.dataLoader\", false, this.context.stx);\n\t}\n\n\t/**\n\t * Imports the data if the dialog is in a valid state.\n\t * Closes dialog after successfully importing data.\n\t * @param {Event} e Submit event. Default is prevented.\n\t * @memberof WebComponents.cq-data-dialog\n\t */\n\timportData(e) {\n\t\te.preventDefault();\n\t\tconst { dialog } = this;\n\t\tif (!dialog.validate()()) return;\n\t\tlet {\n\t\t\tcontext: { stx },\n\t\t\tfileMap\n\t\t} = dialog;\n\t\tdialog.getFormData();\n\t\tfileMap.forEach((reader) => {\n\t\t\tstx.dataLoader.importData(reader);\n\t\t});\n\t\tdialog.close();\n\t}\n\n\t/**\n\t * Parses files uploaded by the user.\n\t * @async\n\t * @memberof WebComponents.cq-data-dialog\n\t */\n\tasync loadData() {\n\t\tthis.validateFileInput()();\n\t\tif (this.warning.getAttribute(\"cq-active\")) return;\n\t\tfor (const file of this.fileInput.files) {\n\t\t\tlet reader = new CIQ.CSVReader(file);\n\t\t\tthis.fileMap.set(file, reader);\n\t\t\tawait reader.parse(file);\n\t\t}\n\n\t\tthis.loadDataBtn.style.display = \"none\";\n\t\tthis.querySelector(\"cq-section.loader\").style.display = \"none\";\n\t\tthis.showData();\n\t}\n\n\t/**\n\t * Realigns tab select from the KeystrokeHub\n\t * @memberof WebComponents.cq-data-dialog\n\t * @private\n\t */\n\tresetTabSelect() {\n\t\tconst {\n\t\t\tuiManager: { keystrokeHub }\n\t\t} = this.context;\n\n\t\tkeystrokeHub.highlightAlign();\n\t}\n\n\t/**\n\t * Constructs and displays form for loaded files.\n\t * @memberof WebComponents.cq-data-dialog\n\t */\n\tshowData() {\n\t\tconst {\n\t\t\tcontext: { stx, config = {} },\n\t\t\tkeystrokeHub\n\t\t} = this;\n\n\t\tconst setAbortFunc = (fileName) => {\n\t\t\treturn (selector) => {\n\t\t\t\tselector.setAttribute(\"fields\", fileName);\n\t\t\t\tselector.addEventListener(\"pointerup\", (e) => {\n\t\t\t\t\te.preventDefault(); // stop submit event!\n\t\t\t\t\tCIQ.UI.containerExecute(selector, \"abortImport\", [e]);\n\t\t\t\t});\n\t\t\t};\n\t\t};\n\n\t\tlet main = false;\n\t\tlet tmpl = this.querySelector(\"template\");\n\t\tfor (const entries of this.fileMap) {\n\t\t\tconst [file, reader] = entries;\n\t\t\tconst fileName = file.name;\n\t\t\tconst frag = tmpl.content.cloneNode(true);\n\t\t\tfrag.firstElementChild.id += `${fileName}`;\n\t\t\tfrag.firstElementChild.setAttribute(\"name\", fileName);\n\n\t\t\tconst fieldSet = frag.querySelector(\"fieldset\");\n\t\t\tif (fieldSet) {\n\t\t\t\tfieldSet.setAttribute(\"fields\", fileName);\n\t\t\t\tfieldSet.setAttribute(\"name\", \"fields\");\n\t\t\t}\n\n\t\t\tconst title = frag.querySelector(\"legend.file-name\");\n\t\t\ttitle.innerText = `File: ${fileName}`;\n\n\t\t\tconst name = frag.querySelector(\".data-name input\");\n\t\t\tname.setAttribute(\"placeholder\", fileName);\n\t\t\tname.value = fileName;\n\n\t\t\tconst periodicity = frag.querySelector(\".ciq-select[name='periodicity']\");\n\t\t\tconst periodicities = config.menuPeriodicity\n\t\t\t\t? config.menuPeriodicity\n\t\t\t\t: (function () {\n\t\t\t\t\t\tconst periodicity = stx.getPeriodicity();\n\t\t\t\t\t\treturn [\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tvalue: periodicity,\n\t\t\t\t\t\t\t\tlabel: `${periodicity.period}, ${periodicity.timeUnit}`\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t];\n\t\t\t\t })();\n\t\t\tperiodicities\n\t\t\t\t.filter((m) => m.label)\n\t\t\t\t.forEach((p) => {\n\t\t\t\t\tconst opt = document.createElement(\"option\");\n\t\t\t\t\topt.value = opt.innerText = p.label;\n\t\t\t\t\topt.value = JSON.stringify(p.value);\n\t\t\t\t\tperiodicity.append(opt);\n\t\t\t\t});\n\n\t\t\tconst fieldsSection = frag.querySelector(\".data-fields ul\");\n\t\t\tlet { fields = [] } = reader;\n\n\t\t\tfields.forEach((cell) => {\n\t\t\t\tconst item = document.createElement(\"li\");\n\t\t\t\titem.innerText = cell;\n\t\t\t\tfieldsSection.append(item);\n\t\t\t});\n\n\t\t\tconst display = frag.querySelector(\"[name=display]\");\n\t\t\tconst secondaryOptions = frag.querySelector(\".secondary-options\");\n\n\t\t\tif (!main) main = true;\n\t\t\telse {\n\t\t\t\tdisplay.value = \"secondary\";\n\t\t\t\tsecondaryOptions.style.display = \"block\";\n\t\t\t}\n\n\t\t\tdisplay.addEventListener(\"change\", function (e) {\n\t\t\t\tlet show = this.value.toLowerCase() === \"secondary\";\n\t\t\t\tsecondaryOptions.style.display = show ? \"block\" : \"none\";\n\t\t\t\tkeystrokeHub.highlightAlign();\n\t\t\t});\n\n\t\t\tfrag.querySelectorAll(\".abort\").forEach(setAbortFunc(fileName));\n\n\t\t\tCIQ.UI.pickSwatchColor(this, frag.querySelector(\"cq-swatch\"));\n\t\t\tthis.form.append(frag);\n\n\t\t\t// Prevent accidental submit from inputs\n\t\t\tthis.form.querySelectorAll(\"input:not([type=submit]\").forEach((input) => {\n\t\t\t\tinput.addEventListener(\"keypress\", (e) => {\n\t\t\t\t\tif (e.key === \"Enter\") e.preventDefault();\n\t\t\t\t});\n\t\t\t});\n\t\t}\n\n\t\tthis.importBtn.style.display = \"inline\";\n\t\tCIQ.UI.containerExecute(this, \"resize\");\n\t\tthis.resetTabSelect();\n\t}\n\n\t/**\n\t * Sets UIContext for the component\n\t * @param {CIQ.UI.UIContext} context UIContext for the given chart\n\t * @memberof WebComponents.cq-data-dialog\n\t */\n\tsetContext(context) {\n\t\tthis.context = context;\n\t\tthis.addDefaultMarkup();\n\n\t\tthis.form = this.querySelector(\"form\");\n\t\tthis.fileInput = this.querySelector(\"input[type=file]\");\n\t\tthis.loadDataBtn = this.querySelector(\"button.load\");\n\t\tthis.importBtn = this.querySelector(\"button.import\");\n\t\tthis.controls = this.querySelector(\"div.ciq-dialog-cntrls\");\n\n\t\tthis.warning = this.querySelector(\".invalid-warning\");\n\t\tthis.warningTitle = this.warning.querySelector(\".invalid-warning-title\");\n\t\tthis.warningText = this.warning.querySelector(\".invalid-warning-text\");\n\n\t\tthis.form.dialog = this;\n\t\tthis.form.addEventListener(\"submit\", this.importData);\n\t\tthis.form.addEventListener(\"change\", this.validate());\n\n\t\tthis.fileInput.addEventListener(\"change\", this.validateFileInput());\n\n\t\tthis.keystrokeHub = context.uiManager.keystrokeHub;\n\t}\n\n\t/**\n\t * Custom validate method for the determining whether the data is ready to be submitted for import.\n\t * ** NOTE** this validate method is for the form, not for validating files set on input\n\t * @returns boolean valid\n\t */\n\tvalidate() {\n\t\tconst self = this;\n\t\treturn function (e) {\n\t\t\tself.getFormData();\n\t\t\tlet isMain;\n\t\t\tlet valid = true;\n\t\t\tfor (const entry of self.fileMap) {\n\t\t\t\tconst [, reader] = entry;\n\t\t\t\tconst { formData, fields } = reader;\n\t\t\t\tconst display = formData.get(\"display\");\n\t\t\t\tconst periodicity = formData.get(\"periodicity\");\n\n\t\t\t\tlet validFields =\n\t\t\t\t\t(fields.includes(\"DT\") || fields.includes(\"Date\")) &&\n\t\t\t\t\tfields.some((f) => f === \"Close\" || f === \"Value\");\n\n\t\t\t\tif (!validFields) {\n\t\t\t\t\tvalid = false;\n\t\t\t\t\treturn reportValidity(\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tmessageTitle: \"Invalid Data fields\",\n\t\t\t\t\t\t\tmessageText:\n\t\t\t\t\t\t\t\t'Your data contains invalid schema to display. It must include a \"DT\" column and either a \"Close\" or \"Value\" column.'\n\t\t\t\t\t\t},\n\t\t\t\t\t\tvalid\n\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\tif (display === \"secondary\") {\n\t\t\t\t\tif (\n\t\t\t\t\t\t!CIQ.equals(\n\t\t\t\t\t\t\tJSON.parse(periodicity),\n\t\t\t\t\t\t\tself.context.stx.getPeriodicity()\n\t\t\t\t\t\t)\n\t\t\t\t\t) {\n\t\t\t\t\t\tvalid = false;\n\t\t\t\t\t\treturn reportValidity(\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tmessageTitle: \"Mis-matched periodicities:\",\n\t\t\t\t\t\t\t\tmessageText:\n\t\t\t\t\t\t\t\t\t\"Having mixed periodicities can result in chart displaying incorrect time scales. Check your data and try again.\"\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\tvalid\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tif (isMain) {\n\t\t\t\t\t\tvalid = false;\n\t\t\t\t\t\treturn reportValidity(\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tmessageTitle: \"Multiple Main series\",\n\t\t\t\t\t\t\t\tmessageText:\n\t\t\t\t\t\t\t\t\t\"Detected multiple data files set to display main data. Only one data file can be main.\"\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\tvalid\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t\tisMain = true;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn reportValidity({ messageTitle: \"\", messageText: \"\" }, valid);\n\n\t\t\tfunction reportValidity({ messageTitle, messageText }, valid) {\n\t\t\t\tself.warn(messageTitle, messageText, valid);\n\t\t\t\tself.resetTabSelect();\n\t\t\t\treturn valid;\n\t\t\t}\n\t\t};\n\t}\n\n\t/**\n\t * Validation function for File Input.\n\t * **NOTE** Not the same as the validation for the form\n\t * @returns function Funtion that runs on file input change event\n\t * @memberof WebComponents.cq-data-dialog\n\t */\n\tvalidateFileInput() {\n\t\tconst self = this;\n\t\treturn function (e) {\n\t\t\t// Determine whether called by the dialog or the input then set files\n\t\t\tconst files = self.files || self.fileInput.files;\n\n\t\t\tlet valid = true,\n\t\t\t\ttitle = \"\",\n\t\t\t\tmessage = \"\";\n\t\t\tObject.values(files).forEach(function (file) {\n\t\t\t\tconst { name } = file;\n\t\t\t\tconst extension =\n\t\t\t\t\tname.lastIndexOf(\".\") > 0 &&\n\t\t\t\t\tname.slice(name.lastIndexOf(\".\"), name.length);\n\t\t\t\tif (\n\t\t\t\t\t(extension && extension !== \".csv\") ||\n\t\t\t\t\tDataDialog.mimeTypes.indexOf(file.type) == -1\n\t\t\t\t) {\n\t\t\t\t\ttitle = \"Invalid File Type\";\n\t\t\t\t\tmessage =\n\t\t\t\t\t\t\"Data Importer requires a text/csv file to work. Please select a CSV file.\";\n\t\t\t\t\tvalid = false;\n\t\t\t\t}\n\t\t\t});\n\n\t\t\tif (!files.length) {\n\t\t\t\ttitle = `Please select a file!`;\n\t\t\t\tmessage =\n\t\t\t\t\t\"Data Importer requires a text/csv file to work. Please select a CSV file.\";\n\t\t\t\tvalid = false;\n\t\t\t}\n\t\t\tself.warn(title, message, valid);\n\t\t\tself.resetTabSelect();\n\t\t};\n\t}\n\n\t/**\n\t * Displays or clears warning messages based on the validity of the form.\n\t * @param {string} title Title text of warning to display.\n\t * @param {string} text Body text of warning to display.\n\t * @param {boolean} display Should be valid property from validiity\n\t * @memberof WebComponents.cq-data-dialog\n\t */\n\twarn(title, text, valid) {\n\t\tthis.warningTitle.innerText = title;\n\t\tthis.warningText.innerText = text;\n\t\tif (!valid) this.warning.setAttribute(\"cq-active\", true);\n\t\telse this.warning.removeAttribute(\"cq-active\");\n\t}\n}\n\n/**\n * Valid MIME types that the DataDialog will recognize.\n * By default the file input only accepts the extensions listed here.\n *\n * For more information about extension and MIME types see https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types\n * @memberOf WebComponents.cq-data-dialog\n * @static\n * @type array\n * @alias mimeTypes\n */\nDataDialog.mimeTypes = [\n\t\"text/csv\",\n\t\"application/csv\",\n\t\"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet\",\n\t\"application/vnd.ms-excel\"\n];\n\nDataDialog.markup = `\n

Import Data

\n\n\n\t\n\t\t\n\t\t\n\t\n\t\n\t\t\n\t\n\t\n\t\t
\n\t
\n\t\n\t\n\t\t
\n\t\t\t
\n\t\t\t
\n\t\t
\n\t
\n\t\n\t\t\n\t\n\n
\n`;\n\nCIQ.UI.addComponentDefinition(\"cq-data-dialog\", DataDialog);\n\n};\n\n\nlet __js_webcomponents_dialog_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Dialog web component ``.\n *\n * Manages general dialog interaction such as display, hide, location, size, tap interaction, etc\n *\n * @namespace WebComponents.cq-dialog\n * @example\n\t\n\t\t\n\t\t\t

Choose Timezone

\n\t\t\t\n\n\t\t\t

To set your timezone use the location button below, or scroll through the following list...

\n\t\t\t

\n\t
\n\t
Use My Current Location
\n\t
\n\t
\n\t\t
    \n\t\t
  • \n\t\t
\n\t
\n\t
(Scroll for more options)
\n\t\t
\n\t
\n */\nclass Dialog extends CIQ.UI.BaseComponent {\n\tconstructor() {\n\t\tsuper();\n\t\tthis.activeAttributes = {};\n\t}\n\n\t/**\n\t * The attributes that are added to a cq-dialog when it is opened (and removed when closed).\n\t * Contains \"cq-active\" by default.\n\t * @memberof WebComponents.cq-dialog\n\t * @type {Object}\n\t */\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tthis.isDialog = true;\n\t\tsuper.connectedCallback();\n\t\tvar self = this;\n\t\tfunction handleTap(e) {\n\t\t\tself.tap(e);\n\t\t}\n\t\tCIQ.UI.stxtap(this, handleTap);\n\n\t\tvar uiManager = CIQ.UI.getUIManager(this);\n\t\tuiManager.registerForResize(this);\n\t\tthis.uiManager = uiManager;\n\n\t\tif (!this.hasAttribute(\"cq-no-claim\")) this.addClaim(this);\n\n\t\tif (!this.hasAttribute(\"tabindex\")) this.setAttribute(\"tabindex\", \"0\");\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, Dialog);\n\t}\n\n\tdisconnectedCallback() {\n\t\tif (!this.hasAttribute(\"cq-no-claim\")) this.removeClaim(this);\n\t\tthis.uiManager.unregisterForResize(this);\n\t\tsuper.disconnectedCallback();\n\t}\n\n\t/**\n\t * Finds the first element in `items` that has a `cq-focused` attribute or a name attribute\n\t * that matches the value of `activeElementName`. If found, that element is focused.\n\t *\n\t * @param {NodeList} items A list of elements that are selectable via keyboard navigation.\n\t *\n\t * @memberof WebComponents.cq-dialog\n\t * @alias refreshFocus\n\t * @since 8.7.0\n\t */\n\trefreshFocus() {\n\t\tconst items = this.getKeyboardSelectableItems();\n\t\tlet focused = this.findFocused(items)[0];\n\t\tif (!focused)\n\t\t\tfocused = Array.from(items || []).find((item) =>\n\t\t\t\titem.matches(\"[name=\" + this.activeElementName + \"]\")\n\t\t\t);\n\t\tif (focused) this.focusItem(focused);\n\t}\n\n\tgetKeyboardSelectableItems() {\n\t\treturn this.querySelectorAll(\n\t\t\t\"[keyboard-selectable='true'], input, .ciq-select, cq-swatch, .ciq-btn, .ciq-btn-negative, cq-scroll li\"\n\t\t);\n\t}\n\n\tkeyStroke(hub, key, e) {\n\t\tif (hub.tabActiveModals[0] !== this) return;\n\t\tlet { shiftKey: reverse } = e || {};\n\n\t\tconst items = this.getKeyboardSelectableItems();\n\t\tif (key === \"Tab\") {\n\t\t\tconst focused = this.focusNextItem(items, reverse, true);\n\t\t\tconst scroll = this.querySelector(\"cq-scroll\");\n\t\t\tif (focused && scroll) {\n\t\t\t\t// Scroll to the element that was focused\n\t\t\t\tscroll.scrollToElement(focused);\n\t\t\t\t// Let the scroll complete before aligning the highlight\n\t\t\t\tsetTimeout(() => hub.highlightAlign());\n\t\t\t}\n\t\t} else if (key == \"Enter\") {\n\t\t\tconst focused = this.findFocused(items)[0];\n\t\t\tif (focused) {\n\t\t\t\tthis.clickItem(focused, e, this);\n\t\t\t\tif (typeof focused.click === \"function\") focused.click();\n\t\t\t}\n\t\t}\n\t}\n\n\tonKeyboardSelection() {\n\t\t// Need to hide the highlight on select because the study dialog contents re-render quite often\n\t\t// throwing off the highlight position (e.g. When a dropdown selection is made). Pressing the\n\t\t// tab key will re-focus the next appropriate item and helps the user re-orient themselves.\n\t\tthis.keyboardNavigation.highlightHide();\n\t}\n\n\tonKeyboardDeselection() {\n\t\t// If we're using keyboard navigation, return the highlight to the tab selected element\n\t\tif (this.keyboardNavigation && this.keyboardNavigation !== null)\n\t\t\tthis.keyboardNavigation.highlightAlign();\n\t}\n\n\tclickItem(item, e, originationElement) {\n\t\t// Pass control to the dropdown. Dropdowns within the dialog become detached from their\n\t\t// parent in the dom and cannot pass comtrol directly.\n\t\tif (item && this.keyboardNavigation) {\n\t\t\tconst dropdown = item.querySelector(\"cq-menu-dropdown\");\n\t\t\tif (dropdown) {\n\t\t\t\tdropdown.keyboardOriginationElement = originationElement;\n\t\t\t\tthis.keyboardNavigation.setKeyControlElement(dropdown);\n\t\t\t}\n\t\t}\n\t\tsuper.clickItem(item, e, this);\n\t}\n\n\tprocessEsc(hub) {\n\t\t// See if we need to use Esc to clean up the dialog\n\t\tif (this.closeActiveMenu()) {\n\t\t\t// If there's another modal available at position 0, set it as active\n\t\t\tif (hub.tabActiveModals[0])\n\t\t\t\thub.setKeyControlElement(hub.tabActiveModals[0]);\n\t\t\t// Returning true prevents the keyHub from processing esc.\n\t\t\treturn true;\n\t\t}\n\t\t// If nothing was done, pass false to process esc in the keyHub\n\t\treturn false;\n\t}\n\n\t/**\n\t * Returns true if a menu was closed\n\t */\n\tcloseActiveMenu() {\n\t\tconst activeMenu = this.querySelector(\"*.stxMenuActive\");\n\t\tif (activeMenu) {\n\t\t\tconst uiManager = CIQ.UI.getUIManager(this);\n\t\t\tif (uiManager) uiManager.closeMenu(activeMenu);\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}\n\n\t/**\n\t * Creates a new attribute to be activated when the dialog is open. Use\n\t * this to style the dialog. This is automatically set by any component\n\t * that is derived from DialogContentTag\n\t * @param {string} attribute The attribute to add or remove\n\t * @memberof WebComponents.cq-dialog\n\t * @since 4.1.0\n\t * @example\n\t * \n\t * \n\t */\n\taddActiveAttribute(attribute) {\n\t\tthis.activeAttributes[attribute] = true;\n\t}\n\n\tcenter() {\n\t\tvar parent = this.parentElement;\n\t\tif (parent.tagName == \"BODY\") parent = window;\n\t\tvar gSz = CIQ.guaranteedSize(parent);\n\t\tvar h = gSz.height;\n\t\tvar outer = CIQ.elementDimensions(this, {\n\t\t\tpadding: 1,\n\t\t\tborder: 1\n\t\t});\n\t\tvar ch = outer.height;\n\t\tvar left = 50;\n\t\tvar top = 50;\n\t\tif (h > ch * 2) {\n\t\t\ttop = 33; // Position 1/3 down the screen on large screens\n\t\t}\n\n\t\tvar elementStyle = {\n\t\t\ttop: top + \"%\",\n\t\t\tleft: left + \"%\",\n\t\t\ttransform: \"translate(-50%, -50%)\"\n\t\t};\n\t\tObject.assign(this.style, elementStyle);\n\t}\n\n\tclose() {\n\t\tthis.uiManager.closeMenu(this);\n\t\tif (this.onClose) this.onClose();\n\t}\n\n\thide() {\n\t\tif (this.node.find(\":invalid\").length) return;\n\t\t// Call the \"hide()\" function for any immediate children. This will allow nested\n\t\t// components to clean themselves up when a dialog is removed from outside of their scope.\n\t\tthis.node.children().each(function () {\n\t\t\tif (typeof this.hide == \"function\") this.hide();\n\t\t});\n\t\tthis.active = false;\n\t\t// Remove the opener and allow it to be closed like any other dialog\n\t\tif (this.opener) {\n\t\t\tdelete this.opener.keepOpen;\n\t\t\tdelete this.opener;\n\t\t}\n\t\tif (\n\t\t\tthis.uiManager.overlay &&\n\t\t\tthis.uiManager.overlay.hasAttribute(\"cq-active\")\n\t\t)\n\t\t\tthis.uiManager.overlay.removeAttribute(\"cq-active\");\n\t\t//this.uiManager.overlay=null;\n\t\tfor (var attribute in this.activeAttributes) {\n\t\t\tif (this.hasAttribute(attribute)) this.removeAttribute(attribute);\n\t\t}\n\t\tthis.activeAttributes = {};\n\n\t\t// blur any input boxes that are inside the dialog we're closing, to get rid of soft keyboard\n\t\tthis.node.find(\"input\").each(function () {\n\t\t\tif (this == this.ownerDocument.activeElement) this.blur();\n\t\t});\n\n\t\t// Blur any focused elements\n\t\tthis.removeFocused();\n\t\t// Remove this dialog from the active index\n\t\tconst keystrokeHub = this.ownerDocument.body.keystrokeHub;\n\t\tif (keystrokeHub) keystrokeHub.removeActiveModal(this);\n\t}\n\n\tlaunchColorPicker() {\n\t\tif (this.uiManager) this.uiManager.closeMenu(null, \"CQ-MENU\");\n\t}\n\n\topen(params) {\n\t\tthis.uiManager.openMenu(this, params);\n\t\t// Capture context to be able to later notify dialog closing in channel\n\t\tconst { context, opener } = params || {};\n\t\tif (!context || !context.config) {\n\t\t\tthis.onClose = null;\n\t\t\treturn;\n\t\t}\n\n\t\tconst {\n\t\t\tconfig: { channels },\n\t\t\tstx\n\t\t} = context;\n\n\t\tif (stx.translateUI) stx.translateUI(this.node[0]);\n\n\t\tthis.onClose = () => {\n\t\t\tthis.channelWrite(channels.dialog || \"channel.dialog\", {}, stx);\n\t\t\tthis.onClose = null;\n\t\t\t// If Dialog content has a hide method, call it.\n\t\t\tif (this.firstElementChild.hide) this.firstElementChild.hide();\n\t\t};\n\t\tif (opener) {\n\t\t\tthis.opener = opener;\n\t\t\tthis.opener.keepOpen = true;\n\t\t}\n\t}\n\n\tresize() {\n\t\tvar scrollers = this.node.find(\"cq-scroll\");\n\t\tscrollers.each(function () {\n\t\t\tif (this.resize) this.resize();\n\t\t});\n\t\tif (this.params && this.params.x) {\n\t\t\tthis.stxContextMenu();\n\t\t} else {\n\t\t\tthis.center();\n\t\t}\n\t}\n\n\t/**\n\t * Show the dialog. Use X,Y *screen location* (pageX, pageY from an event) for where to display context menus. If the context menu cannot fit on the screen then it will be adjusted leftward and upward\n\t * by enough pixels so that it shows.\n\t * @param {object} [params] Parameters\n\t * @param {Boolean} [params.bypassOverlay=false] If true will not display the scrim overlay\n\t * @param {Number} [params.x] X location of top left corner. Use for context menus, otherwise dialog will be centered.\n\t * @param {Number} [params.y] Y location of top left corner. Use for context menus, otherwise dialog will be centered.\n\t * @alias show\n\t * @memberof WebComponents.cq-dialog\n\t */\n\tshow(params) {\n\t\tthis.params = params;\n\t\tif (!params) params = this.params = {};\n\t\tvar self = this;\n\t\tvar context = params.context || CIQ.UI.getMyContext(this);\n\t\tif (!this.uiManager.overlay && !params.bypassOverlay) {\n\t\t\tthis.uiManager.overlay = document.createElement(\"cq-dialog-overlay\");\n\t\t\tif (context) context.node.append(this.uiManager.overlay);\n\t\t}\n\t\tself.active = true;\n\t\tsetTimeout(function () {\n\t\t\t// to get the opacity transition effect\n\t\t\tif (self.uiManager.overlay && !params.bypassOverlay) {\n\t\t\t\tif (self.uiManager.overlay.getAttribute(\"cq-active\") !== \"true\")\n\t\t\t\t\tself.uiManager.overlay.setAttribute(\"cq-active\", \"true\");\n\t\t\t}\n\t\t\tself.activeAttributes[\"cq-active\"] = true; // cq-active is what css uses to display the dialog\n\t\t\tfor (var attribute in self.activeAttributes) {\n\t\t\t\tif (self.node.attr(attribute) !== \"true\")\n\t\t\t\t\tself.node.attr(attribute, \"true\");\n\t\t\t}\n\t\t\tself.resize();\n\t\t});\n\n\t\t// Add the theme class to the dialog. It exists outside of the theme context so it will not inherit the theme.\n\t\tif (context && context.config && context.config.themes) {\n\t\t\tlet themes = Object.keys(context.config.themes.builtInThemes);\n\t\t\t// First remove any existing theme classes on the dialog\n\t\t\tthis.classList.remove(...themes);\n\t\t\tlet activeTheme = themes.find(\n\t\t\t\t(r) => context.topNode.classList.contains(r) === true\n\t\t\t);\n\t\t\t// Add the active theme class to the dialog\n\t\t\tif (activeTheme) this.classList.add(activeTheme);\n\t\t}\n\n\t\t// Set this dialog as active for tab navigation\n\t\tconst keystrokeHub = this.ownerDocument.body.keystrokeHub;\n\t\tif (keystrokeHub) keystrokeHub.addActiveModal(this);\n\t}\n\n\tstxContextMenu() {\n\t\tvar parent = this.parentElement;\n\t\tif (parent.tagName == \"BODY\") parent = window;\n\t\tvar gSz = CIQ.guaranteedSize(parent);\n\t\tvar w = gSz.width;\n\t\tvar h = gSz.height;\n\t\tvar outer = CIQ.elementDimensions(this, {\n\t\t\tpadding: 1,\n\t\t\tborder: 1\n\t\t});\n\t\tvar cw = outer.width;\n\t\tvar ch = outer.height;\n\t\tvar left = this.params.x;\n\t\tvar top = this.params.y;\n\t\tvar saveAdjustedPosition = false;\n\n\t\tthis.node.find(\"cq-menu.stxMenuActive\").each(function () {\n\t\t\tif (this.querySelector(\".context-menu-right\")) {\n\t\t\t\tvar overlapItemCount = CIQ.UI.$(this).nextAll().length + 1;\n\n\t\t\t\tvar outerMenu = CIQ.elementDimensions(this, {\n\t\t\t\t\tpadding: 1,\n\t\t\t\t\tborder: 1\n\t\t\t\t});\n\t\t\t\tvar outerContext = CIQ.elementDimensions(\n\t\t\t\t\tthis.querySelector(\".context-menu-right\"),\n\t\t\t\t\t{ padding: 1, border: 1 }\n\t\t\t\t);\n\t\t\t\tcw += outer.width;\n\t\t\t\tch += outerContext.height - outerMenu.height * overlapItemCount;\n\t\t\t\tsaveAdjustedPosition = true;\n\t\t\t}\n\t\t});\n\n\t\tif (left + cw > w) left = w - cw;\n\t\tif (top + ch > h) top = h - ch;\n\t\tif (top < 0) top = 0;\n\t\tif (saveAdjustedPosition) {\n\t\t\tthis.params.x = left;\n\t\t\tthis.params.y = top;\n\t\t}\n\n\t\tObject.assign(this.style, { top: top + \"px\", left: left + \"px\" });\n\t}\n\n\ttap(e) {\n\t\tvar topMenu = this.uiManager.topMenu();\n\t\tif (topMenu === this) {\n\t\t\te.stopPropagation(); // prevent a tap inside the dialog from closing itself\n\t\t\treturn;\n\t\t}\n\t\tif (!e.currentTarget.active) {\n\t\t\te.stopPropagation(); // If the dialog we tapped on is closed, then we must have closed it manually. Don't allow a body tap otherwise we'll close two dialogs!\n\t\t}\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-dialog\", Dialog);\n\n};\n\n\nlet __js_webcomponents_doubleSlider_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Double range slider web component ``.\n *\n * A double slider has a thumb (slidable control) at each end of the slider track.\n *\n * This web component is an implementation of a low/high range slider. The left thumb sets the low\n * value of the slider; the right thumb, the high value.\n *\n * The value of the slider is an object specifying the high and low values. The component includes\n * a text readout of the values.\n *\n * **Attributes**\n * - min — Minimum value of the slider\n * - max — Maximum value of the slider\n * - low — Preset value for the left thumb\n * - high — Preset value for the right thumb\n * - step — The absolute amount (positive or negative) the movement of a thumb changes a\n * slider setting\n *\n * See the example below.\n *\n * @namespace WebComponents.cq-double-slider\n * @since 8.3.0\n *\n * @example\n * \n * Strike \n * \n */\nclass DoubleSlider extends CIQ.UI.BaseComponent {\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tsuper.connectedCallback();\n\t\tthis.init();\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, DoubleSlider);\n\t\tthis.constructor = DoubleSlider;\n\t}\n\n\tinit() {\n\t\tthis.addDefaultMarkup();\n\t\tthis.textRange = this.querySelector(\".ciq-double-slider-text\");\n\t\tthis.lowSlider = this.querySelector(\n\t\t\t\".ciq-double-slider-range[range='low']\"\n\t\t);\n\t\tthis.highSlider = this.querySelector(\n\t\t\t\".ciq-double-slider-range[range='high']\"\n\t\t);\n\t\tthis.backing = this.querySelector(\"cq-double-slider-range\");\n\t\tthis.name = this.getAttribute(\"name\") || CIQ.uniqueID();\n\t\t[\"min\", \"max\", \"step\", \"low\", \"high\"].forEach((prop) => {\n\t\t\tif (this.hasAttribute(prop)) this[prop] = Number(this.getAttribute(prop));\n\t\t});\n\n\t\tthis.setBounds(this);\n\t\tconst self = this;\n\n\t\tfunction slide(slider, event) {\n\t\t\tlet value = slider.value;\n\t\t\tif (event) {\n\t\t\t\tconst touch = event.touches[0];\n\t\t\t\tconst boundingClientRect = self.highSlider.getBoundingClientRect();\n\t\t\t\tlet { height, width } = getComputedStyle(self.highSlider);\n\t\t\t\theight = parseFloat(height);\n\t\t\t\twidth = parseFloat(width);\n\t\t\t\tlet ratio = 1;\n\t\t\t\tif (height > width) {\n\t\t\t\t\tconst boundedOffset = Math.max(\n\t\t\t\t\t\t0,\n\t\t\t\t\t\tMath.min(height, touch.pageY - boundingClientRect.top)\n\t\t\t\t\t);\n\t\t\t\t\tratio = boundedOffset / height;\n\t\t\t\t} else {\n\t\t\t\t\tconst boundedOffset = Math.max(\n\t\t\t\t\t\t0,\n\t\t\t\t\t\tMath.min(width, touch.pageX - boundingClientRect.left)\n\t\t\t\t\t);\n\t\t\t\t\tratio = boundedOffset / width;\n\t\t\t\t}\n\t\t\t\tvalue = self.min + ratio * (self.max - self.min);\n\t\t\t}\n\t\t\t// If we are performing an initial slide, figure out whether we are closer to high or to low\n\t\t\tif (!self.whichSlider) {\n\t\t\t\tself.whichSlider =\n\t\t\t\t\tvalue * 2 >\n\t\t\t\t\t(isNaN(self.high) ? self.max : self.high) +\n\t\t\t\t\t\t(isNaN(self.low) ? self.min : self.low) +\n\t\t\t\t\t\t1\n\t\t\t\t\t\t? self.highSlider\n\t\t\t\t\t\t: self.lowSlider;\n\t\t\t}\n\t\t\tif (self.whichSlider === self.lowSlider) {\n\t\t\t\tself.low = self.lowSlider.value = Math.min(\n\t\t\t\t\ttypeof self.high === \"undefined\" ? self.max : self.high,\n\t\t\t\t\tvalue\n\t\t\t\t);\n\t\t\t} else if (self.whichSlider === self.highSlider) {\n\t\t\t\tself.high = self.highSlider.value = Math.max(\n\t\t\t\t\ttypeof self.low === \"undefined\" ? self.min : self.low,\n\t\t\t\t\tvalue\n\t\t\t\t);\n\t\t\t}\n\t\t\tself.setValue(self);\n\t\t}\n\n\t\t[this.highSlider, this.lowSlider].forEach((slider) => {\n\t\t\t[\"mousedown\", \"pointerdown\"].forEach((ev) => {\n\t\t\t\tslider.addEventListener(ev, (evt) => {\n\t\t\t\t\tself.whichSlider = null;\n\t\t\t\t});\n\t\t\t});\n\t\t\tslider.addEventListener(\"input\", () => slide(slider));\n\t\t\tif (CIQ.touchDevice) {\n\t\t\t\tslider.addEventListener(\n\t\t\t\t\t\"touchstart\",\n\t\t\t\t\t(evt) => {\n\t\t\t\t\t\tself.whichSlider = null;\n\t\t\t\t\t\tself.engaged = true;\n\t\t\t\t\t\tslide(slider, evt);\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\tpassive: false\n\t\t\t\t\t}\n\t\t\t\t);\n\t\t\t\tslider.addEventListener(\n\t\t\t\t\t\"touchmove\",\n\t\t\t\t\t(evt) => {\n\t\t\t\t\t\tif (self.engaged) slide(slider, evt);\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\tpassive: false\n\t\t\t\t\t}\n\t\t\t\t);\n\t\t\t\tslider.addEventListener(\n\t\t\t\t\t\"touchend\",\n\t\t\t\t\t(evt) => {\n\t\t\t\t\t\tself.engaged = false;\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\tpassive: false\n\t\t\t\t\t}\n\t\t\t\t);\n\t\t\t}\n\t\t});\n\t}\n\n\t/**\n\t * Sets the min, max, and step of the slider.\n\t *\n\t * @param {object} bounds Contains min, max, and step values.\n\t *\n\t * @alias setBounds\n\t * @memberof WebComponents.cq-double-slider#\n\t * @since 8.3.0\n\t */\n\tsetBounds(bounds) {\n\t\tArray.from(this.querySelectorAll('input[type=\"range\"]')).forEach((el) => {\n\t\t\t[\"min\", \"max\", \"step\"].forEach((prop) => {\n\t\t\t\tif (bounds[prop] || bounds[prop] === 0) {\n\t\t\t\t\tel.setAttribute(prop, bounds[prop]);\n\t\t\t\t\tthis[prop] = bounds[prop];\n\t\t\t\t}\n\t\t\t});\n\t\t});\n\t\tthis.updateVisual();\n\t}\n\n\t/**\n\t * Sets the high and low values of the slider.\n\t *\n\t * The high and low values are restricted to the range of the max and min.\n\t *\n\t * @param {object} [data] Contains high and low values.\n\t *\n\t * @alias setValue\n\t * @memberof WebComponents.cq-double-slider#\n\t * @since 8.3.0\n\t */\n\tsetValue(data) {\n\t\tconst obj = {};\n\t\tif (data) {\n\t\t\tif (data.low !== undefined) {\n\t\t\t\tobj.low =\n\t\t\t\t\tthis.min === undefined ? data.low : Math.max(this.min, data.low);\n\t\t\t}\n\t\t\tif (data.high !== undefined) {\n\t\t\t\tobj.high =\n\t\t\t\t\tthis.max === undefined ? data.high : Math.min(this.max, data.high);\n\t\t\t}\n\t\t}\n\t\tif (!CIQ.equals(this.value, obj)) this.value = obj;\n\t\tthis.low = obj.low;\n\t\tthis.high = obj.high;\n\t\tthis.updateVisual();\n\t}\n\n\t/**\n\t * Updates the slider view based on the slider attributes.\n\t *\n\t * @alias updateVisual\n\t * @memberof WebComponents.cq-double-slider#\n\t * @since 8.3.0\n\t */\n\tupdateVisual() {\n\t\tthis.setAttribute(\"min\", this.min);\n\t\tthis.setAttribute(\"max\", this.max);\n\t\tthis.setAttribute(\"low\", this.low);\n\t\tthis.setAttribute(\"high\", this.high);\n\t\tthis.setAttribute(\"step\", this.step);\n\n\t\tconst style = getComputedStyle(this.textRange);\n\t\tconst inColor = style.color;\n\t\tconst outColor = style.borderLeftColor;\n\t\tlet low = this.low;\n\t\tif (isNaN(low) || low < this.min) low = this.min;\n\t\tlet high = this.high;\n\t\tif (isNaN(high) || high > this.max) high = this.max;\n\t\tthis.lowSlider.value = low;\n\t\tthis.highSlider.value = high;\n\n\t\t// let input element do the rounding for us\n\t\tif (typeof low !== \"undefined\") low = Number(this.lowSlider.value);\n\t\tif (typeof high !== \"undefined\") high = Number(this.highSlider.value);\n\n\t\tconst min = low - this.min;\n\t\tconst max = high - this.min;\n\t\tthis.textRange.innerHTML = low + \"-\" + high;\n\t\tconst range = this.max - this.min;\n\t\tconst stop = [(min / range) * 100, (max / range) * 100];\n\t\tthis.backing.style.background = `linear-gradient(to right,\n\t\t\t${outColor} 0% ${stop[0]}%,\n\t\t\t${inColor} ${stop[0]}% ${stop[1]}%,\n\t\t\t${outColor} ${stop[1]}% 100%)`;\n\t}\n}\n\nDoubleSlider.markup = `\n\t\t\n\t\t\n\t\t\n\t\t\n`;\n\nCIQ.UI.addComponentDefinition(\"cq-double-slider\", DoubleSlider);\n\n};\n\n\nlet __js_webcomponents_drawingContext_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Drawing Context Dialog web component ``.\n * Managed by an instance of {CIQ.UI.DrawingEdit}.\n *\n * @namespace WebComponents.cq-drawing-context\n * @since 6.2.0\n */\nclass DrawingContext extends CIQ.UI.DialogContentTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, DrawingContext);\n\t\tthis.constructor = DrawingContext;\n\t}\n\n\t/**\n\t * Open the context menu as a dialog.\n\t *\n\t * @param {Object} params\n\t * @param {number} params.x used to position the dialog\n\t * @param {number} params.y used to position the dialog\n\t * @param {CIQ.Drawing} params.drawing sets the `drawing` instance property\n\t * @param {CIQ.UI.Context} params.context passed to the components setContext method\n\t * @since 6.2.0\n\t */\n\topen(params) {\n\t\tthis.addDefaultMarkup();\n\t\tthis.classList.add(\"ciq-context-menu\");\n\n\t\tthis.drawing = params.drawing;\n\t\tvar textEdit = this.node.find(\"[cq-edit-text]\");\n\t\tif (this.drawing.edit) {\n\t\t\ttextEdit.show();\n\t\t} else {\n\t\t\ttextEdit.hide();\n\t\t}\n\t\treturn super.open(params);\n\t}\n}\n\nDrawingContext.markup = `\n\t\t
Edit Text
\n\t\t
Edit Settings
\n\t\t
Clone Drawing
\n\t\t\n\t\t\t\n\t\t\t\tBring to Top\n\t\t\t\tBring Forward\n\t\t\t\tSend Backward\n\t\t\t\tSend to Bottom\n\t\t\t\n\t\t\t\n\t\t\t
Layer Management
\n\t\t
\n\t\t
Delete Drawing
\n\t`;\nCIQ.UI.addComponentDefinition(\"cq-drawing-context\", DrawingContext);\n\n};\n\n\nlet __js_webcomponents_fibSettingsDialog_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * fibonacci settings dialog web component ``.\n *\n * @namespace WebComponents.cq-fib-settings-dialog\n * @example\n \n \t\n \t\t

Settings

\n \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
Done
\n \t\t
\n \t
\n
\n * @since 3.0.9\n */\nclass FibSettingsDialog extends CIQ.UI.DialogContentTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, FibSettingsDialog);\n\t\tthis.constructor = FibSettingsDialog;\n\t}\n\n\t/**\n\t * Adds a custom fib level\n\t * @memberOf WebComponents.cq-fib-settings-dialog\n\t * @since 5.2.0\n\t */\n\tadd() {\n\t\tvar level = this.node.find(\"[cq-custom-fibonacci-setting] input\").val();\n\t\tif (!level) return;\n\t\tlevel = parseFloat(level) / 100;\n\t\tif (isNaN(level)) return;\n\t\tvar defaultFibs =\n\t\t\tthis.context.stx.currentVectorParameters.fibonacci.fibs || [];\n\t\tvar fib, newFib;\n\t\tfor (var index = 0; index < defaultFibs.length; index++) {\n\t\t\tfib = defaultFibs[index];\n\t\t\tif (fib.level > level) {\n\t\t\t\tnewFib = CIQ.clone(fib);\n\t\t\t\tnewFib.level = level;\n\t\t\t\tnewFib.display = true;\n\t\t\t\tif (newFib.parameters) newFib.parameters.opacity = 0.25;\n\t\t\t\tdefaultFibs.splice(index, 0, newFib);\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\tif (!newFib) {\n\t\t\tif (defaultFibs.length) fib = CIQ.clone(defaultFibs[0]);\n\t\t\telse\n\t\t\t\tfib = {\n\t\t\t\t\tcolor: \"auto\",\n\t\t\t\t\tparameters: { pattern: \"solid\", opacity: 0.25, lineWidth: 1 }\n\t\t\t\t};\n\t\t\tnewFib = CIQ.clone(fib);\n\t\t\tnewFib.level = level;\n\t\t\tnewFib.display = true;\n\t\t\tdefaultFibs.push(newFib);\n\t\t}\n\t\tthis.open();\n\t}\n\n\t/**\n\t * Fires a \"change\" event and closes the dialog.\n\t *\n\t * @memberOf WebComponents.cq-fib-settings-dialog\n\t * @since 6.2.0\n\t */\n\tclose() {\n\t\tif (this.opener) {\n\t\t\tvar event = new Event(\"change\", {\n\t\t\t\tbubbles: true,\n\t\t\t\tcancelable: true\n\t\t\t});\n\n\t\t\tthis.opener.dispatchEvent(event);\n\t\t\tthis.context.stx.currentVectorParameters.fibonacci.fibsAlreadySet = true;\n\t\t}\n\n\t\tsuper.close();\n\t}\n\n\t/**\n\t * Opens the cq-fib-settings-dialog\n\t * @param {Object} params Parameters\n\t * @memberOf WebComponents.cq-fib-settings-dialog\n\t */\n\topen(params) {\n\t\tthis.addDefaultMarkup();\n\t\tsuper.open(params);\n\t\tif (params) this.opener = params.caller;\n\t\tvar vectorParameters = this.context.stx.currentVectorParameters;\n\t\tvar vectorType = vectorParameters.vectorType;\n\t\tvar dialog = this.node;\n\n\t\t// fibonacci type\n\t\tvar parameters;\n\t\tif (vectorParameters.fibonacci && vectorType != \"fibtimezone\") {\n\t\t\tdialog.find(\".title\").text(\"Fibonacci Settings\");\n\t\t\tvar defaultFibs = vectorParameters.fibonacci.fibs || [];\n\t\t\tparameters = dialog.find(\"cq-fibonacci-settings\");\n\t\t\tparameters.children(\":not(template)\").remove();\n\n\t\t\tfor (var index = 0; index < defaultFibs.length; index++) {\n\t\t\t\tvar fib = defaultFibs[index];\n\n\t\t\t\t// no negative values for fibonacci arc\n\t\t\t\tif (vectorType === \"fibarc\" && fib.level < 0) continue;\n\n\t\t\t\tvar newParam = CIQ.UI.makeFromTemplate(\n\t\t\t\t\tthis.node.find(\"template\"),\n\t\t\t\t\tparameters\n\t\t\t\t);\n\t\t\t\tvar convertPercent = fib.level * 100;\n\t\t\t\tnewParam.find(\".ciq-heading\").text(convertPercent.toFixed(1) + \"%\");\n\t\t\t\tvar paramInput = newParam.find(\"input\");\n\n\t\t\t\tif (fib.display) {\n\t\t\t\t\tparamInput.prop(\"checked\", true);\n\t\t\t\t}\n\n\t\t\t\tthis.setChangeEvent(paramInput, \"fib\", fib.level);\n\t\t\t\tnewParam.find(\".stx-data\").append(paramInput);\n\t\t\t}\n\t\t}\n\t\t// settings dialog default\n\t\telse {\n\t\t\tdialog.find(\".title\").text(\"Settings\");\n\n\t\t\t// clear the existing web components\n\t\t\tparameters = dialog.find(\"cq-fibonacci-settings\");\n\t\t\tparameters.children(\":not(template)\").remove();\n\t\t}\n\t\tthis.node.find(\"[cq-custom-fibonacci-setting] input\").val(\"\");\n\t}\n\n\t/**\n\t * Sets up a handler to process changes to fields\n\t * @param {HTMLElement} node The input field\n\t * @param {string} section The section that is being updated\n\t * @param {string} name The name of the field being updated\n\t * @memberOf WebComponents.cq-fib-settings-dialog\n\t * @private\n\t */\n\tsetChangeEvent(node, section, item) {\n\t\tvar self = this;\n\t\tfunction closure() {\n\t\t\treturn function () {\n\t\t\t\tvar vectorParameters = self.context.stx.currentVectorParameters;\n\t\t\t\tvar vectorType = vectorParameters.vectorType;\n\n\t\t\t\t// fibonacci type\n\t\t\t\tif (vectorParameters.fibonacci && vectorType != \"fibtimezone\") {\n\t\t\t\t\tvar defaultFibs = vectorParameters.fibonacci.fibs || [];\n\t\t\t\t\tif (this.type == \"checkbox\") {\n\t\t\t\t\t\tfor (var index = 0; index < defaultFibs.length; index++) {\n\t\t\t\t\t\t\tvar fib = defaultFibs[index];\n\n\t\t\t\t\t\t\tif (fib.level === item) {\n\t\t\t\t\t\t\t\tfib.display = this.checked ? true : false;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t};\n\t\t}\n\t\tnode[0].addEventListener(\"change\", closure());\n\t}\n}\n\nFibSettingsDialog.markup = `\n\t\t

Settings

\n\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\t
\n\t\t\t\t%\n\t\t\t\t
Add
\n\t\t\t
\n\t\t
\n\t\t
\n\t\t\t
Done
\n\t\t
\n\t`;\nCIQ.UI.addComponentDefinition(\"cq-fib-settings-dialog\", FibSettingsDialog);\n\n};\n\n\nlet __js_webcomponents_floatingWindow_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * The floating window component `cq-floating-window`.\n *\n * Creates a floating window that users can move and resize.\n *\n * @namespace WebComponents.cq-floating-window\n * @since 8.2.0\n */\nclass FloatingWindow extends CIQ.UI.ContextTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, FloatingWindow);\n\t\tthis.constructor = FloatingWindow;\n\t}\n\n\t/**\n\t * Initializes the context of the floating window component. Dynamically adds a listener for\n\t * the \"floatingWindow\" event based on the `type` parameter of the event (see\n\t * [floatingWindowEventListener]{@link CIQ.ChartEngine~floatingWindowEventListener}).\n\t *\n\t * @param {CIQ.UI.Context} context The chart user interface context.\n\t *\n\t * @alias setContext\n\t * @memberof WebComponents.cq-floating-window#\n\t * @since 8.2.0\n\t */\n\tsetContext(context) {\n\t\tconst { stx } = context;\n\t\tif (!stx.callbackListeners.floatingWindow) {\n\t\t\tstx.callbackListeners.floatingWindow = [];\n\t\t}\n\n\t\tstx.addEventListener(\"floatingWindow\", (message) => {\n\t\t\tconst exec = this[\"on\" + CIQ.capitalize(message.type)];\n\t\t\tif (exec) {\n\t\t\t\texec.call(this, message);\n\t\t\t\treturn true;\n\t\t\t}\n\t\t});\n\t}\n\n\t/**\n\t * The listener for \"floatingWindow\" events where the `type` parameter of the event is\n\t * \"shortcut\" (see\n\t * [floatingWindowEventListener]{@link CIQ.ChartEngine~floatingWindowEventListener}).\n\t *\n\t * Creates and positions a floating window.\n\t *\n\t * @param {object} params Listener parameters.\n\t * @param {string} params.content The contents of the floating window, typically an HTML\n\t * \t\tstring.\n\t * @param {HTMLElement} [params.container] The DOM element that visually contains the floating\n\t * \t\twindow. The window is positioned on screen relative to the element (see\n\t * \t\t{@link WebComponents.cq-floating-window.DocWindow#positionRelativeTo}). Defaults to\n\t * \t\t`document.body`.\n\t * @param {string} [params.title] Text that appears in the title bar of the floating window.\n\t * @param {number} [params.width] The width of the floating window in pixels.\n\t * @param {boolean} [params.status] The state of the floating window: true, to open the\n\t * \t\twindow; false, to close it. If the parameter is not provided, the floating window is\n\t * \t\ttoggled (opened if closed, closed if open).\n\t * @param {string} [params.tag] A label that identifies the floating window type; for example,\n\t * \t\t\"shortcut\", which indicates that the floating window contains the keyboard shortcuts\n\t * \t\tlegend. See the `tag` parameter of\n\t * \t\t[floatingWindowEventListener]{@link CIQ.ChartEngine~floatingWindowEventListener}.\n\t * @param {function} [params.onClose] A callback to execute when the floating window is\n\t * \t\tclosed.\n\t *\n\t * @alias onShortcut\n\t * @memberof WebComponents.cq-floating-window#\n\t * @since 8.2.0\n\t */\n\tonShortcut({ container, title, tag, content, width, status, onClose }) {\n\t\tif (this.shortcutWindow) {\n\t\t\tthis.shortcutWindow.toggle(status).ensureVisible();\n\t\t\treturn;\n\t\t}\n\t\tthis.shortcutWindow = this.constructor.windowImplementation.get({\n\t\t\ttag,\n\t\t\tcontent: content,\n\t\t\ttitle,\n\t\t\tcontainer: container || document.body,\n\t\t\tonClose\n\t\t});\n\t\tthis.shortcutWindow.toggle(true).update({ width }).positionRelativeTo();\n\t}\n\n\tonDocumentation({\n\t\tcontainer,\n\t\ttitle,\n\t\ttag,\n\t\tcontent,\n\t\tactionButtons,\n\t\twidth,\n\t\tstatus,\n\t\tonClose\n\t}) {\n\t\tfunction processButtonAction(action, documentationWindow) {\n\t\t\treturn () => {\n\t\t\t\tif (action === \"close\") {\n\t\t\t\t\tdocumentationWindow.toggle(false);\n\t\t\t\t} else if (typeof action === \"function\") {\n\t\t\t\t\taction();\n\t\t\t\t}\n\t\t\t};\n\t\t}\n\n\t\tthis.documentationWindow = this.constructor.windowImplementation.get({\n\t\t\ttag,\n\t\t\tcontent: content + \"
\",\n\t\t\ttitle,\n\t\t\tcontainer: container || document.body,\n\t\t\tonClose\n\t\t});\n\t\t// Add action buttons\n\t\tfor (let buttonData of actionButtons) {\n\t\t\tlet actionButton = document.createElement(\"button\");\n\t\t\tactionButton.innerText = buttonData.label;\n\t\t\tactionButton.style.marginTop = \"1em\";\n\t\t\tactionButton.style.marginRight = \"1em\";\n\t\t\tCIQ.safeClickTouch(\n\t\t\t\tactionButton,\n\t\t\t\tprocessButtonAction(buttonData.action, this.documentationWindow)\n\t\t\t);\n\t\t\tthis.documentationWindow.bodyEl.appendChild(actionButton);\n\t\t}\n\n\t\tif (this.context.stx.translateUI)\n\t\t\tthis.context.stx.translateUI(this.documentationWindow.w);\n\n\t\tthis.documentationWindow\n\t\t\t.toggle(true)\n\t\t\t.update({ width })\n\t\t\t.positionRelativeTo();\n\t}\n}\n\n/**\n * The window implementation of the [cq-floating-window]{@link WebComponents.cq-floating-window}\n * web component.\n *\n * @name WebComponents.cq-floating-window.DocWindow\n * @class\n * @since 8.2.0\n */\nclass DocWindow {\n\t/**\n\t * Creates the floating window DOM element and binds event handlers to the window.\n\t *\n\t * @param {object} params Constructor parameters.\n\t * @param {string} params.content The contents of the floating window, typically an HTML\n\t * \t\tstring.\n\t * @param {HTMLElement} [params.container] The DOM element that visually contains the floating\n\t * \t\twindow. The window is positioned on screen relative to the container element.\n\t * @param {string} [params.title] Text that appears in the title bar of the floating window.\n\t * @param {string} [params.tag] A label that identifies the floating window type; for example,\n\t * \t\t\"shortcut\", which indicates that the floating window contains the keyboard shortcuts\n\t * \t\tlegend.\n\t * @param {number} [params.minWidth] The minimum width of the floating window.\n\t * @param {number} [params.minHeight] The minimum height of the floating window.\n\t * @param {function} [params.onClose] A callback function to execute when the floating window\n\t * \t\tcloses.\n\t *\n\t * @constructor\n\t * @private\n\t * @since 8.2.0\n\t */\n\tconstructor({\n\t\tcontent,\n\t\ttitle,\n\t\ttag,\n\t\tminWidth,\n\t\tminHeight,\n\t\tcontainer,\n\t\tonClose\n\t}) {\n\t\tconst w = document.createElement(\"div\");\n\t\tw.innerHTML = this.constructor.markup;\n\t\tw.classList.add(\"ciq-window\");\n\t\t(container.ownerDocument || document).body.append(w);\n\t\tw.tag = tag;\n\t\tw.docWindow = this;\n\t\tObject.assign(this, {\n\t\t\tisDragging: false,\n\t\t\tisResizing: false,\n\t\t\tisOpen: false,\n\t\t\txDiff: 0,\n\t\t\tyDiff: 0,\n\t\t\tx: 50,\n\t\t\ty: 50,\n\t\t\tw\n\t\t});\n\t\tthis.bindEvents();\n\n\t\tthis.titleEl = w.querySelector(\".ciq-window-title\");\n\t\tthis.bodyEl = w.querySelector(\".ciq-window-body\");\n\t\tthis.titleBarEl = w.querySelector(\".ciq-window-bar\");\n\n\t\tthis.setProps({ title, content, minWidth, minHeight, container, onClose });\n\t\tthis.render();\n\t}\n\n\t/**\n\t * Stores the function parameters as properties of the floating window object.\n\t *\n\t * @param {object} params Parameters to store as properties.\n\t * @param {string} [params.title] Text that appears in the title bar of the floating window.\n\t * @param {string} [params.content] The contents of the floating window, typically an HTML\n\t * \t\tstring.\n\t * @param {HTMLElement} [params.container] The DOM element that visually contains the floating\n\t * \t\twindow. The window is positioned on screen relative to the container element (see\n\t * \t\t[positionRelativeTo]{@link WebComponents.cq-floating-window.DocWindow#positionRelativeTo}).\n\t * @param {number} [params.minWidth] The minimum width of the floating window.\n\t * @param {number} [params.minHeight] The minimum height of the floating window.\n\t * @param {function} [params.onClose] A callback function to execute when the floating windows\n\t * \t\tcloses.\n\t *\n\t * @alias setProps\n\t * @memberof WebComponents.cq-floating-window.DocWindow#\n\t * @since 8.2.0\n\t */\n\tsetProps({ title, content, minWidth, minHeight, container, onClose }) {\n\t\tconst { w, titleEl, bodyEl } = this;\n\t\tif (title !== undefined) titleEl.textContent = title;\n\t\tif (content !== undefined) bodyEl.innerHTML = content;\n\t\tif (minWidth !== undefined) w.style.minWidth = minWidth + \"px\";\n\t\tif (minHeight !== undefined) w.style.minHeight = minHeight + \"px\";\n\t\tif (container) this.container = container;\n\t\tif (onClose !== undefined) this.onClose = onClose;\n\t}\n\n\t/**\n\t * Adds event listeners to the floating window.\n\t *\n\t * The listeners enable the window to be moved, resized, collapsed/expanded, and closed.\n\t *\n\t * @alias bindEvents\n\t * @memberof WebComponents.cq-floating-window.DocWindow#\n\t * @since 8.2.0\n\t */\n\tbindEvents() {\n\t\tconst { w } = this;\n\t\tconst qs = (path) => w.querySelector(path);\n\n\t\tqs(\".ciq-window-bar\").addEventListener(\n\t\t\t\"mousedown\",\n\t\t\tthis.onStartDrag.bind(this)\n\t\t);\n\n\t\tconst toggleCollapse = this.toggleCollapse.bind(this);\n\t\tqs(\".ciq-window-bar\").addEventListener(\"dblclick\", toggleCollapse);\n\t\tqs(\".ciq-window-collapse\").addEventListener(\"click\", toggleCollapse);\n\n\t\tconst resizeControls = (\n\t\t\t\"top, right, bottom, left, \" +\n\t\t\t\"top-right, bottom-right, bottom-left, top-left\"\n\t\t).split(/, /);\n\t\tresizeControls.forEach((control) => {\n\t\t\tqs(`.ciq-window-resize-${control}`).addEventListener(\n\t\t\t\t\"mousedown\",\n\t\t\t\tstartResize()\n\t\t\t);\n\t\t});\n\t\tw.ownerDocument.addEventListener(\"mousemove\", this.onMouseMove.bind(this));\n\t\tw.ownerDocument.addEventListener(\"mouseup\", this.onMouseUp.bind(this));\n\n\t\tqs(\".ciq-window-close\").addEventListener(\n\t\t\t\"click\",\n\t\t\tthis.toggle.bind(this, false)\n\t\t);\n\n\t\tw.ownerDocument.defaultView.addEventListener(\n\t\t\t\"resize\",\n\t\t\tthis.ensureVisible.bind(this)\n\t\t);\n\n\t\tconst self = this;\n\t\tfunction startResize() {\n\t\t\treturn function (e) {\n\t\t\t\tif (e.button !== 0) return;\n\n\t\t\t\tconst type = e.target.className.replace(/ciq-window-resize-/, \"\");\n\t\t\t\tself.isResizing = type;\n\t\t\t\tself.downX = e.pageX;\n\t\t\t\tself.downY = e.pageY;\n\t\t\t\tself.startWidth = self.width;\n\t\t\t\tself.startHeight = self.height;\n\t\t\t\tself.startLeft = self.x;\n\t\t\t\tself.startTop = self.y;\n\t\t\t};\n\t\t}\n\t}\n\n\t/**\n\t * Updates properties of the floating window.\n\t *\n\t * @param {object} params Floating window properties.\n\t * @param {number} [params.x] The horizontal position of the floating window in pixels.\n\t * @param {number} [params.y] The vertical position of the floating window in pixels.\n\t * @param {number} [params.width] The width of the floating window in pixels.\n\t * @param {number} [params.height] The height of the floating window in pixels.\n\t *\n\t * @alias update\n\t * @memberof WebComponents.cq-floating-window.DocWindow#\n\t * @since 8.2.0\n\t */\n\tupdate({ x, y, width, height }) {\n\t\tObject.assign(this, { x, y, width, height });\n\t\tthis.render();\n\t\treturn this;\n\t}\n\n\t/**\n\t * Positions the floating window relative to the\n\t * \n\t * DOMRect of a DOM element.\n\t *\n\t * @param {object} params Positioning parameters.\n\t * @param {HTMLElement} [params.container] The DOM element relative to which the floating\n\t * \t\twindow is positioned. Defaults to the `container` parameter of the\n\t * \t\t[floatingWindowEventListener]{@link CIQ.ChartEngine~floatingWindowEventListener} or,\n\t * \t\tif the `container` parameter is not available, `document.body`.\n\t * @param {string} [params.location=\"center\"] The location of the floating window within the\n\t * \t\tcontainer element's bounding rectangle. If the value is \"center\" (the default), the\n\t * \t\tfloating window is centered horizontally and vertically within the container\n\t * \t\trectangle. Otherwise, the window is positioned in the upper left corner of the\n\t * \t\trectangle.\n\t *\n\t * @alias positionRelativeTo\n\t * @memberof WebComponents.cq-floating-window.DocWindow#\n\t * @since 8.2.0\n\t */\n\tpositionRelativeTo({ container, location = \"center\" } = {}) {\n\t\tconst { x, y, width, height } = (\n\t\t\tcontainer ||\n\t\t\tthis.container ||\n\t\t\tdocument.body\n\t\t).getBoundingClientRect();\n\n\t\tif (this.width > width - 20) this.width = width - 20;\n\t\tif (this.height > height - 20) this.height = height - 20;\n\n\t\tif (location === \"center\") {\n\t\t\tthis.x = x + width / 2 - this.width / 2;\n\t\t\tthis.y = y + height / 2 - this.height / 2;\n\t\t}\n\n\t\tthis.render();\n\t\treturn this;\n\t}\n\n\t/**\n\t * Repositions the floating window (if necessary) when the display is resized to keep the\n\t * window within the document view.\n\t *\n\t * @alias ensureVisible\n\t * @memberof WebComponents.cq-floating-window.DocWindow#\n\t * @since 8.2.0\n\t */\n\tensureVisible() {\n\t\tif (!this.isOpen) return;\n\t\tconst { x, y, width } = this.w.getBoundingClientRect();\n\t\tconst { innerWidth, innerHeight } = this.w.ownerDocument.defaultView;\n\n\t\tif (y > innerHeight - 20) {\n\t\t\tthis.y = innerHeight - 20;\n\t\t}\n\t\tif (x > innerWidth - width) {\n\t\t\tthis.x = innerWidth - width;\n\t\t}\n\t\tthis.render();\n\t}\n\n\t/**\n\t * Renders the position updates and open/close, dragging, and resizing state changes made to\n\t * the floating window by other methods of this class.\n\t *\n\t * @alias render\n\t * @memberof WebComponents.cq-floating-window.DocWindow#\n\t * @private\n\t * @since 8.2.0\n\t */\n\trender() {\n\t\tconst { x, y } = this;\n\t\tObject.assign(this.w.style, {\n\t\t\tdisplay: this.isOpen ? \"\" : \"none\",\n\t\t\ttransform: \"translate(\" + x + \"px, \" + y + \"px)\"\n\t\t});\n\t\tthis.w.classList.toggle(\n\t\t\t\"ciq-wdragging\",\n\t\t\tthis.isDragging || this.isResizing\n\t\t);\n\t}\n\n\tget width() {\n\t\treturn this.w.offsetWidth;\n\t}\n\tset width(value) {\n\t\tif (value) {\n\t\t\tthis.w.style.width = value + \"px\";\n\t\t}\n\t}\n\n\tget height() {\n\t\treturn this.w.offsetHeight;\n\t}\n\tset height(value) {\n\t\tif (value) {\n\t\t\tthis.w.style.height = value + \"px\";\n\t\t}\n\t}\n\n\t/**\n\t * Helper function that constrains the floating window to the document view when the window\n\t * is dragged horizontally.\n\t *\n\t * Clamps the horizontal position of the floating window between 0 (so the window cannot be\n\t * dragged off the left side of the view) and the width of the document view minus the width\n\t * of the floating window (so the window cannot be dragged off the right side of the view).\n\t *\n\t * @param {number} value The position of the mouse relative to the left edge of the floating\n\t * \t\twindow.\n\t * @return {number} The value for the clamped horizontal position of the floating window:\n\t * - `value` if `value` is greater than 0 and less than the width of the document view minus\n\t * the width of the floating window\n\t * - 0 if `value` is less than 0\n\t * - The width of the document view minus the width of the floating window if `value` is\n\t * greater than the width of the document view minus the width of the floating window\n\t *\n\t * @alias clampX\n\t * @memberof WebComponents.cq-floating-window.DocWindow#\n\t * @since 8.2.0\n\t */\n\tclampX(value) {\n\t\treturn Math.min(\n\t\t\tMath.max(value, 0),\n\t\t\tthis.w.ownerDocument.defaultView.innerWidth - this.w.offsetWidth\n\t\t);\n\t}\n\n\t/**\n\t * Helper function that constrains the floating window to the document view when the window\n\t * is dragged vertically.\n\t *\n\t * Clamps the vertical position of the floating window between 0 (so the window cannot be\n\t * dragged off the top of the view) and the height of the document view minus the height of\n\t * the floating window title bar and a margin (so the window title bar cannot be dragged off\n\t * the bottom of the view).\n\t *\n\t * @param {number} n The position of the mouse relative to the top edge of the floating window.\n\t * @return {number} The value for the clamped vertical position of the floating window:\n\t * - `n` if `n` is greater than 0 and less than the height of the document view minus the\n\t * height of the floating window title bar and margin\n\t * - 0 if `n` is less than 0\n\t * - The height of the document view minus the height of the floating window title bar and\n\t * margin if `n` is greater than the height of the document view minus the height of the\n\t * floating window title bar and margin\n\t *\n\t * @alias clampY\n\t * @memberof WebComponents.cq-floating-window.DocWindow#\n\t * @since 8.2.0\n\t */\n\tclampY(n) {\n\t\tconst margin = 8;\n\t\treturn Math.min(\n\t\t\tMath.max(n, 0),\n\t\t\tthis.w.ownerDocument.defaultView.innerHeight -\n\t\t\t\tthis.titleBarEl.offsetHeight -\n\t\t\t\tmargin\n\t\t);\n\t}\n\n\t/**\n\t * The event listener for mouse move events that occur when a floating window is being dragged\n\t * or resized.\n\t *\n\t * Moves or resizes the floating window.\n\t *\n\t * @param {MouseEvent} e The\n\t * \t\t\n\t * \t\tmouse event object.\n\t *\n\t * @alias onMouseMove\n\t * @memberof WebComponents.cq-floating-window.DocWindow#\n\t * @since 8.2.0\n\t */\n\tonMouseMove(e) {\n\t\tconst { isDragging, isResizing } = this;\n\n\t\tif (!isDragging && !isResizing) return;\n\n\t\tconst xDiff = e.pageX - this.downX;\n\t\tconst yDiff = e.pageY - this.downY;\n\n\t\tif (isDragging) {\n\t\t\tthis.x = this.clampX(xDiff);\n\t\t\tthis.y = this.clampY(yDiff);\n\t\t}\n\t\tconst { startWidth, startHeight } = this;\n\t\tconst margin = 2;\n\t\tlet height, width;\n\n\t\tif (/left/.test(isResizing)) {\n\t\t\twidth = this.startWidth - xDiff;\n\t\t\tthis.width = width;\n\t\t\tthis.x = this.startLeft + xDiff;\n\t\t}\n\n\t\tif (/top/.test(isResizing)) {\n\t\t\theight = this.startHeight - yDiff;\n\t\t\tthis.height = height;\n\t\t\tthis.y = this.startTop + yDiff;\n\t\t}\n\n\t\tif (isResizing && /right|bottom/.test(isResizing)) {\n\t\t\tthis.width = /right/.test(isResizing)\n\t\t\t\t? xDiff + startWidth\n\t\t\t\t: width || startWidth;\n\n\t\t\tthis.height = /bottom/.test(isResizing)\n\t\t\t\t? yDiff + startHeight\n\t\t\t\t: height || startHeight;\n\n\t\t\tconst win = this.w.ownerDocument.defaultView;\n\t\t\tif (this.x + this.width - margin > win.innerWidth) {\n\t\t\t\tthis.width = win.innerWidth - this.x - margin;\n\t\t\t}\n\t\t\tif (this.y + this.height - margin > win.innerHeight) {\n\t\t\t\tthis.height = win.innerHeight - this.y - margin;\n\t\t\t}\n\t\t}\n\n\t\tthis.render();\n\t}\n\n\t/**\n\t * The event listener for mouse down events that occur on the floating window's title bar.\n\t *\n\t * The mouse down event starts a click-and-drag action on the floating window.\n\t *\n\t * @param {MouseEvent} e The\n\t * \t\t\n\t * \t\tmouse event object.\n\t *\n\t * @alias onStartDrag\n\t * @memberof WebComponents.cq-floating-window.DocWindow#\n\t * @since 8.2.0\n\t */\n\tonStartDrag(e) {\n\t\tif (e.button !== 0) return;\n\n\t\tthis.isDragging = true;\n\t\tthis.downX = e.pageX - this.x;\n\t\tthis.downY = e.pageY - this.y;\n\t}\n\n\t/**\n\t * The event listener for mouse up events that occur on a floating window.\n\t *\n\t * Stops a dragging or resizing action of the floating window.\n\t *\n\t * @alias onMouseUp\n\t * @memberof WebComponents.cq-floating-window.DocWindow#\n\t * @since 8.2.0\n\t */\n\tonMouseUp() {\n\t\tthis.isDragging = false;\n\t\tthis.isResizing = false;\n\t\tthis.render();\n\t}\n\n\t/**\n\t * Opens and closes the floating window.\n\t *\n\t * @param {boolean} [value] If true, the floating window is opened. If false, the\n\t * \t\tfloating window is closed. If undefined, the floating window is toggled; that is,\n\t * \t\topened if it is currently closed, closed if it is currently open.\n\t *\n\t * @alias toggle\n\t * @memberof WebComponents.cq-floating-window.DocWindow#\n\t * @since 8.2.0\n\t */\n\ttoggle(value) {\n\t\tconst newValue = value === undefined ? !this.isOpen : value;\n\t\tconst changed = this.isOpen !== newValue;\n\t\tthis.isOpen = newValue;\n\t\tif (changed && !this.isOpen && this.onClose) {\n\t\t\tthis.onClose();\n\t\t\tif (this.isCollapsed) this.toggleCollapse(); // reset to open for next time\n\t\t}\n\t\tthis.render();\n\t\treturn this;\n\t}\n\n\t/**\n\t * Toggles the display state — expanded or collapsed — of the floating window.\n\t *\n\t * In the expanded state, the full floating window is displayed; in the collapsed state, only\n\t * the floating window title bar appears.\n\t *\n\t * @alias toggleCollapse\n\t * @memberof WebComponents.cq-floating-window.DocWindow#\n\t * @since 8.2.0\n\t */\n\ttoggleCollapse() {\n\t\tthis.isCollapsed = !this.isCollapsed;\n\t\tif (this.isCollapsed) {\n\t\t\tthis.prevHeight = this.height;\n\t\t\tthis.w.classList.add(\"ciq-window-collapsed\");\n\t\t\tthis.height = this.titleBarEl.offsetHeight;\n\t\t\tif (this.onCollapse) this.onCollapse();\n\t\t} else {\n\t\t\tthis.height = this.prevHeight;\n\t\t\tthis.w.classList.remove(\"ciq-window-collapsed\");\n\t\t}\n\t\tconst collapseEl = this.w.querySelector(\".ciq-window-collapse\");\n\t\tcollapseEl.title = this.isCollapsed ? \"Expand\" : \"Collapse\";\n\t\tthis.render();\n\t}\n}\n\nDocWindow.markup = `\n
\n
\n\n\n\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n`;\n\n/**\n * Gets a floating window instance.\n *\n * If the `tag` parameter is provided, the function checks whether the document already contains\n * a floating window with that tag. If so, the function parameters are stored as properties of the\n * floating window object (see\n * [setProps]{@link WebComponents.cq-floating-window.DocWindow#setProps}), and a reference to the\n * floating window is returned. Otherwise, the function returns a new floating window created with\n * the provided parameters.\n *\n * **Note:** Tags can be used to manage floating windows in multi-chart documents. For more\n * information, see the `tag` parameter of\n * [floatingWindowEventListener]{@link CIQ.ChartEngine~floatingWindowEventListener}.\n *\n * @param {object} params Floating window parameters.\n * @param {string} params.content The contents of the floating window, typically an HTML string.\n * @param {HTMLElement} [params.container] The DOM element that visually contains the floating\n * \t\twindow. The floating window is positioned on screen relative to the container element (see\n * \t\t[positionRelativeTo]{@link WebComponents.cq-floating-window.DocWindow#positionRelativeTo}).\n * @param {string} [params.title] Text that appears in the title bar of the floating window.\n * @param {string} [params.tag] A label that identifies the floating window type; for example,\n * \t\t\"shortcut\", which indicates that the floating window contains the chart keyboard shortcuts\n * \t\tlegend.\n * @param {number} [params.minWidth] The minimum width of the floating window.\n * @param {number} [params.minHeight] The minimum height of the floating window.\n * @param {function} [params.onClose] A callback function to execute when the floating window\n * \t\tcloses.\n * @return {object} A [DocWindow]{@link WebComponents.cq-floating-window.DocWindow} instance.\n *\n * @alias get\n * @memberof WebComponents.cq-floating-window.DocWindow\n * @static\n * @since 8.2.0\n */\nDocWindow.get = function (params) {\n\tlet w;\n\tif (params.tag) {\n\t\tw = Array.from(\n\t\t\t(params.container.ownerDocument || document).querySelectorAll(\n\t\t\t\t\".ciq-window\"\n\t\t\t)\n\t\t).find((el) => el.tag === params.tag);\n\t\tif (w) {\n\t\t\tw.docWindow.setProps(params);\n\t\t\treturn w.docWindow;\n\t\t}\n\t}\n\treturn new this(params);\n};\n\n/**\n * A reference to the class that implements the floating window.\n *\n * @alias windowImplementation\n * @memberof WebComponents.cq-floating-window#\n * @default [DocWindow]{@link WebComponents.cq-floating-window.DocWindow}\n * @since 8.2.0\n */\nFloatingWindow.windowImplementation = DocWindow;\n\nCIQ.UI.addComponentDefinition(\"cq-floating-window\", FloatingWindow);\n\n};\n\n\nlet __js_webcomponents_gridSizePicker_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Creates a `` web component.\n *\n * Attributes:\n *
    \n * \t
  • maxrows: number — Maximum number of rows allowed
  • \n * \t
  • maxcols: number — Maximum number of columns allowed
  • \n *
\n * \n * Please note that this web component uses 'Symbol' and 'Symbol.Iterator' to create the table dynamically.\n * This syntax is not supported on older browsers such as in IE 11 or Chrome 49.\n *\n * @namespace WebComponents.cq-grid-size-picker\n * @example\n \n * @since 7.2.0\n */\nclass GridSizePicker extends CIQ.UI.BaseComponent {\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tthis.innerHTML = this.render();\n\t\tthis.columns = 2;\n\t\tthis.rows = 2;\n\t\tthis.generateTable(this.columns, this.rows);\n\t\tthis.highlightTable(this.columns - 1, this.rows - 1);\n\t\tthis.querySelector(\"table\").addEventListener(\"mouseleave\", () => {\n\t\t\tthis.generateTable(this.columns + 1, this.rows + 1);\n\t\t\tthis.highlightTable(this.columns, this.rows);\n\t\t});\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, GridSizePicker);\n\t\tthis.constructor = GridSizePicker;\n\t}\n\n\tget maxcols() {\n\t\treturn this.getAttribute(\"maxcols\") || 4;\n\t}\n\n\tset maxcols(newValue) {\n\t\tthis.setAttribute(\"maxcols\", newValue);\n\t}\n\n\tget maxrows() {\n\t\treturn this.getAttribute(\"maxrows\") || 4;\n\t}\n\n\tset maxrows(newValue) {\n\t\tthis.setAttribute(\"maxrows\", newValue);\n\t}\n\n\tgenerateTable(columns, rows) {\n\t\tvar self = this;\n\t\tfunction mouseEnterFcn(event) {\n\t\t\t// Clamp the rows and cols to their max setting before generating the new table\n\t\t\tlet newColCt = parseInt(event.target.dataset.column) + 1;\n\t\t\tif (newColCt > self.maxcols) newColCt = self.maxcols;\n\t\t\tlet newRowCt = parseInt(event.target.dataset.row) + 1;\n\t\t\tif (newRowCt > self.maxrows) newRowCt = self.maxrows;\n\n\t\t\tself.generateTable(newColCt, newRowCt);\n\t\t\t// Hilite based on the selected cell, not the expected grid size\n\t\t\tself.highlightTable(\n\t\t\t\tparseInt(event.target.dataset.column),\n\t\t\t\tparseInt(event.target.dataset.row)\n\t\t\t);\n\t\t}\n\n\t\tlet parentElem = this.querySelector(\"table\");\n\n\t\tif (!parentElem) return;\n\t\t// Clear out the existing table\n\t\tthis.cleanTable(columns, rows);\n\n\t\tcolumns = columns || 1;\n\t\trows = rows || 1;\n\n\t\tfor (let idx = 1; idx <= Math.min(rows, this.maxrows); idx++) {\n\t\t\tlet tmpRow;\n\t\t\tif (parentElem.childNodes[idx - 1]) {\n\t\t\t\ttmpRow = parentElem.childNodes[idx - 1];\n\t\t\t} else {\n\t\t\t\ttmpRow = document.createElement(\"tr\");\n\t\t\t\tparentElem.appendChild(tmpRow);\n\t\t\t}\n\t\t\tfor (let jdx = 1; jdx <= Math.min(columns, this.maxcols); jdx++) {\n\t\t\t\tif (!tmpRow.childNodes[jdx - 1]) {\n\t\t\t\t\tlet tmpCell = document.createElement(\"td\");\n\t\t\t\t\ttmpCell.dataset.row = idx;\n\t\t\t\t\ttmpCell.dataset.column = jdx;\n\t\t\t\t\ttmpCell.dataset.rows = rows;\n\t\t\t\t\ttmpCell.dataset.columns = columns;\n\t\t\t\t\ttmpCell.addEventListener(\"mouseenter\", mouseEnterFcn);\n\t\t\t\t\ttmpCell.addEventListener(\n\t\t\t\t\t\t\"click\",\n\t\t\t\t\t\tfunction (event) {\n\t\t\t\t\t\t\tthis.triggerUpdateGridEvent(\n\t\t\t\t\t\t\t\tevent.target.dataset.column,\n\t\t\t\t\t\t\t\tevent.target.dataset.row\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}.bind(this)\n\t\t\t\t\t);\n\n\t\t\t\t\ttmpCell.appendChild(document.createElement(\"div\"));\n\n\t\t\t\t\ttmpRow.appendChild(tmpCell);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\ttriggerUpdateGridEvent(columns, rows) {\n\t\tthis.columns = +columns;\n\t\tthis.rows = +rows;\n\t\tconst context = this.closest(\"cq-context, [cq-context]\");\n\t\tcontext.dispatchEvent(\n\t\t\tnew CustomEvent(\"update-grid\", {\n\t\t\t\tdetail: {\n\t\t\t\t\tcolumns: columns,\n\t\t\t\t\trows: rows,\n\t\t\t\t\tcontainer: this.closest(\"cq-context\")\n\t\t\t\t},\n\t\t\t\tbubbles: true,\n\t\t\t\tcomposed: true\n\t\t\t})\n\t\t);\n\t}\n\n\thighlightTable(columns, rows) {\n\t\tfor (let gridCell of this.querySelectorAll(\"td\")) {\n\t\t\tif (gridCell.dataset.column <= columns && gridCell.dataset.row <= rows) {\n\t\t\t\tgridCell.classList.add(\"highlight\");\n\t\t\t} else {\n\t\t\t\tgridCell.classList.remove(\"highlight\");\n\t\t\t}\n\t\t}\n\t\tconst rowEl = this.querySelector(\".row.count\");\n\t\tconst multEl = this.querySelector(\".multiply\");\n\t\tconst hideRows = this.maxrows < 2;\n\t\trowEl.style.display = hideRows ? \"none\" : \"\";\n\t\tmultEl.style.display = hideRows ? \"none\" : \"\";\n\t\trowEl.innerHTML = rows;\n\t\tthis.querySelector(\".column.count\").innerHTML = columns;\n\t}\n\n\tcleanTable(columns, rows) {\n\t\tlet element = this.querySelector(\"table\");\n\t\t// Remove unused rows\n\t\twhile (element.childNodes.length > rows) {\n\t\t\telement.removeChild(element.lastChild);\n\t\t}\n\t\t// Remove unused columns from remaining rows\n\t\tfor (let rowNode of element.childNodes) {\n\t\t\twhile (rowNode.childNodes.length > columns) {\n\t\t\t\trowNode.removeChild(rowNode.lastChild);\n\t\t\t}\n\t\t}\n\t}\n\n\trender() {\n\t\treturn `\n\t\t\t\t\n\n\t\t\t\t
\n\t\t\t\t

1 + 1

\n\t\t\t`;\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-grid-size-picker\", GridSizePicker);\n\n};\n\n\nlet __js_webcomponents_heading_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Menu web component ``.\n *\n * Attribute cq-filter adds input for filtering cq-items in\n * cq-heading sibling container based on entered input.\n * Filter is matching input pattern anywhere in cq-item text.\n *\n * Attribute value passed in cq-filter is used for input placeholder.\n * Default placeholder is set to \"Search\"\n *\n * Attribute cq-filter-min can be used to override the default minimum\n * number of records for filter to show. The default is 15.\n *\n * @namespace WebComponents.cq-menu-item-filter\n * @example\n * \n * Studies\n *\n * \n * Studies\n *\n * \n * Studies\n */\nclass Heading extends CIQ.UI.ContextTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, Heading);\n\t}\n\n\tsetContext() {\n\t\tif (!this.hasAttribute(\"cq-filter\")) return;\n\n\t\tconst filter = this.getAttribute(\"cq-filter\") || \"Search\";\n\t\tthis.createFilter(filter);\n\t}\n\n\tcreateFilter(placeholder) {\n\t\tconst searchWrapper = document.createElement(\"div\");\n\t\tsearchWrapper.classList.add(\"searchFilter\");\n\t\tthis.appendChild(searchWrapper);\n\t\tconst input = document.createElement(\"input\");\n\t\tinput.type = \"search\";\n\t\tinput.placeholder = placeholder;\n\t\tinput.setAttribute(\"tabindex\", \"-1\");\n\t\tsearchWrapper.appendChild(input);\n\t\tthis.searchWrapper = searchWrapper;\n\n\t\tconst itemContainer = this.nextElementSibling;\n\t\tlet previousValue = \"\";\n\n\t\tconst updateListVisibility = ({ target: { value } }) => {\n\t\t\tconst re = new RegExp(value, \"i\");\n\t\t\tconst qsa = this.qsa;\n\n\t\t\tqsa(\"cq-item\", itemContainer).forEach((el) => {\n\t\t\t\tconst visibilityAction =\n\t\t\t\t\tvalue && !re.test(el.textContent) ? \"add\" : \"remove\";\n\t\t\t\tel.classList[visibilityAction](\"item-hidden\");\n\t\t\t\tif (previousValue !== value) {\n\t\t\t\t\tpreviousValue = value;\n\t\t\t\t\tthis.removeFocused.apply(itemContainer);\n\t\t\t\t\tqsa(\"cq-keyboard-selected-highlight\").forEach((highlightEl) => {\n\t\t\t\t\t\thighlightEl.classList.add(\"disabled\");\n\t\t\t\t\t});\n\t\t\t\t\tinput.focus();\n\t\t\t\t}\n\t\t\t});\n\t\t};\n\t\tinput.addEventListener(\"input\", updateListVisibility);\n\t\tinput.addEventListener(\"keyup\", updateListVisibility);\n\n\t\tconst minItemCount = this.getAttribute(\"cq-filter-min\") || 15;\n\n\t\tconst showFilterIfNecessary = () => {\n\t\t\tconst itemCount = this.qsa(\"cq-item\", itemContainer).length;\n\t\t\tsearchWrapper.classList[itemCount > minItemCount ? \"add\" : \"remove\"](\n\t\t\t\t\"active\"\n\t\t\t);\n\t\t};\n\n\t\t// Delay the execution of the filter activation check until sibling child nodes\n\t\t// have been created providing reference to the need for filter\n\t\t// based on cq-filter-min setting\n\t\tif (typeof MutationObserver === undefined) {\n\t\t\tsearchWrapper.classList.add(\"active\");\n\t\t\treturn;\n\t\t}\n\t\tnew MutationObserver(showFilterIfNecessary).observe(this.parentElement, {\n\t\t\tchildList: true,\n\t\t\tsubtree: true\n\t\t});\n\n\t\tshowFilterIfNecessary();\n\t}\n}\nCIQ.UI.addComponentDefinition(\"cq-heading\", Heading);\n\n};\n\n\nlet __js_webcomponents_headsupDynamic_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * The dynamic heads-up display web component ``.\n *\n * An encapsulation of the markup of a dynamic heads-up display.\n *\n * @namespace WebComponents.cq-hu-dynamic\n * @since 7.5.0\n *\n * @example\n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n * \n *
\n * \n * \n * \n * \n *
Volume
\n *
\n *
\n *
\n *
\n * \n *
Open
\n *
Close
\n *
High
\n *
Low
\n *
\n *
\n *
\n */\nclass HeadsUpDynamic extends CIQ.UI.ContextTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, HeadsUpDynamic);\n\t\tthis.constructor = HeadsUpDynamic;\n\t}\n\n\tdisconnectedCallback() {\n\t\tsuper.disconnectedCallback();\n\t\tthis.attached = true; // prevent recursive recreation\n\t}\n\n\t/**\n\t * Creates an instance of {@link CIQ.UI.HeadsUp}. Subscribes to the `headsUp` channel\n\t * which provides messages to start and stop the marker.\n\t *\n\t * @param {CIQ.UI.Context} context The chart user interface context.\n\t *\n\t * @alias setContext\n\t * @memberof WebComponents.cq-hu-dynamic\n\t * @since 7.5.0\n\t */\n\tsetContext(context) {\n\t\tthis.addDefaultMarkup();\n\t\tconst UIHeadsUpDynamic = new CIQ.UI.HeadsUp(this, context, {\n\t\t\tfollowMouse: true,\n\t\t\tautoStart: false\n\t\t});\n\n\t\tlet headsUp =\n\t\t\tcontext.config && context.config.channels\n\t\t\t\t? context.config.channels.headsUp\n\t\t\t\t: \"layout.headsUp\";\n\t\tthis.channelSubscribe(headsUp, (value) => {\n\t\t\tUIHeadsUpDynamic[\n\t\t\t\tvalue === \"dynamic\" || (value || {}).dynamic ? \"begin\" : \"end\"\n\t\t\t]();\n\t\t});\n\t}\n}\n\nHeadsUpDynamic.markup = `\n\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t\t
\n\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t
Volume
\n\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t
\n\t\t\t\n\t\t\t\t
Open
\n\t\t\t\t
Close
\n\t\t\t\t
High
\n\t\t\t\t
Low
\n\t\t\t
\n\t\t
\n\t`;\nCIQ.UI.addComponentDefinition(\"cq-hu-dynamic\", HeadsUpDynamic);\n\n};\n\n\nlet __js_webcomponents_headsupStatic_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * The static heads up display web component ``.\n *\n * An encapsulation of the markup of a static heads-up marker. The static heads-up marker does\n * not follow the mouse cursor.\n *\n * @namespace WebComponents.cq-hu-static\n * @since 7.5.0\n *\n * @example\n * \n *
\n *
Price
\n *
Open
\n *
Close
\n *
\n *
\n *
Vol
\n * \n * \n * \n * \n *
High
\n *
Low
\n *
\n *
\n */\nclass HeadsUpStatic extends CIQ.UI.ContextTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, HeadsUpStatic);\n\t\tthis.constructor = HeadsUpStatic;\n\t}\n\n\tdisconnectedCallback() {\n\t\tsuper.disconnectedCallback();\n\t\tthis.attached = true; // prevent recursive recreation\n\t}\n\n\t/**\n\t * Creates an instance of {@link CIQ.UI.HeadsUp}. Subscribes to the `headsUp` channel\n\t * which provides messages to start and stop the marker.\n\t *\n\t * @param {CIQ.UI.Context} context The chart user interface context.\n\t *\n\t * @alias setContext\n\t * @memberof WebComponents.cq-hu-static\n\t * @since 7.5.0\n\t */\n\tsetContext(context) {\n\t\tthis.addDefaultMarkup();\n\t\tconst UIHeadsUpStatic = new CIQ.UI.HeadsUp(this, context, {\n\t\t\tautoStart: true\n\t\t});\n\n\t\tlet headsUp =\n\t\t\tcontext.config && context.config.channels\n\t\t\t\t? context.config.channels.headsUp\n\t\t\t\t: \"layout.headsUp\";\n\t\tthis.channelSubscribe(headsUp, (value) => {\n\t\t\tUIHeadsUpStatic[\n\t\t\t\tvalue === \"static\" || (value || {}).static ? \"begin\" : \"end\"\n\t\t\t]();\n\t\t});\n\t}\n}\n\nHeadsUpStatic.markup = `\n\t\t
\n\t\t\t
Price
\n\t\t\t
Open
\n\t\t\t
Close
\n\t\t
\n\t\t
\n\t\t\t
Vol
\n\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\t
High
\n\t\t\t
Low
\n\t\t
\n\t`;\nCIQ.UI.addComponentDefinition(\"cq-hu-static\", HeadsUpStatic);\n\n};\n\n\nlet __js_webcomponents_help_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Help web component `` displays help if available. Long-press time is set in the [stxx.longHoldTime]{@link https://documentation.chartiq.com/CIQ.ChartEngine.html#callbacks%5B%60longhold%60%5D} function.\n * \n * **Configuring help pop-ups**\n * \n * The *chartiq/examples/help/* folder contains image files and the *helpContent.js* file for configuring help pop ups.\n * \n * ```js\n * import { CIQ } from \"../../js/chartiq.js\";\n * CIQ.Help = CIQ.Help || function () {};\n * CIQ.Help.Message = \"Glowing dots indicate which items have help available. At any time, long press a feature to make the help window appear.\";\n * CIQ.Help.Actions = {\n * \t\tclose: {\n * \t\t\tlabel: \"Exit Help\",\n * \t\t\taction: \"close\" // Close is handled by the floating window\n *\t\t},\n *\t\tenable: {\n *\t\t\tlabel: \"Enable This Feature\",\n *\t\t\taction: function (target) {\n *\t\t\t\t// Click the target (parent of the element)\n *\t\t\t\ttarget.dispatchEvent(new Event(\"stxtap\"));\n * \t}\n * \t}\n * };\n * CIQ.Help.Content = {\n * \t\tdrawing_tools_toggle: {\n * title: \"Toggle: Drawing Tools\",\n * content:\n *\t\t\t\"Toggles display of the drawing tools palette. Drawing tools allow you to add custom markings and annotations to the chart.\"\n * \t},\n *\t\tdrawing_palette_rectangle: {\n * title: \"Drawing Tool: Rectangle\",\n * content:\n * \" Add a rectangle shape onto the chart.\"\n *\t\t},\n *\t\tdrawing_palette_annotation: {\n *\t\t\ttitle: \"Drawing Tool: Annotation\",\n *\t\t\tcontent: \"Add text annotations onto the chart.\"\n *\t\t},\n *\t\tdrawing_palette_arrow: {\n *\t\t\ttitle: \"Drawing Tool: Arrow\",\n *\t\t\tcontent: \"Add an arrow shape onto the chart.\"\n *\t\t},\n *\t\tdrawing_palette_line: {\n *\t\t\ttitle: \"Drawing Tool: Line\",\n *\t\t\tcontent: \"Add a line at any angle or position across the chart.\"\n *\t\t},\n *\t\tdrawing_palette_horizontal: {\n *\t\t\ttitle: \"Drawing Tool: Horizontal\",\n *\t\t\tcontent: \"Add a horizontal line at any point onto the chart.\"\n *\t\t},\n *\t\tdrawing_palette_vertical: {\n *\t\t\ttitle: \"Drawing Tool: Vertical\",\n *\t\t\tcontent: \"Add a vertical line at any point onto the chart.\"\n *\t\t},\n *\t\tdrawing_palette_segment: {\n *\t\t\ttitle: \"Drawing Tool: Segment\",\n *\t\t\tcontent: \"Add a line segment onto the chart.\"\n *\t\t},\n *\t\tdefault: {\n *\t\t\ttitle: \"Help not available.\",\n *\t\t\tcontent: \"No documentation for this topic could be found.\",\n *\t\t\tactions: [CIQ.Help.Actions.close]\n *\t\t}\n * };\n```\n\n * - `CIQ.Help.Content` defines the content object. \n * - Properties such as `drawing_palette_rectangle` match with an identifier set in the HTML. \n * - The help author adds `title` and `content`.\n * - Actions are optional.\n * \n * @namespace WebComponents.cq-help\n * @example\n * \n * \n *\n */\nclass Help extends CIQ.UI.ContextTag {\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tsuper.connectedCallback();\n\n\t\t[\"mousedown\", \"pointerdown\", \"touchstart\"].forEach((eventName) =>\n\t\t\tthis.addEventListener(eventName, this.mouseTouchDown, { passive: false })\n\t\t);\n\t\t[\"mouseup\", \"pointerup\", \"touchend\", \"touchmove\"].forEach((eventName) =>\n\t\t\tthis.addEventListener(eventName, this.mouseTouchUp, { passive: false })\n\t\t);\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, Help);\n\t\tthis.constructor = Help;\n\t}\n\n\tdisconnectedCallback() {\n\t\t[\"mousedown\", \"pointerdown\", \"touchstart\"].forEach((eventName) =>\n\t\t\tthis.removeEventListener(eventName, this.mouseTouchDown)\n\t\t);\n\t\t[\"mouseup\", \"pointerup\", \"touchend\", \"touchmove\"].forEach((eventName) =>\n\t\t\tthis.removeEventListener(eventName, this.mouseTouchUp)\n\t\t);\n\t\tsuper.disconnectedCallback();\n\t}\n\n\tsetContext() {\n\t\tthis.addDefaultMarkup();\n\t\tconst attributeName = \"help-active\";\n\t\tlet { topNode, stx } = this.context;\n\t\tif (CIQ.Help && !topNode.hasAttribute(attributeName))\n\t\t\ttopNode.setAttribute(attributeName, \"\");\n\t\tthis.ensureMessagingAvailable(stx);\n\t}\n\n\tmouseTouchDown(evt) {\n\t\tif (\n\t\t\t!CIQ.Help ||\n\t\t\t!CIQ.Help.Content ||\n\t\t\t!CIQ.Help.Content[this.getAttribute(\"help-id\")] ||\n\t\t\tthis.pressTimer\n\t\t)\n\t\t\treturn;\n\t\tthis.pressTimer = setTimeout(() => {\n\t\t\tthis.pressTimer = null;\n\t\t\t// Allow the press highlight animation to complete before removing\n\t\t\tsetTimeout(() => this.classList.remove(\"pressing\"), 1000);\n\t\t\tthis.press();\n\t\t}, this.context.stx.longHoldTime);\n\t\tthis.classList.add(\"pressing\");\n\t}\n\n\tmouseTouchUp(evt) {\n\t\tif (!this.pressTimer) return;\n\t\tclearTimeout(this.pressTimer);\n\t\tthis.pressTimer = null;\n\t\tthis.classList.remove(\"pressing\");\n\t}\n\n\t/**\n\t * Ensures that an instance of the [cq-floating-window]{@link WebComponents.cq-floating-window}\n\t * web component is available to handle event messaging and create the shortcuts legend floating\n\t * window.\n\t *\n\t * This function is called when the add-on is instantiated.\n\t *\n\t * @param {CIQ.ChartEngine} stx The chart engine that provides the UI context, which contains the\n\t * [cq-floating-window]{@link WebComponents.cq-floating-window} web component.\n\t *\n\t * @memberof WebComponents.cq-help\n\t * @alias ensureMessagingAvailable\n\t * @since 8.4.0\n\t */\n\tensureMessagingAvailable(stx) {\n\t\tsetTimeout(() => {\n\t\t\tconst contextContainer = stx.uiContext.topNode;\n\t\t\tif (!contextContainer.querySelector(\"cq-floating-window\")) {\n\t\t\t\tcontextContainer.append(document.createElement(\"cq-floating-window\"));\n\t\t\t}\n\t\t});\n\t}\n\n\t/**\n\t * Adds class `help-available` if a property matching this elements help-id attribute\n\t * can be found in CIQ.Help.Content object. The help indicator (glowing dot) will not\n\t * appear unless this class is present.\n\t *\n\t * @alias verifyHelpContent\n\t * @memberof WebComponents.cq-help\n\t * @since 8.4.0\n\t */\n\tverifyHelpContent() {\n\t\tif (!CIQ.Help || !CIQ.Help.Content) return;\n\t\tlet helpData = CIQ.Help.Content[this.getAttribute(\"help-id\")];\n\t\tif (helpData) {\n\t\t\tthis.classList.add(\"help-available\");\n\t\t} else {\n\t\t\tthis.classList.remove(\"help-available\");\n\t\t}\n\t}\n\n\t/**\n\t * @alias press\n\t * @memberof WebComponents.cq-help\n\t * @since 8.4.0\n\t */\n\tpress() {\n\t\tif (!CIQ.Help || !CIQ.Help.Content) return;\n\t\tlet { config, stx } = this.context;\n\t\tlet helpId = this.getAttribute(\"help-id\") || \"default\";\n\t\tlet helpData = CIQ.Help.Content[helpId] || CIQ.Help.Content[\"default\"];\n\t\tif (!helpData) return;\n\t\t// Add \"close\" & \"enable\" action buttons if no actions are provided\n\t\tif (!helpData.actions)\n\t\t\thelpData.actions = [CIQ.Help.Actions.close, CIQ.Help.Actions.enable];\n\n\t\t// Pass the parent element to each action function\n\t\thelpData.actionButtons = [];\n\n\t\tfunction processAction(actionItem, parentElement) {\n\t\t\treturn () => actionItem.action(parentElement);\n\t\t}\n\n\t\tfor (let actionItem of helpData.actions) {\n\t\t\tlet { label, action } = actionItem;\n\t\t\tif (typeof action === \"function\") {\n\t\t\t\taction = processAction(actionItem, this.parentElement);\n\t\t\t}\n\t\t\thelpData.actionButtons.push({ label, action });\n\t\t}\n\n\t\tstx.dispatch(\"floatingWindow\", {\n\t\t\ttype: \"documentation\",\n\t\t\ttitle: helpData.title,\n\t\t\tcontent: helpData.content,\n\t\t\tactionButtons: helpData.actionButtons,\n\t\t\tcontainer: stx.container.querySelector(\".stx-subholder\"),\n\t\t\tonClose: () => true,\n\t\t\twidth: 500,\n\t\t\tstatus: true,\n\t\t\ttag: \"help\"\n\t\t});\n\t}\n}\n\nHelp.markup = `\n\t\t
\n\t\t
\n\t\t\t\n\t\t\t\n\t\t
\n\t`;\nCIQ.UI.addComponentDefinition(\"cq-help\", Help);\n\n};\n\n\nlet __js_webcomponents_infoToggle_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * The information toggle web component ``.\n *\n * Provides toggle management for the three-state heads-up display.\n *\n * By default, the component toggles among three states: `dynamic`, `static`, and `null` (off).\n * States are changed using the `cq-toggles` attribute which can have any of the three toggle\n * values: `dynamic`, `static`, or `null`.\n *\n * The component appends a [cq-hu-dynamic]{@link WebComponents.cq-hu-dynamic} or\n * [cq-hu-static]{@link WebComponents.cq-hu-static} element to the top node of the chart\n * context if one is required and not already present.\n *\n * The info toggle is mobile and crosshairs aware and can change the toggle state to\n * accommodate both conditions; for example, if the crosshairs are active or the chart is on a\n * mobile device, the component automatically makes the heads-up display static.\n *\n * @namespace WebComponents.cq-info-toggle\n * @since 7.5.0\n *\n * @example\n * \n * \n * Info\n * \n */\nclass InfoToggle extends CIQ.UI.ContextTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, InfoToggle);\n\t\tthis.constructor = InfoToggle;\n\t}\n\n\t/**\n\t * Adds the default markup. Sets the toggle tooltip. Subscribes to the `headsUp` and\n\t * `crosshair` channels. Appends a [cq-hu-dynamic]{@link WebComponents.cq-hu-dynamic} or\n\t * [cq-hu-static]{@link WebComponents.cq-hu-static} element to the top node of the chart\n\t * context if one is not already attached.\n\t *\n\t * @param {CIQ.UI.Context} context The chart user interface context.\n\t *\n\t * @alias setContext\n\t * @memberof WebComponents.cq-info-toggle\n\t * @since 7.5.0\n\t */\n\tsetContext(context) {\n\t\tlet markup = this.constructor.markup;\n\t\tconst toggles = this.getAttribute(\"cq-toggles\");\n\t\tif (toggles) {\n\t\t\tmarkup = markup.replace(/dynamic,static,null/, toggles);\n\t\t}\n\n\t\tthis.addDefaultMarkup(this, markup);\n\t\tthis.tooltip = this.querySelector(\"cq-tooltip\");\n\n\t\tlet channels = context.config\n\t\t\t? context.config.channels\n\t\t\t: {\n\t\t\t\t\theadsUp: \"layout.headsUp\",\n\t\t\t\t\tcrosshair: \"layout.crosshair\"\n\t\t\t };\n\t\tthis.channelSubscribe(channels.headsUp, () => this.applyValues(channels));\n\n\t\tthis.channelSubscribe(channels.crosshair, (value) => {\n\t\t\tif (\n\t\t\t\t(CIQ.isMobile || value) &&\n\t\t\t\tthis.channelRead(channels.headsUp) === \"dynamic\"\n\t\t\t) {\n\t\t\t\tsetTimeout(() => this.channelWrite(channels.headsUp, \"static\"));\n\t\t\t}\n\t\t});\n\n\t\tthis.initInfoComponents(context);\n\t}\n\n\t/**\n\t * Sets a tooltip on the toggle.\n\t *\n\t * @param {String} value The text of the tooltip, which is appended to the string \"Info \".\n\t * \t\tIf a value is not provided, the tooltip is \"Info off\".\n\t *\n\t * @alias setTooltip\n\t * @memberof WebComponents.cq-info-toggle\n\t * @since 7.5.0\n\t */\n\tsetTooltip(value) {\n\t\tconst {\n\t\t\tcontext: { stx },\n\t\t\ttooltip\n\t\t} = this;\n\t\ttooltip.innerText = stx.translateIf(`Info ${value ? value : \"off\"}`);\n\t}\n\n\t/**\n\t * Appends a [cq-hu-dynamic]{@link WebComponents.cq-hu-dynamic} or\n\t * [cq-hu-static]{@link WebComponents.cq-hu-static} element to the top node of the chart\n\t * context if one is not already present.\n\t *\n\t * @param {CIQ.UI.Context} context The chart user interface context.\n\t *\n\t * @alias initInfoComponents\n\t * @memberof WebComponents.cq-info-toggle\n\t * @since 7.5.0\n\t */\n\tinitInfoComponents(context) {\n\t\tconst toggles = this.querySelector(\"cq-toggle\").getAttribute(\"cq-toggles\");\n\t\t[\"dynamic\", \"static\"].forEach(function (i) {\n\t\t\tif (new RegExp(i).test(toggles)) {\n\t\t\t\tif (!context.topNode.querySelector(`cq-hu-${i}`)) {\n\t\t\t\t\tconst hu = document.createElement(`cq-hu-${i}`);\n\t\t\t\t\tcontext.topNode.append(hu);\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t}\n\n\t/**\n\t * Sets the toggle state to `static` if on a mobile device or the crosshairs are active.\n\t * If on a mobile device and the toggle state is `static`, activates the crosshairs.\n\t *\n\t * @param {Object} channels The web component communication channels.\n\t *\n\t * @alias applyValues\n\t * @memberof WebComponents.cq-info-toggle\n\t * @since 7.5.0\n\t */\n\tapplyValues(channels) {\n\t\tconst crosshair = this.channelRead(channels.crosshair);\n\t\tconst headsUp = this.channelRead(channels.headsUp);\n\n\t\tif (headsUp === \"dynamic\" && (crosshair || CIQ.isMobile)) {\n\t\t\t// The dynamic headsUp doesn't make any sense on mobile devices or with crosshair\n\t\t\t// setting the toggle to \"static\"\n\t\t\tsetTimeout(() => this.channelWrite(channels.headsUp, \"static\"));\n\t\t}\n\t\tif (CIQ.isMobile && headsUp === \"static\") {\n\t\t\tsetTimeout(() => this.channelWrite(channels.crosshair, true));\n\t\t}\n\t\tthis.setTooltip(headsUp);\n\t}\n}\n\nInfoToggle.markup = `\n\t\t\n\t\t\t\n\t\t\tInfo\n\t\t\n\t`;\nCIQ.UI.addComponentDefinition(\"cq-info-toggle\", InfoToggle);\n\n};\n\n\nlet __js_webcomponents_infoToggleDropdown_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * The drop-down toggle web component ``.\n *\n * Provides toggle management for the crosshairs and heads-up display.\n *\n * Typically wraps a [cq-toggle]{@link WebComponents.cq-toggle} component and\n * [cq-menu]{@link WebComponents.cq-menu} component (see the examples below). The\n * [cq-toggle]{@link WebComponents.cq-toggle} web component creates the user interface toggle\n * control, which is similar to a button. The [cq-menu]{@link WebComponents.cq-menu} web component\n * creates a drop-down menu that provides component options. For example, for the heads-up display,\n * the options menu enables activation of either a dynamic callout or floating tooltip; for the\n * crosshairs, activation of a static information display (also referred to as the static heads-up\n * display, or static HUD).\n *\n * The drop-down toggle component appends a \n * \\,\n * ``, or \n * \\ element to the top node of the chart context\n * if one is required and not already present. The elements represent the heads-up dynamic callout,\n * heads-up floating tooltip, and crosshairs static HUD, respectively.\n *\n * The drop-down toggle is mobile aware. On mobile devices, the drop-down menu of the component is\n * hidden, and the following mobile-friendly behavior is set automatically:\n * - The crosshairs drop-down toggle turns the crosshairs and static HUD on and off in unison\n * - The heads-up display drop-down toggle is not available\n *\n * The HUD menu can be managed programmatically by sending a 'channel' message to enable or disable the different HUD modes.
\n * Here is the code you will need:\n *\n * ```\n * function changeHUD(type, stx) {\n * const hudChannel = stx.uiContext.config.channels.headsUp;\n * const { channelWrite } = CIQ.UI.BaseComponent.prototype;\n * channelWrite(hudChannel, type, stx);\n * }\n * ```\n *\n * Then you can do things such as:\n *\n * - `changeHUD(false, stxx); // turn off HUD`\n * - `changeHUD({dynamic: true, floating: false}, stxx); // turn on the dynamic HUD`\n * - `changeHUD({dynamic: false, floating: true}, stxx); // turn on the floating HUD`\n *\n * @namespace WebComponents.cq-info-toggle-dropdown\n * @since 8.2.0\n *\n * @example Heads-up display drop-down toggle:\n * \n * \n * \n * \n * \n *\n * \n * \n * \n * Show Dynamic Callout\n * Show Tooltip\n * \n * \n *\n * @example Crosshairs drop-down toggle:\n * \n * \n * \n * Crosshair (Alt + \\) \n * \n *\n * \n * \n * \n * Hide Heads-Up Display\n * Show Heads-Up Display\n * \n * \n * \n */\nclass InfoToggleDropdown extends CIQ.UI.ContextTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, InfoToggleDropdown);\n\t}\n\n\t/**\n\t * Sets the status of the drop-down toggle; that is, whether the drop-down toggle is active or\n\t * inactive.\n\t *\n\t * @param {boolean} value The status of the drop-down toggle. If true, the drop-down toggle\n\t * is active; if false, inactive.\n\t *\n\t * @alias set\n\t * @memberof WebComponents.cq-info-toggle-dropdown\n\t * @since 8.2.0\n\t */\n\tset(value) {\n\t\tconst { toggleEl, options, selected, stx } = this;\n\t\tconst { crossX, crossY } = stx.controls;\n\t\tconst { obj: layout } = toggleEl.params;\n\t\tconst newLayoutValues = {};\n\n\t\toptions.forEach((option) => {\n\t\t\tconst [member, type] = option.getAttribute(\"cq-member\").split(\"-\");\n\t\t\tconst valueToSet = option === selected && value === true;\n\n\t\t\tif (type) {\n\t\t\t\tnewLayoutValues[member] = Object.assign(newLayoutValues[member] || {}, {\n\t\t\t\t\t[type]: valueToSet\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tnewLayoutValues[member] = valueToSet;\n\t\t\t}\n\t\t});\n\n\t\tthis.connectedCharts().forEach((chartEngine) => {\n\t\t\tObject.entries(newLayoutValues).forEach(([key, prop]) => {\n\t\t\t\tif (typeof prop === \"object\") {\n\t\t\t\t\t// replace reference in order to trigger channelSubscribe\n\t\t\t\t\tchartEngine.layout[key] = Object.assign(\n\t\t\t\t\t\t{},\n\t\t\t\t\t\tchartEngine.layout[key],\n\t\t\t\t\t\tprop\n\t\t\t\t\t);\n\t\t\t\t} else {\n\t\t\t\t\tchartEngine.layout[key] = prop;\n\t\t\t\t}\n\t\t\t});\n\t\t\tchartEngine.changeOccurred(\"layout\");\n\t\t});\n\n\t\tif (toggleEl.params.action === \"class\") {\n\t\t\ttoggleEl.classList[value ? \"add\" : \"remove\"](toggleEl.params.value);\n\t\t}\n\n\t\ttoggleEl.currentValue = value;\n\t\ttoggleEl.updateClass();\n\t\tthis.applyValues(this.channels);\n\n\t\tconst isMultiChart = this.context.topNode.getCharts;\n\t\tif (value) {\n\t\t\tconst activeChart = isMultiChart\n\t\t\t\t? this.connectedCharts().find((el) => {\n\t\t\t\t\t\tconst wrapper = el.container.closest(\"cq-context-wrapper.active\");\n\t\t\t\t\t\treturn wrapper;\n\t\t\t\t })\n\t\t\t\t: stx;\n\t\t\tthis.positionCrosshair(activeChart);\n\t\t}\n\t}\n\n\t/**\n\t * Gets all connected charts.\n\t *\n\t * @alias connectedCharts\n\t * @memberof WebComponents.cq-info-toggle-dropdown\n\t * @since 8.4.0\n\t */\n\tconnectedCharts() {\n\t\tconst isMultiChart = this.context.topNode.getCharts;\n\t\tconst charts = isMultiChart ? this.context.topNode.getCharts() : [this.stx];\n\n\t\treturn charts;\n\t}\n\n\t/**\n\t * Places crosshair at last data segment in the chart that contains the Close value\n\t *\n\t * @alias positionCrosshair\n\t * @memberof WebComponents.cq-info-toggle-dropdown\n\t * @since 8.4.0\n\t */\n\tpositionCrosshair(stx) {\n\t\tif (!stx) return;\n\t\tconst { dataSegment } = stx.chart;\n\t\tif (\n\t\t\tstx.container.classList.contains(\"stx-crosshair-on\") ||\n\t\t\t!dataSegment.length\n\t\t)\n\t\t\treturn;\n\n\t\tconst { index, Close } = findLastClose(dataSegment);\n\n\t\tif (index < 0) return;\n\n\t\tconst x = stx.pixelFromBar(index);\n\t\tconst y = stx.pixelFromPrice(Close);\n\t\tstx.mousemoveinner(x + stx.left, y + stx.top);\n\n\t\tfunction findLastClose(array) {\n\t\t\tlet index = array.length;\n\t\t\twhile (index-- && array[index]) {\n\t\t\t\tconst { Close } = array[index];\n\t\t\t\tif (Close || Close === 0) return { index, Close };\n\t\t\t}\n\t\t\treturn -1;\n\t\t}\n\t}\n\n\t/**\n\t * Sets the currently selected option for the drop-down toggle component. The options are\n\t * presented as a list of radio buttons in a drop-down menu associated with the component.\n\t *\n\t * Selects (or checks) the radio button of the selected option and clears (or unchecks) the\n\t * radio buttons of other options.\n\t *\n\t * @param {HTMLElement} selected The menu option to set as the selected option.\n\t *\n\t * @alias setSelected\n\t * @memberof WebComponents.cq-info-toggle-dropdown\n\t * @since 8.2.0\n\t */\n\tsetSelected(selected) {\n\t\tconst { options } = this;\n\t\tthis.selected = selected;\n\t\toptions.forEach((option) => {\n\t\t\toption.classList[option === selected ? \"add\" : \"remove\"](\"ciq-active\");\n\t\t});\n\t}\n\n\t/**\n\t * Subscribes to the `headsUp` channel. References the `crosshair` channel.\n\t *\n\t * Enables selection of the drop-down toggle options. Sets the initial selected option.\n\t * Enables selection of the options using the keyboard. Sets default options on mobile devices\n\t * (see `applyValues`). Sets the drop-down toggle tooltip (see `setTooltip`).\n\t *\n\t * Appends a ``, ``, or `` element to the top\n\t * node of the chart context if one is not already attached (see `initInfoComponents`).\n\t *\n\t * @param {CIQ.UI.Context} context The chart user interface context.\n\t *\n\t * @alias setContext\n\t * @memberof WebComponents.cq-info-toggle-dropdown\n\t * @private\n\t * @since 8.2.0\n\t */\n\tsetContext(context) {\n\t\tthis.tooltip = this.querySelector(\"cq-tooltip\");\n\t\tthis.toggleEl = this.querySelector(\"cq-toggle\");\n\t\tthis.optionsMenu = this.querySelector(\"cq-menu-dropdown\");\n\t\tthis.options = Array.from(this.optionsMenu.querySelectorAll(\"cq-item\")); // ciao to NodeList\n\n\t\tlet { config: { channels = {} } = {} } = context;\n\t\tif (!channels.headsUp) channels.headsUp = \"layout.headsUp\";\n\t\tif (!channels.crosshair) channels.crosshair = \"layout.crosshair\";\n\t\tthis.channels = channels;\n\n\t\tthis.channelSubscribe(channels.headsUp, () => this.applyValues(channels));\n\t\tconst initialHUValues = this.channelRead(channels.headsUp) || {};\n\t\tconst initialCrosshair = this.channelRead(channels.crosshair);\n\t\tlet crosshairIsOptionAndOn = false;\n\n\t\tconst selectItem = (event) => {\n\t\t\tthis.setSelected(event.target);\n\t\t\tthis.set(true);\n\t\t\tthis.stx.changeOccurred(\"layout\");\n\t\t};\n\n\t\t// set selection option based on layout\n\t\tthis.options.forEach((option) => {\n\t\t\tconst [, type] = option.getAttribute(\"cq-member\").split(\"-\");\n\t\t\tif (!type && initialCrosshair) crosshairIsOptionAndOn = true;\n\t\t\tif (initialHUValues[type]) this.setSelected(option);\n\t\t\toption.selectFC = function () {\n\t\t\t\tselectItem({ target: this }); // capture focused element from keyStroke in scroll.js\n\t\t\t};\n\t\t});\n\n\t\tthis.toggleEl.isInfoToggle = true;\n\t\tthis.toggleEl.currentValue = this.selected || crosshairIsOptionAndOn;\n\t\tif (!this.selected) this.setSelected(this.options[0]); // fallback/for crosshair only\n\n\t\tCIQ.UI.stxtap(this.optionsMenu, selectItem);\n\n\t\tif (CIQ.isMobile) this.querySelector(\"cq-menu\").style.display = \"none\";\n\t\tthis.initInfoComponents(context.topNode);\n\t\tthis.applyValues(channels);\n\t}\n\n\t/**\n\t * Sets a tooltip on the `cq-toggle` component contained in the drop-down toggle. The tooltip\n\t * text is \"Info Off\" when the drop-down toggle is inactive; \"Info On\", when the drop-down\n\t * toggle is active.\n\t *\n\t * **Note:** This function does not set a tooltip on the crosshairs drop-down toggle. The\n\t * crosshairs drop-down toggle tooltip is set in the markup (see the example in the\n\t * `cq-info-toggle-dropdown` description.)\n\t *\n\t * @param {string} [value] Unused.\n\t *\n\t * @alias setTooltip\n\t * @memberof WebComponents.cq-info-toggle-dropdown\n\t * @private\n\t * @since 8.2.0\n\t */\n\tsetTooltip(value) {\n\t\tconst {\n\t\t\tcontext: { stx },\n\t\t\ttooltip\n\t\t} = this;\n\n\t\tif (\n\t\t\t!this.options.some(\n\t\t\t\t(option) => option.getAttribute(\"cq-member\") === \"crosshair\"\n\t\t\t)\n\t\t) {\n\t\t\tconst thisState = this.toggleEl.currentValue ? \"On\" : \"Off\";\n\t\t\ttooltip.innerText = stx.translateIf(`Info ${thisState}`);\n\t\t}\n\t}\n\n\t/**\n\t * Appends a ``, ``, or `` element to the top\n\t * node of the chart context if one is not already present. The elements represent the\n\t * heads-up dynamic callout, heads-up floating tooltip, and crosshairs static HUD,\n\t * respectively.\n\t *\n\t * @param {CIQ.UI.Context} context The chart user interface context.\n\t *\n\t * @alias initInfoComponents\n\t * @memberof WebComponents.cq-info-toggle-dropdown\n\t * @private\n\t * @since 8.2.0\n\t */\n\tinitInfoComponents(container) {\n\t\tcontainer.querySelectorAll(\".ciq-chart-area\").forEach((chartContainer) => {\n\t\t\tthis.options.forEach((option) => {\n\t\t\t\tconst [, type] = option.getAttribute(\"cq-member\").split(\"-\");\n\t\t\t\tif (type && !chartContainer.querySelector(`cq-hu-${type}`)) {\n\t\t\t\t\tconst hu = document.createElement(`cq-hu-${type}`);\n\t\t\t\t\tchartContainer.append(hu);\n\t\t\t\t}\n\t\t\t});\n\t\t});\n\t}\n\n\t/**\n\t * Sets the following functionality of the crosshairs and heads-up display drop-down toggles\n\t * on mobile devices:\n\t * - The crosshairs drop-down toggle turns the crosshairs and static HUD on and off in unison\n\t * - The heads-up display drop-down toggle is not available\n\t *\n\t * Sets the heads-up drop-down toggle tooltip (see `setTooltip`).\n\t *\n\t * @param {object} channels The web component communication channels.\n\t *\n\t * @alias applyValues\n\t * @memberof WebComponents.cq-info-toggle-dropdown\n\t * @private\n\t * @since 8.2.0\n\t */\n\tapplyValues(channels) {\n\t\tconst crosshair = this.channelRead(channels.crosshair);\n\t\tconst headsUp = this.channelRead(channels.headsUp) || {};\n\t\tconst { dynamic, floating, crosssection } = headsUp;\n\t\tconst { channelWrite } = this;\n\t\tconst charts = this.connectedCharts();\n\n\t\tif (CIQ.isMobile) {\n\t\t\tconst staticHudContainer =\n\t\t\t\tthis.context.topNode.querySelector(\"cq-hu-static\");\n\t\t\tif (staticHudContainer) {\n\t\t\t\tstaticHudContainer.style.display = floating ? \"none\" : \"\";\n\t\t\t}\n\t\t\tconst dynamicHudContainer =\n\t\t\t\tthis.context.topNode.querySelector(\"cq-hu-dynamic\");\n\t\t\tif (dynamicHudContainer) {\n\t\t\t\tdynamicHudContainer.style.display = \"none\";\n\t\t\t}\n\n\t\t\tif (dynamic) {\n\t\t\t\tfanOutWrite(\n\t\t\t\t\tchannels.headsUp,\n\t\t\t\t\tObject.assign({}, headsUp, { dynamic: false, floating: true })\n\t\t\t\t);\n\t\t\t\tthis.applyValues(channels);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst defaultHud = this.querySelector(\n\t\t\t\t\"cq-item[cq-member*='headsUp-']:not([cq-member*='-dynamic'])\"\n\t\t\t);\n\t\t\tif (defaultHud && !Object.values(headsUp).includes(true)) {\n\t\t\t\tthis.setSelected(defaultHud);\n\t\t\t\tif (crosshair) {\n\t\t\t\t\tconst [, type] = defaultHud.getAttribute(\"cq-member\").split(\"-\");\n\t\t\t\t\tif (type) {\n\t\t\t\t\t\tconst obj = {};\n\t\t\t\t\t\tobj[type] = true;\n\t\t\t\t\t\tfanOutWrite(channels.headsUp, Object.assign({}, headsUp, obj));\n\t\t\t\t\t\tthis.applyValues(channels);\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (!crosshair && (headsUp.static || crosssection)) {\n\t\t\tfanOutWrite(channels.crosshair, true);\n\t\t}\n\n\t\tfunction fanOutWrite(channel, value) {\n\t\t\tcharts.forEach((chartEngine) =>\n\t\t\t\tchannelWrite(channel, value, chartEngine)\n\t\t\t);\n\t\t}\n\n\t\t// No longer adding the on/off state to Info toggle tooltip, the blue underline indicator already shows this.\n\t\t//this.setTooltip(headsUp);\n\t}\n\n\t/**\n\t * Determines whether the drop-down toggle is active.\n\t *\n\t * @param {object} params Contains data related to the drop-down toggle.\n\t * @param {object} params.obj Contains the status of the drop-down toggle.\n\t * @param {boolean} params.obj.crosshair If true, the crosshairs are active.\n\t * @param {object} params.obj.headsUp Contains the status of the on screen information\n\t * \t\tdisplays for the heads-up display and the crosshairs.\n\t * @param {boolean} params.obj.headsUp.dynamic If true, the dynamic heads-up display is active.\n\t * @param {boolean} params.obj.headsUp.floating If true, the floating heads-up display is\n\t * \t\tactive.\n\t * @param {boolean} params.obj.headsUp.static If true, the static information display for the\n\t * \t\tcrosshairs is active.\n\t * @return {boolean} True if the drop-down toggle is active, false otherwise.\n\t *\n\t * @alias getCurrentValue\n\t * @memberof WebComponents.cq-info-toggle-dropdown\n\t * @private\n\t * @since 8.2.0\n\t */\n\tgetCurrentValue(params) {\n\t\tconst { options } = this;\n\t\tconst { obj: layout } = params;\n\n\t\tfor (let i = 0; i < options.length; i++) {\n\t\t\tconst [member, type] = options[i].getAttribute(\"cq-member\").split(\"-\");\n\n\t\t\tif (\n\t\t\t\t(!type && layout[member]) ||\n\t\t\t\t(layout[member] && layout[member][type])\n\t\t\t) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\n\t\treturn false;\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-info-toggle-dropdown\", InfoToggleDropdown);\n\n};\n\n\nlet __js_webcomponents_instantChart_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nlet InstantChart_movedDialogs = false;\n\n/**\n * Container web component ``. Used to contain charts in multi-chart\n * environments.\n *\n * The `` element has the following custom attributes:\n * - `tmpl-src` — Specifies a template source file that contains the chart user interface\n * elements.\n * - `symbol` — Provides the primary chart symbol.\n * - `env-container` — Identifies an HTML DOM node (for example \"body\") that is used to\n * contain transient user interface elements such as dialog boxes and color pickers.\n * - `cq-event-flag` — Indicates that an instant chart container has dispatched an event.\n * Enables the container element to be identified so that an event handler can be called for the\n * element. See the *sample-template-multi-charts.html* template for an example.\n *\n * Dispatches a `signal-chart-ready` event. Event listeners typically run a handler that\n * configures the chart. See the *sample-template-multi-charts.html* template for an example.\n *\n * @namespace WebComponents.cq-instant-chart\n *\n * @example\n *
\n *
\n */\nclass InstantChart extends HTMLElement {\n\tconnectedCallback() {\n\t\tif (this.hasAttribute(\"attached\")) return;\n\t\tthis.setAttribute(\"attached\", \"\");\n\n\t\tvar self = this;\n\n\t\tconst environmentContainer = this.getAttribute(\"env-container\") || \"body\";\n\t\tconst tmplSrc = this.getAttribute(\"tmpl-src\");\n\t\tvar context = this.querySelector(\"cq-context\");\n\t\tif (!context)\n\t\t\tcontext = this.appendChild(document.createElement(\"cq-context\"));\n\t\tconst noLocalStorage = this.hasAttribute(\"no-save\");\n\n\t\tthis.style.visibility = \"hidden\";\n\n\t\tCIQ.loadUI(tmplSrc, context, function (err) {\n\t\t\tif (err) return;\n\n\t\t\tvar chartTitle = self.querySelector(\"cq-chart-title\");\n\t\t\tif (chartTitle) chartTitle.removeAttribute(\"cq-browser-tab\");\n\n\t\t\tvar elementBlocks = self.querySelectorAll(\n\t\t\t\t\"cq-ui-manager, cq-dialog, cq-color-picker\"\n\t\t\t);\n\t\t\tfor (var eb = 0; eb < elementBlocks.length; eb++) {\n\t\t\t\tvar elementBlock = elementBlocks[eb];\n\t\t\t\telementBlock.parentNode.removeChild(elementBlock);\n\t\t\t\tif (!InstantChart_movedDialogs)\n\t\t\t\t\tdocument\n\t\t\t\t\t\t.querySelector(environmentContainer)\n\t\t\t\t\t\t.appendChild(elementBlock);\n\t\t\t}\n\t\t\tInstantChart_movedDialogs = true;\n\n\t\t\tconst params = {\n\t\t\t\textendedHours: true,\n\t\t\t\trangeSlider: true,\n\t\t\t\tinactivityTimer: true,\n\t\t\t\tfullScreen: false,\n\t\t\t\tinitialSymbol: self.getAttribute(\"symbol\") || undefined,\n\t\t\t\trestore: !noLocalStorage\n\t\t\t};\n\n\t\t\tself.signalEvent = new CustomEvent(\"signal-chart-ready\", {\n\t\t\t\tdetail: { node: self, params }\n\t\t\t});\n\t\t\tself.setAttribute(\"cq-event-flag\", \"\");\n\t\t\tself.style.visibility = \"\";\n\n\t\t\tself.ownerDocument.body.dispatchEvent(self.signalEvent);\n\t\t});\n\t}\n\tdisconnectedCallback() {\n\t\tthis.stx.destroy();\n\t}\n}\n\ncustomElements.define(\"cq-instant-chart\", InstantChart); // do not use addComponentsDefinition for this component!\n\n};\n\n\nlet __js_webcomponents_languageDialog_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nif (!CIQ.I18N) {\n\tconsole.error(\n\t\t\"languageDialog component requires first activating i18n feature.\"\n\t);\n} else {\n\t/**\n\t * Language dialog web component ``. This creates a dialog that the user can use to change the language.\n\t *\n\t * The actual language choices are obtained from {@link CIQ.I18N.languages}. Choosing a different language causes the entire\n\t * UI to be translated through use of the {@link CIQ.I18N.setLanguage} method.\n\t *\n\t * @namespace WebComponents.cq-language-dialog\n\t * @since\n\t * - 4.0.0 New component added added.\n\t * - 4.1.0 Now it calls {@link CIQ.I18N.localize} instead of {@link CIQ.I18N.setLocale}.\n\t *\n\t * @example\n\t * \n\t * \n\t * \n\t * \n\t */\n\tclass LanguageDialog extends CIQ.UI.DialogContentTag {\n\t\tadoptedCallback() {\n\t\t\tsuper.adoptedCallback();\n\t\t\tCIQ.UI.flattenInheritance(this, LanguageDialog);\n\t\t\tthis.constructor = LanguageDialog;\n\t\t}\n\n\t\t/**\n\t\t * Closes dialog box.\n\t\t *\n\t\t * @alias close\n\t\t * @memberof WebComponents.cq-language-dialog\n\t\t * @since 4.0.0\n\t\t */\n\t\tclose() {\n\t\t\tconst langDialog = this.ownerDocument.querySelector(\"cq-language-dialog\");\n\t\t\tif (langDialog) langDialog.closest(\"cq-dialog,cq-menu\").close();\n\t\t}\n\n\t\t/**\n\t\t * Opens the nearest {@link WebComponents.cq-dialog} to display your dialog.\n\t\t *\n\t\t * @param {Object} [params] Contains the chart context.\n\t\t * @param {CIQ.UI.Context} [params.context] A context to set for the dialog. See\n\t\t * \t\t{@link CIQ.UI.DialogContentTag#setContext}.\n\t\t *\n\t\t * @alias open\n\t\t * @memberof WebComponents.cq-language-dialog\n\t\t * @since 4.0.0\n\t\t */\n\t\topen(params) {\n\t\t\tthis.addDefaultMarkup();\n\t\t\tsuper.open(params);\n\n\t\t\tconst cqLanguages = this.node.find(\"cq-languages\");\n\t\t\tcqLanguages.children(\":not(template)\").remove();\n\t\t\tconst template = this.node.find(\"template\");\n\t\t\tconst { languages } = CIQ.I18N;\n\t\t\tif (!languages) return;\n\t\t\tconst self = this;\n\n\t\t\tfunction switchToLanguage(langCode) {\n\t\t\t\treturn function () {\n\t\t\t\t\tCIQ.UI.contextsForEach(function () {\n\t\t\t\t\t\tconst { stx } = this;\n\t\t\t\t\t\tstx.preferences.language = langCode;\n\t\t\t\t\t\tstx.changeOccurred(\"preferences\");\n\t\t\t\t\t\tCIQ.I18N.localize(stx, langCode);\n\t\t\t\t\t\tstx.draw();\n\t\t\t\t\t}, self);\n\t\t\t\t};\n\t\t\t}\n\t\t\tfor (let langCode in languages) {\n\t\t\t\tconst node = CIQ.UI.makeFromTemplate(template, cqLanguages);\n\t\t\t\tnode.find(\"cq-language-name\").text(languages[langCode]);\n\t\t\t\tnode.find(\"cq-flag\").attr(\"cq-lang\", langCode);\n\t\t\t\tCIQ.UI.stxtap(node[0], switchToLanguage(langCode));\n\t\t\t}\n\t\t\t// Set the main dialog as keyboard active to reset the highlight when this panel reloads\n\t\t\tif (this.ownerDocument.body.keystrokeHub) {\n\t\t\t\tlet { tabActiveModals } = this.ownerDocument.body.keystrokeHub;\n\t\t\t\tif (tabActiveModals[0])\n\t\t\t\t\tthis.ownerDocument.body.keystrokeHub.setKeyControlElement(\n\t\t\t\t\t\ttabActiveModals[0]\n\t\t\t\t\t);\n\t\t\t}\n\t\t}\n\t}\n\n\tLanguageDialog.markup = `\n\t\t

Choose language

\n\t\t\n\t\t\n\t\t\t\n\t\t\n\t`;\n\tCIQ.UI.addComponentDefinition(\"cq-language-dialog\", LanguageDialog);\n}\n\n};\n\n\nlet __js_webcomponents_loader_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Loader web component ``.\n *\n * CSS loading icon.\n *\n * @namespace WebComponents.cq-loader\n *\n * @example\n * \n */\nclass Loader extends CIQ.UI.ContextTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, Loader);\n\t}\n\n\tsetContext(context) {\n\t\tthis.context.setLoader(this);\n\t}\n\t/**\n\t * Shows the loading icon.\n\t * @alias show\n\t * @memberof WebComponents.cq-loader\n\t */\n\tshow() {\n\t\tthis.classList.add(\"stx-show\");\n\t}\n\n\t/**\n\t * Hides the loading icon.\n\t * @alias hide\n\t * @memberof WebComponents.cq-loader\n\t */\n\thide() {\n\t\tthis.classList.remove(\"stx-show\");\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-loader\", Loader);\n\n};\n\n\nlet __js_webcomponents_lookup_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nif (!CIQ.ChartEngine.Driver) {\n\tconsole.error(\n\t\t\"lookup component requires first activating quoteFeed feature.\"\n\t);\n} else if (!CIQ.ChartEngine.Driver.Lookup) {\n\tconsole.error(\n\t\t\"lookup component requires first activating symbolLookupBase feature.\"\n\t);\n} else {\n\t/**\n\t * Symbol lookup component ``.\n\t *\n\t * A {@link CIQ.ChartEngine.Driver.Lookup} must be connected to this web component. The lookup\n\t * driver searches financial exchanges for symbols that match the text entered in the\n\t * component's input field.\n\t *\n\t * The symbol lookup can be toggled using the Ctrl+Alt+S keystroke combination (see the\n\t * `symbolLookup` action in `hotkeyConfig.hotkeys` in *js/defaultConfiguration.js*).\n\t *\n\t * A default lookup driver is specified in the chart configuration object (see the\n\t * Chart Configuration\n\t * tutorial).\n\t *\n\t * You can provide a different driver in the following ways:\n\t * - Assign the driver to the\n\t * \n\t * lookupDriver property of the chart configuration\n\t * object\n\t * - Connect the driver to this component using\n\t * [setDriver]{@link WebComponents.cq-lookup#setDriver}\n\t * - Add the driver to the UI context with {@link CIQ.UI.Context#setLookupDriver}\n\t *\n\t * **Note:** If the lookup component is unable to access a lookup driver, the component's\n\t * input field is active, but the component does not produce results.\n\t *\n\t * **Keyboard control**\n\t *\n\t * When selected with tab key navigation and activated with Return/Enter, this component has\n\t * the following internal controls:\n\t * - Up/Down arrow — Move selection between search input, filters, and search results\n\t * - Left/Right arrow — Switch between search result filters\n\t *\n\t * **Attributes**\n\t * | Name | Description | Valid Values |\n\t * | ---- | ----------- | ------------ |\n\t * | cq-keystroke-claim | Enables processing of keyboard input. | Boolean attribute |\n\t * | cq-keystroke-default | Enables the component to respond to keystrokes when the lookup input field does not have focus.

**Warning:** This feature may conflict with keyboard shortcuts set in other components. | Boolean attribute |\n\t * | cq-uppercase | Forces text to uppercase. | Boolean attribute |\n\t * | cq-exchanges | Specifies a list of financial exchanges searched by the lookup driver. Overrides the `exchanges` parameter of {@link CIQ.ChartEngine.Driver.Lookup}. | Comma-delimited list of exchange names; for example, \"futures,govt,muni,corp\"|\n\t *\n\t * **Customization**\n\t *\n\t * - To hide the lookup results window, modify the CSS as follows:\n\t * ```css\n\t * .stxMenuActive cq-lookup-results { opacity: 0 }\n\t * ```\n\t *\n\t * - To preload default results (rather than an empty result pane) on initial load , set an\n\t * `onChartReady` handler in the chart configuration object (see the\n\t * Chart Configuration\n\t * tutorial); for example:\n\t *\n\t * ```\n\t * config.onChartReady = (stx) => {\n\t * const defaultResults = [\n\t * {\n\t * \"display\": [\"KW\", \"Kennedy - Wilson Holdings Inc\", \"NYSE\"],\n\t * \"data\": {\n\t * \"symbol\": \"KW\",\n\t * \"name\": \"Kennedy - Wilson Holdings Inc\",\n\t * \"exchDisp \": \"NYSE\"\n\t * }\n\t * },\n\t * {\n\t * \"display\": [\"RWR\", \"SPDR Series Trust - SPDR DJ Wilshire REIT ETF\", \"NYSEArca\"],\n\t * \"data\": {\n\t * \"symbol\": \"RWR\",\n\t * \"name\": \"SPDR Series Trust - SPDR DJ Wilshire REIT ETF\",\n\t * \"exchDisp\": \"NYSEArca\"\n\t * }\n\t * }\n\t * ];\n\t *\n\t * const UISymbolLookup = document.querySelector(\".ciq-search cq-lookup\");\n\t * UISymbolLookup.results(defaultResults);\n\t * }\n\t * ````\n\t *\n\t * - The placeholder is programmatically set based on the width of the chart.\n\t * On larger screens \"Enter Symbol\" is used, but on smaller screens only \"Symbol\" is used.\n\t * As such, it is not sufficient to set a placeholder value on the HTML, as it will be overwritten by the Web Component logic.\n\t * The following script will update the placeholder according to breakpoint values set in placeholderMapping.\n\t * It should be placed inside the [onWebComponentsReady]{@tutorial Chart Configuration} callback provided in the\n\t * `defaultConfiguration` object to ensure it is executed once all Web Components have been properly initialized.\n\t * The approach here is to add a second breakpoint channel listener for the lookup component that overwrites the value set by default in the library.\n\t *\n\t * ```\n\t * function setLookupPlaceholders(placeholderMapping = {\n\t * \"break-lg\": \"Change symbol\",\n\t * \"break-md\": \"+ symbol\",\n\t * \"break-sm\": \"\"\n\t * }) {\n\n \t * Array.from(uiContext.topNode.querySelectorAll('cq-lookup'))\n \t * .forEach(el => {\n\t * const { channels = {} } = el.context.config;\n\t * el.channelSubscribe(\n\t * channels.breakpoint || \"channel.breakpoint\",\n\t * (breakPoint) => {\n\t * const symbolValue = placeholderMapping[breakpoint] || \"Change symbol\";\n\t *\n\t * const symbolInput = el.querySelector(\"input\");\n\t * symbolInput.setAttribute(\"placeholder\", symbolValue);\n\t * );\n\t * });\n\t * });\n\t * }\n\t * setLookupPlaceholders();\n\t * ```\n\t *\n\t * @namespace WebComponents.cq-lookup\n\t * @since\n\t * - 4.0.0 Added optional `cq-uppercase` attribute.\n\t * - 7.4.0 Added optional `cq-exchanges` attribute.\n\t * - 8.3.0 Enabled internal keyboard navigation and selection.\n\t *\n\t * @example\n\t * \n\t * \n\t * \n\t * \n\t * \n\t * \n\t * \n\t * ALL\n\t * STOCKS\n\t * FX\n\t * INDEXES\n\t * FUNDS\n\t * FUTURES\n\t * \n\t * \n\t * \n\t * \n\t */\n\tclass Lookup extends CIQ.UI.ContextTag {\n\t\tconstructor() {\n\t\t\tsuper();\n\t\t\tthis.usingEmptyDriver = false;\n\t\t\tthis.currentFilter = null;\n\t\t\t// Will hold references to filter tabs for keyboard navigation\n\t\t\tthis.filterElements = null;\n\t\t\tthis.params = {};\n\t\t\tthis.overrideIsActive = false;\n\t\t}\n\n\t\tadoptedCallback() {\n\t\t\tsuper.adoptedCallback();\n\t\t\tCIQ.UI.flattenInheritance(this, Lookup);\n\t\t\tthis.constructor = Lookup;\n\t\t}\n\n\t\t/**\n\t\t * With the decoupling of the uiHelper to the Lookup.Driver you must be sure to include both an argument for maxResults and the closure to handle the results.\n\t\t * maxResults must either be a number or a string to result in default value of 100.\n\t\t * @alias acceptText\n\t\t * @memberof WebComponents.cq-lookup#\n\t\t * @since 3.0.0\n\t\t */\n\t\tacceptText(value, filter) {\n\t\t\tvar self = this;\n\t\t\tif (!this.params.driver) {\n\t\t\t\tif (this.context.lookupDriver) {\n\t\t\t\t\tthis.setDriver(this.context.lookupDriver);\n\t\t\t\t} else {\n\t\t\t\t\tthis.setDriver(new CIQ.ChartEngine.Driver.Lookup());\n\t\t\t\t\tthis.usingEmptyDriver = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tvar restoredExchanges = this.params.driver.exchanges;\n\t\t\tfunction closure(results) {\n\t\t\t\tself.params.driver.exchanges = restoredExchanges;\n\t\t\t\tself.results(results);\n\t\t\t}\n\t\t\tvar exchanges = this.getAttribute(\"cq-exchanges\");\n\t\t\tif (exchanges) this.params.driver.exchanges = exchanges.split(\",\");\n\t\t\tthis.params.driver.acceptText(value, filter, null, closure);\n\t\t}\n\n\t\tattachDriver(driver) {\n\t\t\tthis.driver = driver;\n\t\t}\n\n\t\tclose() {\n\t\t\tif (this.keyboardNavigation) {\n\t\t\t\t// Position the highlight over the input to wait for the collapse animation to complete\n\t\t\t\tthis.highlightItem(this.input[0]);\n\t\t\t\t// Reposition the highlight after css animation is complete.\n\t\t\t\tsetTimeout(this.highlightItem.bind(this, this.input[0]), 250);\n\n\t\t\t\t// Remove any focused property from the filter tabs\n\t\t\t\tthis.removeFocused(this.filterElements);\n\t\t\t\t// Remove keyboard control from scroll\n\t\t\t\tthis.resultList[0].keyboardNavigation = null;\n\t\t\t} else {\n\t\t\t\t// Reset the hilight. In the event that tab navigation is activated while the lookup is open\n\t\t\t\tconst keystrokeHub = this.ownerDocument.body.keystrokeHub;\n\t\t\t\tif (keystrokeHub) setTimeout(() => keystrokeHub.highlightAlign(), 250);\n\t\t\t}\n\t\t\tthis.closest(\"cq-dialog,cq-menu\").close();\n\t\t}\n\n\t\tforceInput() {\n\t\t\tvar input = this.input[0];\n\t\t\tthis.selectItem({ symbol: input.value });\n\t\t\tCIQ.blur(input);\n\t\t\tthis.close();\n\t\t\tinput.value = \"\";\n\t\t}\n\n\t\tinitialize() {\n\t\t\tthis.addDefaultMarkup();\n\t\t\tvar node = this.node;\n\n\t\t\tthis.label = this.querySelector(\"label\");\n\t\t\tthis.labelName = this.getAttribute(\"label-name\");\n\t\t\tthis.labelText = this.getAttribute(\"label-text\");\n\n\t\t\tif (this.label && this.labelText && this.labelName) {\n\t\t\t\tconst { config: { chartId = \"\" } = {} } = this.context;\n\t\t\t\tthis.label.id = chartId\n\t\t\t\t\t? `${this.labelName}-${chartId}`\n\t\t\t\t\t: this.labelName;\n\t\t\t\tthis.label.innerText = this.labelText;\n\t\t\t\tif (chartId) this.setAttribute(\"aria-labelledby\", this.label.id);\n\t\t\t}\n\n\t\t\tthis.resultList = node.find(\"cq-scroll\");\n\n\t\t\tthis.input = node.find(\"input\");\n\t\t\tif (!this.input.length) {\n\t\t\t\tvar hiddenInput = document.createElement(\"input\");\n\t\t\t\thiddenInput.setAttribute(\"type\", \"hidden\");\n\t\t\t\thiddenInput.value = \"\";\n\t\t\t\tthis.input = node.append(hiddenInput);\n\t\t\t}\n\t\t\tCIQ.UI.stxtap(this.input[0], function () {\n\t\t\t\tthis.focus();\n\t\t\t});\n\t\t\tvar self = this;\n\t\t\tArray.from(this.input).forEach(function (input) {\n\t\t\t\tinput.addEventListener(\"paste\", function (e) {\n\t\t\t\t\tvar input = e.target;\n\t\t\t\t\tsetTimeout(function () {\n\t\t\t\t\t\tself.acceptText(input.value, self.currentFilter);\n\t\t\t\t\t}, 0);\n\t\t\t\t});\n\t\t\t});\n\t\t\tvar filters = this.querySelector(\"cq-lookup-filters\");\n\t\t\tif (filters) {\n\t\t\t\tvar allFilters = filters.querySelectorAll(\"cq-filter\");\n\t\t\t\tallFilters.forEach(function (filter) {\n\t\t\t\t\tCIQ.UI.stxtap(filter, function () {\n\t\t\t\t\t\tallFilters.forEach(function (f) {\n\t\t\t\t\t\t\tf.classList.remove(\"true\");\n\t\t\t\t\t\t});\n\t\t\t\t\t\tthis.classList.add(\"true\");\n\t\t\t\t\t\tvar translate = this.querySelector(\"cq-translate\");\n\t\t\t\t\t\tif (translate) {\n\t\t\t\t\t\t\t// if the filter text has been translated then it will be in a tag\n\t\t\t\t\t\t\tself.currentFilter = translate.getAttribute(\"original\");\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tself.currentFilter = this.innerHTML;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tself.acceptText(self.input.val(), self.currentFilter);\n\t\t\t\t\t});\n\t\t\t\t});\n\t\t\t}\n\n\t\t\tif (typeof node.attr(\"cq-keystroke-claim\") != \"undefined\") {\n\t\t\t\t// add keyboard claim for entire body\n\t\t\t\tthis.addClaim(this);\n\t\t\t}\n\t\t}\n\n\t\tisActive() {\n\t\t\treturn this.input[0].value !== \"\";\n\t\t}\n\n\t\t// Note that this captures keystrokes on the body. If the input box is focused then we need to allow the input box itself\n\t\t// to handle the strokes but we still want to capture them in order to display the lookup results. We first check\n\t\t// activeElement to see if the input is focused. If so then we bypass logic that manipulates the input.value. In order make\n\t\t// sure that the lookup menu is responding to an up-to-date input.value therefore we have to put all of those pieces of code\n\t\t// in setTimeout(0)\n\t\t//\n\t\t// Note that when comparisons are enabled, there are two Lookup components on the screen. Each keypress will therefore pass\n\t\t// through this function twice, once for each Lookup component. Only the active component will process the keystroke.\n\t\tkeyStroke(hub, key, e, keystroke) {\n\t\t\tif (keystroke.ctrl || keystroke.cmd) return false;\n\t\t\tif (key == \"Meta\" || key == \"Win\") return false;\n\n\t\t\tvar input = this.input[0];\n\t\t\tvar result = false;\n\t\t\tvar activeElement = this.ownerDocument.activeElement;\n\t\t\tvar focused = activeElement === input; // If focused then we need to allow the input box to get most keystrokes\n\t\t\t// Rejecting alt key combinations only when the input is out of focus because some special chars can be typed with an alt key\n\t\t\tif (\n\t\t\t\t!focused &&\n\t\t\t\t(e.altKey ||\n\t\t\t\t\t(activeElement &&\n\t\t\t\t\t\t(activeElement.tagName == \"INPUT\" ||\n\t\t\t\t\t\t\tactiveElement.tagName == \"TEXTAREA\")))\n\t\t\t) {\n\t\t\t\treturn false; // either an alt key combination was pressed or some other input has focus\n\t\t\t}\n\n\t\t\tvar iAmActive = false,\n\t\t\t\tiAmDisplayed = false;\n\t\t\tif (CIQ.climbUpDomTree(this, \".stxMenuActive\").length) {\n\t\t\t\tiAmDisplayed = true; // if my menu chain is active then I'm alive\n\t\t\t}\n\t\t\tif (focused || iAmDisplayed) iAmActive = true; // If my input is focused or I'm displayed, then I'm alive\n\t\t\tif (!iAmActive) {\n\t\t\t\t// Otherwise, I may still be alive under certain conditions\n\t\t\t\tif (typeof this.node.attr(\"cq-keystroke-default\") == \"undefined\")\n\t\t\t\t\treturn; // I'm always alive if I have default body keystrokes\n\t\t\t\tif (!iAmDisplayed && this.uiManager.topMenu()) return; // unless there's another menu active and it isn't me\n\t\t\t}\n\t\t\tif ((key === \" \" || key === \"Spacebar\") && input.value === \"\") {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\tvar self = this;\n\t\t\tvar focusedElements = this.findFocused(this.filterElements);\n\n\t\t\tswitch (key) {\n\t\t\t\tcase \"Delete\":\n\t\t\t\tcase \"Backspace\":\n\t\t\t\tcase \"Del\":\n\t\t\t\t\tif (input.value.length) {\n\t\t\t\t\t\t//ctrl-a or highlight all text + delete implies remove all text\n\t\t\t\t\t\tif (window.getSelection().toString()) {\n\t\t\t\t\t\t\tinput.value = \"\";\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif (!focused)\n\t\t\t\t\t\t\t\tinput.value = input.value.substring(0, input.value.length - 1);\n\t\t\t\t\t\t\tif (input.value.length) {\n\t\t\t\t\t\t\t\tself.acceptText(input.value, self.currentFilter);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tresult = true; // only capture delete key if there was something to delete\n\t\t\t\t\t}\n\t\t\t\t\tif (key == \"Backspace\") result = true; // always capture backspace because otherwise chrome will navigate back\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"Escape\":\n\t\t\t\tcase \"Esc\":\n\t\t\t\t\tinput.value = \"\";\n\t\t\t\t\tthis.close();\n\t\t\t\t\tCIQ.blur(input);\n\t\t\t\t\tresult = true;\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"Enter\":\n\t\t\t\t\tvar scrollable = this.resultList;\n\t\t\t\t\tfocused = scrollable.length && scrollable[0].focused(); // Using cursor keys to maneuver down lookup results\n\t\t\t\t\tif ((input.value === \"\" && !focused) || this.overrideIsActive) break;\n\t\t\t\t\tif (focused && focused.selectFC) {\n\t\t\t\t\t\tfocused.selectFC.apply(focused, {});\n\t\t\t\t\t} else {\n\t\t\t\t\t\tvar val = input.value;\n\t\t\t\t\t\tvar toUpperCase =\n\t\t\t\t\t\t\t[\"false\", \"0\", null].indexOf(this.getAttribute(\"cq-uppercase\")) ==\n\t\t\t\t\t\t\t-1;\n\t\t\t\t\t\tif (toUpperCase) val = val.toUpperCase();\n\t\t\t\t\t\tthis.selectItem({ symbol: val });\n\t\t\t\t\t}\n\n\t\t\t\t\tCIQ.blur(input);\n\t\t\t\t\tthis.close();\n\t\t\t\t\tinput.value = \"\";\n\t\t\t\t\tresult = true;\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"ArrowRight\":\n\t\t\t\tcase \"Right\":\n\t\t\t\t\tif (focusedElements.length) {\n\t\t\t\t\t\t// Remove control from the result list\n\t\t\t\t\t\tif (this.resultList[0].keyboardNavigation)\n\t\t\t\t\t\t\tthis.resultList[0].keyboardNavigation = null;\n\t\t\t\t\t\t// Ignore right if a tab is not focused to allow cursor movement in input\n\t\t\t\t\t\tthis.focusNextItem(this.filterElements);\n\t\t\t\t\t\tthis.clickFocusedItem(this.filterElements, e);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"ArrowLeft\":\n\t\t\t\tcase \"Left\":\n\t\t\t\t\t// Remove control from the result list\n\t\t\t\t\tif (this.resultList[0].keyboardNavigation)\n\t\t\t\t\t\tthis.resultList[0].keyboardNavigation = null;\n\t\t\t\t\t// Ignore left if a tab is not focused to allow cursor movement in input\n\t\t\t\t\tif (focusedElements.length) {\n\t\t\t\t\t\tthis.focusNextItem(this.filterElements, true);\n\t\t\t\t\t\tthis.clickFocusedItem(this.filterElements, e);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"ArrowDown\":\n\t\t\t\tcase \"Down\":\n\t\t\t\t\t// Up/Down arrows are only used in this component when keyboard navigation is enabled\n\t\t\t\t\tif (!this.keyboardNavigation) break;\n\t\t\t\t\t// If no tab is focused, then give the first one focus, otherwise, pass control to the resultList\n\t\t\t\t\tfocusedElements = this.findFocused(this.filterElements);\n\t\t\t\t\tif (!focusedElements.length) {\n\t\t\t\t\t\t// If a tab hasn't been focused, highlight the active one.\n\t\t\t\t\t\tfor (\n\t\t\t\t\t\t\tlet filterIdx = 0;\n\t\t\t\t\t\t\tfilterIdx < this.filterElements.length;\n\t\t\t\t\t\t\tfilterIdx++\n\t\t\t\t\t\t) {\n\t\t\t\t\t\t\tlet filterElement = this.filterElements[filterIdx];\n\t\t\t\t\t\t\tif (filterElement.classList.contains(\"true\")) {\n\t\t\t\t\t\t\t\tthis.focusItem(filterElement);\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t} else if (!this.resultList[0].keyboardNavigation) {\n\t\t\t\t\t\t// Only pass control to the result list if there are results\n\t\t\t\t\t\tvar resultItem = this.resultList[0].querySelector(\"cq-item\");\n\t\t\t\t\t\tif (resultItem)\n\t\t\t\t\t\t\tthis.resultList[0].keyboardNavigation = this.keyboardNavigation;\n\t\t\t\t\t}\n\t\t\t\t\tCIQ.blur(input);\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"ArrowUp\":\n\t\t\t\tcase \"Up\":\n\t\t\t\t\t// Up/Down arrows are only used in this component when keyboard navigation is enabled\n\t\t\t\t\tif (!this.keyboardNavigation) break;\n\t\t\t\t\t// resultList has its own up/down control.\n\t\t\t\t\tif (this.resultList[0].keyboardNavigation) {\n\t\t\t\t\t\t// If the scroll has control, check for the top item selected and move highlight back to the tabs\n\t\t\t\t\t\tvar firstResult = this.resultList[0].querySelector(\n\t\t\t\t\t\t\t\"cq-item:first-of-type\"\n\t\t\t\t\t\t);\n\t\t\t\t\t\tif (firstResult && firstResult.hasAttribute(\"cq-focused\")) {\n\t\t\t\t\t\t\tfirstResult.removeAttribute(\"cq-focused\");\n\t\t\t\t\t\t\tthis.resultList[0].keyboardNavigation = null;\n\t\t\t\t\t\t\tthis.highlightFocusedItem(this.filterElements);\n\t\t\t\t\t\t}\n\t\t\t\t\t} else if (focusedElements.length) {\n\t\t\t\t\t\t//If a tab has the highlight, reset the highlight back to the input\n\t\t\t\t\t\tthis.removeFocused(focusedElements);\n\t\t\t\t\t\tthis.highlightItem(input);\n\t\t\t\t\t\tCIQ.focus(input);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\t// Prevent keys like Control and ArrowLeft from triggering focus\n\t\t\t\t\tif (key.length === 1) {\n\t\t\t\t\t\t// Changes the value when keystrokes are registered against the body.\n\t\t\t\t\t\tif (!focused) input.value = input.value + key;\n\t\t\t\t\t\tself.acceptText(input.value, self.currentFilter);\n\t\t\t\t\t\tresult = true;\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tif (result) {\n\t\t\t\t// If we're focused, then keep the lookup open unless we hit escape.\n\t\t\t\t// Otherwise, if there is no length close it (user hit \"escape\", \"enter\", or \"backspace/delete\" while unfocused)\n\t\t\t\tif (\n\t\t\t\t\tthis.usingEmptyDriver ||\n\t\t\t\t\t(!input.value.length &&\n\t\t\t\t\t\t(key == \"Escape\" || key == \"Esc\" || key == \"Enter\" || !focused))\n\t\t\t\t) {\n\t\t\t\t\tthis.close();\n\t\t\t\t} else {\n\t\t\t\t\tthis.open();\n\t\t\t\t}\n\t\t\t\tif (focused) return { allowDefault: true };\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\n\t\topen() {\n\t\t\t// Reposition the highlight after css animation is complete.\n\t\t\twindow.setTimeout(this.highlightItem.bind(this, this.input[0]), 250);\n\t\t\tthis.closest(\"cq-dialog,cq-menu\").open();\n\t\t}\n\n\t\tonKeyboardDeselection() {\n\t\t\tCIQ.blur(this.input[0]);\n\t\t\tthis.close();\n\t\t\t// If we're using keyboard navigation, return the highlight to the tab selected element\n\t\t\tif (this.keyboardNavigation) this.keyboardNavigation.highlightPosition();\n\t\t\tthis.resultList[0].keyboardNavigationWait = false;\n\t\t}\n\n\t\tonKeyboardSelection() {\n\t\t\t// If we're using keyboard navigation, return the highlight to the tab selected element\n\t\t\tthis.highlightItem(this.input[0]);\n\t\t\tCIQ.focus(this.input[0]);\n\t\t\tthis.resultList[0].keyboardNavigationWait = true;\n\t\t\tthis.open();\n\t\t}\n\n\t\t/**\n\t\t * Displays an array of results returned by the {@link CIQ.ChartEngine.Driver.Lookup}.\n\t\t *\n\t\t * Each element in the array should be in the following format (see\n\t\t * {@link CIQ.ChartEngine.Driver.Lookup#acceptText}):\n\t\t * ```\n\t\t * {\n\t\t * display: [\"symbol ID\", \"symbol description\", \"exchange\"],\n\t\t * data: {\n\t\t * symbol: \"symbol ID\",\n\t\t * name: \"symbol description\",\n\t\t * exchDis: \"exchange\"\n\t\t * }\n\t\t * }\n\t\t * ```\n\t\t *\n\t\t * The lookup component by default displays three columns as represented by the array. The\n\t\t * data object can be a format required by your quote feed, or it can be a simple string\n\t\t * if you just need to support a stock symbol.\n\t\t *\n\t\t * @param {array} arr The array of results.\n\t\t *\n\t\t * @alias results\n\t\t * @memberof WebComponents.cq-lookup#\n\t\t */\n\t\tresults(arr) {\n\t\t\tfunction closure(self, data) {\n\t\t\t\treturn function (e) {\n\t\t\t\t\tCIQ.blur(self.input[0]);\n\t\t\t\t\t//self.close();\n\t\t\t\t\tself.selectItem(data);\n\t\t\t\t\tself.input[0].value = \"\";\n\t\t\t\t};\n\t\t\t}\n\n\t\t\tthis.resultList = CIQ.UI.$(this.resultList);\n\t\t\tthis.resultList.empty();\n\t\t\tfor (var i = 0; i < arr.length; i++) {\n\t\t\t\tvar item = arr[i];\n\t\t\t\tvar nodeText = \"\";\n\t\t\t\tfor (var j = 0; j < item.display.length; j++) {\n\t\t\t\t\tnodeText += \"\" + item.display[j] + \"\";\n\t\t\t\t}\n\n\t\t\t\tvar node = document.createElement(\"cq-item\");\n\t\t\t\tnode.innerHTML = nodeText;\n\t\t\t\tnode.setAttribute(\"role\", \"menuitem\");\n\t\t\t\tthis.resultList.append(node);\n\t\t\t\tnode.selectFC = closure(this, item.data);\n\t\t\t\tCIQ.UI.stxtap(node, node.selectFC);\n\t\t\t}\n\t\t\tvar scrollable = this.resultList;\n\t\t\tif (scrollable[0]) scrollable[0].top();\n\n\t\t\t// Reset the hilight position\n\t\t\tthis.highlightFocusedItem(this.filterElements);\n\t\t}\n\n\t\t/**\n\t\t * Accepts a new symbol or symbol object.\n\t\t *\n\t\t * @param {object} data Contains a symbol or symbol object in a form accepted by\n\t\t * \t\t{@link CIQ.ChartEngine#loadChart}.\n\t\t * @param {function} fn Function to execute when the callback set by\n\t\t * \t\t[setCallback]{@link WebComponents.cq-lookup#setCallback} finishes.\n\t\t *\n\t\t * @alias selectItem\n\t\t * @memberof WebComponents.cq-lookup#\n\t\t * @since 8.2.0 Removed the `params` parameter. Added the `fn` parameter.\n\t\t */\n\t\tselectItem(data, fn) {\n\t\t\tif (this.params.cb) {\n\t\t\t\tthis.params.cb(data, fn);\n\t\t\t}\n\t\t}\n\n\t\t/**\n\t\t * Sets a callback function to be called when the user selects a symbol.\n\t\t *\n\t\t * @param {function} cb The callback function; for example, an implementation of\n\t\t * \t\t{@link CIQ.UI.Context#changeSymbol}.\n\t\t *\n\t\t * @alias setCallback\n\t\t * @memberof WebComponents.cq-lookup#\n\t\t */\n\t\tsetCallback(cb) {\n\t\t\tthis.params.cb = cb;\n\t\t}\n\n\t\tsetContext(context) {\n\t\t\tthis.initialize();\n\n\t\t\tconst symbolInput = this.querySelector(\"cq-lookup-input input\");\n\t\t\tconst { config, stx } = context;\n\t\t\tif (!config) return;\n\t\t\tconst { channels = {} } = config;\n\n\t\t\tthis.channelSubscribe(\n\t\t\t\tchannels.breakpoint || \"channel.breakpoint\",\n\t\t\t\t(breakPoint) => {\n\t\t\t\t\tvar placeholder = stx.crossSection\n\t\t\t\t\t\t? stx.crossSection.symbolInputType\n\t\t\t\t\t\t: \"Symbol\";\n\t\t\t\t\tif (breakPoint === \"break-lg\") {\n\t\t\t\t\t\tplaceholder = \"Enter \" + placeholder;\n\t\t\t\t\t}\n\t\t\t\t\tsymbolInput.setAttribute(\n\t\t\t\t\t\t\"placeholder\",\n\t\t\t\t\t\tbreakPoint === \"break-sm\" ? \"\" : placeholder\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t);\n\n\t\t\t// Get a list of filter tabs for keyboard navigation\n\t\t\tthis.filterElements = this.querySelectorAll(\n\t\t\t\t\"cq-lookup-filters cq-filter\"\n\t\t\t);\n\n\t\t\tif (!this.params.cb && context.changeSymbol)\n\t\t\t\tthis.params.cb = context.changeSymbol;\n\t\t}\n\n\t\tchangeContext(newContext) {\n\t\t\tif (this.params.cb && newContext.changeSymbol)\n\t\t\t\tthis.params.cb = newContext.changeSymbol;\n\t\t}\n\n\t\t/**\n\t\t * Connects a {@link CIQ.ChartEngine.Driver.Lookup} to the web component.\n\t\t *\n\t\t * The lookup driver searches financial exchanges for symbols that match the text entered\n\t\t * in the component's input field.\n\t\t *\n\t\t * @param {CIQ.ChartEngine.Driver.Lookup} driver The lookup driver to connect to the web\n\t\t * \t\tcomponent.\n\t\t *\n\t\t * @alias setDriver\n\t\t * @memberof WebComponents.cq-lookup#\n\t\t */\n\t\tsetDriver(driver) {\n\t\t\tthis.params.driver = driver;\n\t\t}\n\t}\n\n\tLookup.markup = `\n\t\t\n\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t\t\n\t\t\t\n\t\t\t\tALL\n\t\t\t\tSTOCKS\n\t\t\t\tFX\n\t\t\t\tINDEXES\n\t\t\t\tFUNDS\n\t\t\t\tFUTURES\n\t\t\t\n\t\t\t\n\t\t\n\t`;\n\tCIQ.UI.addComponentDefinition(\"cq-lookup\", Lookup);\n}\n\n};\n\n\nlet __js_webcomponents_menu_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Menu web component ``.\n *\n * Add attribute `cq-focus` to provide a query selector path to the element to focus when the\n * menu is opened.\n *\n * The node is contextually aware of its surroundings. Handles opening and closing\n * {@link WebComponents.cq-menu-dropdown}.\n *\n * @namespace WebComponents.cq-menu\n *\n * @example\n * \n * \t Events\n * \t \n * \t\t Simple Square \n * \t\t \n * \t\t Simple Circle \n * \t\t \n * \t\t Callouts \n * \t\t \n * \t\t Abstract \n * \t\t \n * \t\t None \n * \t\t \n * \t \n * \n */\nclass Menu extends HTMLElement {\n\tconstructor() {\n\t\tsuper();\n\t\tthis.activeClassName = \"stxMenuActive\";\n\t\tthis.active = false;\n\t}\n\n\t/**\n\t * READ ONLY. The value of the `cq-focus` attribute.\n\t *\n\t * @alias focusElement\n\t * @memberof WebComponents.cq-menu\n\t * @type String\n\t * @since 7.5.0\n\t */\n\tget focusElement() {\n\t\treturn this.getAttribute(\"cq-focus\");\n\t}\n\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tthis.uiManager = CIQ.UI.getUIManager(this);\n\n\t\tthis.attached = true;\n\n\t\tif (this.hasAttribute(\"readonly\")) return;\n\t\tvar self = this;\n\t\tfunction handleTap(e) {\n\t\t\tself.tap(e);\n\t\t}\n\t\tfunction handleCaptureTap(e) {\n\t\t\tself.captureTap(e);\n\t\t}\n\t\tthis.addEventListener(\"stxtap\", handleCaptureTap, true);\n\t\tCIQ.UI.stxtap(this, handleTap);\n\t}\n\n\tadoptedCallback() {\n\t\tCIQ.UI.flattenInheritance(this, Menu);\n\t}\n\n\t/**\n\t * Captures a tap event *before* it descends down to what it is clicked on. The key thing this does is determine\n\t * whether the thing clicked on was inside of a \"cq-no-close\" section. We do this on the way down, because the act\n\t * of clicking on something may release it from the dom, making it impossible to figure out on propagation.\n\t * @param {object} e Element\n\t * @private\n\t */\n\tcaptureTap(e) {\n\t\tvar domChain = Array.from(CIQ.climbUpDomTree(e.target));\n\t\t// Determine if the tapped element, or any of its parents have a cq-no-close attribute\n\t\tthis.noClose = domChain.filter(function (el) {\n\t\t\tvar attr = el.getAttribute(\"cq-no-close\");\n\t\t\treturn attr !== null && attr !== false;\n\t\t}).length;\n\n\t\t// Determine if the tapped element was inside of something untappable, like a cq-heading or cq-separator\n\t\tif (!this.noClose) {\n\t\t\tthis.noClose = domChain.filter(function (el) {\n\t\t\t\treturn el.matches(\"cq-separator,cq-heading\");\n\t\t\t}).length;\n\t\t}\n\t}\n\n\tclose() {\n\t\tthis.uiManager.closeMenu(this);\n\t}\n\n\thide() {\n\t\tif (!this.active) return;\n\t\tthis.unlift();\n\t\tthis.classList.remove(this.activeClassName);\n\t\tthis.active = false;\n\t\t// blur any input boxes that are inside the menu we're closing, to get rid of soft keyboard\n\t\tthis.querySelectorAll(\"input\").forEach(function (i) {\n\t\t\tif (i == i.ownerDocument.activeElement) i.blur();\n\t\t});\n\t\t// Disable keyboardNavigation controls in the dropdown\n\t\tconst dropdown = this.querySelector(\"cq-menu-dropdown\");\n\t\tif (dropdown) {\n\t\t\tdropdown.disablekeyboardNavigation();\n\t\t\t// Remove focus from any selected menu item\n\t\t\tCIQ.UI.BaseComponent.prototype.removeFocused(\n\t\t\t\tdropdown.querySelectorAll(\"[cq-focused]\")\n\t\t\t);\n\t\t}\n\t\tif (this.ownerDocument.body.keystrokeHub) {\n\t\t\tlet { tabActiveModals } = this.ownerDocument.body.keystrokeHub;\n\t\t\tif (tabActiveModals[0])\n\t\t\t\tthis.ownerDocument.body.keystrokeHub.setKeyControlElement(\n\t\t\t\t\ttabActiveModals[0]\n\t\t\t\t);\n\t\t}\n\n\t\t// Close the lookup component\n\t\tconst lookup = this.querySelector(\"cq-lookup\");\n\t\tif (lookup) lookup.close();\n\t}\n\n\tlift() {\n\t\tconst context = CIQ.UI.getMyContext(this);\n\t\tconst lifts = (this.lifts = this.uiManager.findLifts(this));\n\t\tfor (let i = 0; i < lifts.length; i++) {\n\t\t\t// The lifted menu will no longer inherit the active theme class. Attach it directly to the element.\n\t\t\tif (context && context.config && context.config.themes) {\n\t\t\t\tlet themes = Object.keys(context.config.themes.builtInThemes);\n\t\t\t\t// First remove any existing theme classes on the dialog\n\t\t\t\tlifts[i].classList.remove(...themes);\n\t\t\t\tlet activeTheme = themes.find(\n\t\t\t\t\t(r) => context.topNode.classList.contains(r) === true\n\t\t\t\t);\n\t\t\t\t// Add the active theme class to the dialog\n\t\t\t\tif (activeTheme) lifts[i].classList.add(activeTheme);\n\t\t\t}\n\t\t\tthis.uiManager.lift(lifts[i]);\n\t\t}\n\t}\n\n\tonKeyboardDeselection() {\n\t\tthis.close();\n\t}\n\n\topen(params) {\n\t\tvar stack = this.uiManager.activeMenuStack;\n\t\tfor (var i = 0; i < stack.length; i++) {\n\t\t\tif (stack[i] === this) return;\n\t\t}\n\t\tthis.uiManager.openMenu(this, params);\n\t}\n\n\tshow(params) {\n\t\tif (this.active) return;\n\t\tthis.active = true;\n\t\tthis.classList.add(this.activeClassName);\n\t\tthis.lift();\n\t\t// For good measure, call resize on any nested scrollables to give them\n\t\t// a chance to change their height and scrollbars\n\t\tthis.querySelectorAll(\"cq-scroll, cq-menu-dropdown\").forEach(function (s) {\n\t\t\tif (s.resize) s.resize();\n\t\t});\n\t\t// Pass keyboard navigation over to the dropdown if it exists\n\t\tif (this.keyboardNavigation) {\n\t\t\tconst dropdown = this.querySelector(\"cq-menu-dropdown\");\n\t\t\tif (dropdown)\n\t\t\t\tthis.keyboardNavigation.setKeyControlElement(dropdown, true);\n\t\t}\n\t}\n\n\ttap(e) {\n\t\te.stopPropagation();\n\t\tvar uiManager = this.uiManager;\n\t\tif (this.active) {\n\t\t\t// tapping on the menu if it is open will close it\n\t\t\tif (!this.noClose) uiManager.closeMenu(this);\n\t\t} else {\n\t\t\t// if we've clicked on the label for the menu, then open the menu\n\n\t\t\t// If the tap came from within this menu's cq-menu-dropdown then this is probably an accidental\n\t\t\t// \"re-open\", which occurs when a click on a menu item causes an action that closes the menu, tricking\n\t\t\t// it into thinking it should re-open\n\t\t\tvar insideDropdown = e.target.closest(\"cq-menu-dropdown\");\n\t\t\tif (insideDropdown) return;\n\n\t\t\tvar child = false;\n\t\t\tvar parents = CIQ.climbUpDomTree(this.parentElement, \"cq-menu\");\n\t\t\tfor (var i = 0; i < parents.length; i++) {\n\t\t\t\tif (parents[i].active) child = true;\n\t\t\t}\n\t\t\tif (!child) uiManager.closeMenu(null, \"CQ-MENU, CQ-COLOR-PICKER\"); // close all menus or color pickers, unless we're the child of an active menu (cascading)\n\n\t\t\tthis.open();\n\n\t\t\tif (this.focusElement && !CIQ.isMobile) {\n\t\t\t\tlet el = this.querySelector(this.focusElement);\n\t\t\t\tif (!el && this.lifts)\n\t\t\t\t\tel = this.lifts[0].querySelector(this.focusElement);\n\t\t\t\tif (el) el.focus();\n\t\t\t}\n\t\t}\n\t}\n\n\tunlift() {\n\t\tvar lifts = this.lifts;\n\t\tif (!lifts) return;\n\t\tfor (var i = 0; i < lifts.length; i++) {\n\t\t\tthis.uiManager.restoreLift(lifts[i]);\n\t\t}\n\t\tthis.lifts = null;\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-menu\", Menu);\n\n};\n\n\nlet __js_webcomponents_menuContainer_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * The menu container web component ``.\n *\n * Generates a menu based on the value of the `cq-name` attribute.\n *\n * @namespace WebComponents.cq-menu-container\n * @since 7.5.0\n *\n * @example\n * \n * 1D\n * \n * \n * \n * \n */\nclass MenuContainer extends CIQ.UI.ContextTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, MenuContainer);\n\t}\n\n\t/**\n\t * Obtains the name of the menu and the items contained in the menu. Adds the default\n\t * markup.\n\t *\n\t * @param {CIQ.UI.Context} context The chart user interface context.\n\t *\n\t * @alias setContext\n\t * @memberof WebComponents.cq-menu-container\n\t * @since 7.5.0\n\t */\n\tsetContext(context) {\n\t\tconst setName = this.getAttribute(\"cq-name\");\n\t\tif (setName && context.config) {\n\t\t\t// get menu items as array\n\t\t\tconst menuItems = context.config.getMenu(setName);\n\t\t\tthis.addDefaultMarkup(this, menuItems && menuItems.join(\"\"));\n\t\t\tif (!this.innerHTML) {\n\t\t\t\t// hide container and heading if there is no content\n\t\t\t\tconst container = CIQ.UI.BaseComponent.selfOrParentElement(\n\t\t\t\t\tthis,\n\t\t\t\t\t\"cq-menu-dropdown-section\"\n\t\t\t\t);\n\t\t\t\tif (container) container.style.display = \"none\";\n\t\t\t}\n\t\t\treturn;\n\t\t}\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-menu-container\", MenuContainer);\n\n};\n\n\nlet __js_webcomponents_messageToaster_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Message toaster web component ``.\n *\n * Displays pop-up messages, also known as toasts.\n *\n * Listens for a chart engine event of type \"notification\" and displays the notification as a\n * pop-up message over the chart.\n *\n * To trigger the notification event, call {@link CIQ.ChartEngine#dispatch} with the\n * \"notification\" type and the required notification listener data (see\n * [notificationEventListener]{@link CIQ.ChartEngine~notificationEventListener}), for example:\n * ```\n * stxx.dispatch(\"notification\", { message: \"A toast!\" });\n * ```\n *\n * Toasts are displayed immediately unless another toast is already on screen. Concurrent toasts\n * are displayed sequentially, not simultaneously.\n *\n * When a toast is created, it's added to a display queue. The toast at the front of the queue is\n * dequeued and displayed when no other toasts are on screen. Toasts can be prioritized (that is,\n * reordered in the queue) by setting the `priority` parameter of the\n * [notificationEventListener]{@link CIQ.ChartEngine~notificationEventListener} argument.\n *\n * **Attributes**:\n * | Name | Description | Valid Values |\n * | ---- | ----------- | ------------ |\n * | `defaultDisplayTime` | Amount of time, in seconds, toasts are displayed before being automatically dismissed (removed from the display). | Integer numbers >= 0. A value of 0 causes toasts to remain on screen — blocking the toast display queue — until selected by the user. |\n * | `defaultPosition` | Vertical on-screen position of toasts relative to the chart. (Toasts are centered horizontally.) | \"top\" or \"bottom\" |\n * | `defaultTransition` | Animation used to display and dismiss toasts. | \"fade\", \"slide\", \"pop\" or \"drop\" |\n *\n * **Note:** All attributes can be overridden by the argument provided to\n * [notificationEventListener]{@link CIQ.ChartEngine~notificationEventListener}.\n *\n * @namespace WebComponents.cq-message-toaster\n * @since 8.2.0\n *\n * @example\n * \n */\nclass MessageToaster extends CIQ.UI.ContextTag {\n\tconstructor() {\n\t\tsuper();\n\t}\n\n\t/**\n\t * Initializes the message toaster web component.\n\t *\n\t * @alias connectedCallback\n\t * @memberof WebComponents.cq-message-toaster#\n\t * @private\n\t * @since 8.2.0\n\t */\n\tconnectedCallback() {\n\t\tsuper.connectedCallback();\n\n\t\tthis.messageQueue = [];\n\t\tthis.displayTime = +this.getAttribute(\"defaultDisplayTime\") || 10; // Time in seconds\n\t\tthis.messagePosition = this.getAttribute(\"defaultPosition\") || \"top\";\n\t\tthis.messageTransition = this.getAttribute(\"defaultTransition\") || \"\"; // Default is no transition\n\t\tthis.displayTimer = null;\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, MessageToaster);\n\t}\n\n\tsetContext() {\n\t\tconst { stx } = this.context;\n\n\t\t// Listen for notification events from the chartEngine\n\t\tstx.addEventListener(\"notification\", (params) => {\n\t\t\tif (params && params.remove) this.dismissMessage(params.message);\n\t\t\telse this.newMessage(params);\n\t\t});\n\n\t\tstx.append(\"resizeChart\", () => this.handleResize());\n\t}\n\n\t/**\n\t * Updates the position settings of all toasts (all DOM elements with class\n\t * `cq-toast-message`), including those not currently displayed, when the chart is resized.\n\t *\n\t * @alias handleResize\n\t * @memberof WebComponents.cq-message-toaster#\n\t * @since 8.2.0\n\t */\n\thandleResize() {\n\t\tfor (let idx = 0; idx < this.messageQueue.length; idx++) {\n\t\t\tif (this.messageQueue[idx].isDisplayed)\n\t\t\t\tthis.positionElement(this.messageQueue[idx]);\n\t\t}\n\t}\n\n\t/**\n\t * Sets the display position of the toast identified by `messageElement` within the bounds of\n\t * the chart canvas. Centers the toast horizontally and positions it vertically based on the\n\t * toast's \n\t * position setting.\n\t *\n\t * @param {HTMLElement} messageElement The toast DOM element to position.\n\t *\n\t * @alias positionElement\n\t * @memberof WebComponents.cq-message-toaster#\n\t * @since 8.2.0\n\t */\n\tpositionElement(messageElement) {\n\t\tconst canvasBounds = this.context.stx.chart.canvas.getBoundingClientRect();\n\t\tconst contextBounds = this.context.topNode.getBoundingClientRect();\n\t\tconst bottomAlign = messageElement.classList.contains(\"align-bottom\");\n\n\t\tlet offsetTop = canvasBounds.top - contextBounds.top;\n\t\tlet offsetLeft = canvasBounds.left - contextBounds.left;\n\n\t\tObject.assign(messageElement.style, {\n\t\t\ttop: bottomAlign\n\t\t\t\t? offsetTop + canvasBounds.height + \"px\"\n\t\t\t\t: offsetTop + \"px\",\n\t\t\tleft: offsetLeft + canvasBounds.width * 0.5 + \"px\"\n\t\t});\n\t}\n\n\t/**\n\t * Creates a new toast DOM element. Toast elements have the `cq-toast-message` class attribute.\n\t *\n\t * @param {object} notification Data object from a \"notification\" event. See\n\t * \t\t[notificationEventListener]{@link CIQ.ChartEngine~notificationEventListener}.\n\t * \t\t

**Note:** This parameter does not accommodate the string type specified in\n\t * \t\t[notificationEventListener]{@link CIQ.ChartEngine~notificationEventListener}.\n\t * @param {string} notification.message Text to display in the toast notification. Strings\n\t * \t\tlonger than 160 characters are truncated.\n\t * @param {string} [notification.position=\"top\"] Position of the toast on the chart: \"top\" or\n\t * \t\t\"bottom\". Overrides the `defaultPosition` attribute of the\n\t * \t\t[``]{@link WebComponents.cq-message-toaster} element.\n\t * @param {string} [notification.type=\"info\"] Toast style: \"info\", \"error\", \"warning\", or\n\t * \t\t\"confirmation\". Overrides the `defaultTransition` attribute of the\n\t * \t\t[``]{@link WebComponents.cq-message-toaster} element.\n\t * @param {string} [notification.transition] Type of animation used to display and dismiss the\n\t * \t\ttoast: \"fade\", \"slide\", \"pop\" or \"drop\". The default is no transition.\n\t * @param {number} [notification.displayTime=10] Number of seconds to display the toast before\n\t * \t\tautomatically dismissing it. A value of 0 causes the toast to remain on\n\t * \t\tscreen — preventing other toasts from\n\t * \t\tdisplaying — until the toast is selected by the user. Overrides the\n\t * \t\t`defaultDisplayTime` attribute of the\n\t * \t\t[``]{@link WebComponents.cq-message-toaster} element.\n\t * @param {number} [notification.priority=0] Priority of the toast relative to others in the\n\t * \t\tdisplay queue. Higher priority toasts are displayed before toasts with lower priority.\n\t * \t\tFor example, a toast with priority = 4 is displayed before a toast with\n\t * \t\tpriority = 1. Toasts with the same priority are displayed in the order\n\t * \t\tthey were created; that is, in the order they entered the display queue.\n\t * @param {Function} [notification.callback] Function to call when the toast is selected\n\t * \t\t(dismissed) by the user. If the toast is dismissed automatically (see `displayTime`),\n\t * \t\tthis function is not called.\n\t * @return {HTMLElement} A toast DOM element.\n\t *\n\t * @alias createMessageElement\n\t * @memberof WebComponents.cq-message-toaster#\n\t * @since 8.2.0\n\t */\n\tcreateMessageElement(notification) {\n\t\tif (!notification.message) return;\n\n\t\tlet {\n\t\t\tmessage,\n\t\t\tposition,\n\t\t\ttype,\n\t\t\ttransition,\n\t\t\tdisplayTime,\n\t\t\tpriority,\n\t\t\tcallback\n\t\t} = notification;\n\n\t\tdisplayTime = parseInt(displayTime);\n\t\t// A value of 0 will prevent the message from removing automatically.\n\t\tif (displayTime !== 0) displayTime = displayTime || this.displayTime;\n\t\tposition = position || this.messagePosition;\n\t\ttransition = transition || this.messageTransition;\n\t\tpriority = priority || 0;\n\n\t\t// Truncate a string longer than 160 characters\n\t\tif (message.length > 160) {\n\t\t\tmessage = message.slice(0, 160) + \"...\";\n\t\t}\n\n\t\tlet messageElement = document.createElement(\"div\");\n\t\tmessageElement.innerHTML = `\n\t\t\t

\n\t\t\t\t
\n\t\t\t\t
\n\t\t\t
`;\n\t\tmessageElement\n\t\t\t.querySelector(\".cq-message-text\")\n\t\t\t.appendChild(CIQ.translatableTextNode(this.context.stx, message));\n\t\tmessageElement.classList.add(\"cq-toast-message\");\n\t\tmessageElement.classList.add(\"type-\" + type);\n\t\tif (transition)\n\t\t\tmessageElement.classList.add(\"animate\", \"transition-\" + transition);\n\t\tif (position == \"bottom\") messageElement.classList.add(\"align-bottom\");\n\t\tmessageElement.displayTime = displayTime;\n\t\tmessageElement.priority = priority;\n\t\tmessageElement.message = message;\n\n\t\tCIQ.safeClickTouch(\n\t\t\tmessageElement,\n\t\t\tfunction (messageElement, callback, event) {\n\t\t\t\tevent.stopPropagation();\n\t\t\t\tif (callback) callback();\n\t\t\t\tthis.removeMessageNode(messageElement);\n\t\t\t}.bind(this, messageElement, callback)\n\t\t);\n\n\t\tthis.positionElement(messageElement);\n\n\t\treturn messageElement;\n\t}\n\n\t/**\n\t * Displays the next toast in the display queue and sets a timer based on the toast\n\t * \n\t * displayTime property to automatically dismiss the toast.\n\t *\n\t * @alias displayNextMessage\n\t * @memberof WebComponents.cq-message-toaster#\n\t * @since 8.2.0\n\t */\n\tdisplayNextMessage() {\n\t\tif (!this.messageQueue.length) return;\n\n\t\tlet messageNodes = this.context.topNode.querySelector(\".cq-toast-message\");\n\t\tif (!messageNodes) {\n\t\t\tlet nextMessage = this.messageQueue[0];\n\t\t\t// Toast Message nodes are added to the body to ensure they appear over all other UI elements (e.g. Dialogs)\n\t\t\tthis.context.topNode.appendChild(nextMessage);\n\t\t\tnextMessage.isDisplayed = true;\n\t\t\tif (nextMessage.displayTime !== 0) {\n\t\t\t\tthis.displayTimer = window.setTimeout(\n\t\t\t\t\tthis.removeMessageNode.bind(this, nextMessage),\n\t\t\t\t\tnextMessage.displayTime * 1000\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\t}\n\n\t/**\n\t * Removes the toast specified by `messageNode` from the display queue and displays the next\n\t * message in the queue.\n\t *\n\t * @param messageNode The toast to remove from the display queue.\n\t *\n\t * @alias removeMessageNode\n\t * @memberof WebComponents.cq-message-toaster#\n\t * @since 8.2.0\n\t */\n\tremoveMessageNode(messageNode) {\n\t\tif (messageNode.classList.contains(\"hide\")) return;\n\n\t\tmessageNode.classList.add(\"hide\");\n\t\tlet delayTime = messageNode.classList.contains(\"animate\") ? 500 : 0;\n\n\t\twindow.setTimeout(() => {\n\t\t\t// Remove the node from the dom\n\t\t\tmessageNode.remove();\n\t\t\t// Remove the node from the queue\n\t\t\tthis.messageQueue.splice(this.messageQueue.indexOf(messageNode), 1);\n\t\t\tif (this.displayTimer)\n\t\t\t\tthis.displayTimer = window.clearTimeout(this.displayTimer);\n\t\t\tthis.displayNextMessage();\n\t\t}, delayTime);\n\t}\n\n\t/**\n\t * Removes the toast specified by `messageNode` from the DOM but not from the display queue.\n\t *\n\t * Use this function to interrupt a toast and display one of higher priority. The interrupted\n\t * toast is re-displayed by the next call to\n\t * [displayNextMessage](WebComponents.cq-message-toaster.html#displayNextMessage).\n\t *\n\t * @param messageNode The toast to recall.\n\t *\n\t * @alias recallMessageNode\n\t * @memberof WebComponents.cq-message-toaster#\n\t * @since 8.2.0\n\t */\n\trecallMessageNode(messageNode) {\n\t\tif (messageNode.isDisplayed) {\n\t\t\tif (this.displayTimer)\n\t\t\t\tthis.displayTimer = window.clearTimeout(this.displayTimer);\n\t\t\tmessageNode.isDisplayed = false;\n\t\t\tthis.context.topNode.removeChild(messageNode);\n\t\t}\n\t}\n\n\t/**\n\t * Creates a new toast and adds it to a queue that determines the display sequence of\n\t * concurrent toasts.\n\t *\n\t * This function is the \"notification\" event listener. See\n\t * [notificationEventListener]{@link CIQ.ChartEngine~notificationEventListener}.\n\t *\n\t * @param {object|string} notification Either an object containing data relevant to the\n\t * \t\tnotification event or a string that identifies a property of the `systemMessages`\n\t * \t\tproperty of the chart configuration object. The property contained in `systemMessages`\n\t * \t\tis an object literal that specifies data relevant to the notification event (see\n\t * \t\t\n\t * \t\tsystemMessages in the\n\t * \t\tChart Configuration\n\t * \t\ttutorial).\n\t * @param {string} notification.message Text to display in the toast notification. Strings\n\t * \t\tlonger than 160 characters are truncated.\n\t * @param {string} [notification.position=\"top\"] Position of the toast on the chart: \"top\" or\n\t * \t\t\"bottom\". Overrides the `defaultPosition` attribute of the\n\t * \t\t[``]{@link WebComponents.cq-message-toaster} element.\n\t * @param {string} [notification.type=\"info\"] Toast style: \"info\", \"error\", \"warning\", or\n\t * \t\t\"confirmation\". Overrides the `defaultTransition` attribute of the\n\t * \t\t[``]{@link WebComponents.cq-message-toaster} element.\n\t * @param {string} [notification.transition] Type of animation used to display and dismiss the\n\t * \t\ttoast: \"fade\", \"slide\", \"pop\" or \"drop\". The default is no transition.\n\t * @param {number} [notification.displayTime=10] Number of seconds to display the toast before\n\t * \t\tautomatically dismissing it. A value of 0 causes the toast to remain on\n\t * \t\tscreen — preventing other toasts from\n\t * \t\tdisplaying — until the toast is selected by the user. Overrides the\n\t * \t\t`defaultDisplayTime` attribute of the\n\t * \t\t[``]{@link WebComponents.cq-message-toaster} element.\n\t * @param {number} [notification.priority=0] Priority of the toast relative to others in the\n\t * \t\tdisplay queue. Higher priority toasts are displayed before toasts with lower priority.\n\t * \t\tFor example, a toast with priority = 4 is displayed before a toast with\n\t * \t\tpriority = 1. Toasts with the same priority are displayed in the order\n\t * \t\tthey were created; that is, in the order they entered the display queue.\n\t * @param {Function} [notification.callback] Function to call when the toast is selected\n\t * \t\t(dismissed) by the user. If the toast is dismissed automatically (see `displayTime`),\n\t * \t\tthis function is not called.\n\t *\n\t * @alias newMessage\n\t * @memberof WebComponents.cq-message-toaster#\n\t * @since\n\t * - 8.2.0\n\t * - 8.4.0 Calling this method with a message that is already displayed or in the queue\n\t * \t\twill return without doing anything.\n\t */\n\tnewMessage(notification) {\n\t\tif (typeof notification === \"string\" && this.context.config) {\n\t\t\tif (this.context.config.systemMessages)\n\t\t\t\tnotification = this.context.config.systemMessages[notification];\n\t\t}\n\t\tif (!notification) return;\n\t\tfor (const queueItem of this.messageQueue) {\n\t\t\tif (queueItem.message === notification.message) return;\n\t\t}\n\t\tlet newMessage = this.createMessageElement(notification);\n\t\tif (newMessage) {\n\t\t\t// Determine if the message priority places it ahead of other messages in the queue\n\t\t\tconst index = this.messageQueue.findIndex(\n\t\t\t\t(m) => m.priority < newMessage.priority\n\t\t\t);\n\t\t\tif (index >= 0) {\n\t\t\t\t// Recall the message if it's already displayed\n\t\t\t\tif (this.messageQueue[index].isDisplayed)\n\t\t\t\t\tthis.recallMessageNode(this.messageQueue[index]);\n\t\t\t\t// Inject the new priority message before the first non-priority message\n\t\t\t\tthis.messageQueue.splice(index, 0, newMessage);\n\t\t\t} else {\n\t\t\t\tthis.messageQueue.push(newMessage);\n\t\t\t}\n\t\t\tthis.displayNextMessage();\n\t\t}\n\t}\n\n\t/**\n\t * Dismisses a message by removing it from the queue (including if it is already displayed).\n\t *\n\t * @param {string} message The message to dismiss.\n\t * @alias dismissMessage\n\t * @memberof WebComponents.cq-message-toaster#\n\t * @since 8.4.0\n\t */\n\tdismissMessage(message) {\n\t\tfor (const notification of this.messageQueue) {\n\t\t\tif (notification.message === message) {\n\t\t\t\tthis.removeMessageNode(notification);\n\t\t\t}\n\t\t}\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-message-toaster\", MessageToaster);\n\n};\n\n\nlet __js_webcomponents_palette_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Provides a palette to dock alongside the chart or float above it. Palette components must be\n * placed within a `` component.\n *\n * @param {Boolean} docked The initial docked state of the palette.\n * @param {String} orientation Accepted values are \"horizontal\" and \"vertical\". Horizontal\n * \t\tpalettes dock to the left of the chart. Vertical palettes dock to the top.\n * @param {String} min-height Minimum height to display if not enough content.\n *\n * @namespace WebComponents.cq-palette\n * @since 7.2.0\n *\n * @example\n * \n *
\n *
\n * ...\n *
\n *
\n *
\n */\nclass Palette extends CIQ.UI.ContextTag {\n\tconstructor() {\n\t\tsuper();\n\n\t\tthis.dragMargin = 10; // number of px to constrain the draggable area within the chart.\n\t}\n\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tsuper.connectedCallback();\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, Palette);\n\t}\n\n\tinit() {\n\t\tthis.isDragging = false;\n\t\tthis.minHeight = parseInt(this.getAttribute(\"min-height\"), 10);\n\t\t// If the minimum height is not set, default to 25\n\t\tif (isNaN(this.minHeight)) {\n\t\t\tthis.minHeight = 25;\n\t\t}\n\t\tthis.paletteDock = this.parentElement.parentElement;\n\t\tthis.dragStrip = this.querySelector(\".drag-strip\");\n\t\tthis.resizeStrip = this.querySelector(\".resize-strip\");\n\n\t\t// Drag actions are managed by the palette dock\n\t\tif (this.dragStrip) {\n\t\t\tthis.dragStrip.addEventListener(\n\t\t\t\t\"mousedown\",\n\t\t\t\tthis.handleDragResize.bind(this, \"dragging\")\n\t\t\t);\n\n\t\t\tthis.dragStrip.addEventListener(\n\t\t\t\t\"touchstart\",\n\t\t\t\tthis.handleDragResize.bind(this, \"dragging\"),\n\t\t\t\t{ passive: false }\n\t\t\t);\n\t\t}\n\n\t\t// Resize actions are managed by the palette dock\n\t\tif (this.resizeStrip) {\n\t\t\tthis.resizeStrip.addEventListener(\n\t\t\t\t\"mousedown\",\n\t\t\t\tthis.handleDragResize.bind(this, \"resizing\")\n\t\t\t);\n\t\t\tthis.resizeStrip.addEventListener(\n\t\t\t\t\"touchstart\",\n\t\t\t\tthis.handleDragResize.bind(this, \"resizing\"),\n\t\t\t\t{ passive: false }\n\t\t\t);\n\t\t}\n\n\t\tif (this.paletteDock.paletteSubscribe) {\n\t\t\tthis.sendMessage = this.paletteDock.paletteSubscribe(\n\t\t\t\tthis.handleMessage.bind(this)\n\t\t\t);\n\t\t}\n\t}\n\n\tget hide() {\n\t\treturn this.getAttribute(\"hide\");\n\t}\n\n\tset hide(newValue) {\n\t\tthis.setAttribute(\"hide\", newValue);\n\t}\n\n\tget docked() {\n\t\treturn this.getAttribute(\"docked\");\n\t}\n\n\tset docked(newValue) {\n\t\tthis.setAttribute(\"docked\", newValue);\n\t}\n\n\tget orientation() {\n\t\treturn this.getAttribute(\"orientation\");\n\t}\n\n\tset orientation(newValue) {\n\t\tthis.setAttribute(\"orientation\", newValue);\n\t}\n\n\tstatic get observedAttributes() {\n\t\treturn [\"docked\", \"hide\"];\n\t}\n\n\tattributeChangedCallback(name, oldValue, newValue) {\n\t\tswitch (name) {\n\t\t\tcase \"docked\":\n\t\t\t\tif (newValue === \"false\") {\n\t\t\t\t\tthis.setTransform(100, 70);\n\t\t\t\t\tthis.setHeightByScale(0.8);\n\t\t\t\t} else {\n\t\t\t\t\tthis.style.transform = \"\";\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t}\n\t}\n\n\t// Sets dragging property in dock for this palette for mouse and touch events.\n\thandleDragResize(method, event) {\n\t\tif (this.paletteDock.hasOwnProperty(\"dragging\")) {\n\t\t\tthis.paletteDock.startDrag(this, method);\n\t\t}\n\t}\n\n\t// Overloaded by child objects to respond to messaging sent from other palettes\n\thandleMessage(id, message) {\n\t\treturn {\n\t\t\tid: id,\n\t\t\tmessage: message\n\t\t};\n\t}\n\n\tdetach(xPos, yPos) {\n\t\tlet breakSm = this.ownerDocument.body.classList.contains(\"break-sm\");\n\t\t// Never detach on small screens\n\t\tif (this.docked === \"true\" && !breakSm) {\n\t\t\tthis.docked = \"false\";\n\t\t\t// Set a safe default position when detaching\n\t\t\txPos = xPos || 10;\n\t\t\tyPos = yPos || 10;\n\n\t\t\t// Get the parent bounds to check position\n\t\t\tlet parentBounds = { top: 0, left: 0, width: 0, height: 0 };\n\t\t\tif (this.paletteDock.getBounds) {\n\t\t\t\tparentBounds = this.paletteDock.getChartBoundsOffset();\n\t\t\t}\n\t\t\t// When the palette is detached to a location, it should show all or most of its contents even if the location is close to the right edge\n\t\t\t// Check the position of the palette against the right bound of the parent\n\t\t\tif (xPos > parentBounds.left + parentBounds.width - this.clientWidth) {\n\t\t\t\txPos = parentBounds.left + parentBounds.width - this.clientWidth;\n\t\t\t}\n\t\t\t// Always set the position for instances where repositioning is necessary.\n\t\t\tthis.setTransformPosition(xPos, yPos);\n\t\t\tthis.paletteDock.setChartDimensions();\n\t\t\tthis.paletteDock.setVerticalPaletteHeight();\n\t\t}\n\t}\n\n\tdock() {\n\t\tif (this.docked === \"false\") {\n\t\t\tthis.docked = \"true\";\n\t\t\tthis.paletteDock.setChartDimensions();\n\t\t\tthis.paletteDock.setVerticalPaletteHeight();\n\t\t}\n\t}\n\n\tgetHeight() {\n\t\treturn this.clientHeight;\n\t}\n\n\tgetWidth() {\n\t\treturn this.clientWidth;\n\t}\n\n\t// Get the offset position of the palette and call setTransformPosition\n\t// to clamp the palette position in the event of a chartContainer resize\n\tcheckPosition() {\n\t\tlet parentBounds = { top: 0, left: 0, width: 0, height: 0 };\n\t\tif (this.paletteDock.getBounds) {\n\t\t\tparentBounds = this.paletteDock.getChartBoundsOffset();\n\t\t}\n\t\t// Get the xyz values in px\n\t\tconst transformValue = this.style.transform.match(/-?[0-9]{1,5}(?=px)/g);\n\t\t// Parse out the integer values from the style\n\t\tconst coordinates = transformValue.map(function (val) {\n\t\t\treturn parseInt(val);\n\t\t});\n\t\t// Apply the offsets normally produced by the mouse pointer. Nneeded to satisfy setTransformPosition\n\t\tcoordinates[0] += parentBounds.left + this.dragStrip.clientWidth * 0.5;\n\t\tcoordinates[1] += parentBounds.top + this.dragStrip.clientHeight * 0.5;\n\n\t\tthis.setTransformPosition(coordinates[0], coordinates[1]);\n\t}\n\n\t// Set the palette transform property based on mouse position\n\tsetTransformPosition(x, y) {\n\t\tlet parentBounds = { top: 0, left: 0, width: 0, height: 0 };\n\t\tif (this.paletteDock.getBounds) {\n\t\t\tparentBounds = this.paletteDock.getChartBoundsOffset();\n\t\t}\n\t\tlet nextTop = Math.floor(\n\t\t\ty - parentBounds.top - this.dragStrip.clientHeight * 0.5\n\t\t);\n\t\tlet nextLeft = Math.floor(\n\t\t\tx - parentBounds.left - this.dragStrip.clientWidth * 0.5\n\t\t);\n\n\t\t// Clamp the top position within chart bounds\n\t\tnextTop = Math.min(\n\t\t\tMath.max(nextTop, this.dragMargin),\n\t\t\tparentBounds.height - (this.dragStrip.clientHeight + this.dragMargin)\n\t\t);\n\t\t// Clamp the left position within chart bounds\n\t\tnextLeft = Math.min(\n\t\t\tMath.max(nextLeft, this.dragMargin),\n\t\t\tparentBounds.width - (this.dragStrip.clientWidth + this.dragMargin)\n\t\t);\n\n\t\tthis.setTransform(nextLeft, nextTop);\n\t}\n\n\t// Set the palette transform property explicitly\n\tsetTransform(x, y) {\n\t\tthis.style.transform = \"translate3d(\" + x + \"px,\" + y + \"px, 0px)\";\n\t}\n\n\t// Set the palette height property based on mouse position\n\tsetHeightToPosition(yPosition) {\n\t\tlet parentBounds = { top: 0, left: 0, width: 0, height: 0 };\n\t\tif (this.paletteDock.getBounds) {\n\t\t\tparentBounds = this.paletteDock.getBounds();\n\t\t}\n\n\t\tlet paletteViewportOffset = this.getBoundingClientRect();\n\t\tlet nextHeight = yPosition - paletteViewportOffset.top;\n\n\t\tif (this.orientation === \"vertical\") {\n\t\t\tif (\n\t\t\t\tnextHeight > this.minHeight &&\n\t\t\t\tnextHeight + (paletteViewportOffset.top - parentBounds.top) <\n\t\t\t\t\tparentBounds.height\n\t\t\t) {\n\t\t\t\tthis.setHeight(nextHeight);\n\t\t\t}\n\t\t}\n\t}\n\n\t// Set the palette height property relative to its current height property\n\tsetHeightByScale(scale) {\n\t\tthis.style.height =\n\t\t\tMath.floor(parseInt(this.style.height, 10) * scale) + \"px\";\n\t}\n\n\t// Set the palette height property explicitly\n\tsetHeight(nextHeight) {\n\t\tthis.style.height = nextHeight + \"px\";\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-palette\", Palette);\n\n};\n\n\nlet __js_webcomponents_paletteDock_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * A container for `` components. Provides docking and dragging capabilities to child\n * palettes.\n *\n * The `` element does not wrap the chart. It must be a sibling of the chart\n * container.\n *\n * @namespace WebComponents.cq-palette-dock\n * @since 7.2.0\n *\n * @example\n * \n *
\n * ...\n *
\n *
\n */\nclass PaletteDock extends CIQ.UI.ContextTag {\n\tconstructor() {\n\t\tsuper();\n\t\t//let shadowRoot = this.attachShadow({mode: 'open'});\n\t\t//shadowRoot.innerHTML = this.render();\n\n\t\tthis.dragging = false; /* pointer to the palette currently dragging */\n\t\tthis.paletteRegistry = [];\n\t\t// Use to store and cancel the mouseout check\n\t\tthis.mouseOutCk = false;\n\t}\n\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tsuper.connectedCallback();\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, PaletteDock);\n\t}\n\n\tinitListeners() {\n\t\tconst { stx, config = {} } = this.context;\n\t\tconst self = this;\n\t\tconst handleResize = self.handleResize.bind(this);\n\n\t\tthis.setVerticalPaletteHeight();\n\n\t\t// palette mouse events are handled here, on the parent, to prevent losing the event if the pointer moves off the palette\n\t\tthis.addEventListener(\"touchend\", (e) => this.stopDrag(e));\n\t\tthis.addEventListener(\"touchmove\", handleTouchMove, { passive: false });\n\n\t\tthis.addEventListener(\"mouseup\", (e) => this.stopDrag(e));\n\t\tthis.addEventListener(\"mouseleave\", handleMouseLeave);\n\t\tthis.addEventListener(\"mouseenter\", handleMouseEnter);\n\t\tthis.addEventListener(\"mousemove\", handleMouseMove);\n\n\t\t// Close a palette context menu when clicking anywhere over the chart\n\t\tthis.addEventListener(\"mousedown\", this.stopContext.bind(this));\n\n\t\t// respond to resizes, prevent loops\n\t\tstx.append(\"resizeChart\", () => handleResize({ resizeChart: false }));\n\n\t\tconst channel = (config.channels || {}).drawing || \"channel.drawing\";\n\t\tthis.channelSubscribe(channel, handleEnableDrawing);\n\n\t\tfunction handleMouseLeave(event) {\n\t\t\tself.context.stx.showCrosshairs();\n\t\t\t// An extra guard against spastic mousing.\n\t\t\t// Mouseout of the draggable area does not immediately cancel in case\n\t\t\t// the user unintentionally leaves the area for a brief moment\n\t\t\tself.mouseOutCk = setTimeout(() => self.stopDrag(), 500);\n\t\t}\n\n\t\tfunction handleMouseEnter(event) {\n\t\t\tself.context.stx.undisplayCrosshairs();\n\t\t\tif (!self.dragging) return;\n\n\t\t\t// Checking for a re-entry while the mouse button is still down\n\t\t\tif (event.buttons === 1) {\n\t\t\t\tclearTimeout(self.mouseOutCk);\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t// If all else fails, cancel the drag\n\t\t\tself.stopDrag();\n\t\t}\n\n\t\tfunction handleMouseMove(event) {\n\t\t\tif (self.dragging) {\n\t\t\t\tevent.stopPropagation();\n\t\t\t\tif (self.dragging.classList.contains(\"dragging\")) {\n\t\t\t\t\tself.dragging.setTransformPosition(event.clientX, event.clientY);\n\t\t\t\t}\n\t\t\t\tif (self.dragging.classList.contains(\"resizing\")) {\n\t\t\t\t\tself.dragging.setHeightToPosition(event.clientY);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tfunction handleTouchMove(event) {\n\t\t\tif (self.dragging && event.touches[0]) {\n\t\t\t\tevent.stopPropagation();\n\t\t\t\tif (self.dragging.classList.contains(\"dragging\")) {\n\t\t\t\t\tself.dragging.setTransformPosition(\n\t\t\t\t\t\tevent.touches[0].clientX,\n\t\t\t\t\t\tevent.touches[0].clientY\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t\tif (self.dragging.classList.contains(\"resizing\")) {\n\t\t\t\t\tself.dragging.setHeightToPosition(event.touches[0].clientY);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tfunction handleEnableDrawing(value) {\n\t\t\tself.setChartDimensions();\n\t\t\t// if (value) this.dockAllPalettes();\n\t\t\tstx.resizeChart();\n\t\t}\n\t}\n\n\tsetContext() {\n\t\tthis.initListeners();\n\t}\n\n\t// Provide a means for the dispirate palettes to communicate\n\tpalettePublish(id, message) {\n\t\tfor (\n\t\t\tvar paletteIdx = 0;\n\t\t\tpaletteIdx < this.paletteRegistry.length;\n\t\t\tpaletteIdx++\n\t\t) {\n\t\t\tthis.paletteRegistry[paletteIdx](id, message);\n\t\t}\n\t}\n\n\tpaletteSubscribe(paletteCallback) {\n\t\tthis.paletteRegistry.push(paletteCallback);\n\t\treturn this.palettePublish.bind(this);\n\t}\n\n\t// Get bounds of the chart container\n\tgetBounds() {\n\t\treturn this.parentNode.getBoundingClientRect();\n\t}\n\n\t// Get bounds of the chart within the chart container\n\tgetChartBounds() {\n\t\tlet clientBounds = this.parentNode.getBoundingClientRect();\n\t\tlet bounds = {\n\t\t\ttop: 0,\n\t\t\tleft: 0,\n\t\t\theight: clientBounds.height,\n\t\t\twidth: clientBounds.width\n\t\t};\n\n\t\tvar palettes = this.querySelectorAll('[docked=\"true\"]');\n\t\tfor (var paletteIdx = 0; paletteIdx < palettes.length; paletteIdx++) {\n\t\t\tvar palette = palettes[paletteIdx];\n\t\t\tif (palette.orientation === \"vertical\") {\n\t\t\t\tbounds.width -= palette.getWidth();\n\t\t\t\tbounds.left += palette.getWidth();\n\t\t\t} else if (palette.orientation === \"horizontal\") {\n\t\t\t\tbounds.height -= palette.getHeight();\n\t\t\t\tbounds.top += palette.getHeight();\n\t\t\t}\n\t\t}\n\t\treturn bounds;\n\t}\n\n\tgetChartBoundsOffset() {\n\t\tlet clientBounds = this.parentNode.getBoundingClientRect();\n\t\tlet bounds = this.getChartBounds();\n\n\t\tbounds.top += clientBounds.top;\n\t\tbounds.left += clientBounds.left;\n\n\t\treturn bounds;\n\t}\n\n\t// Handle the drawing palette contextual menu open state ti allow clicking anywhere over the chart to close\n\tstartContext() {\n\t\tthis.classList.add(\"context\");\n\t}\n\n\tstopContext() {\n\t\tthis.classList.remove(\"context\");\n\t\tthis.palettePublish(\"context\", \"stop\");\n\t}\n\n\t// Indicate a palette is presently in dragging mode\n\t// Extends overlay via css in dragging mode to capture mouse position\n\tstartDrag(palette, paletteMode) {\n\t\tvar palettes = this.querySelectorAll('[docked=\"false\"]');\n\t\tfor (var paletteIdx = 0; paletteIdx < palettes.length; paletteIdx++) {\n\t\t\tpalettes[paletteIdx].style.zIndex = 1; // Drop down any palettes which were previously bumped to the top of the z-index\n\t\t}\n\n\t\t// Default to dragging unless resizing is specified\n\t\tpaletteMode = paletteMode || \"dragging\";\n\t\tthis.dragging = palette;\n\t\t// The palette dock is always dragging regardless of the palette's mode\n\t\tthis.classList.add(\"dragging\");\n\t\tthis.dragging.classList.add(paletteMode);\n\t\tthis.dragging.style.zIndex = 10; // Bump the active palette to the top of the z-index\n\t}\n\n\tstopDrag(e) {\n\t\tif (e) e.preventDefault(); // prevent mouse event from firing if both touch and mouse are supported\n\t\tthis.classList.remove(\"dragging\");\n\t\tthis.dragging = false;\n\t\tthis.resizing = false;\n\t\tthis.node.find('[docked=\"false\"]').each(function () {\n\t\t\tthis.node.removeClass(\"dragging resizing\");\n\t\t});\n\t}\n\n\t// Indicate a palette is presently in resize mode\n\t// Extends overlay via css in dragging mode to capture mouse position\n\tstartResize(palette) {\n\t\tthis.resizing = palette;\n\t\tthis.classList.add(\"dragging\");\n\t\tthis.dragging.classList.add(\"dragging\");\n\t}\n\n\thandleResize({ resizeChart = true } = {}) {\n\t\t// Notify palettes that a resize is about to occur\n\t\tthis.palettePublish(\"dockWillResize\");\n\t\tthis.setChartDimensions();\n\t\tthis.setVerticalPaletteHeight();\n\n\t\tlet breakSm = this.ownerDocument.body.classList.contains(\"break-sm\");\n\t\t// Palettes can move out of view or the display context can change to mobile,\n\t\t// so adjust the floating palettes on resize\n\t\tvar palettes = this.querySelectorAll('[docked=\"false\"]');\n\t\tfor (var paletteIdx = 0; paletteIdx < palettes.length; paletteIdx++) {\n\t\t\tvar palette = palettes[paletteIdx];\n\t\t\tif (breakSm) {\n\t\t\t\t// If in the mobile context, double check that all palettes are docked\n\t\t\t\tpalette.dock();\n\t\t\t} else {\n\t\t\t\t// Set detached palettes positions equal to themselves. setTransformPosition will\n\t\t\t\t// check against the chart bounds and move the palette if it will go off-screen\n\t\t\t\tpalette.checkPosition();\n\t\t\t}\n\t\t}\n\n\t\t// Notify palettes that a resize has occured\n\t\tthis.palettePublish(\"dockDidResize\");\n\n\t\t// prevent loop as this function is can be invoked on resizeChart injection\n\t\tif (resizeChart) this.context.stx.resizeChart();\n\t}\n\n\tsetVerticalPaletteHeight() {\n\t\t// Set height of vertically oriented child palettes\n\t\tthis.node.find(\"[orientation=vertical]\").each(\n\t\t\tfunction (idx, elem) {\n\t\t\t\tif (elem.getAttribute(\"docked\") === \"true\") {\n\t\t\t\t\telem.style.height = this.parentNode.clientHeight + \"px\";\n\t\t\t\t}\n\t\t\t}.bind(this)\n\t\t);\n\t}\n\n\t// Resize chart to accommodate palette gutters\n\tsetChartDimensions() {\n\t\tconst chartContainer = this.context.stx.container;\n\t\tconst { top, left, width, height } = this.getChartBounds();\n\n\t\tconst { config } = this.context;\n\t\tif (config && config.channels) {\n\t\t\tthis.channelWrite(\n\t\t\t\tconfig.channels.drawingPalettes || \"channel.drawingPalettes\",\n\t\t\t\t{\n\t\t\t\t\ttop,\n\t\t\t\t\tleft,\n\t\t\t\t\twidth,\n\t\t\t\t\theight\n\t\t\t\t}\n\t\t\t);\n\t\t} else {\n\t\t\t// configuration not available support previous direct updates (React app using v7.3)\n\t\t\tchartContainer.style.width = width + \"px\";\n\t\t\tchartContainer.style.height = height + \"px\";\n\n\t\t\tchartContainer.style.top = top + \"px\";\n\t\t\tchartContainer.style.left = left + \"px\";\n\t\t}\n\n\t\t// Align any horizontal docked palettes with the chart left\n\t\tvar hPalettes = this.querySelectorAll('[orientation=\"horizontal\"]');\n\t\tfor (var hPaletteIdx = 0; hPaletteIdx < hPalettes.length; hPaletteIdx++) {\n\t\t\tvar hPalette = hPalettes[hPaletteIdx];\n\t\t\t// Offset horizontal palettes by the width of the vertical palettes\n\t\t\t// Add 1px for the border\n\t\t\thPalette.style.left = left + 1 + \"px\";\n\t\t\thPalette.style.width = width + \"px\";\n\t\t}\n\t\t// Align any vertical docked palettes with the chart left\n\t\tvar vPalettes = this.querySelectorAll('[orientation=\"vertical\"]');\n\t\tfor (var vPaletteIdx = 0; vPaletteIdx < vPalettes.length; vPaletteIdx++) {\n\t\t\tvar vPalette = vPalettes[vPaletteIdx];\n\t\t\t// Only offset vertical palettes when undocked. Docked vertical palettes are flush with the chart top edge.\n\t\t\tif (vPalette.docked === \"false\") {\n\t\t\t\tvPalette.style.top = top + \"px\";\n\t\t\t} else {\n\t\t\t\tvPalette.style.top = 0;\n\t\t\t}\n\t\t}\n\t}\n\n\tdockAllPalettes() {\n\t\tvar palettes = this.querySelectorAll('[docked=\"false\"]');\n\t\tfor (var paletteIdx = 0; paletteIdx < palettes.length; paletteIdx++) {\n\t\t\tpalettes[paletteIdx].dock();\n\t\t}\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-palette-dock\", PaletteDock);\n\n};\n\n\nlet __js_webcomponents_redo_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Redo web component ``.\n *\n * Pairs with {@link WebComponents.cq-undo} to redo changes to a drawing.\n *\n * @namespace WebComponents.cq-redo\n *\n * @example\n * \n * Undo\n * Redo\n * \n */\nclass Redo extends CIQ.UI.ContextTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, Redo);\n\t}\n\n\t/**\n\t * Finds {@link WebComponents.cq-undo} and pairs with it to find the last undo and reverse it.\n\t * @param {WebComponents.cq-undo} A cq-undo webcomponent\n\t * @alias pairUp\n\t * @memberof WebComponents.cq-redo\n\t * @example\n\t * document.querySelector(\"cq-redo\").pairUp(document.querySelector(\"cq-undo\"));\n\t */\n\tpairUp(undo) {\n\t\tthis.undo = undo;\n\t\tthis.undo.redoButton = this;\n\t\tvar self = this;\n\t\tCIQ.UI.stxtap(this, function () {\n\t\t\tself.undo.redo();\n\t\t});\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-redo\", Redo);\n\n};\n\n\nlet __js_webcomponents_scroll_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Scroll web component ``.\n *\n * The cq-scroll web component creates a scrollable container, which resizes itself when the screen\n * is resized. If CIQ.UI.scrollbarStyling is initialized to a scrollbar implementation (such as\n * PerfectScrollbar), the scrollbar implementation replaces the native scrollbar.\n *\n * **Keyboard control**\n *\n * When selected with tab key navigation and activated with Return/Enter, this component has the\n * following internal controls:\n * - Up/Down arrow — Move selection between internal cq-item elements.\n * - Left/Right arrow — Select a control within a selected cq-item element, such as\n * Remove and Edit buttons. Child elements must have the attribute `keyboard-selectable-child` set\n * to \"true\" to be selectable with these keys.\n *\n * **Attributes**\n * - cq-no-claim — Do not apply any keystroke capturing\n * - cq-no-maximize — Do not automatically maximize the height (but keep it showing on screen)\n * - cq-no-resize — Do not apply any sizing logic\n *\n * Use `this.dataPortion` to dynamically inject items into the list.\n *\n * @namespace WebComponents.cq-scroll\n * @since\n * - 6.1.0 Added `cq-no-claim` attribute.\n * - 8.3.0 Enabled internal keyboard navigation and selection.\n *\n * @example\n * \n * \n * ALL\n * STOCKS\n * FX\n * INDEXES\n * FUNDS\n * FUTURES\n * \n * \n * \n */\nclass Scroll extends CIQ.UI.BaseComponent {\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tsuper.connectedCallback();\n\t\tif (!this.hasAttribute(\"cq-no-claim\")) this.addClaim(this);\n\t\tif (this.hasAttribute(\"cq-no-scroll\")) return;\n\t\t// Setting CSS in constructor will throw exception when calling document.createElement (done in plugins)\n\t\t// So set default CSS here when connected instead.\n\t\tthis.style.overflowY = \"auto\";\n\t\tthis.uiManager = CIQ.UI.getUIManager(this);\n\t\tif (this.uiManager.length > 0) this.uiManager = this.uiManager[0];\n\n\t\t// prevent mousewheel event from propagating up to parents, such as when embedded\n\t\t// in a chart, e.g. comparison lookup component\n\t\tthis.addEventListener(\n\t\t\tCIQ.wheelEvent,\n\t\t\tfunction (e) {\n\t\t\t\te.stopPropagation();\n\t\t\t},\n\t\t\t{ passive: false }\n\t\t);\n\n\t\tvar self = this;\n\t\tCIQ.UI.addResizeListener(this, function () {\n\t\t\tself.resize();\n\t\t});\n\t\tthis.resize();\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, Scroll);\n\t}\n\n\tdisconnectedCallback() {\n\t\tif (this.doNotDisconnect) return;\n\t\tCIQ.UI.removeResizeListener(this);\n\t\tsuper.disconnectedCallback();\n\t}\n\n\t/**\n\t * Returns the focused element or null. An item is focused if it has\n\t * attribute cq-focused.\n\t * @return {HTMLElement} The element or null\n\t * @alias focused\n\t * @memberof WebComponents.cq-scroll\n\t */\n\tfocused() {\n\t\tvar focused = this.node.find(\"cq-item[cq-focused]\");\n\t\tif (focused.length) return focused[0];\n\t\treturn null;\n\t}\n\n\t/**\n\t * Scroll components can handle up and down enter keystrokes.\n\t * They do not register for claims directly. Another section of code must\n\t * establish the claim on their behalf or proxy the keystroke.\n\t *\n\t * Up and down arrows will iterate through cq-item tags. The attribute\n\t * cq-focused will be added to the currently focused tag. This can then be\n\t * queried later, such as when a user hits enter.\n\t *\n\t * space bar or enter will call the selectFC callback on the cq-item if it exists\n\t * @param {undefined} hub Unused parameter\n\t * @param {string} key Key that was stroked\n\t * @param {object} e The event object\n\t * @return {boolean}\n\t */\n\tkeyStroke(hub, key, e) {\n\t\tconst activeElements =\n\t\t\tthis.ownerDocument.querySelectorAll(\".stxMenuActive *\");\n\t\tif (\n\t\t\t!this.keyboardNavigation &&\n\t\t\t!Array.from(activeElements).includes(this)\n\t\t) {\n\t\t\treturn;\n\t\t}\n\t\tif (!CIQ.trulyVisible(this)) return false;\n\t\tif (this.keyboardNavigationWait && !this.keyboardNavigation) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst items = this.querySelectorAll(\n\t\t\t\"[keyboard-selectable='true'], cq-item:not(.item-hidden), li\"\n\t\t);\n\t\tif (!items.length) return;\n\n\t\tif (key == \" \" || key == \"Spacebar\" || key == \"Enter\") {\n\t\t\tconst focused = this.findFocused(items);\n\t\t\tif (!focused || !focused.length) return;\n\t\t\tconst childItemsSelected = focused[0].querySelectorAll(\n\t\t\t\t\"[keyboard-selectable-child='true'][cq-focused]\"\n\t\t\t);\n\t\t\tif (childItemsSelected.length) this.clickItem(childItemsSelected[0], e);\n\t\t\telse this.clickItem(focused[0], e);\n\t\t} else if (key == \"ArrowDown\" || key == \"Down\") {\n\t\t\tthis.focusNextItem(items);\n\t\t} else if (key == \"ArrowUp\" || key == \"Up\") {\n\t\t\tthis.focusNextItem(items, true);\n\t\t} else if (key == \"ArrowRight\" || key == \"Right\") {\n\t\t\tconst focused = this.findFocused(items);\n\t\t\tif (!focused || !focused.length) return;\n\t\t\tconst childItems = focused[0].querySelectorAll(\n\t\t\t\t\"[keyboard-selectable-child='true']\"\n\t\t\t);\n\t\t\tif (childItems.length) this.focusNextItem(childItems);\n\t\t} else if (key == \"ArrowLeft\" || key == \"Left\") {\n\t\t\tconst focused = this.findFocused(items)[0];\n\t\t\tif (!focused) return;\n\t\t\tconst childItems = focused.querySelectorAll(\n\t\t\t\t\"[keyboard-selectable-child='true']\"\n\t\t\t);\n\t\t\t// If the end of the child items has been reached select the parent item instead\n\t\t\tif (childItems.length && !this.focusNextItem(childItems, true)) {\n\t\t\t\tthis.removeFocused(childItems);\n\t\t\t\tthis.focusItem(focused);\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}\n\n\t/**\n\t * Overrides [focusItem](CIQ.UI.BaseComponent.html#focusItem) in\n\t * [CIQ.UI.BaseComponent]{@link CIQ.UI.BaseComponent}.\n\t *\n\t * Scrolls to an item and gives the item focus.\n\t *\n\t * @param {HTMLElement} item The element to scroll to and focus. Must be a child of this\n\t * component.\n\t *\n\t * @alias focusItem\n\t * @memberof WebComponents.cq-scroll#\n\t * @since 8.3.0\n\t */\n\tfocusItem(item) {\n\t\tthis.scrollToElement(item);\n\t\tsuper.focusItem(item);\n\t}\n\n\tonKeyboardDeselection() {\n\t\t// If we're using keyboard navigation, return the highlight to the tab selected element\n\t\tif (this.keyboardNavigation && this.keyboardNavigation !== null)\n\t\t\tthis.keyboardNavigation.highlightPosition();\n\t}\n\n\tresize() {\n\t\tvar node = this.node;\n\t\tvar context = CIQ.UI.getMyContext(this);\n\t\tif (node.parents(\".sharing\").length)\n\t\t\treturn; /*share.js appends this class to the body.\n\t\t\tDo not attempt unnecessary resize of scroll\n\t\t\tfor a chart about to become a shared image.*/\n\t\tif (this.hasAttribute(\"cq-no-resize\")) return;\n\t\tif (this.hasAttribute(\"cq-no-maximize\")) this.noMaximize = true;\n\t\tvar position = this.getBoundingClientRect();\n\t\tvar reduceMenuHeight = this.reduceMenuHeight || 45; // defaulted to 45 to take into account 15px of padding on menus and then an extra 5px for aesthetics\n\t\tvar contextHeight, contextTop;\n\t\tif (context && context.topNode) {\n\t\t\tvar contextRect = context.topNode.getBoundingClientRect();\n\t\t\tcontextHeight = contextRect.height;\n\t\t\tcontextTop = contextRect.top;\n\t\t} else {\n\t\t\t// Fallback to the window height if context element cannot be found\n\t\t\tcontextHeight = window.innerHeight;\n\t\t\tcontextTop = 0;\n\t\t}\n\t\tif (!contextHeight) return;\n\t\tvar height = contextHeight - (position.top - contextTop) - reduceMenuHeight;\n\t\tvar holders = node.parents(\".stx-holder,.stx-subholder,.chartContainer\");\n\t\tif (holders.length) {\n\t\t\tholders.each(function () {\n\t\t\t\tvar holderBottom =\n\t\t\t\t\tthis.getBoundingClientRect().top + CIQ.elementDimensions(this).height;\n\t\t\t\theight = Math.min(height, holderBottom - position.top - 5); // inside a holder we ignore reduceMenuHeight, but take off 5 pixels just for aesthetics\n\t\t\t});\n\t\t}\n\n\t\t// If there are subsequent siblings that have a fixed height then make room for them\n\t\tvar nextAll = node.nextAll();\n\t\tfor (var i = 0; i < nextAll.length; i++) {\n\t\t\tvar sibling = nextAll[i];\n\t\t\tif (sibling && !CIQ.trulyVisible(sibling)) continue; // skip hidden siblings\n\t\t\theight -= CIQ.elementDimensions(sibling, {\n\t\t\t\tborder: 1,\n\t\t\t\tpadding: 1,\n\t\t\t\tmargin: 1\n\t\t\t}).height;\n\t\t}\n\t\tif (!this.noMaximize) node.css({ height: height + \"px\" });\n\t\tnode.css({ \"max-height\": height + \"px\" });\n\t\tthis.refresh();\n\t}\n\n\t/**\n\t * Scrolls to an element.\n\t *\n\t * @param {HTMLElement} item The element to scroll to. Must be a child of this component.\n\t *\n\t * @alias scrollToElement\n\t * @memberof WebComponents.cq-scroll#\n\t */\n\tscrollToElement(item) {\n\t\tvar bottom = this.clientHeight,\n\t\t\tscrolled = this.scrollTop;\n\t\tvar itemBottom = item.offsetTop + item.clientHeight;\n\t\tif (item.offsetTop > scrolled && itemBottom < bottom + scrolled) return;\n\t\tthis.scrollTop = Math.max(itemBottom - bottom, 0);\n\t\tthis.refresh();\n\t}\n\n\t/**\n\t * Scroll back to top\n\t */\n\ttop() {\n\t\tthis.scrollTop = 0;\n\t\tthis.refresh();\n\t}\n\n\t/*\n\t * Refreshes the scrollbar, if CIQ.UI.scrollbarStyling is enabled.\n\t * @since 7.2.0\n\t */\n\trefresh() {\n\t\tif (CIQ.UI.scrollbarStyling) CIQ.UI.scrollbarStyling.refresh(this);\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-scroll\", Scroll);\n\n};\n\n\nlet __js_webcomponents_shareButton_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Share Button web component ``.\n *\n * @namespace WebComponents.cq-share-button\n *\n * @example\n * \n *
Share
\n *
\n */\nclass ShareButton extends CIQ.UI.ContextTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, ShareButton);\n\t\tthis.constructor = ShareButton;\n\t}\n\n\tsetContext() {\n\t\tthis.addDefaultMarkup();\n\t\tCIQ.safeClickTouch(this, () => this.tap());\n\t}\n\n\t/**\n\t * Opens a customizable dialog that can share a chart.\n\t * @alias tap\n\t * @memberof WebComponents.cq-share-button\n\t */\n\ttap(e) {\n\t\tconst { context } = this;\n\t\tif (context.config) {\n\t\t\tthis.channelWrite(\n\t\t\t\tcontext.config.channels.dialog,\n\t\t\t\t{ type: \"share\", params: { context } },\n\t\t\t\tcontext.stx\n\t\t\t);\n\t\t} else {\n\t\t\tconst shareDialog = this.ownerDocument.querySelector(\"cq-share-dialog\");\n\t\t\tif (shareDialog && shareDialog.open) shareDialog.open({ context });\n\t\t}\n\t}\n}\n\nShareButton.markup = \"
Share
\";\nCIQ.UI.addComponentDefinition(\"cq-share-button\", ShareButton);\n\n};\n\n\nlet __js_webcomponents_shareDialog_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nif (!CIQ.Share) {\n\tconsole.error(\n\t\t\"shareDialog component requires first activating share feature.\"\n\t);\n} else {\n\t/**\n\t * Share dialog web component ``.\n\t *\n\t * @namespace WebComponents.cq-share-dialog\n\t *\n\t * @example\n\t * \n\t * \n\t *

Share Your Chart

\n\t * \n\t *
\n\t * \n\t * Create Image\n\t * Generating Image\n\t * Uploading Image\n\t * \n\t * Copy Link to Clipboard\n\t * Link Copied!\n\t *
\n\t *
\n\t *
\n\t */\n\tclass ShareDialog extends CIQ.UI.DialogContentTag {\n\t\tadoptedCallback() {\n\t\t\tsuper.adoptedCallback();\n\t\t\tCIQ.UI.flattenInheritance(this, ShareDialog);\n\t\t\tthis.constructor = ShareDialog;\n\t\t}\n\n\t\topen(params) {\n\t\t\tthis.addDefaultMarkup();\n\t\t\tthis.setState(\"share-create\");\n\t\t\tsuper.open(params);\n\t\t}\n\n\t\tclose() {\n\t\t\tthis.setState(\"share-create\");\n\t\t\tsuper.close();\n\t\t}\n\n\t\tsetState(state) {\n\t\t\tthis.addDefaultMarkup();\n\t\t\tthis.node.find(\"div[cq-share-dialog-div]\")[0].className = state;\n\n\t\t\t// Set the main dialog as keyboard active to reset the highlight when this panel changes state\n\t\t\tif (this.ownerDocument.body.keystrokeHub) {\n\t\t\t\tlet { tabActiveModals } = this.ownerDocument.body.keystrokeHub;\n\t\t\t\tif (tabActiveModals[0])\n\t\t\t\t\tthis.ownerDocument.body.keystrokeHub.setKeyControlElement(\n\t\t\t\t\t\ttabActiveModals[0]\n\t\t\t\t\t);\n\t\t\t}\n\t\t}\n\n\t\t/**\n\t\t * Shares a chart with default parameters.\n\t\t *\n\t\t * @alias share\n\t\t * @memberof WebComponents.cq-share-dialog\n\t\t */\n\t\tshare() {\n\t\t\tvar stx = this.context.stx;\n\t\t\tvar self = this;\n\t\t\tself.setState(\"share-generate\");\n\t\t\tvar shareDialog = this.ownerDocument.querySelector(\n\t\t\t\t\"cq-share-dialog .share-link-div\"\n\t\t\t);\n\t\t\tif (shareDialog) shareDialog.innerHTML = \"\";\n\t\t\t// \"hide\" is a selector list, of DOM elements to be hidden while an image of the chart is created. \"cq-comparison-add-label\" and \".chartSize\" are hidden by default.\n\t\t\tCIQ.UI.bypassBindings = true;\n\t\t\tCIQ.Share.createImage(\n\t\t\t\tstx,\n\t\t\t\t{\n\t\t\t\t\thide: [\n\t\t\t\t\t\t\".stx_chart_controls\",\n\t\t\t\t\t\t\".stx-btn-panel\",\n\t\t\t\t\t\t\".stx_jump_today\",\n\t\t\t\t\t\t\".stx-baseline-handle\",\n\t\t\t\t\t\t\".ciq-edit\",\n\t\t\t\t\t\t\".ciq-close\",\n\t\t\t\t\t\t\"cq-marker-label\"\n\t\t\t\t\t]\n\t\t\t\t},\n\t\t\t\tfunction (data) {\n\t\t\t\t\tCIQ.UI.bypassBindings = false;\n\t\t\t\t\tvar id = CIQ.uniqueID();\n\t\t\t\t\tvar host = \"https://share.chartiq.com\";\n\t\t\t\t\tvar startOffset = stx.getStartDateOffset();\n\t\t\t\t\tvar metaData = {\n\t\t\t\t\t\tlayout: stx.exportLayout(),\n\t\t\t\t\t\tdrawings: stx.exportDrawings(),\n\t\t\t\t\t\txOffset: startOffset,\n\t\t\t\t\t\tstartDate: stx.chart.dataSegment[startOffset].Date,\n\t\t\t\t\t\tendDate:\n\t\t\t\t\t\t\tstx.chart.dataSegment[stx.chart.dataSegment.length - 1].Date,\n\t\t\t\t\t\tid: id,\n\t\t\t\t\t\tsymbol: stx.chart.symbol\n\t\t\t\t\t};\n\t\t\t\t\tvar url = host + \"/upload/\" + id;\n\t\t\t\t\tvar payload = { id: id, image: data, config: metaData };\n\t\t\t\t\tself.setState(\"share-upload\");\n\t\t\t\t\tCIQ.Share.uploadImage(data, url, payload, function (err, response) {\n\t\t\t\t\t\tself.setState(\"share-copy\");\n\t\t\t\t\t\tif (err !== null) {\n\t\t\t\t\t\t\tCIQ.alert(\"error: \" + err);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif (shareDialog) shareDialog.innerHTML = host + response;\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t);\n\t\t\t// Set the main dialog as keyboard active to reset the highlight when this panel reloads\n\t\t\tif (this.ownerDocument.body.keystrokeHub) {\n\t\t\t\tlet { tabActiveModals } = this.ownerDocument.body.keystrokeHub;\n\t\t\t\tif (tabActiveModals[0])\n\t\t\t\t\tthis.ownerDocument.body.keystrokeHub.setKeyControlElement(\n\t\t\t\t\t\ttabActiveModals[0]\n\t\t\t\t\t);\n\t\t\t}\n\t\t}\n\n\t\tcopy() {\n\t\t\tvar shareDialog = this.ownerDocument.querySelector(\n\t\t\t\t\"cq-share-dialog .share-link-div\"\n\t\t\t);\n\t\t\tif (!shareDialog) return;\n\t\t\tvar linkToCopy = shareDialog.innerText;\n\t\t\tvar tempInputElem = document.createElement(\"input\");\n\t\t\ttempInputElem.type = \"text\";\n\t\t\ttempInputElem.value = linkToCopy;\n\t\t\ttempInputElem.contentEditable = true;\n\t\t\ttempInputElem.readOnly = true;\n\t\t\tthis.ownerDocument.body.appendChild(tempInputElem);\n\t\t\ttempInputElem.focus();\n\t\t\ttempInputElem.select();\n\t\t\tif (!CIQ.isIE) {\n\t\t\t\tvar range = document.createRange();\n\t\t\t\trange.selectNodeContents(tempInputElem);\n\t\t\t\tvar s = window.getSelection();\n\t\t\t\ts.removeAllRanges();\n\t\t\t\ts.addRange(range);\n\t\t\t\ttempInputElem.setSelectionRange(0, linkToCopy.length);\n\t\t\t}\n\t\t\tthis.ownerDocument.execCommand(\"copy\");\n\t\t\tthis.ownerDocument.body.removeChild(tempInputElem);\n\t\t\tthis.setState(\"share-copied\");\n\t\t}\n\t}\n\n\tShareDialog.markup = `\n\t\t

Share Your Chart

\n\t\t\n\t\t
\n\t\t\t\n\t\t\tCreate Image\n\t\t\tGenerating Image\n\t\t\tUploading Image\n\t\t\t\n\t\t\tCopy Link to Clipboard\n\t\t\tLink Copied!\n\t`;\n\tCIQ.UI.addComponentDefinition(\"cq-share-dialog\", ShareDialog);\n}\n\n};\n\n\nlet __js_webcomponents_showRange_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Show Range web component ``.\n *\n * @namespace WebComponents.cq-show-range\n *\n * @example\n * \n *
1d
\n *
5d
\n *
1m
\n *
3m
\n *
6m
\n *
YTD
\n *
1y
\n *
5y
\n *
All
\n *
\n */\nclass ShowRange extends CIQ.UI.ContextTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, ShowRange);\n\t\tthis.constructor = ShowRange;\n\t}\n\n\t/**\n\t * Proxies UI requests for span changes to the chart engine.\n\t *\n\t * Usage Examples:\n\t * - `set(5,'day',30,2,'minute')` means that you want to combine two 30-minute bars into a single candle.\n\t * - So your quote feed must return one data object for every 30 minutes. A total of 2 data points per hour.\n\t * - `set(5,'day',2,30,'minute')` means that you want to combine thirty 2-minute bars into a single candle.\n\t * - So your quote feed must return one data object for every 2 minutes. A total of 30 data points per hour.\n\t * - `set(5,'day', 1, 60,'minute')` means that you want to combine sixty 1-minute bars into a single candle.\n\t * - So your quote feed must return one data object for every minute . A total of 60 data points per hour.\n\t * - `set(5,'day', 60, 1,'minute')` means that you want to have a single 60 minute bar per period.\n\t * - So your quote feed must return one data object for every 60 minutes . A total of 1 data point per hour.\n\t *\n\t * @param {Object} activator Activation information\n\t * @param {Number} multiplier The period that will be passed to {@link CIQ.ChartEngine#setSpan}\n\t * @param {Number} base The interval that will be passed to {@link CIQ.ChartEngine#setSpan}\n\t * @param {Number} [interval] Chart interval to use (leave empty for autodetect)\n\t * @param {Number} [period] Chart period to use (leave empty for autodetect)\n\t * @param {Number} [timeUnit] Chart timeUnit to use (leave empty for autodetect)\n\t * @alias set\n\t * @memberof WebComponents.cq-show-range\n\t * @since 5.1.1 timeUnit added\n\t */\n\tset(activator, multiplier, base, interval, period, timeUnit) {\n\t\tvar self = this;\n\t\tif (self.context.loader) self.context.loader.show();\n\t\tvar params = {\n\t\t\tmultiplier: multiplier,\n\t\t\tbase: base,\n\t\t\tpadding: 40\n\t\t};\n\t\tif (interval) {\n\t\t\tparams.periodicity = {\n\t\t\t\tinterval: interval,\n\t\t\t\tperiod: period ? period : 1,\n\t\t\t\ttimeUnit: timeUnit\n\t\t\t};\n\t\t}\n\t\tself.context.stx.setSpan(params, function () {\n\t\t\tif (self.context.loader) self.context.loader.hide();\n\t\t});\n\t}\n\n\tsetContext(context) {\n\t\tconst menuItems = context.config && context.config.getMenu(\"rangeMenu\");\n\t\tthis.addDefaultMarkup(this, menuItems && menuItems.join(\"\"));\n\t}\n}\n\nShowRange.markup = `\n\t\t
1D
\n\t\t
5D
\n\t\t
1M
\n\t\t
3M
\n\t\t
6M
\n\t\t
YTD
\n\t\t
1Y
\n\t\t
5Y
\n\t\t
All
\n\t`;\nCIQ.UI.addComponentDefinition(\"cq-show-range\", ShowRange);\n\n};\n\n\nlet __js_webcomponents_sideNav_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * The side navigation web component ``.\n *\n * Responds to the `breakpoint` and `sidenav` channels to control side navigation panel\n * availability.\n *\n * @namespace WebComponents.cq-side-nav\n * @since 7.5.0\n */\nclass SideNav extends CIQ.UI.ContextTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, SideNav);\n\t}\n\n\t/**\n\t * Subscribes to the `sidenav`, `breakpoint`, and `tfc` channels. Sets the side navigation\n\t * availability based on the contents of the channels.\n\t *\n\t * @param {object} params context Function parameters.\n\t * @param {object} params.config Chart configuration.\n\t * @param {object} params.config.channels The web component communication channels.\n\t * @param {CIQ.ChartEngine} [stx] A reference to the chart engine. Unused.\n\t *\n\t * @alias setContext\n\t * @memberof WebComponents.cq-side-nav\n\t * @since 7.5.0\n\t */\n\tsetContext({ config: { channels = {} } = {}, stx }) {\n\t\tconst node = this.querySelector(\"div\");\n\t\tconst isOn = this.getAttribute(\"cq-on\") || \"sidenavOn\";\n\t\tconst isOff = this.getAttribute(\"cq-off\") || \"sidenavOff\";\n\t\tconst breakpointChannel = channels.breakpoint || \"channel.breakpoint\";\n\t\tconst sidenavChannel = channels.sidenav || \"layout.sidenav\";\n\t\tconst sidenavSizeChannel = channels.sidenavSize || \"channel.sidenavSize\";\n\t\tconst tfcChannel = channels.tfc || \"channel.tfc\";\n\n\t\tconst setActive = () => {\n\t\t\tconst available = this.channelRead(breakpointChannel) === \"break-sm\";\n\t\t\tconst show = available && this.channelRead(sidenavChannel) === isOn;\n\n\t\t\tnode.classList.remove(\"sidenav\", \"ciq-toggles\");\n\t\t\tnode.classList.add(available ? \"sidenav\" : \"ciq-toggles\");\n\n\t\t\tnode.classList[show ? \"add\" : \"remove\"](\"active\");\n\n\t\t\tthis.channelWrite(\n\t\t\t\tsidenavSizeChannel,\n\t\t\t\tshow ? node.getBoundingClientRect().width : 0\n\t\t\t);\n\t\t};\n\n\t\tthis.channelSubscribe(sidenavChannel, setActive);\n\t\tthis.channelSubscribe(breakpointChannel, setActive);\n\t\tthis.channelSubscribe(tfcChannel, (isActive) => {\n\t\t\tif (isActive) this.channelWrite(sidenavChannel, isOff);\n\t\t});\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-side-nav\", SideNav);\n\n};\n\n\nlet __js_webcomponents_sidePanel_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Side Panel web component ``.\n *\n * @namespace WebComponents.cq-side-panel\n *\n * @example\n * \n */\nclass SidePanel extends CIQ.UI.ContextTag {\n\tconstructor() {\n\t\tsuper();\n\t\tthis.callbacks = [];\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, SidePanel);\n\t}\n\n\tsetContext(context) {\n\t\tconst { config, stx } = context;\n\t\tif (!config) return;\n\n\t\tconst { channels = {} } = config;\n\t\tconst resizeHandler = this.resizeMyself.bind(this);\n\t\tconst { node } = this;\n\n\t\tthis.channelSubscribe(\n\t\t\tchannels.breakpoint || \"channel.breakpoint\",\n\t\t\thandleSizeChanges\n\t\t);\n\t\tthis.channelSubscribe(channels.tfc || \"channel.tfc\", handleTfcOpen, stx);\n\n\t\tfunction handleSizeChanges() {\n\t\t\tsetTimeout(resizeHandler);\n\t\t}\n\n\t\tfunction handleTfcOpen(isOpen) {\n\t\t\tif (isOpen) node.attr(\"cq-active\", true);\n\t\t\telse node.removeAttr(\"cq-active\");\n\n\t\t\thandleSizeChanges();\n\t\t}\n\t}\n\n\tclose() {\n\t\tthis.node.removeAttr(\"cq-active\");\n\t\tvar children = this.node.children();\n\t\tchildren.each(function () {\n\t\t\tif (this.sidePanelActiveClass)\n\t\t\t\tthis.classList.remove(this.sidePanelActiveClass);\n\t\t\t// turn off a child by removing the class name added to it\n\t\t\telse this.removeAttribute(this.sidePanelActiveAttribute); // turn off a child by removing the attribute name added to it\n\t\t});\n\t\tvar self = this;\n\t\tsetTimeout(function () {\n\t\t\tself.resizeMyself();\n\t\t}, 0);\n\t}\n\n\t/**\n\t * Use this method to get the width instead of querying the node directly because the side panel may be animated.\n\t * @return {number} The width\n\t */\n\tnonAnimatedWidth() {\n\t\tvar width = 0;\n\t\tArray.from(this.children).forEach(function (child) {\n\t\t\twidth += CIQ.elementDimensions(child).width;\n\t\t}); // accumulate width of all children\n\t\treturn width;\n\t}\n\n\t/**\n\t * Opens a side panel to show more options in mobile.\n\t * @param {Object} params Parameters\n\t * @param {string} params.selector The selector for which child to enable\n\t * @param {string} [params.className] The class name to add to turn on the panel\n\t * @param {string} [params.attribute] The attribute to add to turn on the panel\n\t * @alias open\n\t * @memberof WebComponents.cq-side-panel\n\t */\n\topen(params) {\n\t\tthis.close();\n\t\tvar children = this.node.find(params.selector);\n\t\tif (params.className) {\n\t\t\tchildren.addClass(params.className);\n\t\t\tchildren.each(function () {\n\t\t\t\tthis.sidePanelActiveClass = params.className; // store the class name used to turn it on\n\t\t\t});\n\t\t} else {\n\t\t\tchildren.attr(params.attribute, \"true\");\n\t\t\tchildren.each(function () {\n\t\t\t\tthis.sidePanelActiveAttribute = params.attribute; // store the attribute name used to turn it on\n\t\t\t});\n\t\t}\n\t\tthis.node.attr(\"cq-active\", \"true\");\n\t\tvar self = this;\n\t\tsetTimeout(function () {\n\t\t\tself.resizeMyself();\n\t\t}, 0);\n\t}\n\n\tregisterCallback(fc) {\n\t\tthis.callbacks.push(fc);\n\t}\n\n\tresizeMyself() {\n\t\tvar width = this.nonAnimatedWidth();\n\t\tthis.node.css({ width: width + \"px\" }); // expand the side panel\n\t\tfor (\n\t\t\tvar i = 0;\n\t\t\ti < this.callbacks.length;\n\t\t\ti++ // let any callbacks know that we've been resized\n\t\t)\n\t\t\tthis.callbacks[i].call(this, width);\n\n\t\t// channel notification\n\t\tconst { config, stx } = this.context || {};\n\t\tif (!config) return;\n\t\tconst channel =\n\t\t\t(config.channels || {}).sidepanelSize || \"channel.sidepanelSize\";\n\t\tthis.channelWrite(channel, width, stx);\n\t}\n}\n\n/**\n * A side panel contains children that should be enabled by calling open({selector:selector}).\n */\nCIQ.UI.addComponentDefinition(\"cq-side-panel\", SidePanel);\n\n};\n\n\nlet __js_webcomponents_studies_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Studies list web component ``.\n *\n * Lists all studies contained in the study library, {@link CIQ.Studies.studyLibrary}.\n *\n * @namespace WebComponents.cq-studies\n * @since 5.2.0\n *\n * @example\n * \n * Studies\n * \n * \n * \n * Current Studies\n * \n * \n * \n * \n *
Clear All
\n *
\n *
\n *
\n * \n * \n * \n * \n * \n * \n * \n *
\n *
\n */\nclass Studies extends CIQ.UI.ContextTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, Studies);\n\t\tthis.constructor = Studies;\n\t}\n\n\tdisconnectedCallback() {\n\t\tif (this.context) {\n\t\t\tCIQ.UI.unobserveProperty(\n\t\t\t\t\"studyLibraryHash\",\n\t\t\t\tthis.context.stx.chart,\n\t\t\t\tthis.listener\n\t\t\t);\n\t\t}\n\t\tsuper.disconnectedCallback();\n\t}\n\n\t/**\n\t * Initializes and displays the list of available studies.\n\t *\n\t * @param {object} [params] Parameters to control initialization of the studies list.\n\t * @param {object} [params.excludedStudies] A map of study names that should be excluded from\n\t * \t\tthe studies list, for example: { \"macd\": true }.\n\t * @param {object|boolean} [params.alwaysDisplayDialog=false] If set to boolean true (not\n\t * \t\ttruthy), the study edit dialog box is automatically opened for any of the available\n\t * \t\tstudies after the study has been added to the chart. If set to boolean false, the\n\t * \t\tstudy edit dialog box is not opened for any of the available studies after the study\n\t * \t\thas been added to the chart.\n\t * \t\t

If set to an object containing a map of study names and boolean values (for example,\n\t * \t\t{ \"ma\": true, \"AVWAP\": true }), the study edit\n\t * \t\tdialog box is opened after the study has been added to the chart for studies in the\n\t * \t\tmap that have a boolean value of true but not for those that have a value of false or\n\t * \t\tfor any studies not included in the map.\n\t * @param {object|boolean} [params.dialogBeforeAddingStudy=false] If set to boolean true (not\n\t * \t\ttruthy), the study edit dialog box is automatically opened for any of the available\n\t * \t\tstudies before the study is added to the chart. If set to boolean false, the study\n\t * \t\tedit dialog box is not opened for any of the available studies before the study is\n\t * \t\tadded to the chart.\n\t * \t\t

If set to an object containing a map of study names and boolean values (for example,\n\t * \t\t{ \"macd\": true }), the study edit dialog box is opened\n\t * \t\tbefore the study is added to the chart for studies in the map that have a boolean value\n\t * \t\tof true but not for those that have a value of false or for any studies not included\n\t * \t\tin the map.\n\t *\n\t * @alias initialize\n\t * @memberof WebComponents.cq-studies\n\t * @since 5.2.0 The `CIQ.UI.StudyMenu` helper has been deprecated. Please call\n\t * \t\t`document.querySelector(\"cq-studies\").initialize()` now.\n\t *\n\t * @example\n\t * let params = {\n\t * excludedStudies: { \"macd\": true }, // Exclude studies from the list of available studies.\n\t * alwaysDisplayDialog: { \"ma\": true }, // Show the study preferences dialog after adding studies.\n\t * dialogBeforeAddingStudy: { \"rsi\": true } // Show the study preferences dialog before adding studies.\n\t * };\n\t * document.querySelectorAll(\"cq-studies\").forEach(function(i) {\n\t * i.initialize(params);\n\t * });\n\t */\n\tinitialize(params) {\n\t\tthis.addDefaultMarkup();\n\t\tthis.params = params || {};\n\t\tthis.alwaysDisplayDialog = this.params.alwaysDisplayDialog || false;\n\t\tthis.excludedStudies = this.params.excludedStudies || [];\n\t\tif (!this.params.template) this.params.template = \"template\";\n\t\tthis.params.template = this.node.find(this.params.template);\n\t\tthis.renderMenu();\n\n\t\tvar self = this,\n\t\t\tstx = this.context.stx;\n\t\tthis.listener = function (obj) {\n\t\t\tself.renderMenu();\n\t\t};\n\t\tCIQ.UI.observeProperty(\"studyLibraryHash\", stx.chart, this.listener);\n\t}\n\n\tsetContext({ config }) {\n\t\tif (config && config.menuStudiesConfig) {\n\t\t\tthis.initialize(Object.assign({}, config.menuStudiesConfig));\n\t\t}\n\t}\n\n\t/**\n\t * Creates a list of studies in a `` element.\n\t *\n\t * You have the option of creating a hardcoded HTML menu and just using {@link CIQ.Studies}\n\t * for processing `stxtap` attributes, or you can call this method to automatically generate\n\t * the menu.\n\t *\n\t * @alias renderMenu\n\t * @memberof WebComponents.cq-studies\n\t */\n\trenderMenu() {\n\t\tif (!CIQ.Studies) return;\n\t\tvar stx = this.context.stx;\n\t\tvar alphabetized = [];\n\t\tvar sd;\n\n\t\tfor (var field in CIQ.Studies.studyLibrary) {\n\t\t\tsd = CIQ.Studies.studyLibrary[field];\n\t\t\tif (\n\t\t\t\t!sd ||\n\t\t\t\tthis.excludedStudies[field] ||\n\t\t\t\tthis.excludedStudies[sd.name] ||\n\t\t\t\tsd.siqList !== undefined\n\t\t\t)\n\t\t\t\tcontinue; // siqList = ScriptIQ entry\n\t\t\tif (!sd.name) sd.name = field; // Make sure there's always a name\n\t\t\talphabetized.push(field);\n\t\t}\n\t\talphabetized.sort(function (lhs, rhs) {\n\t\t\tvar lsd = CIQ.Studies.studyLibrary[lhs];\n\t\t\tvar rsd = CIQ.Studies.studyLibrary[rhs];\n\t\t\tif (lsd.name < rsd.name) return -1;\n\t\t\tif (lsd.name > rsd.name) return 1;\n\t\t\treturn 0;\n\t\t});\n\t\tvar menu = this.node;\n\t\tvar self = this;\n\t\tvar tapFn = function (studyName, context) {\n\t\t\treturn function (e) {\n\t\t\t\tpickStudy(e.target, studyName);\n\t\t\t\tself.dispatchEvent(new Event(\"resize\"));\n\t\t\t};\n\t\t};\n\n\t\tvar contentNode = menu.find(\"cq-studies-content\");\n\t\twhile (contentNode.length > 0 && contentNode[0].firstChild) {\n\t\t\tcontentNode[0].removeChild(contentNode[0].firstChild);\n\t\t}\n\n\t\tfor (var i = 0; i < alphabetized.length; i++) {\n\t\t\tvar menuItem = CIQ.UI.makeFromTemplate(this.params.template);\n\t\t\tsd = CIQ.Studies.studyLibrary[alphabetized[i]];\n\t\t\tmenuItem.append(CIQ.translatableTextNode(stx, sd.name));\n\t\t\tthis.makeTap(menuItem[0], tapFn(alphabetized[i], this.context));\n\t\t\tmenu.find(\"cq-studies-content\").append(menuItem);\n\t\t}\n\n\t\tfunction studyDialog(params, addWhenDone) {\n\t\t\tconst { context } = self;\n\n\t\t\tif (context.config) {\n\t\t\t\tself.channelWrite(\n\t\t\t\t\tcontext.config.channels.dialog,\n\t\t\t\t\t{\n\t\t\t\t\t\ttype: \"study\",\n\t\t\t\t\t\tparams: Object.assign({}, params, { context, addWhenDone })\n\t\t\t\t\t},\n\t\t\t\t\tcontext.stx\n\t\t\t\t);\n\t\t\t} else {\n\t\t\t\t// legacy use when config is not available\n\t\t\t\tparams.context = self.context;\n\t\t\t\tconst dialog = self.ownerDocument.querySelector(\"cq-study-dialog\");\n\t\t\t\tdialog.addWhenDone = addWhenDone;\n\t\t\t\tdialog.open(params);\n\t\t\t}\n\t\t}\n\n\t\tfunction pickStudy(node, studyName) {\n\t\t\tconst {\n\t\t\t\talwaysDisplayDialog = {},\n\t\t\t\tcontext: { stx }\n\t\t\t} = self;\n\n\t\t\tfunction handleSpecialCase(flag, params, addWhenDone) {\n\t\t\t\tif (flag === true) {\n\t\t\t\t\tstudyDialog(params, addWhenDone);\n\t\t\t\t\treturn true;\n\t\t\t\t} else if (typeof flag === \"object\") {\n\t\t\t\t\tfor (let i in flag) {\n\t\t\t\t\t\tif (i == studyName && flag[i]) {\n\t\t\t\t\t\t\tstudyDialog(params, addWhenDone);\n\t\t\t\t\t\t\treturn true;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (\n\t\t\t\thandleSpecialCase(\n\t\t\t\t\tself.params.dialogBeforeAddingStudy,\n\t\t\t\t\t{ stx, name: studyName },\n\t\t\t\t\ttrue\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst studyParams = alwaysDisplayDialog[studyName]\n\t\t\t\t? { interactiveAdd: false } // interactiveAdd and dialog are not compatible\n\t\t\t\t: null;\n\t\t\tconst sd = CIQ.Studies.addStudy(stx, studyName, null, null, studyParams);\n\n\t\t\thandleSpecialCase(self.alwaysDisplayDialog, { sd, stx });\n\t\t}\n\t}\n}\n\nStudies.markup = `\n\t\t\n\t\t\n\t`;\nCIQ.UI.addComponentDefinition(\"cq-studies\", Studies);\n\n};\n\n\nlet __js_webcomponents_studyContext_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Study Context Dialog web component ``.\n *\n * @namespace WebComponents.cq-study-context\n * @since 4.1.0 cq-study-context is now required (cq-dialog[cq-study-context] no longer works)\n */\nclass StudyContext extends CIQ.UI.DialogContentTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, StudyContext);\n\t\tthis.constructor = StudyContext;\n\t}\n\n\tsetContext(context) {\n\t\tthis.addDefaultMarkup();\n\t\tthis.classList.add(\"ciq-context-menu\");\n\t\tsuper.setContext(context);\n\t}\n}\n\nStudyContext.markup = `\n\t\t

Edit Settings...
\n\t\t
Delete Study
\n\t`;\nCIQ.UI.addComponentDefinition(\"cq-study-context\", StudyContext);\n\n};\n\n\nlet __js_webcomponents_studyDialog_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\n\n\n\n\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nif (!CIQ.Studies) {\n\tconsole.error(\n\t\t\"studyDialog component requires first activating studies feature.\"\n\t);\n} else {\n\t/**\n\t * Study dialogs web component ``.\n\t *\n\t * Creates and manages study dialogs based on the corresponding study library entry (title,\n\t * inputs, outputs, parameters, etc.).\n\t *\n\t * Requires {@link CIQ.UI.StudyEdit}.\n\t *\n\t * Optional Attributes:\n\t * - `cq-study-axis` — Displays UI for selecting the y-axisposition (left, right, etc.),\n\t * color and for inverting the y-axis *if not shared with the primary-axis*.\n\t * - `cq-study-panel` — Displays UI for selecting the panel for the study (own, shared,\n\t * etc.) and whether it is rendered as an underlay (under the primary chart) or an overlay\n\t * (over the primary chart). Set this attribute to \"alias\" to have the panel names listed as\n\t * \"\", \"\", etc.\n\t *\n\t * @namespace WebComponents.cq-study-dialog\n\t * @since\n\t * - 5.2.0 Optional Attributes `cq-study-axis` and `cq-study-panel` are now available.\n\t * - 6.3.0 `cq-study-axis` now also provides a check box allowing users to invert study y-axis\n\t * \t\tif not shared with the primary-axis.\n\t *\n\t * @example Here is an example of how to create a study dialog. We add the\n\t * cq-study-axis and cq-study-panel attributes to enable form fields\n\t * used to control axis position, color, study panel, and underlay/overlay.\n\t * \n\t * \n\t * \n\t *

Study

\n\t * \n\t * \n\t * \n\t * \n\t *
\n\t * \n\t * \n\t * \n\t *
\n\t * \n\t * \n\t * \n\t *
\n\t *
\n\t *
Done
\n\t *
\n\t *
\n\t *
\n\t */\n\tclass StudyDialog extends CIQ.UI.DialogContentTag {\n\t\tconnectedCallback() {\n\t\t\tif (this.attached) return;\n\t\t\tsuper.connectedCallback();\n\t\t\tthis.queuedUpdates = {};\n\t\t}\n\n\t\tclose() {\n\t\t\tif (this.addWhenDone) {\n\t\t\t\tvar helper = this.helper;\n\t\t\t\tvar sd = CIQ.Studies.addStudy(helper.stx, helper.name);\n\t\t\t\tif (!CIQ.isEmpty(this.queuedUpdates)) {\n\t\t\t\t\thelper.sd = sd;\n\t\t\t\t\thelper.updateStudy(this.queuedUpdates);\n\t\t\t\t\tthis.queuedUpdates = {};\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tcloseActiveMenu(node) {\n\t\t\tconst hub = this.ownerDocument.body.keystrokeHub;\n\t\t\tconst activeMenu = this.querySelector(\"*.stxMenuActive\");\n\t\t\tconst uiManager = CIQ.UI.getUIManager(this);\n\t\t\tif (\n\t\t\t\t!activeMenu ||\n\t\t\t\t!hub ||\n\t\t\t\t!hub.tabActiveElement ||\n\t\t\t\thub.tabActiveElement.element !== node\n\t\t\t)\n\t\t\t\treturn;\n\t\t\thub.tabActiveElement = null;\n\t\t\thub.highlightHide();\n\t\t\tuiManager.closeMenu(activeMenu);\n\t\t}\n\n\t\tadoptedCallback() {\n\t\t\tsuper.adoptedCallback();\n\t\t\tCIQ.UI.flattenInheritance(this, StudyDialog);\n\t\t\tthis.constructor = StudyDialog;\n\t\t}\n\n\t\tdisconnectedCallback() {\n\t\t\tCIQ.UI.unobserveProperty(\"signal\", this.helper);\n\t\t\tsuper.disconnectedCallback();\n\t\t}\n\n\t\tformatDateInput(date) {\n\t\t\tdate = date.replace(/-/g, \"\");\n\t\t\tif (!date.search(/^\\d{8}$/))\n\t\t\t\tdate =\n\t\t\t\t\tdate.substring(0, 4) +\n\t\t\t\t\t\"-\" +\n\t\t\t\t\tdate.substring(4, 6) +\n\t\t\t\t\t\"-\" +\n\t\t\t\t\tdate.substring(6, 8);\n\t\t\treturn date;\n\t\t}\n\n\t\tformatTimeInput(time) {\n\t\t\ttime = time.replace(/:/g, \"\");\n\t\t\tif (!time.search(/^\\d{4,6}$/))\n\t\t\t\ttime =\n\t\t\t\t\ttime.substring(0, 2) +\n\t\t\t\t\t\":\" +\n\t\t\t\t\ttime.substring(2, 4) +\n\t\t\t\t\t(time.length == 4 ? \"\" : \":\" + time.substring(4, 6));\n\t\t\treturn time;\n\t\t}\n\n\t\thide() {\n\t\t\tif (!CIQ.isEmpty(this.queuedUpdates)) {\n\t\t\t\tthis.helper.updateStudy(this.queuedUpdates);\n\t\t\t\tthis.queuedUpdates = {};\n\t\t\t}\n\t\t\tthis.node.find(\"cq-menu\").each(function () {\n\t\t\t\tif (this.unlift) this.unlift();\n\t\t\t});\n\t\t\tthis.node.find(\"cq-swatch\").each(function () {\n\t\t\t\tif (this.colorPicker) this.colorPicker.close();\n\t\t\t});\n\t\t}\n\n\t\tmakeMenu(name, currentValue, fields, section) {\n\t\t\tvar menu = CIQ.UI.makeFromTemplate(this.menuTemplate);\n\t\t\tvar cqMenu = menu.find(\"cq-menu-dropdown\"); // scrollable in menu.\n\t\t\tfor (var field in fields) {\n\t\t\t\tvar item = document.createElement(\"cq-item\");\n\t\t\t\titem.innerText = fields[field];\n\t\t\t\titem.setAttribute(\n\t\t\t\t\t\"stxtap\",\n\t\t\t\t\t\"StudyDialog.setSelectOption('\" + section + \"')\"\n\t\t\t\t); // must call StudyDialog because the item is \"lifted\" and so doesn't know its parent\n\t\t\t\tcqMenu.append(item);\n\t\t\t\titem.cqMenuWrapper = cqMenu.parents(\"cq-menu\")[0];\n\t\t\t\titem.setAttribute(\"name\", name);\n\t\t\t\titem.setAttribute(\"value\", field);\n\t\t\t\titem.context = this.context;\n\t\t\t}\n\t\t\tvar inputValue = menu.find(\"cq-selected\");\n\t\t\tinputValue.text(this.helper.stx.translateIf(currentValue));\n\t\t\treturn menu[0];\n\t\t}\n\n\t\topen(params) {\n\t\t\tthis.addDefaultMarkup();\n\t\t\tthis.selectTemplates();\n\n\t\t\tsuper.open(params);\n\t\t\tif (!(\"axisSelect\" in params)) {\n\t\t\t\tparams.axisSelect = this.getAttribute(\"cq-study-axis\");\n\t\t\t\tif (params.axisSelect === \"\") params.axisSelect = true;\n\t\t\t}\n\t\t\tif (!(\"panelSelect\" in params)) {\n\t\t\t\tparams.panelSelect = this.getAttribute(\"cq-study-panel\");\n\t\t\t\tif (params.panelSelect === \"\") params.panelSelect = true;\n\t\t\t}\n\n\t\t\tif (typeof params.addWhenDone !== \"undefined\")\n\t\t\t\tthis.addWhenDone = params.addWhenDone;\n\t\t\t// Generate a \"helper\" which tells us how to create a dialog\n\t\t\tvar self = this,\n\t\t\t\tstx = this.context.stx;\n\t\t\tCIQ.UI.unobserveProperty(\"signal\", this.helper);\n\t\t\tthis.helper = new CIQ.Studies.DialogHelper(params);\n\t\t\tCIQ.UI.observeProperty(\"signal\", this.helper, function (obj) {\n\t\t\t\tself.refreshInputs();\n\t\t\t\tself.refreshOutputs();\n\t\t\t\tself.refreshParameters(params);\n\t\t\t});\n\n\t\t\tvar dialog = this.node;\n\n\t\t\tdialog.find(\".title\").text(this.helper.title);\n\n\t\t\t// Create form elements for all of the inputs\n\t\t\tthis.refreshInputs(true);\n\n\t\t\t// Create form elements for all of the outputs\n\t\t\tthis.refreshOutputs(true);\n\n\t\t\t// Create form elements for all of the parameters\n\t\t\tthis.refreshParameters(params, true);\n\t\t}\n\n\t\trefreshInputs(empty) {\n\t\t\tvar inputs = this.node.find(\"cq-study-inputs\");\n\t\t\tif (empty) inputs.empty();\n\t\t\tfor (var i = 0; i < this.helper.inputs.length; i++) {\n\t\t\t\tvar input = this.helper.inputs[i];\n\t\t\t\tvar newInput = CIQ.UI.makeFromTemplate(this.inputTemplate);\n\t\t\t\tthis.menuTemplate = newInput.find(\"template[cq-menu]\");\n\t\t\t\tnewInput.find(\".ciq-heading\").text(input.heading);\n\t\t\t\tnewInput[0].setAttribute(\"fieldname\", input.name);\n\t\t\t\tvar formField = null;\n\n\t\t\t\tvar iAttr;\n\t\t\t\tvar attributes = this.helper.attributes[input.name];\n\t\t\t\tif (input.type == \"number\") {\n\t\t\t\t\tformField = document.createElement(\"input\");\n\t\t\t\t\tformField.setAttribute(\"type\", \"number\");\n\t\t\t\t\tformField.value = input.value;\n\t\t\t\t\tthis.setChangeEvent(formField, \"inputs\", input.name);\n\t\t\t\t\tfor (iAttr in attributes) {\n\t\t\t\t\t\tvar iAttrVal = attributes[iAttr];\n\t\t\t\t\t\t// poor IE/Edge can't perform decimal step validation properly, so we need to change step to any and give up the neat step effect\n\t\t\t\t\t\tif (\n\t\t\t\t\t\t\t(CIQ.isIE || CIQ.isEdge) &&\n\t\t\t\t\t\t\tiAttr == \"step\" &&\n\t\t\t\t\t\t\tMath.floor(iAttrVal) != iAttrVal\n\t\t\t\t\t\t)\n\t\t\t\t\t\t\tiAttrVal = \"any\";\n\t\t\t\t\t\tif (iAttr !== \"hidden\") formField.setAttribute(iAttr, iAttrVal);\n\t\t\t\t\t}\n\t\t\t\t} else if (\n\t\t\t\t\tinput.type == \"text\" ||\n\t\t\t\t\tinput.type == \"date\" ||\n\t\t\t\t\tinput.type == \"time\"\n\t\t\t\t) {\n\t\t\t\t\tformField = document.createElement(\"input\");\n\t\t\t\t\tformField.setAttribute(\"type\", CIQ.UI.supportedInputType(input.type));\n\t\t\t\t\tif (input.type == \"date\")\n\t\t\t\t\t\tformField.value = this.formatDateInput(input.value);\n\t\t\t\t\telse if (input.type == \"time\")\n\t\t\t\t\t\tformField.value = this.formatTimeInput(input.value);\n\t\t\t\t\telse formField.value = input.value;\n\t\t\t\t\tthis.setChangeEvent(formField, \"inputs\", input.name);\n\t\t\t\t\tfor (iAttr in attributes)\n\t\t\t\t\t\tif (iAttr !== \"hidden\")\n\t\t\t\t\t\t\tformField.setAttribute(iAttr, attributes[iAttr]);\n\t\t\t\t} else if (input.type == \"select\") {\n\t\t\t\t\tformField = this.makeMenu(\n\t\t\t\t\t\tinput.name,\n\t\t\t\t\t\tinput.value,\n\t\t\t\t\t\tinput.options,\n\t\t\t\t\t\t\"inputs\"\n\t\t\t\t\t);\n\t\t\t\t\tif (attributes && attributes.readonly)\n\t\t\t\t\t\tformField.setAttribute(\"readonly\", attributes.readonly);\n\t\t\t\t} else if (input.type == \"checkbox\") {\n\t\t\t\t\tformField = document.createElement(\"input\");\n\t\t\t\t\tformField.setAttribute(\"type\", \"checkbox\");\n\t\t\t\t\tif (input.value) formField.checked = true;\n\t\t\t\t\tthis.setChangeEvent(formField, \"inputs\", input.name);\n\t\t\t\t\tfor (iAttr in attributes)\n\t\t\t\t\t\tif (iAttr !== \"hidden\")\n\t\t\t\t\t\t\tformField.setAttribute(iAttr, attributes[iAttr]);\n\t\t\t\t}\n\t\t\t\tif (attributes && attributes.hidden) newInput.hide();\n\t\t\t\tif (formField) newInput.find(\".stx-data\").append(formField);\n\n\t\t\t\tnewInput[0].originalOuterHTML = newInput[0].outerHTML;\n\t\t\t\tvar oldInput = inputs.find(\"[fieldname='\" + input.name + \"']\");\n\t\t\t\tif (!oldInput.length) {\n\t\t\t\t\tinputs.append(newInput);\n\t\t\t\t} else if (\n\t\t\t\t\toldInput[0].originalOuterHTML !== newInput[0].originalOuterHTML\n\t\t\t\t) {\n\t\t\t\t\toldInput[0].replaceWith(newInput[0]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\trefreshOutputs(empty) {\n\t\t\tvar outputs = this.node.find(\"cq-study-outputs\");\n\t\t\tif (empty) outputs.empty();\n\t\t\tfor (var i = 0; i < this.helper.outputs.length; i++) {\n\t\t\t\tvar output = this.helper.outputs[i];\n\t\t\t\tvar newOutput = CIQ.UI.makeFromTemplate(this.outputTemplate);\n\t\t\t\tnewOutput[0].initialize({\n\t\t\t\t\tstudyDialog: this,\n\t\t\t\t\toutput: output.name\n\t\t\t\t});\n\t\t\t\tnewOutput.find(\".ciq-heading\").text(output.heading);\n\t\t\t\tnewOutput[0].setAttribute(\"fieldname\", output.name);\n\n\t\t\t\tvar swatch = newOutput.find(\"cq-swatch\");\n\t\t\t\tvar color = output.color;\n\t\t\t\tif (typeof color === \"object\") {\n\t\t\t\t\tcolor = color.color;\n\t\t\t\t}\n\t\t\t\tnewOutput[0].originalOuterHTML = newOutput[0].outerHTML;\n\t\t\t\tvar oldOutput = outputs.find(\"[fieldname='\" + output.name + \"']\");\n\t\t\t\tif (!oldOutput.length) {\n\t\t\t\t\toutputs.append(newOutput);\n\t\t\t\t} else if (\n\t\t\t\t\toldOutput[0].originalOuterHTML !== newOutput[0].originalOuterHTML\n\t\t\t\t) {\n\t\t\t\t\toldOutput[0].replaceWith(newOutput[0]);\n\t\t\t\t}\n\t\t\t\tswatch[0].setColor(color, false); // don't percolate\n\t\t\t}\n\t\t}\n\n\t\trefreshParameters(params, empty) {\n\t\t\tvar parameters = this.node.find(\"cq-study-parameters\");\n\t\t\tif (empty) parameters.empty();\n\t\t\tfor (var i = 0; i < this.helper.parameters.length; i++) {\n\t\t\t\tvar parameter = this.helper.parameters[i];\n\t\t\t\tvar newParam = CIQ.UI.makeFromTemplate(this.parameterTemplate);\n\t\t\t\tthis.menuTemplate = newParam.find(\"template[cq-menu]\");\n\t\t\t\tif (!this.menuTemplate.length && parameter.options) {\n\t\t\t\t\tnewParam.remove();\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\tnewParam.find(\".ciq-heading\").text(parameter.heading);\n\t\t\t\tnewParam[0].setAttribute(\"fieldname\", parameter.name);\n\t\t\t\tvar swatch = newParam.find(\"cq-swatch\");\n\t\t\t\tvar paramInput = document.createElement(\"input\");\n\t\t\t\tvar pAttr;\n\t\t\t\tvar setSwatch = false;\n\t\t\t\tvar attributes = {};\n\t\t\t\tif (parameter.defaultValue.constructor == Boolean) {\n\t\t\t\t\tparamInput.setAttribute(\"type\", \"checkbox\");\n\t\t\t\t\tif (parameter.value) paramInput.checked = true;\n\t\t\t\t\tthis.setChangeEvent(\n\t\t\t\t\t\tparamInput,\n\t\t\t\t\t\t\"parameters\",\n\t\t\t\t\t\tparameter.name + \"Enabled\"\n\t\t\t\t\t);\n\t\t\t\t\tswatch.remove();\n\n\t\t\t\t\tattributes = this.helper.attributes[parameter.name + \"Enabled\"];\n\t\t\t\t\tfor (pAttr in attributes)\n\t\t\t\t\t\tif (pAttr !== \"hidden\")\n\t\t\t\t\t\t\tparamInput.setAttribute(pAttr, attributes[pAttr]);\n\t\t\t\t} else if (parameter.defaultValue.constructor == String) {\n\t\t\t\t\tvar paramName = parameter.name;\n\t\t\t\t\tif (parameter.defaultColor) {\n\t\t\t\t\t\tnewParam[0].initialize({\n\t\t\t\t\t\t\tstudyDialog: this,\n\t\t\t\t\t\t\tparameter: parameter.name + \"Color\",\n\t\t\t\t\t\t\tparams: params\n\t\t\t\t\t\t});\n\t\t\t\t\t\tsetSwatch = true;\n\t\t\t\t\t\tparamName = paramName + \"Value\";\n\t\t\t\t\t} else {\n\t\t\t\t\t\tswatch.remove();\n\t\t\t\t\t}\n\t\t\t\t\tif (parameter.options) {\n\t\t\t\t\t\tparamInput = this.makeMenu(\n\t\t\t\t\t\t\tparamName,\n\t\t\t\t\t\t\tparameter.value,\n\t\t\t\t\t\t\tparameter.options,\n\t\t\t\t\t\t\t\"parameters\"\n\t\t\t\t\t\t);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tparamInput.value = parameter.value;\n\t\t\t\t\t}\n\t\t\t\t\tattributes = this.helper.attributes[paramName];\n\t\t\t\t\tfor (pAttr in attributes)\n\t\t\t\t\t\tif (pAttr !== \"hidden\")\n\t\t\t\t\t\t\tparamInput.setAttribute(pAttr, attributes[pAttr]);\n\t\t\t\t} else if (parameter.defaultValue.constructor == Number) {\n\t\t\t\t\tparamInput.setAttribute(\"type\", \"number\");\n\t\t\t\t\tparamInput.value = parameter.value;\n\t\t\t\t\tthis.setChangeEvent(\n\t\t\t\t\t\tparamInput,\n\t\t\t\t\t\t\"parameters\",\n\t\t\t\t\t\tparameter.name + \"Value\"\n\t\t\t\t\t);\n\t\t\t\t\tnewParam[0].initialize({\n\t\t\t\t\t\tstudyDialog: this,\n\t\t\t\t\t\tparameter: parameter.name + \"Color\",\n\t\t\t\t\t\tparams: params\n\t\t\t\t\t});\n\t\t\t\t\tsetSwatch = true;\n\n\t\t\t\t\tattributes = this.helper.attributes[parameter.name + \"Value\"];\n\t\t\t\t\tfor (pAttr in attributes) {\n\t\t\t\t\t\tvar pAttrVal = attributes[pAttr];\n\t\t\t\t\t\t// poor IE/Edge can't perform decimal step validation properly, so we need to change step to any and give up the neat step effect\n\t\t\t\t\t\tif (\n\t\t\t\t\t\t\t(CIQ.isIE || CIQ.isEdge) &&\n\t\t\t\t\t\t\tpAttr == \"step\" &&\n\t\t\t\t\t\t\tMath.floor(pAttrVal) != pAttrVal\n\t\t\t\t\t\t)\n\t\t\t\t\t\t\tpAttrVal = \"any\";\n\t\t\t\t\t\tif (pAttr !== \"hidden\") paramInput.setAttribute(pAttr, pAttrVal);\n\t\t\t\t\t}\n\t\t\t\t} else continue;\n\n\t\t\t\tif (attributes && attributes.hidden) newParam.not(\"hr\").hide();\n\t\t\t\tnewParam.find(\".stx-data\").append(paramInput);\n\n\t\t\t\tnewParam[0].originalOuterHTML = newParam[0].outerHTML;\n\t\t\t\tvar oldParam = parameters.find(\"[fieldname='\" + parameter.name + \"']\");\n\t\t\t\tif (!oldParam.length) {\n\t\t\t\t\tparameters.append(newParam);\n\t\t\t\t} else if (\n\t\t\t\t\toldParam[0].originalOuterHTML !== newParam[0].originalOuterHTML\n\t\t\t\t) {\n\t\t\t\t\toldParam[0].replaceWith(newParam[0]);\n\t\t\t\t}\n\t\t\t\tif (setSwatch) swatch[0].setColor(parameter.color, false); // don't percolate\n\t\t\t}\n\t\t}\n\n\t\t/**\n\t\t * Sets up a handler to process changes to input fields\n\t\t * @param {HTMLElement} node The input field\n\t\t * @param {string} section The section that is being updated, \"inputs\",\"outputs\",\"parameters\"\n\t\t * @param {string} name The name of the field being updated\n\t\t * @memberof! WebComponents.cq-study-dialog\n\t\t * @private\n\t\t */\n\t\tsetChangeEvent(node, section, name) {\n\t\t\tvar self = this;\n\t\t\tfunction closure() {\n\t\t\t\treturn function () {\n\t\t\t\t\tvar updates = {};\n\t\t\t\t\tupdates[section] = {};\n\t\t\t\t\tupdates[section][name] = this.value;\n\t\t\t\t\tif (this.type == \"checkbox\" || this.type == \"radio\") {\n\t\t\t\t\t\tupdates[section][name] = this.checked;\n\t\t\t\t\t}\n\t\t\t\t\tself.updateStudy(updates);\n\t\t\t\t};\n\t\t\t}\n\t\t\tnode.addEventListener(\"change\", closure());\n\t\t}\n\n\t\tsetContext(context) {\n\t\t\tthis.context = context;\n\t\t\tcontext.advertiseAs(this, \"StudyDialog\");\n\t\t}\n\n\t\t/**\n\t\t * Accepts new menu (select box) selections\n\t\t * @param {object} activator\n\t\t * @param {string} section within the dialog (\"inputs\", \"outputs\", \"parameters\")\n\t\t * @memberof! WebComponents.cq-study-dialog\n\t\t * @since 5.2.0 Added `section` parameter.\n\t\t */\n\t\tsetSelectOption(activator, section) {\n\t\t\tvar node = CIQ.UI.$(activator.node);\n\t\t\tvar name = node.attr(\"name\");\n\t\t\tvar value = node.attr(\"value\");\n\t\t\tvar newInput = node[0].cqMenuWrapper;\n\t\t\tnewInput.fieldValue = value;\n\t\t\tvar inputValue = newInput.querySelector(\"cq-selected\");\n\t\t\tif (inputValue) inputValue.innerText = this.helper.stx.translateIf(value);\n\t\t\tif (!section) section = \"inputs\";\n\t\t\tvar updates = {};\n\t\t\tupdates[section] = {};\n\t\t\tupdates[section][name] = value;\n\t\t\t// Close the option menu here when selected via keyboard because keyboard navigation\n\t\t\t// doesn't provide the necessary mouse event to close it automatically.\n\t\t\tthis.closeActiveMenu(node[0]);\n\t\t\tthis.updateStudy(updates);\n\t\t}\n\n\t\tupdateStudy(updates) {\n\t\t\tif (this.node.find(\":invalid\").length) return;\n\t\t\tif (this.addWhenDone) {\n\t\t\t\tCIQ.extend(this.queuedUpdates, updates);\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tif (this.helper.libraryEntry.deferUpdate) {\n\t\t\t\tCIQ.extend(this.queuedUpdates, { inputs: updates.inputs });\n\t\t\t\tthis.helper.updateStudy({\n\t\t\t\t\toutputs: updates.outputs,\n\t\t\t\t\tparameters: updates.parameters\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tthis.helper.updateStudy(updates);\n\t\t\t}\n\t\t}\n\n\t\t/**\n\t\t * Selects template elements and attaches them as class properties only once\n\t\t * @memberof! WebComponents.cq-study-dialog\n\t\t */\n\t\tselectTemplates() {\n\t\t\tif (this.inputTemplate) return;\n\t\t\tthis.inputTemplate = this.querySelector(\"template[cq-study-input]\");\n\t\t\tthis.outputTemplate = this.querySelector(\"template[cq-study-output]\");\n\t\t\tthis.parameterTemplate = this.querySelector(\n\t\t\t\t\"template[cq-study-parameters]\"\n\t\t\t);\n\t\t}\n\t}\n\n\tStudyDialog.markup = `\n\t\t

Study here

\n\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\t\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
Done
\n\t\t
\n\t`;\n\tCIQ.UI.addComponentDefinition(\"cq-study-dialog\", StudyDialog);\n}\n\n};\n\n\nlet __js_webcomponents_studyInput_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Study input web component ``.\n *\n * See example in {@link WebComponents.cq-study-dialog}.\n *\n * @namespace WebComponents.cq-study-input\n */\nclass StudyInput extends CIQ.UI.DialogContentTag {}\n\nCIQ.UI.addComponentDefinition(\"cq-study-input\", StudyInput);\n\n};\n\n\nlet __js_webcomponents_studyLegend_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nif (!CIQ.Studies) {\n\tconsole.error(\n\t\t\"studyLegend component requires first activating studies feature.\"\n\t);\n} else {\n\t/**\n\t * Study legend web component ``.\n\t *\n\t * Click on the \"X\" to remove the study.\n\t * Click on the cog to edit the study.\n\t * Optionally only show studies needing custom Removal. cq-custom-removal-only\n\t * Optionally only show overlays. cq-overlays-only\n\t * Optionally only show studies in this panel. cq-panel-only\n\t * Optionally only show signalling studies. cq-signal-studies-only\n\t * Optionally clone to all panels. cq-clone-to-panels=\"Plots\" or whatever name you choose\n\t * Optionally specify selector for which nodes have content. cq-content-keys\n\t *\n\t * **Keyboard control**\n\t *\n\t * When selected with tab key navigation and activated with Return/Enter, this component has\n\t * the following internal controls:\n\t * - Up/Down arrow — Move selection between internal cq-item and cq-comparison-item\n\t * elements.\n\t * - Left/Right arrow — Select a control within a selected cq-item element, such as\n\t * the Remove button. Child elements must have the attribute `keyboard-selectable-child` set to\n\t * \"true\" to be selectable with these keys.\n\t *\n\t * @namespace WebComponents.cq-study-legend\n\t * @since\n\t * - 8.3.0 Enabled internal keyboard navigation and selection.\n\t * - 8.6.0 added `cq-signal-studies-only` flag.\n\t *\n\t * @example\n\t * \n\t * Here is an example of how to create a study legend on the chart. We use the\n\t * cq-marker attribute to ensure that it floats inside the chart. We set the\n\t * optional cq-panel-only attribute so that only studies from this panel are\n\t * displayed.\n\t * \n\t * \n\t * \n\t * \n\t *\n\t * @example\n\t * \n\t * Here is an example of how to create a study legend inside a dropdown menu. We use the\n\t * cq-no-close attribute so that dropdown is not closed when the user removes\n\t * a study from the list.\n\t * \n\t * \n\t * Studies\n\t * \n\t * \n\t * \n\t * Current Studies\n\t * \n\t * \n\t * \n\t * \n\t *
Clear All
\n\t *
\n\t *
\n\t *
\n\t * \n\t * \n\t * \n\t * \n\t * \n\t * \n\t * \n\t *
\n\t *
\n\t */\n\tclass StudyLegend extends CIQ.UI.ModalTag {\n\t\tconnectedCallback() {\n\t\t\tif (this.attached) return;\n\t\t\tsuper.connectedCallback();\n\n\t\t\tif (!this.hasAttribute(\"cq-no-claim\")) this.addClaim(this);\n\t\t\t// Update the keyboard navigation. New study legend components can be added at runtime.\n\t\t\tif (this.context && this.context.config && this.context.config.channels) {\n\t\t\t\tthis.channelWrite(\n\t\t\t\t\tthis.context.config.channels.keyboardNavigation ||\n\t\t\t\t\t\t\"channel.keyboardNavigation\",\n\t\t\t\t\t{ action: \"registerElements\" }\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\n\t\tadoptedCallback() {\n\t\t\tsuper.adoptedCallback();\n\t\t\tCIQ.UI.flattenInheritance(this, StudyLegend);\n\t\t}\n\n\t\tdisconnectedCallback() {\n\t\t\tif (this.context) {\n\t\t\t\t// Update the keyboard navigation. Need to remove this element from the index now that it's detached\n\t\t\t\tif (this.context.config && this.context.config.channels) {\n\t\t\t\t\tthis.channelWrite(\n\t\t\t\t\t\tthis.context.config.channels.keyboardNavigation ||\n\t\t\t\t\t\t\t\"channel.keyboardNavigation\",\n\t\t\t\t\t\t{ action: \"registerElements\" }\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t}\n\t\t\tsuper.disconnectedCallback();\n\t\t}\n\n\t\t/**\n\t\t * Begins running the StudyLegend.\n\t\t * @memberof! WebComponents.cq-study-legend\n\t\t * @private\n\t\t */\n\t\tbegin() {\n\t\t\tif (this.init) return;\n\t\t\tvar stx = this.context.stx;\n\t\t\tvar node = this.node;\n\n\t\t\tthis.template = node.find(\"template[cq-study-legend]\");\n\t\t\tif (!this.template.length) this.template = node.find(\"template\"); // backwards compatibility, this can fail if more than one template is present!\n\t\t\tthis.contentKeys = node.attr(\"cq-content-keys\") || \"cq-label\";\n\n\t\t\tthis.eventListeners.push(\n\t\t\t\tstx.addEventListener(\"layout\", this.renderLegend.bind(this))\n\t\t\t);\n\n\t\t\tif (this.hasAttribute(\"cq-marker\")) {\n\t\t\t\tCIQ.UI.stxtap(this, function () {\n\t\t\t\t\tthis.setActiveState();\n\t\t\t\t});\n\t\t\t}\n\n\t\t\tthis.renderLegend();\n\t\t\tthis.init = true;\n\t\t}\n\n\t\tsetActiveState(newState) {\n\t\t\tlet isActive = this.classList.contains(\"ciq-active\");\n\t\t\t// If newState is undefined, toggle the active state\n\t\t\tnewState = typeof newState === \"undefined\" ? !isActive : newState;\n\t\t\tconst keystrokeHub = this.ownerDocument.body.keystrokeHub;\n\t\t\tif (newState) {\n\t\t\t\tthis.classList.add(\"ciq-active\");\n\t\t\t\t// Treat the legend like a modal so keyboard navigation is returned after using colorPicker\n\t\t\t\tif (keystrokeHub && this.keyboardNavigation)\n\t\t\t\t\tkeystrokeHub.addActiveModal(this);\n\t\t\t} else {\n\t\t\t\tthis.classList.remove(\"ciq-active\");\n\t\t\t\tif (keystrokeHub) keystrokeHub.removeActiveModal(this);\n\t\t\t}\n\t\t}\n\n\t\tkeyStroke(hub, key, e) {\n\t\t\tif (!this.keyboardNavigation) return;\n\t\t\tconst items = this.querySelectorAll(\n\t\t\t\t\"[keyboard-selectable='true'], cq-item:not(.item-hidden), cq-comparison-item\"\n\t\t\t);\n\n\t\t\tif (key == \" \" || key == \"Spacebar\" || key == \"Enter\") {\n\t\t\t\tconst focused = this.findFocused(items);\n\t\t\t\tif (!focused || !focused.length) return;\n\t\t\t\tconst childItemsSelected = focused[0].querySelector(\n\t\t\t\t\t\"[keyboard-selectable-child='true'][cq-focused]\"\n\t\t\t\t);\n\t\t\t\tif (childItemsSelected) {\n\t\t\t\t\tthis.clickItem(childItemsSelected, e);\n\t\t\t\t} else {\n\t\t\t\t\t// If no child item is seleted, but there is a swatch, go ahead and click it.\n\t\t\t\t\tconst selectabelSwatch = focused[0].querySelector(\"cq-swatch\");\n\t\t\t\t\tif (selectabelSwatch) this.clickItem(selectabelSwatch, e);\n\t\t\t\t}\n\t\t\t} else if (key == \"ArrowDown\" || key == \"Down\") {\n\t\t\t\tthis.focusNextItem(items);\n\t\t\t} else if (key == \"ArrowUp\" || key == \"Up\") {\n\t\t\t\tthis.focusNextItem(items, true);\n\t\t\t} else if (key == \"ArrowRight\" || key == \"Right\") {\n\t\t\t\tconst focused = this.findFocused(items);\n\t\t\t\tif (!focused || !focused.length) return;\n\t\t\t\tconst childItems = focused[0].querySelectorAll(\n\t\t\t\t\t\"[keyboard-selectable-child='true']\"\n\t\t\t\t);\n\t\t\t\tif (childItems.length) this.focusNextItem(childItems);\n\t\t\t} else if (key == \"ArrowLeft\" || key == \"Left\") {\n\t\t\t\tconst focused = this.findFocused(items)[0];\n\t\t\t\tif (!focused) return;\n\t\t\t\tconst childItems = focused.querySelectorAll(\n\t\t\t\t\t\"[keyboard-selectable-child='true']\"\n\t\t\t\t);\n\t\t\t\t// If the end of the child items has been reached select the parent item instead\n\t\t\t\tif (childItems.length && !this.focusNextItem(childItems, true)) {\n\t\t\t\t\tthis.removeFocused(childItems);\n\t\t\t\t\tthis.focusItem(focused);\n\t\t\t\t}\n\t\t\t} else if (key === \"Tab\" || key === \"Esc\" || key === \"Escape\") {\n\t\t\t\tthis.removeFocused(items);\n\t\t\t\tthis.setActiveState(false);\n\t\t\t\tconst keystrokeHub = this.ownerDocument.body.keystrokeHub;\n\t\t\t\tif (keystrokeHub) keystrokeHub.tabOrderSelect();\n\t\t\t}\n\t\t}\n\n\t\t/**\n\t\t * If a color-picker is opened within this component, this will make sure the component stays active.\n\t\t * @memberof! WebComponents.cq-study-legend\n\t\t */\n\t\tlaunchColorPicker() {\n\t\t\tthis.setActiveState(true);\n\t\t}\n\n\t\t/**\n\t\t * Renders the legend based on the current studies in the CIQ.ChartEngine object.\n\t\t * @memberof! WebComponents.cq-study-legend\n\t\t */\n\t\trenderLegend() {\n\t\t\tvar stx = this.context.stx;\n\n\t\t\tthis.template.nextAll().remove();\n\n\t\t\tfunction closeStudy(self, sd) {\n\t\t\t\treturn function (e) {\n\t\t\t\t\te.stopPropagation();\n\t\t\t\t\t// Need to run this in the nextTick because the study legend can be removed by this click\n\t\t\t\t\t// causing the underlying chart to receive the mousedown (on IE win7)\n\t\t\t\t\tsetTimeout(function () {\n\t\t\t\t\t\tif (!sd.permanent) CIQ.Studies.removeStudy(self.context.stx, sd);\n\t\t\t\t\t\tif (self.node[0].hasAttribute(\"cq-marker\"))\n\t\t\t\t\t\t\tself.context.stx.modalEnd();\n\t\t\t\t\t\tself.renderLegend();\n\t\t\t\t\t}, 0);\n\t\t\t\t};\n\t\t\t}\n\t\t\tfunction editStudy(self, studyId) {\n\t\t\t\treturn function (e) {\n\t\t\t\t\tvar sd = stx.layout.studies[studyId];\n\t\t\t\t\tif (sd.permanent || !sd.editFunction) return;\n\t\t\t\t\te.stopPropagation();\n\t\t\t\t\tself.uiManager.closeMenu();\n\t\t\t\t\tvar studyEdit = self.context.getAdvertised(\"StudyEdit\");\n\t\t\t\t\tvar params = {\n\t\t\t\t\t\tstx: stx,\n\t\t\t\t\t\tsd: sd,\n\t\t\t\t\t\tinputs: sd.inputs,\n\t\t\t\t\t\toutputs: sd.outputs,\n\t\t\t\t\t\tparameters: sd.parameters\n\t\t\t\t\t};\n\t\t\t\t\tstudyEdit.editPanel(params);\n\t\t\t\t};\n\t\t\t}\n\t\t\tvar overlaysOnly = this.hasAttribute(\"cq-overlays-only\");\n\t\t\tvar panelOnly = this.hasAttribute(\"cq-panel-only\");\n\t\t\tvar customRemovalOnly = this.hasAttribute(\"cq-custom-removal-only\");\n\t\t\tvar signalStudiesOnly = this.hasAttribute(\"cq-signal-studies-only\");\n\t\t\tvar markerLabel = this.node.attr(\"cq-marker-label\");\n\t\t\tvar panelName = null;\n\t\t\tvar holder = this.node.parents(\".stx-holder\")[0];\n\t\t\tif (holder) panelName = holder.panel.name;\n\n\t\t\tif (CIQ.Studies) {\n\t\t\t\tfor (var id in stx.layout.studies) {\n\t\t\t\t\tvar sd = stx.layout.studies[id];\n\t\t\t\t\tif (sd.customLegend) continue;\n\t\t\t\t\tif (customRemovalOnly && !sd.study.customRemoval) continue;\n\t\t\t\t\tif (panelOnly && sd.panel != panelName) continue;\n\t\t\t\t\tif (overlaysOnly && !sd.overlay && !sd.underlay) continue;\n\t\t\t\t\tif (markerLabel && sd.signalData && !sd.signalData.reveal) continue;\n\t\t\t\t\tif (!markerLabel && CIQ.xor(signalStudiesOnly, sd.signalData))\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\tvar newChild = CIQ.UI.makeFromTemplate(this.template, true);\n\t\t\t\t\tnewChild.find(\"cq-label\").html(sd.inputs.display);\n\n\t\t\t\t\t// For SignalIQ - Display a show/hide switch when rendered outside of the plot legend\n\t\t\t\t\tif (\n\t\t\t\t\t\tsd.signalData &&\n\t\t\t\t\t\tsd.signalData.hide &&\n\t\t\t\t\t\t!holder &&\n\t\t\t\t\t\tpanelName !== \"chart\"\n\t\t\t\t\t) {\n\t\t\t\t\t\tvar toggle = document.createElement(\"span\");\n\t\t\t\t\t\ttoggle.className = \"ciq-switch\";\n\t\t\t\t\t\ttoggle.setAttribute(\"keyboard-selectable-child\", \"true\");\n\t\t\t\t\t\tif (!sd.disabled) newChild.addClass(\"ciq-active\");\n\t\t\t\t\t\tlet handleClickTouch = function (sd, stx) {\n\t\t\t\t\t\t\treturn (e) => {\n\t\t\t\t\t\t\t\tsd.toggleDisabledState(stx);\n\t\t\t\t\t\t\t\te.target.parentElement.classList[\n\t\t\t\t\t\t\t\t\tsd.disabled ? \"remove\" : \"add\"\n\t\t\t\t\t\t\t\t](\"ciq-active\");\n\t\t\t\t\t\t\t};\n\t\t\t\t\t\t};\n\t\t\t\t\t\tCIQ.safeClickTouch(toggle, handleClickTouch(sd, stx));\n\t\t\t\t\t\tnewChild.append(toggle);\n\t\t\t\t\t}\n\n\t\t\t\t\tvar close = newChild.find(\".ciq-close\");\n\t\t\t\t\tif (sd.permanent) {\n\t\t\t\t\t\tclose.hide();\n\t\t\t\t\t} else {\n\t\t\t\t\t\tclose[0].setAttribute(\"keyboard-selectable-child\", \"true\");\n\t\t\t\t\t\tCIQ.UI.stxtap(close[0], closeStudy(this, sd));\n\t\t\t\t\t}\n\t\t\t\t\tvar edit = newChild.find(\".ciq-edit\")[0];\n\t\t\t\t\tif (edit && (sd.permanent || !sd.editFunction)) {\n\t\t\t\t\t\tedit.style.visibility = \"hidden\";\n\t\t\t\t\t} else if (sd.editFunction) {\n\t\t\t\t\t\t// If there isn't an edit button, put the edit function on the parent so it responds to a keyboard navigation click\n\t\t\t\t\t\tlet targetElem = edit || newChild[0];\n\t\t\t\t\t\tCIQ.UI.stxtap(targetElem, editStudy(this, id));\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t//Only want to display the marker label if at least one study has been\n\t\t\t//rendered in the legend. If no studies are rendered, only the template tag\n\t\t\t//will be in there.\n\t\t\tif (typeof markerLabel != \"undefined\") {\n\t\t\t\tif (!this.node.find(\"cq-marker-label\").length) {\n\t\t\t\t\tvar label = document.createElement(\"cq-marker-label\");\n\t\t\t\t\tlabel.innerText = markerLabel;\n\t\t\t\t\tthis.insertBefore(label, this.firstChild);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tthis.displayLegendTitle();\n\t\t}\n\n\t\tdisplayLegendTitle() {\n\t\t\tif (hasKeys(this, this.contentKeys)) {\n\t\t\t\tthis.node.css(\"display\", \"\");\n\t\t\t\tthis.node.parents(\"div.stx-panel-legend\").css(\"width\", \"\");\n\t\t\t} else {\n\t\t\t\tthis.node.css(\"display\", \"none\");\n\t\t\t\tthis.node.parents(\"div.stx-panel-legend\").css(\"width\", \"0px\");\n\t\t\t}\n\t\t\tif (this.context.stx.translateUI)\n\t\t\t\tthis.context.stx.translateUI(this.node[0]);\n\n\t\t\tfunction hasKeys(node, keys) {\n\t\t\t\t// checks if key is not template as in frameworks such as React or Angular\n\t\t\t\t// templates may be rendered as regular node allowing to inner content queries\n\t\t\t\treturn Array.from(node.querySelectorAll(keys)).some(notInTemplate);\n\t\t\t}\n\n\t\t\tfunction notInTemplate(el) {\n\t\t\t\twhile (el) {\n\t\t\t\t\tif (el.nodeName.toLowerCase() === \"template\") return false;\n\t\t\t\t\tel = el.parentElement;\n\t\t\t\t}\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\n\t\tsetContext(context) {\n\t\t\tif (this.init) return;\n\t\t\tvar self = this;\n\t\t\tif (this.node.attr(\"cq-clone-to-panels\") !== undefined) {\n\t\t\t\tself.closest(\"cq-context\").classList.add(\"stx-panel-legend\");\n\t\t\t\tself.spawnPanelLegend();\n\t\t\t\tcontext.stx.append(\"stackPanel\", function (display, name) {\n\t\t\t\t\tself.spawnPanelLegend();\n\t\t\t\t});\n\t\t\t}\n\t\t\tthis.begin();\n\t\t}\n\n\t\tchangeContext(newContext) {\n\t\t\tthis.eventListeners.forEach((listener) => {\n\t\t\t\tthis.context.stx.removeEventListener(listener);\n\t\t\t});\n\t\t\tthis.eventListeners = [\n\t\t\t\tnewContext.stx.addEventListener(\"layout\", this.renderLegend.bind(this))\n\t\t\t];\n\t\t\tthis.context = newContext;\n\t\t\tthis.renderLegend();\n\t\t}\n\n\t\tspawnPanelLegend() {\n\t\t\tvar stx = this.context.stx;\n\t\t\tfunction tap(legend) {\n\t\t\t\treturn function (e) {\n\t\t\t\t\tlegend.setActiveState();\n\t\t\t\t};\n\t\t\t}\n\t\t\tfor (var p in stx.panels) {\n\t\t\t\tif (p == stx.chart.panel.name) continue;\n\t\t\t\tvar legendHolder =\n\t\t\t\t\tstx.panels[p].subholder.querySelector(\".stx-panel-legend\");\n\t\t\t\tif (legendHolder) {\n\t\t\t\t\tvar panelLegend = legendHolder.querySelector(this.nodeName);\n\t\t\t\t\tif (!panelLegend) {\n\t\t\t\t\t\tif (this.ownerDocument !== document) {\n\t\t\t\t\t\t\tconst templ = document.createElement(\"template\");\n\t\t\t\t\t\t\ttempl.innerHTML = this.outerHTML;\n\t\t\t\t\t\t\tdocument.body.append(templ);\n\t\t\t\t\t\t\tpanelLegend = CIQ.UI.makeFromTemplate(templ)[0];\n\t\t\t\t\t\t\ttempl.remove();\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tpanelLegend = this.cloneNode(true);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tpanelLegend.setAttribute(\n\t\t\t\t\t\t\t\"cq-marker-label\",\n\t\t\t\t\t\t\tthis.getAttribute(\"cq-clone-to-panels\")\n\t\t\t\t\t\t);\n\t\t\t\t\t\tpanelLegend.removeAttribute(\"cq-clone-to-panels\");\n\t\t\t\t\t\tpanelLegend.removeAttribute(\"cq-overlays-only\");\n\t\t\t\t\t\tpanelLegend.removeAttribute(\"cq-marker\");\n\t\t\t\t\t\tCIQ.UI.stxtap(panelLegend, tap(panelLegend));\n\t\t\t\t\t\tvar mLabel = panelLegend.querySelector(\"cq-marker-label\");\n\t\t\t\t\t\tif (mLabel) mLabel.remove();\n\t\t\t\t\t\tvar fixedWrapper = document.createElement(\n\t\t\t\t\t\t\t\"cq-study-legend-fixed-wrapper\"\n\t\t\t\t\t\t);\n\t\t\t\t\t\tfixedWrapper.appendChild(panelLegend);\n\t\t\t\t\t\tlegendHolder.appendChild(fixedWrapper);\n\t\t\t\t\t\tpanelLegend.begin();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tCIQ.UI.addComponentDefinition(\"cq-study-legend\", StudyLegend);\n}\n\n};\n\n\nlet __js_webcomponents_studyOutput_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Study output web component ``.\n *\n * Set the color of study outputs in the {@link WebComponents.cq-study-dialog}.\n *\n * See example in {@link WebComponents.cq-study-dialog}.\n *\n * @namespace WebComponents.cq-study-output\n */\nclass StudyOutput extends CIQ.UI.BaseComponent {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, StudyOutput);\n\t}\n\n\tinitialize(params) {\n\t\tthis.params = params;\n\t}\n\n\tsetColor(color) {\n\t\tif (!this.params) return;\n\t\tvar updates = {\n\t\t\toutputs: {}\n\t\t};\n\t\tupdates.outputs[this.params.output] = {};\n\t\tupdates.outputs[this.params.output].color = color;\n\t\tthis.params.studyDialog.updateStudy(updates);\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-study-output\", StudyOutput);\n\n};\n\n\nlet __js_webcomponents_studyParameter_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Study parameters web component ``.\n *\n * See example in {@link WebComponents.cq-study-dialog}.\n *\n * @namespace WebComponents.cq-study-parameter\n */\nclass StudyParameter extends CIQ.UI.DialogContentTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, StudyParameter);\n\t}\n\n\tinitialize(params) {\n\t\tthis.params = params;\n\t}\n\n\tsetColor(color) {\n\t\tif (!this.params) return;\n\t\tvar updates = { parameters: {} };\n\t\tupdates.parameters[this.params.parameter] = color;\n\t\tthis.params.studyDialog.updateStudy(updates);\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-study-parameter\", StudyParameter);\n\n};\n\n\nlet __js_webcomponents_swatch_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Swatch web component ``.\n *\n * An interactive color swatch. Relies on the existence of a {@link CIQ.UI.ColorPicker} component.\n * Interactivity can be disabled by adding cq-static attribute\n *\n * When a color is selected, setColor(color) will get called for any parent component with that\n * method.\n *\n * @namespace WebComponents.cq-swatch\n *\n * @example\n * \n * Candle Color\n * \n * \n * \n * Candle Wick\n * \n * \n * \n * Candle Border\n * \n * \n * \n * \n * Line/Bar Chart\n * \n * \n * \n * Mountain Color\n * \n * \n * \n * \n */\nclass Swatch extends HTMLElement {\n\tconstructor() {\n\t\tsuper();\n\t\t/**\n\t\t * Optionally set the default color for the swatch.\n\t\t * @type {string}\n\t\t * @memberof WebComponents.cq-swatch\n\t\t */\n\t\tthis.defaultColor = null;\n\t}\n\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tthis.attached = true;\n\n\t\tif (this.getAttribute(\"cq-static\")) {\n\t\t\tthis.style.cursor = \"default\";\n\t\t\treturn;\n\t\t}\n\t\tvar self = this;\n\t\tCIQ.UI.stxtap(this, function (e) {\n\t\t\tself.launchColorPicker();\n\t\t\te.stopPropagation();\n\t\t});\n\t}\n\n\tadoptedCallback() {\n\t\tCIQ.UI.flattenInheritance(this, Swatch);\n\t}\n\n\t/**\n\t * Attempts to identify the default color for the associated chart. It does so by traversing\n\t * up the parent stack and looking for any component that has a context. Or you can set\n\t * the default color manually by setting member variable defaultColor;\n\t * @memberof WebComponents.cq-swatch\n\t */\n\tgetDefaultColor() {\n\t\tif (this.defaultColor) return this.defaultColor;\n\t\tvar context = CIQ.UI.getMyContext(this);\n\t\tif (context) return context.stx.defaultColor; // some parent with a context\n\t\treturn \"transparent\";\n\t}\n\n\t/**\n\t * @alias setColor\n\t * @memberof WebComponents.cq-swatch\n\t * @since 6.2.0 Colors strip out the opacity so they are the rgb representation\n\t */\n\tsetColor(color, percolate, isAuto) {\n\t\tvar bgColor = CIQ.getBackgroundColor(this.parentNode);\n\t\tvar border = CIQ.chooseForegroundColor(bgColor);\n\t\tvar hslb = CIQ.hsl(bgColor);\n\t\tif (color == \"auto\") isAuto = true;\n\t\tif (!color) color = \"transparent\";\n\t\tvar fillColor = color;\n\t\tif (color == \"auto\") {\n\t\t\tfillColor = this.getDefaultColor();\n\t\t} else if (color.indexOf(\"rgba(\") === 0) {\n\t\t\t// strip out the alpha component\n\t\t\tfillColor = (fillColor.split(\",\").slice(0, 3).join(\",\") + \")\").replace(\n\t\t\t\t/rgba/,\n\t\t\t\t\"rgb\"\n\t\t\t);\n\t\t}\n\t\tvar hslf = CIQ.hsl(fillColor);\n\t\tvar isTransparent = CIQ.isTransparent(color);\n\t\tthis.style.background = this.value = fillColor;\n\t\tif (isAuto || Math.abs(hslb[2] - hslf[2]) < 0.2 || isTransparent) {\n\t\t\tthis.style.border = \"solid \" + border + \" 1px\";\n\t\t\tif (isTransparent)\n\t\t\t\tthis.style.background =\n\t\t\t\t\t\"linear-gradient(to bottom right, transparent, transparent 49%, \" +\n\t\t\t\t\tborder +\n\t\t\t\t\t\" 50%, transparent 51%, transparent)\";\n\t\t} else {\n\t\t\tthis.style.border = \"\";\n\t\t}\n\n\t\tif (isAuto) {\n\t\t\tbgColor = CIQ.chooseForegroundColor(fillColor);\n\t\t\tthis.style.background =\n\t\t\t\t\"linear-gradient(to bottom right, \" +\n\t\t\t\tfillColor +\n\t\t\t\t\", \" +\n\t\t\t\tfillColor +\n\t\t\t\t\" 49%, \" +\n\t\t\t\tbgColor +\n\t\t\t\t\" 50%, \" +\n\t\t\t\tbgColor +\n\t\t\t\t\")\";\n\t\t}\n\t\tif (percolate !== false)\n\t\t\tCIQ.UI.containerExecute(this, \"setColor\", color, this);\n\t}\n\n\t/**\n\t * @alias launchColorPicker\n\t * @memberof WebComponents.cq-swatch\n\t */\n\tlaunchColorPicker() {\n\t\tCIQ.UI.containerExecute(this, \"launchColorPicker\");\n\t\tvar colorPicker = this.ownerDocument.querySelector(\"cq-color-picker\");\n\t\tif (colorPicker) {\n\t\t\tcolorPicker.callback = (function (self) {\n\t\t\t\treturn function (color) {\n\t\t\t\t\tself.setColor(color, null);\n\t\t\t\t};\n\t\t\t})(this);\n\t\t\tvar overrides = this.getAttribute(\"cq-overrides\");\n\t\t\tif (overrides) overrides = overrides.split(\",\");\n\t\t\tcolorPicker.display({\n\t\t\t\tnode: this,\n\t\t\t\tcontext: CIQ.UI.getMyContext(this),\n\t\t\t\toverrides: overrides\n\t\t\t});\n\t\t\tthis.colorPicker = colorPicker;\n\t\t}\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-swatch\", Swatch);\n\n};\n\n\nlet __js_webcomponents_themeDialog_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\n\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nif (!CIQ.ThemeHelper) {\n\tconsole.error(\n\t\t\"themeDialog component requires first activating theme feature.\"\n\t);\n} else {\n\t/**\n\t * Theme dialog web component ``.\n\t *\n\t * Enables creation of custom chart themes.\n\t *\n\t * @namespace WebComponents.cq-theme-dialog\n\t *\n\t * @example\n\t * \n\t * \n\t *

Create Custom Theme

\n\t * \n\t * \n\t * ...\n\t * ...\n\t * \n\t *
\n\t *
\n\t */\n\tclass ThemeDialog extends CIQ.UI.DialogContentTag {\n\t\tadoptedCallback() {\n\t\t\tsuper.adoptedCallback();\n\t\t\tCIQ.UI.flattenInheritance(this, ThemeDialog);\n\t\t\tthis.constructor = ThemeDialog;\n\t\t}\n\n\t\t/**\n\t\t * Applies changes to all charts on the screen.\n\t\t *\n\t\t * @memberof WebComponents.cq-theme-dialog\n\t\t * @private\n\t\t */\n\t\tapplyChanges() {\n\t\t\tconst isMultiChart = this.context.topNode.getCharts;\n\t\t\tconst charts = isMultiChart\n\t\t\t\t? this.context.topNode.getCharts()\n\t\t\t\t: [this.context.stx];\n\n\t\t\tcharts.forEach((stx) => {\n\t\t\t\tif (!stx) return;\n\t\t\t\tthis.helper.update(stx);\n\t\t\t\tstx.changeOccurred(\"theme\");\n\t\t\t});\n\t\t}\n\n\t\t/**\n\t\t * Closes the theme dialog box.\n\t\t *\n\t\t * @alias close\n\t\t * @memberof WebComponents.cq-theme-dialog\n\t\t */\n\t\tclose() {\n\t\t\tthis.helper.settings = this.revert;\n\t\t\tthis.applyChanges();\n\t\t\tsuper.close();\n\t\t}\n\n\t\t/**\n\t\t * Opens the theme dialog box.\n\t\t *\n\t\t * @param {object} params Dialog box parameters.\n\t\t * @param {CIQ.UI.Context} params.context The chart user interface context.\n\t\t * @param {object} [params.initiatingMenu The menu that contains the user interface\n\t\t * \t\tcontrol that opened the theme dialog box.\n\t\t * @param {string} [params.themeName] Hint text for the name of the custom theme. Used in\n\t\t * \t\tthe theme name input field of the theme dialog box.\n\t\t *\n\t\t * @alias open\n\t\t * @memberof WebComponents.cq-theme-dialog\n\t\t * @since 6.2.0 `basecolor` of mountain chart can be configured with \"mb\" piece.\n\t\t */\n\t\topen(params) {\n\t\t\tthis.addDefaultMarkup();\n\t\t\tsuper.open(params);\n\t\t\tvar themeName = params.themeName;\n\n\t\t\tthis.initiatingMenu = params.initiatingMenu;\n\t\t\tthis.context = params.context;\n\t\t\tthis.helper = new CIQ.ThemeHelper({ stx: this.context.stx });\n\t\t\tthis.revert = CIQ.clone(this.helper.settings);\n\n\t\t\tvar self = this;\n\t\t\tfunction configurePiece(name, obj, field, type) {\n\t\t\t\tvar cu = self.node.find('cq-theme-piece[cq-piece=\"' + name + '\"]');\n\t\t\t\tif (!cu.length) return;\n\t\t\t\tcu[0].piece = { obj: obj, field: field };\n\t\t\t\tif (type == \"color\") {\n\t\t\t\t\tcu.find(\"cq-swatch\")[0].setColor(obj[field], false);\n\t\t\t\t}\n\t\t\t}\n\t\t\tvar settings = this.helper.settings;\n\t\t\tconfigurePiece(\n\t\t\t\t\"cu\",\n\t\t\t\tsettings.chartTypes[\"Candle/Bar\"].up,\n\t\t\t\t\"color\",\n\t\t\t\t\"color\"\n\t\t\t);\n\t\t\tconfigurePiece(\n\t\t\t\t\"cd\",\n\t\t\t\tsettings.chartTypes[\"Candle/Bar\"].down,\n\t\t\t\t\"color\",\n\t\t\t\t\"color\"\n\t\t\t);\n\t\t\tconfigurePiece(\n\t\t\t\t\"wu\",\n\t\t\t\tsettings.chartTypes[\"Candle/Bar\"].up,\n\t\t\t\t\"wick\",\n\t\t\t\t\"color\"\n\t\t\t);\n\t\t\tconfigurePiece(\n\t\t\t\t\"wd\",\n\t\t\t\tsettings.chartTypes[\"Candle/Bar\"].down,\n\t\t\t\t\"wick\",\n\t\t\t\t\"color\"\n\t\t\t);\n\t\t\tconfigurePiece(\n\t\t\t\t\"bu\",\n\t\t\t\tsettings.chartTypes[\"Candle/Bar\"].up,\n\t\t\t\t\"border\",\n\t\t\t\t\"color\"\n\t\t\t);\n\t\t\tconfigurePiece(\n\t\t\t\t\"bd\",\n\t\t\t\tsettings.chartTypes[\"Candle/Bar\"].down,\n\t\t\t\t\"border\",\n\t\t\t\t\"color\"\n\t\t\t);\n\t\t\tconfigurePiece(\"lc\", settings.chartTypes.Line, \"color\", \"color\");\n\t\t\tconfigurePiece(\"mb\", settings.chartTypes.Mountain, \"basecolor\", \"color\");\n\t\t\tconfigurePiece(\"mc\", settings.chartTypes.Mountain, \"color\", \"color\");\n\t\t\tconfigurePiece(\"bg\", settings.chart.Background, \"color\", \"color\");\n\t\t\tconfigurePiece(\"gl\", settings.chart[\"Grid Lines\"], \"color\", \"color\");\n\t\t\tconfigurePiece(\"dd\", settings.chart[\"Grid Dividers\"], \"color\", \"color\");\n\t\t\tconfigurePiece(\"at\", settings.chart[\"Axis Text\"], \"color\", \"color\");\n\n\t\t\tif (!themeName) themeName = \"My Theme\";\n\t\t\tthis.node.find(\"cq-action input\").val(themeName);\n\t\t}\n\n\t\t/**\n\t\t * Saves the custom theme and closes the theme dialog box.\n\t\t *\n\t\t * @alias save\n\t\t * @memberof WebComponents.cq-theme-dialog\n\t\t */\n\t\tsave() {\n\t\t\tvar themeName = this.node.find(\"cq-action input\").val();\n\t\t\tvar theme = {\n\t\t\t\tsettings: CIQ.clone(this.helper.settings),\n\t\t\t\tname: themeName,\n\t\t\t\tbuiltIn: null\n\t\t\t};\n\t\t\tCIQ.UI.contextsForEach(function () {\n\t\t\t\tthis.stx.updateListeners(\"theme\");\n\t\t\t}, this);\n\t\t\tvar self = this;\n\t\t\tthis.ownerDocument.querySelectorAll(\"cq-themes\").forEach(function (t) {\n\t\t\t\ttheme.builtIn = t.currentLoadedBuiltIn;\n\t\t\t\tt.addCustom(theme, self.initiatingMenu);\n\t\t\t});\n\t\t\tsuper.close();\n\t\t}\n\n\t\t/**\n\t\t * Sets a theme property, such as candle color, and applies the new property to all charts\n\t\t * on the screen.\n\t\t *\n\t\t * @param {object} obj Contains the properties of a theme element.\n\t\t * @param {string} field The property for which the new value is set.\n\t\t * @param {string} value The new value for the theme property.\n\t\t *\n\t\t * @alias setValue\n\t\t * @memberof WebComponents.cq-theme-dialog\n\t\t */\n\t\tsetValue(obj, field, value) {\n\t\t\tobj[field] = value;\n\t\t\tthis.applyChanges();\n\t\t}\n\t}\n\n\tThemeDialog.markup = `\n\t\t

Create Custom Theme

\n\t\t\n\t\t\n\t\t\t\n\t\t\t\tCandle Color\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\tCandle Wick\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\tCandle Border\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\tLine/Bar Chart\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\tMountain Base\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\tMountain Peak\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\tBackground\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\tGrid Lines\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\tDate Dividers\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\tAxis Text\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\t
Save
\n\t\t\t
\n\t\t
\n\t`;\n\tCIQ.UI.addComponentDefinition(\"cq-theme-dialog\", ThemeDialog);\n}\n\n};\n\n\nlet __js_webcomponents_themePiece_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Theme Piece web component ``.\n *\n * Manages themes in for chart layout.\n *\n * @namespace WebComponents.cq-theme-piece\n *\n * @example\n * \n * Background\n * \n * \n * Grid Lines\n * \n * \n * Date Dividers\n * \n * \n * Axis Text\n * \n * \n * \n */\nclass ThemePiece extends CIQ.UI.BaseComponent {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, ThemePiece);\n\t}\n\n\tsetBoolean(result) {\n\t\tCIQ.UI.containerExecute(\n\t\t\tthis,\n\t\t\t\"setValue\",\n\t\t\tthis.piece.obj,\n\t\t\tthis.piece.field,\n\t\t\tresult\n\t\t);\n\t}\n\n\t/**\n\t * @alias setColor\n\t * @memberof WebComponents.cq-theme-piece\n\t */\n\tsetColor(color) {\n\t\tif (color == \"Hollow\" || color == \"No Border\") {\n\t\t\tcolor = \"transparent\";\n\t\t\tthis.node.find(\"cq-swatch\")[0].setColor(\"transparent\", false);\n\t\t}\n\t\tCIQ.UI.containerExecute(\n\t\t\tthis,\n\t\t\t\"setValue\",\n\t\t\tthis.piece.obj,\n\t\t\tthis.piece.field,\n\t\t\tcolor\n\t\t);\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-theme-piece\", ThemePiece);\n\n};\n\n\nlet __js_webcomponents_themes_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Themes web component ``.\n *\n * This web component has two functions. The first is displaying available themes in a menu.\n * The second is providing a theme dialog for entering a new theme.\n *\n * Built in themes are merely the names of classes that will be added to the top element of the UIContext when\n * selected.\n *\n * @namespace WebComponents.cq-themes\n *\n * @example\n * \n * \n * \n * \n * \n * \n * \n * \n * New Theme \n * \n */\nclass Themes extends CIQ.UI.ContextTag {\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tsuper.connectedCallback();\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, Themes);\n\t\tthis.constructor = Themes;\n\t}\n\n\tsetContext({ config }) {\n\t\tif (!config) return; // grid does not provide config\n\t\tconst {\n\t\t\tchartId: id,\n\t\t\tthemes: { builtInThemes, defaultTheme }\n\t\t} = config;\n\t\tconst nameValueStore =\n\t\t\tconfig.themes.nameValueStore || config.nameValueStore;\n\t\tthis.initialize({ builtInThemes, defaultTheme, nameValueStore, id });\n\t}\n\n\t/**\n\t * Adds a custom theme\n\t * @memberof WebComponents.cq-themes\n\t * @param {object} theme The theme descriptor\n\t * @param {Themes} initiatingMenu The menu which initially called ThemeDialog. This is used in order to save the new theme as the current theme.\n\t */\n\taddCustom(theme, initiatingMenu) {\n\t\tthis.params.customThemes[theme.name] = theme;\n\t\tif (initiatingMenu === this) this.currentTheme = theme.name;\n\t\tthis.configureMenu();\n\t\tthis.persist();\n\t}\n\n\tconfigureMenu() {\n\t\tfunction loadBuiltIn(self, className) {\n\t\t\treturn function (e) {\n\t\t\t\tself.loadBuiltIn(className);\n\t\t\t\tif (self.params.callback) {\n\t\t\t\t\tself.params.callback({ theme: self.currentTheme });\n\t\t\t\t}\n\t\t\t\tself.persist(\"current\");\n\t\t\t};\n\t\t}\n\t\tfunction loadCustom(self, themeName) {\n\t\t\treturn function (e) {\n\t\t\t\tself.loadCustom(themeName);\n\t\t\t\tif (self.params.callback) {\n\t\t\t\t\tself.params.callback({ theme: self.currentTheme });\n\t\t\t\t}\n\t\t\t\tself.persist(\"current\");\n\t\t\t};\n\t\t}\n\t\tthis.builtInMenu.children(\":not(template)\").remove();\n\t\tthis.customMenu.children(\":not(template)\").remove();\n\t\tvar display, newMenuItem;\n\t\tvar builtInThemes = this.params.builtInThemes;\n\t\tfor (var className in builtInThemes) {\n\t\t\tdisplay = builtInThemes[className];\n\t\t\tnewMenuItem = CIQ.UI.makeFromTemplate(this.builtInTemplate);\n\t\t\tnewMenuItem.text(display);\n\t\t\tthis.makeTap(newMenuItem[0], loadBuiltIn(this, className));\n\t\t\tthis.builtInMenu.append(newMenuItem);\n\t\t}\n\t\tif (this.context.stx.translateUI)\n\t\t\tthis.context.stx.translateUI(this.builtInMenu[0]);\n\n\t\tif (this.customMenu.length && this.customTemplate.length) {\n\t\t\tvar customThemes = this.params.customThemes;\n\t\t\tfor (var themeName in customThemes) {\n\t\t\t\tdisplay = themeName;\n\t\t\t\tnewMenuItem = CIQ.UI.makeFromTemplate(this.customTemplate);\n\t\t\t\tnewMenuItem.find(\"cq-label\").text(display);\n\t\t\t\tthis.makeTap(\n\t\t\t\t\tnewMenuItem.find(\"cq-item\")[0],\n\t\t\t\t\tloadCustom(this, themeName)\n\t\t\t\t);\n\t\t\t\tnewMenuItem[0].close = (function (self, themeName) {\n\t\t\t\t\treturn function () {\n\t\t\t\t\t\tself.removeTheme(themeName);\n\t\t\t\t\t};\n\t\t\t\t})(this, themeName);\n\t\t\t\tthis.customMenu.append(newMenuItem);\n\t\t\t}\n\t\t}\n\t}\n\n\t/**\n\t * Initialize the web component\n\t * @param {Object} params Parameters\n\t * @param {Object} [params.builtInThemes] Object map of built-in theme names, display names\n\t * @param {Object} [params.defaultTheme] The default built-in theme to use\n\t * @param {Object} [params.nameValueStore] A {@link CIQ.NameValueStore} object for fetching and saving theme state\n\t * @param {string} [params.id] id which can be used to disambiguate when multiple charts are on the screen\n\t * @memberof WebComponents.cq-themes\n\t */\n\tinitialize(params) {\n\t\tif (this.initialized) return;\n\t\tthis.initialized = true;\n\n\t\tthis.addDefaultMarkup();\n\t\tthis.selectTemplates(this);\n\t\tthis.params = {};\n\t\tif (params) this.params = params;\n\t\tconst isConstructor = (check) => typeof check === \"function\";\n\t\tCIQ.ensureDefaults(this.params, {\n\t\t\tcustomThemes: {},\n\t\t\tbuiltInThemes: {},\n\t\t\tnameValueStore: CIQ.NameValueStore && new CIQ.NameValueStore()\n\t\t});\n\t\tif (this.params.id) this.id = \"themes_\" + this.params.id;\n\n\t\tlet self = this;\n\t\tlet { nameValueStore } = this.params;\n\t\tif (nameValueStore) {\n\t\t\tif (isConstructor(nameValueStore))\n\t\t\t\tnameValueStore = this.params.nameValueStore = new nameValueStore();\n\t\t\t// Retrieve any custom themes the user has created\n\t\t\tnameValueStore.get(\"CIQ.Themes.prototype.custom\", (err, result) => {\n\t\t\t\tif (!err && result) {\n\t\t\t\t\tself.params.customThemes = result;\n\t\t\t\t}\n\t\t\t\t// Set the current theme to the last one selected by user\n\t\t\t\tnameValueStore.get(\n\t\t\t\t\tself.id + \"CIQ.Themes.prototype.current\",\n\t\t\t\t\t(err, result) => {\n\t\t\t\t\t\tif (!err && result && result.theme) {\n\t\t\t\t\t\t\tself.loadTheme(result.theme);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tself.loadTheme(self.params.defaultTheme);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tself.configureMenu();\n\t\t\t\t\t}\n\t\t\t\t);\n\t\t\t});\n\t\t} else {\n\t\t\tthis.loadTheme(self.params.defaultTheme);\n\t\t}\n\t}\n\n\tloadBuiltIn(className) {\n\t\tif (this.currentLoadedBuiltIn) {\n\t\t\tthis.removeThemeClass(this.currentLoadedBuiltIn);\n\t\t}\n\t\tthis.addThemeClass(className);\n\t\tthis.currentLoadedBuiltIn = this.currentTheme = className;\n\t\tthis.reinitializeChart();\n\t}\n\n\tloadCustom(themeName) {\n\t\tif (this.currentLoadedBuiltIn) {\n\t\t\tthis.removeThemeClass(this.currentLoadedBuiltIn);\n\t\t}\n\t\tvar theme = this.params.customThemes[themeName];\n\t\tif (theme.builtIn) this.addThemeClass(theme.builtIn);\n\t\tthis.currentLoadedBuiltIn = theme.builtIn;\n\t\tthis.currentTheme = theme.name;\n\t\tthis.reinitializeChart(theme);\n\t}\n\n\tloadTheme(themeName) {\n\t\tif (this.params.customThemes[themeName]) this.loadCustom(themeName);\n\t\telse if (this.params.builtInThemes[themeName]) this.loadBuiltIn(themeName);\n\t\telse this.loadBuiltIn(this.params.defaultTheme);\n\t}\n\n\tget contextContainers() {\n\t\tconst topEl = this.context.topNode;\n\t\treturn [topEl].concat(Array.from(topEl.querySelectorAll(\"cq-context\")));\n\t}\n\n\taddThemeClass(name) {\n\t\tthis.contextContainers.forEach((container) =>\n\t\t\tcontainer.classList.add(name)\n\t\t);\n\t\tthis.context.topNode.setCurrentThemeClass = (container) => {\n\t\t\tcontainer.classList.add(name);\n\t\t};\n\t}\n\n\tremoveThemeClass(name) {\n\t\tthis.contextContainers.forEach((container) =>\n\t\t\tcontainer.classList.remove(name)\n\t\t);\n\t}\n\n\tnewTheme() {\n\t\tconst { context } = this;\n\t\tif (context.config) {\n\t\t\tthis.channelWrite(\n\t\t\t\tcontext.config.channels.dialog,\n\t\t\t\t{ type: \"theme\", params: { context, initiatingMenu: this } },\n\t\t\t\tcontext.stx\n\t\t\t);\n\t\t} else {\n\t\t\tdocument\n\t\t\t\t.querySelector(\"cq-theme-dialog\")\n\t\t\t\t.open({ context: this.context, initiatingMenu: this });\n\t\t}\n\t}\n\n\tpersist(which) {\n\t\tif (!this.params.nameValueStore) return;\n\t\tif (!which || which == \"current\")\n\t\t\tthis.params.nameValueStore.set(this.id + \"CIQ.Themes.prototype.current\", {\n\t\t\t\ttheme: this.currentTheme\n\t\t\t});\n\t\tif (!which || which == \"custom\")\n\t\t\tthis.params.nameValueStore.set(\n\t\t\t\t\"CIQ.Themes.prototype.custom\",\n\t\t\t\tthis.params.customThemes\n\t\t\t);\n\t}\n\n\tremoveTheme(themeName) {\n\t\tvar saved = false;\n\t\tthis.ownerDocument.querySelectorAll(\"cq-themes\").forEach(function (t) {\n\t\t\tdelete t.params.customThemes[themeName];\n\t\t\tt.configureMenu();\n\t\t\tif (!saved) {\n\t\t\t\tt.persist();\n\t\t\t\tsaved = true;\n\t\t\t}\n\t\t});\n\t}\n\n\tselectTemplates() {\n\t\tif (this.builtInMenu) return;\n\t\tthis.builtInMenu = this.node.find(\"cq-themes-builtin\");\n\t\tthis.builtInTemplate = this.builtInMenu.find(\"template\");\n\t\tthis.customMenu = this.node.find(\"cq-themes-custom\");\n\t\tthis.customTemplate = this.customMenu.find(\"template\");\n\t}\n\n\t/**\n\t * @private\n\t * @param {object} theme\n\t * @memberOf WebComponents.cq-themes\n\t */\n\treinitializeChart(theme) {\n\t\tconst isMultiChart = this.context.topNode.getCharts;\n\t\tconst charts = isMultiChart\n\t\t\t? this.context.topNode.getCharts()\n\t\t\t: [this.context.stx];\n\n\t\tcharts.forEach((stx) => {\n\t\t\tif (stx && stx.setThemeSettings) {\n\t\t\t\tstx.setThemeSettings(theme ? theme.settings : null);\n\t\t\t}\n\t\t});\n\t}\n}\n\nThemes.markup = `\n\t\t\n\t\t\t\n\t\t\n\t\t\n\t\t\t\n\t\t\n\t\tNew Theme\n\t`;\nCIQ.UI.addComponentDefinition(\"cq-themes\", Themes);\n\n};\n\n\nlet __js_webcomponents_timezoneDialog_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nif (!CIQ.timeZoneMap) {\n\tconsole.error(\n\t\t\"timezoneDialog component requires first activating timezone feature.\"\n\t);\n} else {\n\t/**\n\t * Time zone dialog web component ``.\n\t *\n\t * @namespace WebComponents.cq-timezone-dialog\n\t */\n\tclass TimezoneDialog extends CIQ.UI.DialogContentTag {\n\t\tadoptedCallback() {\n\t\t\tsuper.adoptedCallback();\n\t\t\tCIQ.UI.flattenInheritance(this, TimezoneDialog);\n\t\t\tthis.constructor = TimezoneDialog;\n\t\t}\n\n\t\t/**\n\t\t * Opens the dialog and sets the time zone selected by the user.\n\t\t *\n\t\t * @alias open\n\t\t * @memberof WebComponents.cq-timezone-dialog\n\t\t */\n\t\topen(params) {\n\t\t\tthis.addDefaultMarkup();\n\t\t\tsuper.open(params);\n\t\t\tvar node = this.node;\n\t\t\tvar self = this;\n\t\t\tthis.context = params.context;\n\t\t\tvar stx = this.context.stx;\n\n\t\t\tfunction setTimezone(zone) {\n\t\t\t\treturn function (e) {\n\t\t\t\t\tself.close();\n\t\t\t\t\tvar translatedZone = CIQ.timeZoneMap[zone];\n\t\t\t\t\tCIQ.ChartEngine.defaultDisplayTimeZone = translatedZone;\n\t\t\t\t\tstx.setTimeZone(stx.dataZone, translatedZone);\n\t\t\t\t\tif (stx.chart.symbol) stx.draw();\n\t\t\t\t};\n\t\t\t}\n\n\t\t\tvar ul = node.find(\"ul, .ciq-ul\");\n\t\t\tvar button = node.find(\".ciq-btn\");\n\t\t\tif (!this.template) {\n\t\t\t\tthis.template = ul.find(\"li.timezoneTemplate\")[0].cloneNode(true);\n\t\t\t}\n\n\t\t\tul.empty();\n\t\t\tfor (var key in CIQ.timeZoneMap) {\n\t\t\t\tvar zone = key;\n\t\t\t\tvar display = stx.translateIf(zone);\n\t\t\t\tvar li = this.template.cloneNode(true);\n\t\t\t\tli.style.display = \"block\";\n\t\t\t\tli.innerHTML = display;\n\t\t\t\tCIQ.safeClickTouch(li, setTimezone(zone));\n\t\t\t\tul.append(li);\n\t\t\t}\n\t\t\tvar currentUserTimeZone = node.find(\".currentUserTimeZone\");\n\t\t\tif (stx.displayZone) {\n\t\t\t\tvar fullZone = stx.displayZone;\n\t\t\t\tfor (var tz in CIQ.timeZoneMap) {\n\t\t\t\t\tif (CIQ.timeZoneMap[tz] === stx.displayZone) fullZone = tz;\n\t\t\t\t}\n\t\t\t\tcurrentUserTimeZone.text(\n\t\t\t\t\tstx.translateIf(\"Current Timezone is\") +\n\t\t\t\t\t\t\" \" +\n\t\t\t\t\t\tstx.translateIf(fullZone)\n\t\t\t\t);\n\t\t\t\tbutton.show();\n\t\t\t} else {\n\t\t\t\tcurrentUserTimeZone.text(\n\t\t\t\t\tstx.translateIf(\"Your timezone is your current location\")\n\t\t\t\t);\n\t\t\t\tbutton.hide();\n\t\t\t}\n\t\t}\n\n\t\t/**\n\t\t * Removes any user-selected time zone settings, and sets the time zone to the user's\n\t\t * current location.\n\t\t *\n\t\t * @alias removeTimeZone\n\t\t * @memberof WebComponents.cq-timezone-dialog\n\t\t */\n\t\tremoveTimezone() {\n\t\t\tCIQ.ChartEngine.defaultDisplayTimeZone = null;\n\t\t\tvar stx = this.context.stx;\n\t\t\tstx.displayZone = null;\n\t\t\tstx.setTimeZone();\n\n\t\t\tif (stx.displayInitialized) stx.draw();\n\n\t\t\tthis.close();\n\t\t}\n\t}\n\n\tTimezoneDialog.markup = `\n\t\t

Choose Timezone

\n\t\t\n\n\t\t

To set your timezone use the location button below, or scroll through the following list...

\n\t\t

\n\t\t
\n\t\t\t
Use My Current Location
\n\t\t
\n\t\t
\n\t\t\t\n\t\t\t\t
  • \n\t\t\t
    \n\t\t
    \n\t\t
    (Scroll for more options)
    \n\t`;\n\tCIQ.UI.addComponentDefinition(\"cq-timezone-dialog\", TimezoneDialog);\n}\n\n};\n\n\nlet __js_webcomponents_toggle_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Creates the `` web component.\n *\n * UI Helper that binds a toggle to an object member or to callback functions when toggled.\n *\n * **Attributes**\n * - `cq-member` — Object member to observe. If not provided, then callbacks are used\n * exclusively.\n * - `cq-action` — Action to take. Default is \"class\".\n * - `cq-value` — Value for the action (i.e., class name). Default is \"active\".\n * - `cq-toggles` — A comma-separated list of values which are toggled through with each\n * click. The list can include \"null\". Stringified booleans and \"null\" are converted to their\n * primitive values. All other values are passed to the Number constructor. If the result is a\n * number (not NaN), the number is used. Otherwise the value is left as a string.\n * - `cq-toggle-classes` — A comma-separated list of classes associated with the toggle\n * setting. If a setting requires multiple classes, they need to be separated with spaces.\n *\n * Use [registerCallback](WebComponents.cq-toggle.html#registerCallback) to receive a callback\n * every time the toggle changes. When a callback is registered, any automatic class changes are\n * bypassed.\n *\n * @since 2015\n * @namespace WebComponents.cq-toggle\n *\n * @example\n * document.querySelector(\"cq-toggle\").registerCallback(function(value){\n * console.log(\"current value is \" + value);\n * if(value!=false) this.node.addClass(\"active\");\n * })\n */\nclass Toggle extends CIQ.UI.ContextTag {\n\tconstructor() {\n\t\tsuper();\n\t\tthis.params = {\n\t\t\tmember: null,\n\t\t\tobj: null,\n\t\t\taction: \"class\",\n\t\t\tvalue: \"active\",\n\t\t\ttoggles: [],\n\t\t\tclasses: {},\n\t\t\tcallbacks: []\n\t\t};\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, Toggle);\n\t}\n\n\tdisconnectedCallback() {\n\t\tthis.disconnectObservable();\n\t\tsuper.disconnectedCallback();\n\t}\n\n\tdisconnectObservable() {\n\t\tconst {\n\t\t\tparams: { member, obj },\n\t\t\tlistener\n\t\t} = this;\n\t\tif (member && obj && listener)\n\t\t\tCIQ.UI.unobserveProperty(member, obj, listener);\n\t}\n\n\tbegin() {\n\t\tconst self = this;\n\n\t\tif (this.params.member) {\n\t\t\tthis.listener = function (obj) {\n\t\t\t\tself.updateFromBinding(self.params);\n\t\t\t};\n\t\t\tCIQ.UI.observeProperty(\n\t\t\t\tself.params.member,\n\t\t\t\tself.params.obj,\n\t\t\t\tthis.listener\n\t\t\t);\n\t\t}\n\t\tif (this.tapInitialized) return;\n\t\tCIQ.UI.stxtap(this, function () {\n\t\t\tvar toggles = self.params.toggles;\n\t\t\tvar obj = self.params.obj;\n\t\t\tif (toggles.length > 1) {\n\t\t\t\t// Cycle through each field in the array with each tap\n\t\t\t\tfor (var i = 0; i < toggles.length; i++) {\n\t\t\t\t\tvar toggle = toggles[i];\n\t\t\t\t\tif (self.currentValue == toggle) {\n\t\t\t\t\t\tif (i < toggles.length - 1) self.set(toggles[i + 1]);\n\t\t\t\t\t\telse self.set(toggles[0]);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (i == toggles.length) {\n\t\t\t\t\t// default to first item in toggle\n\t\t\t\t\tself.set(toggles[0]);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tif (self.currentValue) {\n\t\t\t\t\tself.set(false);\n\t\t\t\t} else {\n\t\t\t\t\tself.set(true);\n\t\t\t\t}\n\t\t\t}\n\t\t\tconst { stx } = this.context;\n\t\t\tstx.draw();\n\t\t\tif (obj === stx.layout) stx.changeOccurred(\"layout\");\n\t\t\tif (obj === stx.preferences) stx.changeOccurred(\"preferences\");\n\t\t});\n\t\tthis.tapInitialized = true;\n\t}\n\n\t/**\n\t * Adds a callback function to the toggle.\n\t *\n\t * @param {function} fc The callback function to add to the toggle. The function accepts the\n\t * \t\tcurrent value of the toggle as a parameter. The value of `this` within the callback\n\t * \t\tfunction is the toggle component.\n\t * @param {boolean} immediate A flag that indicates whether to immediately call the callback\n\t * \t\tfunction after it has been registered with the toggle.\n\t *\n\t * @alias registerCallback\n\t * @memberof WebComponents.cq-toggle\n\t * @since 2015\n\t */\n\tregisterCallback(fc, immediate) {\n\t\tif (immediate !== false) immediate = true;\n\t\tthis.params.callbacks.push(fc);\n\t\tif (immediate) fc.call(this, this.currentValue);\n\t}\n\n\tset(value) {\n\t\tif (this.isInfoToggle) return this.parentElement.set(value);\n\n\t\tif (this.params.member) {\n\t\t\tthis.params.obj[this.params.member] = value;\n\t\t} else {\n\t\t\tthis.currentValue = value;\n\t\t\tfor (var i = 0; i < this.params.callbacks.length; i++) {\n\t\t\t\tthis.params.callbacks[i].call(this, this.currentValue);\n\t\t\t}\n\t\t}\n\t\tthis.updateClass();\n\t}\n\n\tsetContext({ config }) {\n\t\tthis.currentValue |= false; // if it were set to true before, leave it\n\t\tthis.params.obj = this.context.stx.layout;\n\t\tvar member = this.node.attr(\"cq-member\");\n\t\tif (member == \"headsUp\") this.wrapInInfoToggle();\n\t\tif (config && config.channels && config.channels[member]) {\n\t\t\tmember = config.channels[member];\n\t\t}\n\t\tif (member && member.indexOf(\".\") !== -1) {\n\t\t\tvar m = member.split(\".\");\n\t\t\tthis.params.obj = this.context.stx[m[0]];\n\t\t\tif (typeof this.params.obj === \"undefined\") {\n\t\t\t\tthis.context.stx[m[0]] = this.params.obj = {};\n\t\t\t}\n\t\t\tmember = m[1];\n\t\t}\n\t\tif (member) this.params.member = member;\n\t\tvar action = this.node.attr(\"cq-action\");\n\t\tif (action) this.params.action = action;\n\t\tvar value = this.node.attr(\"cq-value\");\n\t\tif (value) this.params.value = value;\n\t\tvar toggles = this.node.attr(\"cq-toggles\");\n\t\tif (toggles) this.params.toggles = toggles.split(\",\");\n\t\t// By default anything in the toggle attribute will be a string, which can cause issues when observing a member b/c \"true\"!==true\n\t\t// Here we are setting \"true\", \"false\", and \"null\" to be their native alternatives instead of strings.\n\t\t// We also check to see if we can cast the number and if it is not NaN we change it to be a number.\n\t\t// Be aware this will change an empty string to 0 but you shouldn't be setting an empty string!\n\t\tfor (var i = 0; i < this.params.toggles.length; i++) {\n\t\t\ttoggles = this.params.toggles;\n\t\t\tvar toggle = toggles[i];\n\t\t\tif (toggle === \"null\") toggles[i] = null;\n\t\t\telse if (toggle === \"true\" || toggle === \"false\")\n\t\t\t\ttoggles[i] = toggle === \"true\";\n\t\t\telse if (!isNaN(Number(toggle))) toggles[i] = Number(toggle);\n\t\t}\n\t\t// associate class with toggle setting\n\t\tvar toggleClasses = this.node.attr(\"cq-toggle-classes\");\n\t\tif (toggleClasses) {\n\t\t\t// extract an array of class settings from comma or comma-space separated class list\n\t\t\tvar toggleClassArr = toggleClasses.split(/, |,/);\n\n\t\t\t// find classes to be cleared when new setting is applied,\n\t\t\t// taking in account that a setting can have more than one space separated class assigned\n\t\t\tthis.params.removeClasses = toggleClasses\n\t\t\t\t.split(/, | |,/)\n\t\t\t\t.filter((el) => el);\n\n\t\t\t// associate each setting with applicable class(es)\n\t\t\tthis.params.classes = this.params.toggles.reduce(function (\n\t\t\t\tclassLookup,\n\t\t\t\tsetting,\n\t\t\t\tindex\n\t\t\t) {\n\t\t\t\tclassLookup[setting] = toggleClassArr[index].split(/ /);\n\t\t\t\treturn classLookup;\n\t\t\t},\n\t\t\t{});\n\t\t}\n\t\t// set default value if object[member] is undefined\n\t\tif (member && this.params.obj[member] === undefined) {\n\t\t\tconst defaultValue =\n\t\t\t\ttoggles && toggles.length ? toggles[toggles.length - 1] : false;\n\t\t\tthis.params.obj[member] = defaultValue;\n\t\t}\n\n\t\tthis.begin();\n\t}\n\n\tchangeContext(newContext) {\n\t\tthis.disconnectObservable();\n\t\tthis.context = newContext;\n\t\tthis.setContext(newContext);\n\t}\n\n\tupdateFromBinding(params) {\n\t\tthis.currentValue = this.isInfoToggle\n\t\t\t? this.parentElement.getCurrentValue(params)\n\t\t\t: params.obj[params.member];\n\n\t\tif (!this.params.callbacks.length) {\n\t\t\tif (this.params.action == \"class\") {\n\t\t\t\tif (this.currentValue) {\n\t\t\t\t\tthis.node.addClass(this.params.value);\n\t\t\t\t} else {\n\t\t\t\t\tthis.node.removeClass(this.params.value);\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\tfor (var i = 0; i < this.params.callbacks.length; i++) {\n\t\t\t\tthis.params.callbacks[i].call(this, this.currentValue);\n\t\t\t}\n\t\t}\n\t\tthis.updateClass();\n\t\tif (params.member == \"crosshair\" && this.currentValue === false)\n\t\t\tthis.context.stx.doDisplayCrosshairs();\n\t}\n\n\tupdateClass() {\n\t\tconst { removeClasses, classes } = this.params;\n\t\tif (!removeClasses || this.currentValue === undefined) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.classList.remove(...removeClasses);\n\t\tif (classes[this.currentValue][0]) {\n\t\t\tlet currentClasses = classes[this.currentValue];\n\t\t\tthis.classList.add(...currentClasses);\n\t\t}\n\t}\n\n\twrapInInfoToggle() {\n\t\t// inserts a cq-info-toggle around the headsUp cq-toggle if there is none, because it needs it to function\n\t\tif (this.closest(\"cq-info-toggle, cq-info-toggle-dropdown\")) return;\n\t\tvar infoToggle = document.createElement(\"cq-info-toggle\");\n\t\tthis.parentNode.replaceChild(infoToggle, this);\n\t\tinfoToggle.appendChild(this);\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-toggle\", Toggle);\n\n};\n\n\nlet __js_webcomponents_toolbar_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nif (!CIQ.Drawing) {\n\tconsole.error(\"toolbar component requires first activating drawing feature.\");\n} else {\n\t/**\n\t * Drawing toolbar web component used to activate and manage available drawings.\n\t *\n\t * Emits a \"change\" event when changed.\n\t *\n\t * @namespace WebComponents.cq-toolbar\n\t * @example\n\t * \n\t * \n\t * Select Tool\n\t * \n\t * None\n\t * Clear All Drawings\n\t * Restore Default Parameters\n\t * Measure\n\t * \n\t * Annotation\n\t * Average Line\n\t * Callout\n\t * Channel\n\t * Continuous\n\t * Crossline\n\t * Doodle\n\t * Ellipse\n\t * Fib Retracement\n\t * Fib Projection\n\t * Fib Arc\n\t * Fib Fan\n\t * Fib Time Zone\n\t * Gann Fan\n\t * Gartley\n\t * Horizontal\n\t * Line\n\t * Pitchfork\n\t * Quadrant Lines\n\t * Ray\n\t * Rectangle\n\t * Regression Line\n\t * Segment\n\t * Shape - Arrow\n\t * Shape - Check\n\t * Shape - Cross\n\t * Shape - Focus\n\t * Shape - Heart\n\t * Shape - Star\n\t * Speed Resistance Arc\n\t * Speed Resistance Line\n\t * Time Cycle\n\t * Tirone Levels\n\t * Trend Line\n\t * Vertical\n\t * \n\t * \n\t * \n\t * \n\t * \n\t * \n\t *
    \n\t * \n\t * \n\t * \n\t * \n\t * \n\t * \n\t * \n\t * \n\t * \n\t * \n\t * \n\t * \n\t * \n\t * \n\t * None\n\t * \n\t * \n\t * \n\t *
    \n\t * \n\t *
    Axis Label:
    \n\t * \n\t *
    \n\t * \n\t * I\n\t * B\n\t * \n\t * 12px\n\t * \n\t * 8\n\t * 10\n\t * 12\n\t * 13\n\t * 14\n\t * 16\n\t * 20\n\t * 28\n\t * 36\n\t * 48\n\t * 64\n\t * \n\t * \n\t * \n\t * Default\n\t * \n\t * Default\n\t * Helvetica\n\t * Courier\n\t * Garamond\n\t * Palatino\n\t * Times New Roman\n\t * \n\t * \n\t * \n\t * Settings\n\t *
    Save Config
    \n\t *
    Restore Config
    \n\t *
    \n\t * \n\t * \n\t * Undo\n\t * Redo\n\t * \n\t *
    \n\t */\n\tclass DrawingToolbar extends CIQ.UI.ContextTag {\n\t\tconnectedCallback() {\n\t\t\tif (this.attached) return;\n\t\t\tsuper.connectedCallback();\n\t\t\tthis.params = {\n\t\t\t\ttoolSelection: this.node.find(\"*[cq-current-tool]\"),\n\t\t\t\tlineSelection: this.node.find(\"*[cq-line-style]\"),\n\t\t\t\tfontSizeSelection: this.node.find(\"*[cq-font-size]\"),\n\t\t\t\tfontFamilySelection: this.node.find(\"*[cq-font-family]\"),\n\t\t\t\tfontStyleToggle: this.node.find(\"cq-annotation-italic\"),\n\t\t\t\tfontWeightToggle: this.node.find(\"cq-annotation-bold\"),\n\t\t\t\taxisLabelToggle: this.node.find(\"cq-axis-label .ciq-checkbox\"),\n\t\t\t\tfillColor: this.node.find(\"cq-fill-color\").not(\"cq-cvp-controller\"),\n\t\t\t\tlineColor: this.node.find(\"cq-line-color\").not(\"cq-cvp-controller\"),\n\t\t\t\tcvpControllers: this.node.find(\"cq-cvp-controller\")\n\t\t\t};\n\t\t\tthis.params.cvpControllers.prop(\"toolbar\", this);\n\t\t\tthis.noToolSelectedText = \"\";\n\t\t}\n\n\t\tadoptedCallback() {\n\t\t\tsuper.adoptedCallback();\n\t\t\tCIQ.UI.flattenInheritance(this, DrawingToolbar);\n\t\t}\n\n\t\tclearDrawings() {\n\t\t\tthis.context.stx.clearDrawings(null, false);\n\t\t}\n\n\t\tcrosshairs(activator) {\n\t\t\tvar node = CIQ.UI.$(activator.node);\n\t\t\tvar stx = this.context.stx;\n\t\t\tthis.params.toolSelection.html(node.html());\n\t\t\tstx.changeVectorType(null);\n\t\t\tstx.layout.crosshair = true;\n\t\t\tstx.doDisplayCrosshairs();\n\t\t\tstx.findHighlights(false, true);\n\t\t\tstx.changeOccurred(\"layout\");\n\t\t\tstx.draw();\n\t\t\tstx.updateChartAccessories();\n\t\t\tthis.node.find(\"*[cq-section]\").removeClass(\"ciq-active\");\n\t\t\tthis.emit();\n\t\t}\n\n\t\tdefaultElements(drawingParameters) {\n\t\t\tvar arr = [];\n\t\t\tfor (var param in drawingParameters) {\n\t\t\t\tif (param == \"color\") arr.push(\"cq-line-color\");\n\t\t\t\telse if (param == \"fillColor\") arr.push(\"cq-fill-color\");\n\t\t\t\telse if (param == \"pattern\" || param == \"lineWidth\")\n\t\t\t\t\tarr.push(\"cq-line-style\");\n\t\t\t\telse if (param == \"axisLabel\") arr.push(\"cq-axis-label\");\n\t\t\t\telse if (param == \"font\") arr.push(\"cq-annotation\");\n\t\t\t\telse if (param == \"parameters\") arr.push(\"cq-clickable\");\n\t\t\t}\n\n\t\t\treturn arr;\n\t\t}\n\n\t\tdirty(on) {\n\t\t\tthis.node\n\t\t\t\t.find(\"*[cq-toolbar-dirty]\")\n\t\t\t\t[on === false ? \"removeClass\" : \"addClass\"](\"ciq-active\");\n\t\t}\n\n\t\temit() {\n\t\t\tvar event = new Event(\"change\", {\n\t\t\t\tbubbles: true,\n\t\t\t\tcancelable: true\n\t\t\t});\n\t\t\tthis.dirty();\n\t\t\tthis.dispatchEvent(event);\n\t\t}\n\n\t\tgetFillColor(activator) {\n\t\t\tvar node = CIQ.UI.$(activator.node);\n\t\t\tvar color = this.context.stx.currentVectorParameters.fillColor;\n\t\t\tif (color == \"transparent\" || color == \"auto\") color = \"\";\n\t\t\tnode.css({ background: color });\n\t\t\tvar bgColor = CIQ.getBackgroundColor(this.parentNode);\n\t\t\tif (color && Math.abs(CIQ.hsl(bgColor)[2] - CIQ.hsl(color)[2]) < 0.2) {\n\t\t\t\tvar border = CIQ.chooseForegroundColor(bgColor);\n\t\t\t\tnode.css({ border: \"solid \" + border + \" 1px\" });\n\t\t\t} else {\n\t\t\t\tnode.css({ border: \"\" });\n\t\t\t}\n\t\t}\n\n\t\tgetLineColor(activator) {\n\t\t\tvar node = CIQ.UI.$(activator.node);\n\t\t\tvar color = this.context.stx.currentVectorParameters.currentColor;\n\t\t\tif (color == \"transparent\" || color == \"auto\") color = \"\";\n\t\t\tnode.css({ background: color });\n\t\t\tvar bgColor = CIQ.getBackgroundColor(this.parentNode);\n\t\t\tif (!color || Math.abs(CIQ.hsl(bgColor)[2] - CIQ.hsl(color)[2]) < 0.2) {\n\t\t\t\tvar border = CIQ.chooseForegroundColor(bgColor);\n\t\t\t\tnode.css({ border: \"solid \" + border + \" 1px\" });\n\t\t\t\tif (!color)\n\t\t\t\t\tnode.css({\n\t\t\t\t\t\tbackground:\n\t\t\t\t\t\t\t\"linear-gradient(to bottom right, \" +\n\t\t\t\t\t\t\tborder +\n\t\t\t\t\t\t\t\", \" +\n\t\t\t\t\t\t\tborder +\n\t\t\t\t\t\t\t\" 49%, \" +\n\t\t\t\t\t\t\tbgColor +\n\t\t\t\t\t\t\t\" 50%, \" +\n\t\t\t\t\t\t\tbgColor +\n\t\t\t\t\t\t\t\")\"\n\t\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tnode.css({ border: \"\" });\n\t\t\t}\n\t\t}\n\n\t\tnoTool() {\n\t\t\tvar stx = this.context.stx;\n\t\t\tstx.changeVectorType(\"\");\n\t\t\tif (stx.layout.crosshair) {\n\t\t\t\tstx.layout.crosshair = false;\n\t\t\t\tstx.changeOccurred(\"layout\");\n\t\t\t\tstx.doDisplayCrosshairs();\n\t\t\t}\n\t\t\tif (stx.preferences.magnet) {\n\t\t\t\tthis.toggleMagnet(this);\n\t\t\t}\n\t\t\tthis.params.toolSelection.text(this.noToolSelectedText);\n\t\t\tthis.params.toolSelection.attr(\"cq-current-tool\", \"\");\n\t\t\tthis.node.find(\"*[cq-section]\").removeClass(\"ciq-active\");\n\t\t\tthis.emit();\n\t\t}\n\n\t\tpickFillColor(activator) {\n\t\t\tvar node = CIQ.UI.$(activator.node);\n\t\t\tvar colorPicker = this.ownerDocument.querySelector(\"cq-color-picker\");\n\t\t\tif (!colorPicker) {\n\t\t\t\tconsole.log(\n\t\t\t\t\t\"DrawingToolbar.prototype.pickFillColor: no ColorPicker available\"\n\t\t\t\t);\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tvar self = this;\n\t\t\tcolorPicker.callback = function (color) {\n\t\t\t\tself.context.stx.currentVectorParameters.fillColor = color;\n\t\t\t\tself.getFillColor({ node });\n\t\t\t\tself.emit();\n\t\t\t};\n\t\t\tcolorPicker.display({ node, context: this.context });\n\t\t}\n\n\t\tpickLineColor(activator) {\n\t\t\tvar node = CIQ.UI.$(activator.node);\n\t\t\tvar colorPicker = this.ownerDocument.querySelector(\"cq-color-picker\");\n\t\t\tif (!colorPicker) {\n\t\t\t\tconsole.log(\n\t\t\t\t\t\"DrawingToolbar.prototype.pickLineColor: no ColorPicker available\"\n\t\t\t\t);\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tvar self = this;\n\t\t\tcolorPicker.callback = function (color) {\n\t\t\t\tself.context.stx.currentVectorParameters.currentColor = color;\n\t\t\t\tself.getLineColor({ node });\n\t\t\t\tself.emit();\n\t\t\t};\n\t\t\tvar overrides = node.attr(\"cq-overrides\");\n\t\t\tif (overrides) overrides = overrides.split(\",\");\n\t\t\tcolorPicker.display({ node, context: this.context, overrides });\n\t\t}\n\n\t\trestoreDefaultConfig(activator, all) {\n\t\t\tvar stx = this.context.stx;\n\t\t\tCIQ.Drawing.restoreDefaultConfig(\n\t\t\t\tstx,\n\t\t\t\tstx.currentVectorParameters.vectorType,\n\t\t\t\tall\n\t\t\t);\n\t\t\tthis.node\n\t\t\t\t.find(\"*[cq-toolbar-action='restore']\")\n\t\t\t\t.removeClass(\"ciq-active\");\n\t\t\tthis.sync();\n\t\t\tthis.dirty(false);\n\t\t}\n\n\t\tsaveConfig() {\n\t\t\tvar stx = this.context.stx;\n\t\t\tCIQ.Drawing.saveConfig(stx, stx.currentVectorParameters.vectorType);\n\t\t\tthis.node.find(\"*[cq-toolbar-action='restore']\").addClass(\"ciq-active\");\n\t\t\tthis.sync();\n\t\t\tthis.dirty(false);\n\t\t}\n\n\t\tsetFibs(width, pattern) {\n\t\t\tvar fib = this.context.stx.currentVectorParameters.fibonacci;\n\t\t\tif (fib) {\n\t\t\t\tfor (var i = 0; i < fib.fibs.length; i++) {\n\t\t\t\t\tfib.fibs[i].parameters.lineWidth = width;\n\t\t\t\t\tfib.fibs[i].parameters.pattern = pattern;\n\t\t\t\t}\n\t\t\t\tfib.timezone.parameters.lineWidth = width;\n\t\t\t\tfib.timezone.parameters.pattern = pattern;\n\t\t\t}\n\t\t}\n\n\t\tsetFontFamily(activator, fontFamily) {\n\t\t\tvar stx = this.context.stx;\n\n\t\t\tif (stx.currentVectorParameters.annotation) {\n\t\t\t\tif (fontFamily == \"Default\") {\n\t\t\t\t\tstx.currentVectorParameters.annotation.font.family = null;\n\t\t\t\t} else {\n\t\t\t\t\tstx.currentVectorParameters.annotation.font.family = fontFamily;\n\t\t\t\t}\n\t\t\t}\n\t\t\tthis.params.fontFamilySelection.text(fontFamily);\n\t\t\tthis.emit();\n\t\t}\n\n\t\tsetFontSize(activator, fontSize) {\n\t\t\tvar stx = this.context.stx;\n\n\t\t\tif (stx.currentVectorParameters.annotation)\n\t\t\t\tstx.currentVectorParameters.annotation.font.size = fontSize;\n\t\t\tthis.params.fontSizeSelection.text(fontSize);\n\t\t\tthis.emit();\n\t\t}\n\n\t\tsetContext(context) {\n\t\t\tthis.noToolSelectedText = this.params.toolSelection.text();\n\t\t\tthis.sync();\n\t\t\tthis.dirty(false);\n\t\t\tvar self = this;\n\t\t\tthis.eventListeners.push(\n\t\t\t\tcontext.stx.addEventListener(\"theme\", function (obj) {\n\t\t\t\t\tvar isDirty = self.node\n\t\t\t\t\t\t.find(\"*[cq-toolbar-dirty]\")\n\t\t\t\t\t\t.hasClass(\"ciq-active\");\n\t\t\t\t\tself.sync();\n\t\t\t\t\tif (!isDirty) self.dirty(false);\n\t\t\t\t})\n\t\t\t);\n\t\t}\n\n\t\tsetLine(activator, width, pattern) {\n\t\t\tvar stx = this.context.stx;\n\n\t\t\tstx.currentVectorParameters.lineWidth = width;\n\t\t\tstx.currentVectorParameters.pattern = pattern;\n\t\t\tthis.setFibs(width, pattern);\n\t\t\tif (this.currentLineSelectedClass)\n\t\t\t\tthis.params.lineSelection.removeClass(this.currentLineSelectedClass);\n\t\t\tthis.currentLineSelectedClass =\n\t\t\t\t\"ciq-\" + pattern + \"-\" + parseInt(width, 10);\n\t\t\tif (pattern == \"none\") {\n\t\t\t\tthis.currentLineSelectedClass = null;\n\t\t\t} else {\n\t\t\t\tthis.params.lineSelection.addClass(this.currentLineSelectedClass);\n\t\t\t}\n\t\t\tthis.emit();\n\t\t}\n\n\t\t/**\n\t\t * Synchronizes the drawing toolbar with stx.currentVectorParameters. Poor man's data binding.\n\t\t * @param {object} [cvp=stx.currentVectorParameters] A new drawing object, otherwise defaults to the current one\n\t\t * @memberof WebComponents.cq-toolbar\n\t\t */\n\t\tsync(cvp) {\n\t\t\tvar stx = this.context.stx;\n\t\t\tif (!cvp) cvp = stx.currentVectorParameters;\n\t\t\telse\n\t\t\t\tstx.currentVectorParameters = CIQ.extend(\n\t\t\t\t\tstx.currentVectorParameters || {},\n\t\t\t\t\tcvp\n\t\t\t\t);\n\n\t\t\tvar params = this.params;\n\t\t\tthis.setLine(null, cvp.lineWidth, cvp.pattern);\n\n\t\t\tvar style = stx.canvasStyle(\"stx_annotation\");\n\n\t\t\tvar font = cvp.annotation && cvp.annotation.font;\n\n\t\t\tvar initialSize = (font && font.size) || style.fontSize;\n\t\t\tthis.setFontSize(null, initialSize);\n\n\t\t\tvar initialFamily = (font && font.family) || style.fontFamily;\n\t\t\tthis.setFontFamily(null, initialFamily);\n\n\t\t\tvar initialFontStyle = (font && font.style) || style.fontStyle;\n\t\t\tparams.fontStyleToggle[\n\t\t\t\tinitialFontStyle === \"italic\" ? \"addClass\" : \"removeClass\"\n\t\t\t](\"ciq-active\");\n\n\t\t\tvar initialWeight = (font && font.weight) || style.fontWeight;\n\t\t\tparams.fontWeightToggle[\n\t\t\t\tinitialWeight === \"bold\" || initialWeight >= 700\n\t\t\t\t\t? \"addClass\"\n\t\t\t\t\t: \"removeClass\"\n\t\t\t](\"ciq-active\");\n\n\t\t\tparams.axisLabelToggle[cvp.axisLabel ? \"addClass\" : \"removeClass\"](\n\t\t\t\t\"ciq-active\"\n\t\t\t);\n\n\t\t\tthis.getFillColor({ node: params.fillColor });\n\t\t\tthis.getLineColor({ node: params.lineColor });\n\n\t\t\tparams.cvpControllers.each(function () {\n\t\t\t\tthis.sync(cvp);\n\t\t\t});\n\t\t}\n\n\t\ttoggleAxisLabel(activator) {\n\t\t\tvar stx = this.context.stx;\n\t\t\tvar node = CIQ.UI.$(activator.node);\n\n\t\t\tif (stx.currentVectorParameters.axisLabel === true) {\n\t\t\t\tstx.currentVectorParameters.axisLabel = false;\n\t\t\t\tnode.removeClass(\"ciq-active\");\n\t\t\t} else {\n\t\t\t\tstx.currentVectorParameters.axisLabel = true;\n\t\t\t\tnode.addClass(\"ciq-active\");\n\t\t\t}\n\t\t\tthis.emit();\n\t\t}\n\n\t\ttoggleFontStyle(activator, fontStyle) {\n\t\t\tvar stx = this.context.stx;\n\t\t\tvar node = CIQ.UI.$(activator.node);\n\n\t\t\tif (fontStyle == \"italic\") {\n\t\t\t\tif (stx.currentVectorParameters.annotation.font.style == \"italic\") {\n\t\t\t\t\tstx.currentVectorParameters.annotation.font.style = null;\n\t\t\t\t\tnode.removeClass(\"ciq-active\");\n\t\t\t\t} else {\n\t\t\t\t\tstx.currentVectorParameters.annotation.font.style = \"italic\";\n\t\t\t\t\tnode.addClass(\"ciq-active\");\n\t\t\t\t}\n\t\t\t} else if (fontStyle == \"bold\") {\n\t\t\t\tif (stx.currentVectorParameters.annotation.font.weight == \"bold\") {\n\t\t\t\t\tstx.currentVectorParameters.annotation.font.weight = null;\n\t\t\t\t\tnode.removeClass(\"ciq-active\");\n\t\t\t\t} else {\n\t\t\t\t\tstx.currentVectorParameters.annotation.font.weight = \"bold\";\n\t\t\t\t\tnode.addClass(\"ciq-active\");\n\t\t\t\t}\n\t\t\t}\n\t\t\tthis.emit();\n\t\t}\n\n\t\ttoggleMagnet(activator) {\n\t\t\tvar toggle = CIQ.UI.$(activator.node);\n\t\t\tvar stx = this.context.stx;\n\t\t\tif (stx.preferences.magnet) {\n\t\t\t\ttoggle.removeClass(\"active\");\n\t\t\t\tstx.preferences.magnet = false;\n\t\t\t} else {\n\t\t\t\ttoggle.addClass(\"active\");\n\t\t\t\tstx.preferences.magnet = true;\n\t\t\t}\n\t\t\tCIQ.clearCanvas(stx.chart.tempCanvas, stx);\n\t\t}\n\n\t\ttool(activator, toolName) {\n\t\t\tvar node = CIQ.UI.$(activator.node);\n\t\t\tif (!toolName) toolName = node.getAttribute(\"cq-tool\");\n\t\t\tif (!toolName) return;\n\t\t\tvar stx = this.context.stx;\n\t\t\tstx.clearMeasure();\n\t\t\tstx.changeVectorType(toolName);\n\t\t\tthis.params.toolSelection.html(node.html());\n\t\t\tthis.params.toolSelection.attr(\"cq-current-tool\", toolName);\n\n\t\t\tthis.node.find(\"*[cq-section]\").removeClass(\"ciq-active\");\n\t\t\tvar removeDirty = !this.node\n\t\t\t\t.find(\"*[cq-toolbar-dirty]\")\n\t\t\t\t.hasClass(\"ciq-active\");\n\t\t\tvar drawingParameters = CIQ.Drawing.getDrawingParameters(stx, toolName);\n\t\t\tif (drawingParameters) {\n\t\t\t\tthis.node.find(\"*[cq-toolbar-action='save']\").addClass(\"ciq-active\");\n\t\t\t\tvar drawingPrefs = stx.preferences.drawings;\n\t\t\t\tif (drawingPrefs && drawingPrefs[toolName]) {\n\t\t\t\t\tthis.node\n\t\t\t\t\t\t.find(\"*[cq-toolbar-action='restore']\")\n\t\t\t\t\t\t.addClass(\"ciq-active\");\n\t\t\t\t\tremoveDirty = true;\n\t\t\t\t}\n\t\t\t\t// fibtimezone has no values to display in the settings dialog\n\t\t\t\tif (toolName === \"fibtimezone\") {\n\t\t\t\t\tdelete drawingParameters.parameters;\n\t\t\t\t}\n\n\t\t\t\tvar none = this.params.lineSelection.parent().find(\".ciq-none\");\n\t\t\t\tnone.hide();\n\t\t\t\tvar elements = this.defaultElements(drawingParameters);\n\t\t\t\tfor (var i = 0; i < elements.length; i++) {\n\t\t\t\t\tthis.node.find(elements[i]).addClass(\"ciq-active\");\n\t\t\t\t\tif (elements[i] == \"cq-fill-color\") none.show();\n\t\t\t\t}\n\t\t\t\telements = CIQ.Drawing[toolName].prototype.$controls;\n\t\t\t\tif (elements) {\n\t\t\t\t\tfor (i = 0; i < elements.length; i++) {\n\t\t\t\t\t\tthis.node.find(elements[i]).addClass(\"ciq-active\");\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tthis.sync();\n\t\t\tif (removeDirty) this.dirty(false);\n\t\t}\n\t}\n\n\tCIQ.UI.addComponentDefinition(\"cq-toolbar\", DrawingToolbar);\n}\n\n};\n\n\nlet __js_webcomponents_undo_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Undo web component ``.\n *\n * @namespace WebComponents.cq-undo\n *\n * @example\n * \n * Undo\n * Redo\n * \n */\nclass Undo extends CIQ.UI.ContextTag {\n\tconstructor() {\n\t\tsuper();\n\t\tthis.redoButton = null;\n\t\tthis.undostack = [];\n\t\tthis.redostack = [];\n\t\tthis.contexts = [];\n\t}\n\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tsuper.connectedCallback();\n\t\tvar self = this;\n\t\tCIQ.UI.stxtap(this, function () {\n\t\t\tself.undo();\n\t\t});\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, Undo);\n\t}\n\n\t/**\n\t * Clears the stack of all redo or undo operations for the context\n\t * @param {CIQ.UI.Context} context The context to clear\n\t * @alias clear\n\t * @memberof WebComponents.cq-undo\n\t */\n\tclear(context) {\n\t\tthis.setButtonStyle();\n\t}\n\n\thandleEvent(context, type, data) {\n\t\tthis.undostack.push({ context: context, drawings: data.before });\n\t\tthis.redostack = [];\n\t\tthis.setButtonStyle();\n\t}\n\n\tkeyStroke(hub, key, e, keystroke) {\n\t\tif (key == \"z\" && (keystroke.ctrl || keystroke.cmd)) {\n\t\t\t// ctrl-z\n\t\t\tif (keystroke.shift) {\n\t\t\t\tthis.redo();\n\t\t\t} else {\n\t\t\t\tthis.undo();\n\t\t\t}\n\t\t\treturn true;\n\t\t}\n\t\tif (key == \"y\" && (keystroke.ctrl || keystroke.cmd)) {\n\t\t\t// ctrl-y\n\t\t\tthis.redo();\n\t\t\treturn true;\n\t\t}\n\t}\n\n\tmanageContext(context) {\n\t\tthis.addClaim(this);\n\t\tvar self = this;\n\t\tthis.eventListeners.push(\n\t\t\tcontext.stx.addEventListener(\"undoStamp\", function (data) {\n\t\t\t\tself.handleEvent(context, \"undoStamp\", data);\n\t\t\t})\n\t\t);\n\t\tthis.contexts.push(context);\n\t}\n\n\t/**\n\t * Reverts latest undone drawing.\n\t * @alias redo\n\t * @memberof WebComponents.cq-undo\n\t */\n\tredo() {\n\t\tvar state = this.redostack.pop();\n\t\tif (state) {\n\t\t\tvar context = state.context;\n\t\t\tthis.undostack.push({\n\t\t\t\tcontext: context,\n\t\t\t\tdrawings: context.stx.exportDrawings()\n\t\t\t});\n\t\t\tvar drawings = state.drawings;\n\t\t\tcontext.stx.abortDrawings(true);\n\t\t\tcontext.stx.importDrawings(drawings);\n\t\t\tcontext.stx.changeOccurred(\"vector\");\n\t\t\tcontext.stx.draw();\n\t\t}\n\t\tthis.setButtonStyle();\n\t}\n\n\t/**\n\t * @private\n\t */\n\tsetButtonStyle() {\n\t\tif (this.undostack.length) {\n\t\t\tthis.node.attr(\"cq-active\", \"true\");\n\t\t} else {\n\t\t\tthis.node.removeAttr(\"cq-active\");\n\t\t}\n\t\tif (this.redoButton) {\n\t\t\tif (this.redostack.length) {\n\t\t\t\tthis.redoButton.setAttribute(\"cq-active\", \"true\");\n\t\t\t} else {\n\t\t\t\tthis.redoButton.removeAttribute(\"cq-active\");\n\t\t\t}\n\t\t}\n\t}\n\n\tsetContext(context) {\n\t\tthis.manageContext(this.context);\n\n\t\tvar self = this;\n\t\tthis.addInjection(\"append\", \"initializeChart\", function () {\n\t\t\tself.undostack = [];\n\t\t\tself.redostack = [];\n\t\t\tself.clear();\n\t\t});\n\t}\n\n\t/**\n\t * Reverts last drawing made.\n\t * @alias undo\n\t * @memberof WebComponents.cq-undo\n\t */\n\tundo() {\n\t\t// If a drawing tool is in action, then pressing undo will kill the current tool\n\t\tvar foundOne = false;\n\t\tfor (var i = 0; i < this.contexts.length; i++) {\n\t\t\tif (this.contexts[i].stx.activeDrawing) {\n\t\t\t\tthis.contexts[i].stx.undo();\n\t\t\t\tfoundOne = true;\n\t\t\t}\n\t\t}\n\t\tif (foundOne) return;\n\n\t\t// otherwise proceed to popping off the stack\n\t\tvar state = this.undostack.pop();\n\t\tif (state) {\n\t\t\tvar context = state.context;\n\t\t\tthis.redostack.push({\n\t\t\t\tcontext: context,\n\t\t\t\tdrawings: context.stx.exportDrawings()\n\t\t\t});\n\t\t\tvar drawings = state.drawings;\n\t\t\tcontext.stx.abortDrawings(true);\n\t\t\tcontext.stx.importDrawings(drawings);\n\t\t\tcontext.stx.changeOccurred(\"vector\");\n\t\t\tcontext.stx.draw();\n\t\t}\n\t\tthis.setButtonStyle();\n\t}\n}\n\nCIQ.UI.addComponentDefinition(\"cq-undo\", Undo);\n\n};\n\n\nlet __js_webcomponents_viewDialog_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * View Dialog web component ``.\n *\n * See {@link WebComponents.cq-views} for more details on menu management for this component.\n *\n * @namespace WebComponents.cq-view-dialog\n *\n * @example\n * \n * \n *

    Save View

    \n *
    \n *
    \n * Enter name of view:\n *

    \n *
    \n *

    \n * Save\n *
    \n *
    \n *
    \n */\nclass ViewDialog extends CIQ.UI.DialogContentTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, ViewDialog);\n\t\tthis.constructor = ViewDialog;\n\t}\n\n\topen(params) {\n\t\tthis.addDefaultMarkup();\n\t\tthis.querySelector(\"input\").value = \"\";\n\t\tsuper.open(params);\n\t}\n\n\t/**\n\t * Saves the new view. This updates all cq-view menus on the screen and persists the view in the nameValueStore.\n\t * @alias save\n\t * @memberof WebComponents.cq-view-dialog\n\t */\n\tsave() {\n\t\tconst viewName = this.node.find(\"input\").val();\n\t\tif (!viewName) return;\n\n\t\tlet madeChange = false;\n\t\tthis.updateContext();\n\t\tconst layout = this.context.stx.exportLayout();\n\t\tthis.ownerDocument.querySelectorAll(\"cq-views\").forEach(function (v) {\n\t\t\tconst obj = v.params.viewObj;\n\t\t\tlet view;\n\n\t\t\tfor (var i = 0; i < obj.views.length; i++) {\n\t\t\t\tview = obj.views[i];\n\t\t\t\tif (viewName == CIQ.first(view)) break;\n\t\t\t}\n\t\t\tif (i == obj.views.length) {\n\t\t\t\tview = {};\n\t\t\t\tview[viewName] = {};\n\t\t\t\tobj.views.push(view);\n\t\t\t}\n\t\t\tview[viewName] = layout;\n\t\t\tdelete view[viewName].candleWidth;\n\t\t\tv.renderMenu();\n\t\t\t//this.context.stx.updateListeners(\"layout\");\n\t\t\tif (!madeChange) {\n\t\t\t\t// We might have a cq-view menu on multiple charts on the screen. Only persist once.\n\t\t\t\tmadeChange = true;\n\t\t\t\tif (v.params.nameValueStore)\n\t\t\t\t\tv.params.nameValueStore.set(\"stx-views\", obj.views);\n\t\t\t}\n\t\t});\n\t\tthis.close();\n\t}\n\n\tupdateContext() {\n\t\tconst { topNode } = this.context;\n\t\tlet activeChart = topNode.querySelector(\n\t\t\t\"cq-context-wrapper.active cq-context\"\n\t\t);\n\n\t\tif (!activeChart) {\n\t\t\tif (topNode.multiChartContainer) {\n\t\t\t\tactiveChart = topNode.multiChartContainer.querySelector(\n\t\t\t\t\t\"cq-context-wrapper.active cq-context\"\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\t\tif (activeChart) {\n\t\t\tthis.context = activeChart.CIQ.UI.context;\n\t\t}\n\t}\n}\n\nViewDialog.markup = `\n\t\t

    Save View

    \n\t\t
    \n\t\t
    \n\t\tEnter name of view:\n\t\t

    \n\t\t\t
    \n\t\t

    \n\t\tSave\n\t\t
    \n\t`;\nCIQ.UI.addComponentDefinition(\"cq-view-dialog\", ViewDialog);\n\n};\n\n\nlet __js_webcomponents_views_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Views web component ``.\n *\n * Displays a menu containing available saved chart views and provides a dialog for saving new\n * views.\n *\n * @namespace WebComponents.cq-views\n *\n * @example\n * \n * Views\n * \n * \n * Saved Views\n * \n * \n * \n * \n * \n * Save View\n * \n * \n * \n * \n */\nclass Views extends CIQ.UI.ContextTag {\n\t/**\n\t * Initializes the views menu.\n\t *\n\t * @param {object} [params] Parameters used to initialize the menu.\n\t * @param {object} [params.viewObj = { views: [] }] Contains the menu items; that is, an array\n\t * \t\tof objects that contain the specifications for saved views of the chart.\n\t * @param {object} [params.nameValueStore] The class or constructor function that saves and\n\t * \t\tretrieves the chart views by means of a name/value store. See the custom storage\n\t * \t\tclass example below. Defaults to the `nameValueStore` property of the chart\n\t * \t\tconfiguration if available (see the {@tutorial Chart Configuration} tutorial);\n\t * \t\totherwise, defaults to {@link CIQ.NameValueStore}.\n\t * @param {object} [params.renderCB = null] A callback function executed on the menu after the\n\t * \t\tmenu has been rendered. Takes the menu as an argument.\n\t * @param {object} [params.cb] A callback function called when the saved views have been\n\t * \t\tretrieved from the name/value store. No arguments are passed to the callback function.\n\t *\n\t * @memberof WebComponents.cq-views\n\t * @since\n\t * - 3.0.7 Added the `params.cb` parameter.\n\t * - 4.1.0 The `ViewMenu` helper has been deprecated. Call\n\t * \t\t`document.querySelector(\"cq-views\").initialize()` instead.\n\t *\n\t * @example Create a custom name/value store for the cq-views web component.\n\t * // Set the custom name/value store as the storage location for the web component.\n\t * document.querySelector(\"cq-views\").initialize({ nameValueStore: MyNameValueStore });\n\t *\n\t * // Create the custom name/value store.\n\t * const MyNameValueStore = function() { };\n\t *\n\t * // Create custom storage functions using the same signatures and callback requirements as those in CIQ.NameValueStore.\n\t * // For the cq-views web component, the data that is saved and retrieved is the array represented by params.viewObj.views.\n\t *\n\t * MyNameValueStore.prototype.set = function(name, value, cb) {\n\t * // Add code here to send the view object (value) to your repository and store it under the provided key (name).\n\t * if (cb) cb(error);\n\t * };\n\t *\n\t * MyNameValueStore.prototype.get = function(name, cb) {\n\t * // Add code here to get the view object for the provided key (name) from your repository and pass it to the callback.\n\t * cb(error, viewObj);\n\t * };\n\t *\n\t * MyNameValueStore.prototype.remove = function(name, cb) {\n\t * // Add code here to remove the view object associated with the provided key (name) from your repository.\n\t * if (cb) cb(error);\n\t * };\n\t *\n\t * @example Reload the drop-down menu with the latest stored data.
    \n\t * (Useful if you are sharing the data with other applications that may also be modifying the\n\t * data in real time.)\n\t * let self = document.querySelector(\"cq-views\");\n\t * self.params.nameValueStore.get(\"stx-views\", function(err, obj) {\n\t * if (!err && obj) self.params.viewObj.views = obj;\n\t * else self.params.viewObj = { views: [] };\n\t * if (self.params.cb) self.params.cb.call(self);\n\t * self.renderMenu();\n\t * });\n\t */\n\tinitialize(params) {\n\t\tthis.params = Object.assign({}, params);\n\n\t\tconst { config } = this.context;\n\t\tlet { nameValueStore } = config;\n\n\t\tCIQ.ensureDefaults(this.params, {\n\t\t\tviewObj: { views: [] },\n\t\t\tnameValueStore:\n\t\t\t\t(nameValueStore && new nameValueStore()) ||\n\t\t\t\t(CIQ.NameValueStore && new CIQ.NameValueStore()),\n\t\t\ttemplate: \"template[cq-view]\"\n\t\t});\n\t\tthis.params.template = this.querySelector(this.params.template);\n\t\tvar self = this;\n\t\tif (this.params.nameValueStore)\n\t\t\tthis.params.nameValueStore.get(\"stx-views\", function (err, obj) {\n\t\t\t\tif (!err && obj) self.params.viewObj.views = obj;\n\t\t\t\tif (self.params.cb) self.params.cb.call(self);\n\t\t\t\tself.renderMenu();\n\t\t\t});\n\t}\n\n\tconnectedCallback() {\n\t\tsuper.connectedCallback();\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, Views);\n\t\tthis.constructor = Views;\n\t}\n\n\tsetContext({ config }) {\n\t\tthis.addDefaultMarkup();\n\t\tif (config && config.menuViewConfig) {\n\t\t\tthis.initialize(config.menuViewConfig);\n\t\t}\n\t}\n\n\t/**\n\t * Creates the menu.\n\t *\n\t * @memberof WebComponents.cq-views\n\t */\n\trenderMenu() {\n\t\tvar menu = this.node;\n\t\tvar self = this;\n\n\t\tfunction remove(i) {\n\t\t\treturn function (e) {\n\t\t\t\te.stopPropagation();\n\t\t\t\tvar saved = false;\n\t\t\t\tself.ownerDocument.querySelectorAll(\"cq-views\").forEach(function (v) {\n\t\t\t\t\tv.params.viewObj.views.splice(i, 1);\n\t\t\t\t\tif (!saved) {\n\t\t\t\t\t\tif (v.params.nameValueStore)\n\t\t\t\t\t\t\tv.params.nameValueStore.set(\n\t\t\t\t\t\t\t\t\"stx-views\",\n\t\t\t\t\t\t\t\tself.params.viewObj.views\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\tsaved = true;\n\t\t\t\t\t}\n\t\t\t\t\tv.renderMenu();\n\t\t\t\t});\n\t\t\t};\n\t\t}\n\n\t\tfunction enable(i) {\n\t\t\treturn function (e) {\n\t\t\t\te.stopPropagation();\n\t\t\t\tself.uiManager.closeMenu();\n\t\t\t\tif (self.context.loader) self.context.loader.show();\n\t\t\t\tvar layout = CIQ.first(self.params.viewObj.views[i]);\n\t\t\t\tfunction importLayout() {\n\t\t\t\t\tvar stx = self.context.stx;\n\t\t\t\t\tvar finishImportLayout = function () {\n\t\t\t\t\t\tstx.changeOccurred(\"layout\");\n\t\t\t\t\t\tif (self.context.loader) self.context.loader.hide();\n\t\t\t\t\t};\n\t\t\t\t\tstx.importLayout(self.params.viewObj.views[i][layout], {\n\t\t\t\t\t\tmanagePeriodicity: true,\n\t\t\t\t\t\tpreserveTicksAndCandleWidth: true,\n\t\t\t\t\t\tcb: finishImportLayout\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\tsetTimeout(importLayout, 10);\n\t\t\t};\n\t\t}\n\n\t\tmenu.find(\"cq-views-content cq-item\").remove();\n\t\tfor (var v = 0; v < this.params.viewObj.views.length; v++) {\n\t\t\tvar view = CIQ.first(self.params.viewObj.views[v]);\n\t\t\tif (view == \"recent\") continue;\n\t\t\tvar item = CIQ.UI.makeFromTemplate(this.params.template);\n\t\t\tvar label = item.find(\"cq-label\");\n\t\t\tvar removeView = item.find(\"div\");\n\n\t\t\tif (label.length) {\n\t\t\t\tlabel.addClass(\"view-name-\" + view);\n\t\t\t\tlabel.text(view); //using text() here to prevent script injection\n\t\t\t}\n\t\t\tif (removeView.length) CIQ.UI.stxtap(removeView[0], remove(v));\n\t\t\tthis.makeTap(item[0], enable(v));\n\t\t\tmenu.find(\"cq-views-content\").append(item);\n\t\t}\n\n\t\tvar addNew = menu.find(\"cq-view-save\");\n\t\tif (addNew) {\n\t\t\tconst { context } = this;\n\t\t\tconst self = this;\n\t\t\tthis.makeTap(addNew.find(\"cq-item\")[0], function (e) {\n\t\t\t\tif (context.config) {\n\t\t\t\t\tself.channelWrite(context.config.channels.dialog, {\n\t\t\t\t\t\ttype: \"view\",\n\t\t\t\t\t\tparams: { context }\n\t\t\t\t\t});\n\t\t\t\t} else {\n\t\t\t\t\tself.ownerDocument.querySelector(\"cq-view-dialog\").open({ context });\n\t\t\t\t}\n\t\t\t\tconst uiManager = CIQ.UI.getUIManager(this);\n\t\t\t\tconst viewMenu = context.topNode.querySelector(\".ciq-views\");\n\t\t\t\tif (uiManager && viewMenu) uiManager.closeMenu(viewMenu);\n\t\t\t});\n\t\t}\n\t\tif (this.params.renderCB) this.params.renderCB(menu);\n\t}\n}\n\nViews.markup = `\n\t\tSaved Views\n\t\t\n\t\t\t\n\t\t\n\t\t\n\t\t\n\t\t\tSave View\n\t\t\n\t`;\nCIQ.UI.addComponentDefinition(\"cq-views\", Views);\n\n};\n\n\nlet __js_webcomponents_volumeProfileSettingsDialog_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\nconst CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\n/**\n * Volume profile drawing settings dialog web component ``.\n *\n * @namespace WebComponents.cq-volumeprofile-settings-dialog\n * @example\n *

    Volume Profile Settings

    \n\t\n\t\t
    \n\t\t\t
    Price Buckets
    \n\t\t\t
    \n\t\t\t\t\n\t\t\t
    \n\t\t\n\t
    \n\t\t
    Done
    \n\t
    \n * @since 8.4.0\n */\nclass VolumeProfileSettingsDialog extends CIQ.UI.DialogContentTag {\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, VolumeProfileSettingsDialog);\n\t\tthis.constructor = VolumeProfileSettingsDialog;\n\t}\n\n\t/**\n\t * Ensures that when the dialog is opened the input field is populated with the correct value.\n\t * Also installs a listener to report changes to the value so the drawing can get updated.\n\t *\n\t * @memberOf WebComponents.cq-volumeprofile-settings-dialog\n\t * @param {Object} params parameters\n\t * @param {HTMLElement} params.caller The HTML element that triggered this dialog to open\n\t * @since 8.4.0\n\t */\n\topen(params) {\n\t\tthis.addDefaultMarkup();\n\t\tsuper.open(params);\n\n\t\tif (params) this.opener = params.caller;\n\t\tconst { currentVectorParameters: vectorParams } = this.context.stx;\n\t\tif (!vectorParams.volumeprofile) vectorParams.volumeprofile = {};\n\t\tconst settings = vectorParams.volumeProfile;\n\t\tconst inputField = this.querySelector(\n\t\t\t'div[fieldname=\"Price Buckets\"] input'\n\t\t);\n\t\tinputField.value = settings.priceBuckets;\n\t\tif (inputField.changeHandler)\n\t\t\tinputField.removeEventListener(\"change\", inputField.changeHandler);\n\n\t\tinputField.changeHandler = ({ target }) => {\n\t\t\tconst intVal = parseInt(target.value);\n\t\t\tif (isNaN(intVal)) return;\n\n\t\t\tsettings.priceBuckets = intVal;\n\t\t\tconst event = new Event(\"change\", {\n\t\t\t\tbubbles: true,\n\t\t\t\tcancelable: true\n\t\t\t});\n\t\t\tthis.opener.dispatchEvent(event);\n\t\t};\n\n\t\tinputField.addEventListener(\"change\", inputField.changeHandler);\n\t}\n}\n\nVolumeProfileSettingsDialog.markup = `\n\t

    Volume Profile Settings

    \n\t\n\t\t
    \n\t\t\t
    Price Buckets
    \n\t\t\t
    \n\t\t\t\t\n\t\t\t
    \n\t\t\n\t
    \n\t\t
    Done
    \n\t
    \n`;\n\nCIQ.UI.addComponentDefinition(\n\t\"cq-volumeprofile-settings-dialog\",\n\tVolumeProfileSettingsDialog\n);\n\n};\n\n\nlet __js_webcomponents_waveParameters_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nclass WaveParameters extends CIQ.UI.ContextTag {\n\tstatic get observedAttributes() {\n\t\treturn [\"corrective\", \"decoration\", \"impulse\", \"show-lines\"];\n\t}\n\n\tget corrective() {\n\t\treturn this.getAttribute(\"corrective\");\n\t}\n\n\tset corrective(attribute) {\n\t\tif (attribute) this.setAttribute(\"corrective\", attribute.join(\" \"));\n\t\telse this.removeAttribute(\"corrective\");\n\t}\n\n\tget decoration() {\n\t\treturn this.getAttribute(\"decoration\");\n\t}\n\n\tset decoration(attribute) {\n\t\tif (attribute) this.setAttribute(\"decoration\", attribute);\n\t\telse this.removeAttribute(\"decoration\");\n\t}\n\n\tget impulse() {\n\t\treturn this.getAttribute(\"impulse\");\n\t}\n\n\tset impulse(attribute) {\n\t\tif (attribute) this.setAttribute(\"impulse\", attribute.join(\" \"));\n\t\telse this.removeAttribute(\"impulse\");\n\t}\n\n\tget showLines() {\n\t\treturn this.hasAttribute(\"show-lines\");\n\t}\n\n\tset showLines(value) {\n\t\tif (value) {\n\t\t\tthis.setAttribute(\"show-lines\", \"\");\n\t\t\tthis.lineToggleCheckbox.classList.add(\"ciq-active\");\n\t\t} else this.removeAttribute(\"show-lines\");\n\t}\n\n\tget template() {\n\t\treturn this.getAttribute(\"template\");\n\t}\n\n\tset template(attribute) {\n\t\tthis.setAttribute(\"template\", attribute);\n\t}\n\n\tstatic templates() {\n\t\treturn {\n\t\t\t\"Grand Supercycle\": {\n\t\t\t\timpulse: [\"I\", \"II\", \"III\", \"IV\", \"V\"],\n\t\t\t\tcorrective: [\"a\", \"b\", \"c\"],\n\t\t\t\tdecoration: \"enclosed\"\n\t\t\t},\n\t\t\tSupercycle: {\n\t\t\t\timpulse: [\"I\", \"II\", \"III\", \"IV\", \"V\"],\n\t\t\t\tcorrective: [\"a\", \"b\", \"c\"],\n\t\t\t\tdecoration: \"parentheses\"\n\t\t\t},\n\t\t\tCycle: {\n\t\t\t\timpulse: [\"I\", \"II\", \"III\", \"IV\", \"V\"],\n\t\t\t\tcorrective: [\"a\", \"b\", \"c\"],\n\t\t\t\tdecoration: null\n\t\t\t},\n\t\t\tPrimary: {\n\t\t\t\timpulse: [\"1\", \"2\", \"3\", \"4\", \"5\"],\n\t\t\t\tcorrective: [\"A\", \"B\", \"C\"],\n\t\t\t\tdecoration: \"enclosed\"\n\t\t\t},\n\t\t\tIntermediate: {\n\t\t\t\timpulse: [\"1\", \"2\", \"3\", \"4\", \"5\"],\n\t\t\t\tcorrective: [\"A\", \"B\", \"C\"],\n\t\t\t\tdecoration: \"parentheses\"\n\t\t\t},\n\t\t\tMinor: {\n\t\t\t\timpulse: [\"1\", \"2\", \"3\", \"4\", \"5\"],\n\t\t\t\tcorrective: [\"A\", \"B\", \"C\"],\n\t\t\t\tdecoration: null\n\t\t\t},\n\t\t\tMinute: {\n\t\t\t\timpulse: [\"i\", \"ii\", \"iii\", \"iv\", \"v\"],\n\t\t\t\tcorrective: [\"a\", \"b\", \"c\"],\n\t\t\t\tdecoration: \"enclosed\"\n\t\t\t},\n\t\t\tMinuette: {\n\t\t\t\timpulse: [\"i\", \"ii\", \"iii\", \"iv\", \"v\"],\n\t\t\t\tcorrective: [\"a\", \"b\", \"c\"],\n\t\t\t\tdecoration: \"parentheses\"\n\t\t\t},\n\t\t\t\"Sub-Minuette\": {\n\t\t\t\timpulse: [\"i\", \"ii\", \"iii\", \"iv\", \"v\"],\n\t\t\t\tcorrective: [\"a\", \"b\", \"c\"],\n\t\t\t\tdecoration: null\n\t\t\t}\n\t\t};\n\t}\n\n\tattributeChangedCallback(name, oldAttr, newAttr) {\n\t\tif (!this.stx) return;\n\t\tlet vector = this.stx.currentVectorParameters;\n\t\tlet waveParameters = vector.waveParameters || {};\n\t\tlet parameters;\n\t\tswitch (name) {\n\t\t\tcase \"template\":\n\t\t\t\tlet newTemplate = this.templates[newAttr];\n\t\t\t\tif (newTemplate) {\n\t\t\t\t\tparameters = {\n\t\t\t\t\t\tdecoration: newTemplate.decoration\n\t\t\t\t\t};\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase \"impulse\":\n\t\t\t\tlet impulse = newAttr ? newAttr.split(\" \") : newAttr;\n\t\t\t\tparameters = { impulse: impulse };\n\t\t\t\tbreak;\n\t\t\tcase \"corrective\":\n\t\t\t\tlet corrective = newAttr ? newAttr.split(\" \") : newAttr;\n\t\t\t\tparameters = { corrective: corrective };\n\t\t\t\tbreak;\n\t\t\tcase \"decoration\":\n\t\t\t\tparameters = { decoration: newAttr };\n\t\t\t\tbreak;\n\t\t\tcase \"show-lines\":\n\t\t\t\tparameters = { showLines: this.showLines };\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tbreak;\n\t\t}\n\t\tvector.waveParameters = Object.assign(waveParameters, parameters);\n\t}\n\n\tconstructor() {\n\t\tsuper();\n\t\tthis.templates = WaveParameters.templates();\n\t}\n\n\tconnectedCallback() {\n\t\tif (this.attached) return;\n\t\tthis.template = \"Grand Supercycle\";\n\t\tvar tmpl = this.ownerDocument.querySelector(\n\t\t\t'template[cq-wave-parameters], template[cq-wave-parameters=\"true\"]'\n\t\t);\n\t\tCIQ.UI.makeFromTemplate(tmpl, this);\n\t\tthis.templateHeader = this.querySelector(\".ciq-active-template\");\n\t\tthis.impulseHeader = this.querySelector(\".ciq-active-impulse\");\n\t\tthis.correctiveHeader = this.querySelector(\".ciq-active-corrective\");\n\t\tthis.decorators = {\n\t\t\tblank: this.querySelector(\".ciq-btn:nth-of-type(1n)\"),\n\t\t\tparentheses: this.querySelector(\".ciq-btn:nth-of-type(2n)\"),\n\t\t\tenclosed: this.querySelector(\".ciq-btn:nth-of-type(3n)\")\n\t\t};\n\t\tthis.lineToggleCheckbox = this.querySelector(\"span.ciq-checkbox\");\n\t\tsuper.connectedCallback();\n\t}\n\n\tadoptedCallback() {\n\t\tsuper.adoptedCallback();\n\t\tCIQ.UI.flattenInheritance(this, WaveParameters);\n\t}\n\n\tactivate() {\n\t\tif (!this.stx) return;\n\t\tthis.cvp = this.stx.currentVectorParameters;\n\t\tthis.update(null, \"template\", this.template);\n\t\tthis.showLines = true;\n\t}\n\n\tsetContext() {\n\t\tthis.stx = this.context.stx;\n\t}\n\n\ttoggleLines() {\n\t\tlet checkbox = this.lineToggleCheckbox;\n\t\tlet active = checkbox.classList.contains(\"ciq-active\");\n\t\tthis.showLines = !active;\n\t\tif (active) checkbox.classList.remove(\"ciq-active\");\n\t\telse checkbox.classList.add(\"ciq-active\");\n\t}\n\n\tupdate(node, field, update) {\n\t\tlet isTemplate = field === \"template\";\n\n\t\tif (!isTemplate) {\n\t\t\tif (field === \"decoration\") {\n\t\t\t\tfor (let d in this.decorators) {\n\t\t\t\t\tthis.decorators[d].classList.remove(\"ciq-active\");\n\t\t\t\t}\n\t\t\t\tnode.node.classList.add(\"ciq-active\");\n\t\t\t\tthis.decoration = node.node.getAttribute(\"decoration\");\n\t\t\t} else if (field === \"showLines\") {\n\t\t\t} else {\n\t\t\t\tlet u = update ? update.split(\",\") : update;\n\t\t\t\tthis[field] = u;\n\t\t\t\tthis[field + \"Header\"].innerHTML = u ? u.join(\" \") : \"- - -\";\n\t\t\t}\n\t\t\tthis.templateHeader.innerHTML = this.template = \"Custom\";\n\t\t} else {\n\t\t\tthis.template = update;\n\t\t\tthis.templateHeader.innerHTML = update;\n\t\t\tlet newTemplate = this.templates[this.template];\n\t\t\tif (newTemplate) {\n\t\t\t\tthis.impulse = newTemplate.impulse;\n\t\t\t\tthis.impulseHeader.innerHTML = newTemplate.impulse.join(\" \");\n\n\t\t\t\tthis.corrective = newTemplate.corrective;\n\t\t\t\tthis.correctiveHeader.innerHTML = newTemplate.corrective.join(\" \");\n\n\t\t\t\tfor (let d in this.decorators) {\n\t\t\t\t\tthis.decorators[d].classList.remove(\"ciq-active\");\n\t\t\t\t}\n\t\t\t\tlet decorator = newTemplate.decoration || \"blank\";\n\t\t\t\tthis.decorators[decorator].classList.add(\"ciq-active\");\n\t\t\t\tthis.decoration = decorator;\n\t\t\t} else\n\t\t\t\tthis.cvp.waveParameters = {\n\t\t\t\t\tcorrective: this.corrective.split(\" \"),\n\t\t\t\t\timpulse: this.impulse.split(\" \"),\n\t\t\t\t\tdecoration: this.decoration\n\t\t\t\t};\n\t\t}\n\t}\n}\nCIQ.UI.addComponentDefinition(\"cq-wave-parameters\", WaveParameters);\n\n};\n\n\nlet __js_webcomponents_dialog_colorPicker_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nconst Dialog = CIQ.UI._webcomponents.list[\"cq-dialog\"];\nif (!Dialog) {\n\tconsole.error(\n\t\t\"colorPicker component requires first activating dialog component.\"\n\t);\n} else {\n\t/**\n\t * Color Picker web component ``.\n\t *\n\t * `cq-colors` attribute can contain a csv list of CSS colors to use\n\t * or `params.colorMap` can be set to a two dimensional array of colors as follows:\n\t * ```\n\t * var myColorPicker = document.querySelector(\"cq-color-picker\");\n\t * myColorPicker.params.colorMap=[[row 1 of colors],[row 2 of colors],[row 3 of colors],[etc]]\n\t * myColorPicker.initialize();\n\t * ```\n\t * @namespace WebComponents.cq-color-picker\n\t * @example\n\t * var myColorPicker = document.querySelector(\"cq-color-picker\");\n\t * myColorPicker.params.colorMap=[[\"#ffffff\", \"#e1e1e1\", \"#cccccc\", \"#b7b7b7\", \"#a0a0a5\", \"#898989\", \"#707070\", \"#626262\", \"#555555\", \"#464646\", \"#363636\", \"#262626\", \"#1d1d1d\", \"#000000\"]];\n\t * myColorPicker.initialize();\n\t *\n\t * @example\n\t\t \n\t\t\t \n\t\t\t \n\t\t\t\t \n\t\t\t \n\t\t \n\t */\n\tclass ColorPicker extends Dialog.classDefinition {\n\t\tconstructor() {\n\t\t\tsuper();\n\t\t\tthis.params = {\n\t\t\t\tcolorMap:[\n\t\t\t\t\t[\"#ffffff\", \"#e1e1e1\", \"#cccccc\", \"#b7b7b7\", \"#a0a0a5\", \"#898989\", \"#707070\", \"#626262\", \"#555555\", \"#464646\", \"#363636\", \"#262626\", \"#1d1d1d\", \"#000000\"],\n\t\t\t\t\t[\"#f4977c\", \"#f7ac84\", \"#fbc58d\", \"#fff69e\", \"#c4de9e\", \"#85c99e\", \"#7fcdc7\", \"#75d0f4\", \"#81a8d7\", \"#8594c8\", \"#8983bc\", \"#a187bd\", \"#bb8dbe\", \"#f29bc1\"],\n\t\t\t\t\t[\"#ef6c53\", \"#f38d5b\", \"#f8ae63\", \"#fff371\", \"#acd277\", \"#43b77a\", \"#2ebbb3\", \"#00bff0\", \"#4a8dc8\", \"#5875b7\", \"#625da6\", \"#8561a7\", \"#a665a7\", \"#ee6fa9\"],\n\t\t\t\t\t[\"#ea1d2c\", \"#ee652e\", \"#f4932f\", \"#fff126\", \"#8ec648\", \"#00a553\", \"#00a99c\", \"#00afed\", \"#0073ba\", \"#0056a4\", \"#323390\", \"#66308f\", \"#912a8e\", \"#e9088c\"],\n\t\t\t\t\t[\"#9b0b16\", \"#9e4117\", \"#a16118\", \"#c6b920\", \"#5a852d\", \"#007238\", \"#00746a\", \"#0077a1\", \"#004c7f\", \"#003570\", \"#1d1762\", \"#441261\", \"#62095f\", \"#9c005d\"],\n\t\t\t\t\t[\"#770001\", \"#792e03\", \"#7b4906\", \"#817a0b\", \"#41661e\", \"#005827\", \"#005951\", \"#003b5c\", \"#001d40\", \"#000e35\", \"#04002c\", \"#19002b\", \"#2c002a\", \"#580028\"],\n\t\t\t\t] // prettier-ignore\n\t\t\t};\n\t\t}\n\n\t\tconnectedCallback() {\n\t\t\tif (this.attached) return;\n\t\t\tsuper.connectedCallback();\n\t\t\tthis.build();\n\t\t}\n\n\t\tadoptedCallback() {\n\t\t\tsuper.adoptedCallback();\n\t\t\tCIQ.UI.flattenInheritance(this, ColorPicker);\n\t\t\tthis.constructor = ColorPicker;\n\t\t}\n\n\t\tbuild() {\n\t\t\tthis.addDefaultMarkup();\n\t\t\tvar node = this.node;\n\t\t\tvar colors = node.attr(\"cq-colors\");\n\t\t\tif (colors) {\n\t\t\t\t// Convert a csv list of colors to a two dimensional array\n\t\t\t\tcolors = colors.split(\",\");\n\t\t\t\tvar cols = Math.ceil(Math.sqrt(colors.length));\n\t\t\t\tthis.params.colorMap = [];\n\t\t\t\tvar col = 0;\n\t\t\t\tvar row = [];\n\t\t\t\tfor (var i = 0; i < colors.length; i++) {\n\t\t\t\t\tif (col >= cols) {\n\t\t\t\t\t\tcol = 0;\n\t\t\t\t\t\tthis.params.colorMap.push(row);\n\t\t\t\t\t\trow = [];\n\t\t\t\t\t}\n\t\t\t\t\trow.push(colors[i]);\n\t\t\t\t\tcol++;\n\t\t\t\t}\n\t\t\t\tthis.params.colorMap.push(row);\n\t\t\t}\n\n\t\t\tthis.cqOverrides = node.find(\"cq-overrides\");\n\t\t\tthis.template = this.cqOverrides.find(\"template\");\n\t\t\tthis.initialize();\n\t\t}\n\n\t\t/**\n\t\t * Displays the color picker in proximity to the node passed in\n\t\t * @param {object} activator The object representing what caused picker to display\n\t\t * @param {HTMLElement} [activator.node] The node near where to display the color picker\n\t\t * @param {array} [activator.overrides] Array of overrides. For each of these, a button will be created that if pressed\n\t\t * will pass that override back instead of the color\n\t\t * @alias display\n\t\t * @memberof WebComponents.cq-color-picker\n\t\t */\n\t\tdisplay(activator) {\n\t\t\t// Algorithm to place the color picker to the right of whichever node was just pressed\n\t\t\tvar node = CIQ.UI.$(activator.node)[0];\n\t\t\tvar positionOfNode = node.getBoundingClientRect();\n\t\t\tthis.node.css({ top: \"0px\", left: \"0px\" });\n\t\t\tvar positionOfColorPicker = this.parentNode.getBoundingClientRect();\n\t\t\tvar oneSwatchDims = CIQ.elementDimensions(node, { border: true });\n\t\t\tvar x =\n\t\t\t\tpositionOfNode.left -\n\t\t\t\tpositionOfColorPicker.left +\n\t\t\t\toneSwatchDims.width +\n\t\t\t\t10;\n\t\t\tvar y = positionOfNode.top - positionOfColorPicker.top + 15;\n\n\t\t\tthis.cqOverrides.children(\":not(template)\").remove();\n\t\t\tvar context =\n\t\t\t\tactivator.context || this.context || CIQ.UI.getMyContext(this);\n\t\t\tthis.uiManager = context.uiManager;\n\n\t\t\tvar closure = function (self, override) {\n\t\t\t\treturn function () {\n\t\t\t\t\tself.pickColor(override);\n\t\t\t\t};\n\t\t\t};\n\n\t\t\tvar overrideHeight = 0;\n\t\t\tif (activator.overrides && this.template.length) {\n\t\t\t\tvar n;\n\t\t\t\tfor (var i = 0; i < activator.overrides.length; i++) {\n\t\t\t\t\tvar override = activator.overrides[i];\n\t\t\t\t\tn = CIQ.UI.makeFromTemplate(this.template, true);\n\t\t\t\t\tif (context.stx) override = context.stx.translateIf(override);\n\t\t\t\t\tn.text(override);\n\t\t\t\t\tCIQ.UI.stxtap(n[0], closure(this, override));\n\t\t\t\t}\n\t\t\t\toverrideHeight = CIQ.elementDimensions(n[0]).height;\n\t\t\t}\n\n\t\t\t// ensure color picker doesn't go off right edge of screen\n\t\t\tvar dims = CIQ.elementDimensions(this, { border: true });\n\t\t\tvar doc = this.ownerDocument || document;\n\t\t\tvar docWidth = CIQ.guaranteedSize(doc).width;\n\t\t\tvar w =\n\t\t\t\tdims.width ||\n\t\t\t\toneSwatchDims.width * this.colors.children()[0].children.length;\n\t\t\tif (x + w > docWidth) x = docWidth - w - 20; // 20 for a little whitespace and padding\n\n\t\t\t// or bottom of screen\n\t\t\tvar docHeight = CIQ.guaranteedSize(doc).height;\n\t\t\tvar h =\n\t\t\t\tdims.height ||\n\t\t\t\toneSwatchDims.height * this.colors.children().length + overrideHeight;\n\t\t\tif (y + h > docHeight) y = docHeight - h - 30; // 30 for a little whitespace and padding\n\n\t\t\tthis.node.css({ left: x + \"px\", top: y + \"px\" });\n\n\t\t\tif (!this.classList.contains(\"stxMenuActive\")) {\n\t\t\t\tthis.open({ context: context }); // Manually activate the color picker\n\t\t\t} else {\n\t\t\t\tif (context.e) context.e.stopPropagation(); // Otherwise the color picker is closed when you swap back and forth between fill and line swatches on the toolbar\n\t\t\t}\n\n\t\t\tif (this.keyboardNavigation) this.keyboardNavigation.highlightAlign();\n\t\t}\n\n\t\tinitialize() {\n\t\t\tvar self = this;\n\t\t\tthis.colors = this.node.find(\"cq-colors\");\n\t\t\tif (!this.colors.length) this.colors = this.node;\n\t\t\tthis.colors.empty(); // allow re-initialize, with new colors for instance\n\n\t\t\tfunction closure(self, color) {\n\t\t\t\treturn function () {\n\t\t\t\t\tself.pickColor(color);\n\t\t\t\t};\n\t\t\t}\n\t\t\tfor (var a = 0; a < this.params.colorMap.length; a++) {\n\t\t\t\tvar lineOfColors = this.params.colorMap[a];\n\t\t\t\tvar ul = document.createElement(\"ul\");\n\t\t\t\tthis.colors[0].appendChild(ul);\n\t\t\t\tfor (var b = 0; b < lineOfColors.length; b++) {\n\t\t\t\t\tvar li = document.createElement(\"li\");\n\t\t\t\t\tul.appendChild(li);\n\t\t\t\t\tvar span = document.createElement(\"span\");\n\t\t\t\t\tli.appendChild(span);\n\t\t\t\t\tspan.style.backgroundColor = lineOfColors[b];\n\t\t\t\t\tCIQ.UI.stxtap(span, closure(self, lineOfColors[b]));\n\t\t\t\t}\n\t\t\t}\n\t\t\tthis.rowLength = this.params.colorMap[0].length || 0;\n\t\t}\n\n\t\tkeyStroke(hub, key, e) {\n\t\t\tif (hub && hub.tabActiveModals[0] !== this) return;\n\n\t\t\tconst items = this.querySelectorAll(\"cq-colors span, .ciq-btn\");\n\t\t\tif (key === \"Escape\" || key === \"Esc\") {\n\t\t\t} else if (key === \"ArrowRight\") {\n\t\t\t\tthis.focusNextItem(items);\n\t\t\t} else if (key === \"ArrowLeft\") {\n\t\t\t\tthis.focusNextItem(items, true);\n\t\t\t} else if (key === \"ArrowDown\") {\n\t\t\t\tthis.focusNextRow(items);\n\t\t\t} else if (key === \"ArrowUp\") {\n\t\t\t\tthis.focusNextRow(items, { reverse: true });\n\t\t\t} else if (key == \"Enter\") {\n\t\t\t\tconst focused = this.findFocused(items);\n\t\t\t\tthis.clickItem(focused[0], e);\n\t\t\t}\n\t\t}\n\n\t\tfocusNextRow(items, options) {\n\t\t\tconst { reverse } = options || {};\n\t\t\tconst focused = this.findFocused(items);\n\t\t\tlet i = -1;\n\t\t\tif (focused.length) {\n\t\t\t\t// find our location in the list of items\n\t\t\t\tfor (i = 0; i < items.length; i++) if (items[i] === focused[0]) break;\n\t\t\t}\n\n\t\t\tif (reverse) {\n\t\t\t\t// Find the previous available item\n\t\t\t\tdo {\n\t\t\t\t\ti -= this.rowLength;\n\t\t\t\t\tif (i < 0) break;\n\t\t\t\t} while (!CIQ.trulyVisible(items[i]));\n\t\t\t} else {\n\t\t\t\t// Find the next available item\n\t\t\t\tdo {\n\t\t\t\t\ti += this.rowLength;\n\t\t\t\t\tif (i >= items.length) {\n\t\t\t\t\t\ti = items.length - 1;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t} while (!CIQ.trulyVisible(items[i]));\n\t\t\t}\n\n\t\t\tif (i > -1 && i < items.length && items[i] !== focused[0]) {\n\t\t\t\tthis.removeFocused(items);\n\t\t\t\tthis.focusItem(items[i]);\n\t\t\t\treturn true;\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\n\t\t/**\n\t\t * @param color\n\t\t * @alias pickColor\n\t\t * @memberof WebComponents.cq-color-picker\n\t\t */\n\t\tpickColor(color) {\n\t\t\tif (this.callback) this.callback(color);\n\t\t\tthis.close();\n\t\t}\n\n\t\tresize() {\n\t\t\t// do nothing for resize, overrides Dialog default which centers\n\t\t}\n\n\t\t/**\n\t\t * @param {object} colorMap Object that holds an array of various color arrays.\n\t\t * @alias setColors\n\t\t * @memberof WebComponents.cq-color-picker\n\t\t */\n\t\tsetColors(colorMap) {\n\t\t\tthis.params.colorMap = colorMap;\n\t\t\tthis.initialize();\n\t\t}\n\t}\n\n\tColorPicker.markup = `\n\t\t\n\t\t\n\t\t\t\n\t\t\n\t`;\n\tCIQ.UI.addComponentDefinition(\"cq-color-picker\", ColorPicker);\n}\n\n};\n\n\nlet __js_webcomponents_palette_drawingPalette_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\n\n\n\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nconst Palette = CIQ.UI._webcomponents.list[\"cq-palette\"];\nif (!Palette) {\n\tconsole.error(\n\t\t\"drawingPalette component requires first activating palette component.\"\n\t);\n} else if (!CIQ.Drawing) {\n\tconsole.error(\n\t\t\"drawingPalette component requires first activating drawing feature.\"\n\t);\n} else {\n\t/**\n\t * Drawing palette web component used to draw and annotate on the chart. Displays a palette\n\t * along the left side of the chart for control and management of drawing tools.\n\t *\n\t * Inherits from ``. Palette components must be placed within a `` component.\n\t *\n\t * This works in conjunction with the [cq-drawing-settings]{@link WebComponents.cq-drawing-settings} component\n\t * and replaces the [cq-toolbar]{@link WebComponents.cq-toolbar} component, providing additional functionality\n\t * and an improved user experience.\n\t *\n\t * Drawing tools support keystroke combinations by setting a `cq-tool-shortcut` attribute in the tool\n\t * `cq-item` element. Combinations take the form Alt+key (upper- or lowercase); for example, Alt+a or\n\t * Alt+A — in either case, the key combination works whether the key is shifted or not. Users can also\n\t * add the modifier Ctrl to the keystroke combination. For example, both Alt+R and Ctrl+Alt+R activate the\n\t * Rectangle tool. The added Ctrl modifier helps provide a unique keystroke combination in the event the Alt+key\n\t * combination is assigned to a function in the web browser or to an application on the user's system.\n\t *\n\t * @namespace WebComponents.cq-drawing-palette\n\t * @example\n\t\t\n\t\t\t
    \n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t
    \n\t\t\t
    \n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\tAll\n\t\t\t\t\t\n\t\t\t\t\t\tAll\n\t\t\t\t\t\tText\n\t\t\t\t\t\tStatistics\n\t\t\t\t\t\tTechnicals\n\t\t\t\t\t\tFibonacci\n\t\t\t\t\t\tMarkings\n\t\t\t\t\t\tLines\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t
    \n\t\t\t\n\t\t\t
    \n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t
    \n\t\t
    \n\t * @since\n\t * - 7.1.0\n\t * - 7.2.0 The drawing settings section has been moved into its own component, [cq-drawing-settings]{@link WebComponents.cq-drawing-settings}.\n\t * - 7.4.0 Drawing tools now support keystroke combinations by setting a `cq-tool-shortcut` attribute in the tool button.\n\t */\n\tclass DrawingPalette extends Palette.classDefinition {\n\t\tconstructor() {\n\t\t\tsuper();\n\t\t\tthis.mode = \"\";\n\t\t\tthis.callbacks = [];\n\t\t\t// A list of tool names to mark as favorite.\n\t\t\tthis.toolSettings = {\n\t\t\t\tfavList: [],\n\t\t\t\ttoolGroup: \"\"\n\t\t\t};\n\t\t\t// Stores a list of keyboard shortcuts.\n\t\t\tthis.toolShortcuts = {};\n\t\t}\n\n\t\tadoptedCallback() {\n\t\t\tsuper.adoptedCallback();\n\t\t\tCIQ.UI.flattenInheritance(this, DrawingPalette);\n\t\t\tthis.constructor = DrawingPalette;\n\t\t}\n\n\t\tsetupKeyboardActivation(context) {\n\t\t\tif (typeof this.getAttribute(\"cq-keystroke-claim\") != \"undefined\") {\n\t\t\t\t// Define keystrokes\n\t\t\t\tlet toolsWithShortcuts = this.context.topNode.querySelectorAll(\n\t\t\t\t\t\"*[cq-tool][cq-tool-shortcut]\"\n\t\t\t\t);\n\t\t\t\tfor (let idx = 0; idx < toolsWithShortcuts.length; idx++) {\n\t\t\t\t\tlet letter = toolsWithShortcuts[idx].getAttribute(\"cq-tool-shortcut\");\n\t\t\t\t\t// Test for a single alpha character\n\t\t\t\t\tif (/^[A-Za-z]{1}$/g.test(letter)) {\n\t\t\t\t\t\t// Store ref to node and toolname for tool selection\n\t\t\t\t\t\tthis.toolShortcuts[letter.toUpperCase()] = {\n\t\t\t\t\t\t\ttoolName: toolsWithShortcuts[idx].getAttribute(\"cq-tool\"),\n\t\t\t\t\t\t\tnode: toolsWithShortcuts[idx]\n\t\t\t\t\t\t};\n\t\t\t\t\t\t// Add keyboard shortcut to button tool tip\n\t\t\t\t\t\tlet buttonLabel = toolsWithShortcuts[idx].querySelector(\"label\");\n\t\t\t\t\t\tlet shortcutLabel = document.createElement(\"span\");\n\t\t\t\t\t\tshortcutLabel.classList.add(\"shortcut\");\n\t\t\t\t\t\tshortcutLabel.innerHTML = \" (Alt+\" + letter.toUpperCase() + \")\";\n\n\t\t\t\t\t\tbuttonLabel.appendChild(shortcutLabel);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tconsole.warn(\n\t\t\t\t\t\t\t\"cq-tool-shortcut attribute must be a single letter: \" +\n\t\t\t\t\t\t\t\tletter +\n\t\t\t\t\t\t\t\t\" ignored.\"\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t// add keyboard claim for entire body\n\t\t\t\tthis.addClaim(this);\n\t\t\t}\n\t\t}\n\n\t\t// Handle keystroke event to activate drawing tools\n\t\tkeyStroke(hub, key, e, keystroke) {\n\t\t\tlet toolName = \"\";\n\t\t\tif (e.altKey && !e.ctrlKey && !e.shiftKey) {\n\t\t\t\tlet selectedKey = String.fromCharCode(e.which).toUpperCase();\n\t\t\t\tlet toolSelection = this.toolShortcuts[selectedKey];\n\n\t\t\t\tif (toolSelection) {\n\t\t\t\t\t// Activate the drawing palette if it isn't already\n\t\t\t\t\t// this.context.stx.layout.drawing=true;\n\t\t\t\t\tconst drawingChannel = this.channels\n\t\t\t\t\t\t? this.channels.drawing\n\t\t\t\t\t\t: \"channel.drawing\";\n\t\t\t\t\tthis.channelWrite(drawingChannel, true);\n\n\t\t\t\t\t// Activate the tool. Pass a reference to the palette button so its activated state is changed.\n\t\t\t\t\tthis.tool({ node: toolSelection.node }, toolSelection.toolName);\n\t\t\t\t}\n\t\t\t} else if (e.key === \"Escape\") {\n\t\t\t\tlet notoolTool = this.context.topNode.querySelector(\n\t\t\t\t\t'*[cq-tool=\"notool\"]'\n\t\t\t\t);\n\t\t\t\tif (notoolTool) this.noTool({ node: notoolTool });\n\t\t\t}\n\t\t}\n\n\t\thandleMessage(id, message) {\n\t\t\tswitch (id) {\n\t\t\t\tcase \"changeToolSettings\":\n\t\t\t\t\tthis.activateTool(message.activator, message.toolName);\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"toggleDrawingPalette\":\n\t\t\t\t\tthis.togglePalette();\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"hideDrawingPalette\":\n\t\t\t\t\tthis.hidePalette();\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"dockWillResize\":\n\t\t\t\t\tthis.hidePalette();\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"dockDidResize\":\n\t\t\t\t\tthis.resetScroller();\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"context\":\n\t\t\t\t\tif (message === \"stop\") this.toolContextMenu.style.display = \"none\";\n\t\t\t}\n\t\t}\n\n\t\t// Retrieve list of tools from local storage.\n\t\tloadToolSettings() {\n\t\t\tif (this.store) {\n\t\t\t\tlet self = this;\n\t\t\t\tthis.store.get(\n\t\t\t\t\t\"CIQ.DrawingToolSettings\",\n\t\t\t\t\tfunction (error, lsDrawingTools) {\n\t\t\t\t\t\tif (!error && lsDrawingTools && lsDrawingTools.favList) {\n\t\t\t\t\t\t\tself.toolSettings = Object.assign(\n\t\t\t\t\t\t\t\tself.toolSettings,\n\t\t\t\t\t\t\t\tlsDrawingTools\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\t\t// Save tool settings to local storage\n\t\tstoreToolSettings() {\n\t\t\tif (this.store)\n\t\t\t\tthis.store.set(\n\t\t\t\t\t\"CIQ.DrawingToolSettings\",\n\t\t\t\t\tJSON.stringify(this.toolSettings)\n\t\t\t\t);\n\t\t}\n\n\t\tsetContext(context) {\n\t\t\tconst { config, stx } = context;\n\n\t\t\tif (config) {\n\t\t\t\tconst { channels = {}, nameValueStore } = config;\n\t\t\t\tthis.store =\n\t\t\t\t\t(nameValueStore && new nameValueStore()) ||\n\t\t\t\t\t(CIQ.NameValueStore && new CIQ.NameValueStore());\n\t\t\t\tthis.addDefaultMarkup(this, this.getMarkup(config));\n\t\t\t\tthis.channels = { drawing: channels.drawing || \"channel.drawing\" };\n\t\t\t}\n\t\t\tthis.init();\n\t\t\tthis.loadToolSettings();\n\t\t\tthis.params = {\n\t\t\t\ttoolGroupSelection: this.node.find(\"*[cq-tool-group-selection]\")\n\t\t\t};\n\t\t\tthis.setFavorites();\n\t\t\tthis.setMode(\"grid\");\n\t\t\tthis.setEvenOdd();\n\n\t\t\t// Inject the right click menu\n\t\t\tthis.toolContextMenu = this.createContextMenu();\n\n\t\t\tthis.addEventListener(\n\t\t\t\t\"contextmenu\",\n\t\t\t\tfunction (event) {\n\t\t\t\t\tconst targetElem = event.target.hasAttribute(\"cq-tool-group\")\n\t\t\t\t\t\t? event.target\n\t\t\t\t\t\t: event.target.parentElement;\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\tif (\n\t\t\t\t\t\ttargetElem !== null &&\n\t\t\t\t\t\ttargetElem.getAttribute(\"cq-tool-group\") !== null\n\t\t\t\t\t) {\n\t\t\t\t\t\t// Only concerned with elements that have a cq-tool-group property\n\t\t\t\t\t\tlet targetRect = targetElem.getBoundingClientRect();\n\t\t\t\t\t\t// Need to position the context menu relative to the parent because the palette can change position\n\t\t\t\t\t\tlet parentRect = this.getBoundingClientRect();\n\t\t\t\t\t\tthis.showToolContextMenu(\n\t\t\t\t\t\t\ttargetElem.getAttribute(\"cq-tool\"),\n\t\t\t\t\t\t\tevent.clientY + targetRect.height - parentRect.top,\n\t\t\t\t\t\t\tevent.clientX - parentRect.left\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t}.bind(this)\n\t\t\t);\n\n\t\t\tthis.setupKeyboardActivation();\n\t\t\tthis.pairUndoRedo();\n\n\t\t\t// Set the tool group if it has been saved in local storage\n\t\t\tif (this.toolSettings.toolGroup) {\n\t\t\t\tthis.setToolGroup(\n\t\t\t\t\t{\n\t\t\t\t\t\tnode: this.querySelector(\n\t\t\t\t\t\t\t'cq-item[cq-tool-group=\"' + this.toolSettings.toolGroup + '\"]'\n\t\t\t\t\t\t)\n\t\t\t\t\t},\n\t\t\t\t\tthis.toolSettings.toolGroup\n\t\t\t\t);\n\t\t\t}\n\n\t\t\tif (this.channels) {\n\t\t\t\tthis.channelSubscribe(\n\t\t\t\t\tthis.channels.drawing || \"channel.drawing\",\n\t\t\t\t\t(value) => {\n\t\t\t\t\t\tconst currentVectorType = stx.currentVectorParameters.vectorType;\n\t\t\t\t\t\tif (value) {\n\t\t\t\t\t\t\tthis.resetScroller();\n\t\t\t\t\t\t\tif (!currentVectorType) {\n\t\t\t\t\t\t\t\t// setting value to \"\" signals that crosshairs should be disabled\n\t\t\t\t\t\t\t\tstx.changeVectorType(this.priorVectorType || \"\");\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tthis.setActiveTool(currentVectorType || \"notool\");\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tconst { multiChartContainer } = this.container.topNode;\n\t\t\t\t\t\t\tif (\n\t\t\t\t\t\t\t\tmultiChartContainer &&\n\t\t\t\t\t\t\t\tCIQ.getFromNS(this, \"context.config.soloActive.onDraw\")\n\t\t\t\t\t\t\t) {\n\t\t\t\t\t\t\t\tArray.from(\n\t\t\t\t\t\t\t\t\tmultiChartContainer.querySelectorAll(\"cq-drawing-palette\")\n\t\t\t\t\t\t\t\t).forEach((palette) => {\n\t\t\t\t\t\t\t\t\tpalette.priorVectorType = currentVectorType;\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tthis.priorVectorType = currentVectorType;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// setting value to null signals that normal crosshair behavior should return\n\t\t\t\t\t\t\tstx.changeVectorType(null);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\n\t\tpairUndoRedo() {\n\t\t\tconst redo = this.qs(\"cq-redo\", this);\n\t\t\tconst undo = this.qs(\"cq-undo\", this);\n\t\t\tredo.pairUp(undo);\n\t\t}\n\n\t\tchangeView(activator, modeName) {\n\t\t\tthis.setMode(modeName);\n\t\t\tfor (\n\t\t\t\tvar i = 0;\n\t\t\t\ti < this.callbacks.length;\n\t\t\t\ti++ // let any callbacks know that the palette mode has changed\n\t\t\t)\n\t\t\t\tthis.callbacks[i].call(this, this.mode);\n\t\t}\n\n\t\tcreateContextMenu() {\n\t\t\t// Add/Remove Favorites menu item\n\t\t\tlet addToFavorites = document.createElement(\"div\");\n\t\t\taddToFavorites.className = \"menu-item\";\n\t\t\taddToFavorites.innerHTML = \"Add/Remove Favorite\";\n\t\t\taddToFavorites.addEventListener(\n\t\t\t\t\"mousedown\",\n\t\t\t\tfunction (event) {\n\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t\tif (event.which === 1) {\n\t\t\t\t\t\t// Right click fires this event too so check for a left mouse button event\n\t\t\t\t\t\tthis.toggleFavorite(\n\t\t\t\t\t\t\tevent.currentTarget.parentElement.getAttribute(\"context-tool\")\n\t\t\t\t\t\t);\n\t\t\t\t\t\tthis.paletteDock.stopContext(this);\n\t\t\t\t\t}\n\t\t\t\t}.bind(this)\n\t\t\t);\n\n\t\t\t// Stop propagation on pointerdown to prevent enabling any drawing tools as a result of clicking the menu\n\t\t\taddToFavorites.addEventListener(\"pointerdown\", (event) =>\n\t\t\t\tevent.stopPropagation()\n\t\t\t);\n\n\t\t\tlet contextMenu = document.createElement(\"div\");\n\t\t\tcontextMenu.appendChild(addToFavorites);\n\t\t\tcontextMenu.className = \"tool-context-menu\";\n\t\t\tthis.node.append(contextMenu);\n\t\t\treturn contextMenu;\n\t\t}\n\n\t\tregisterCallback(fc) {\n\t\t\tthis.callbacks.push(fc);\n\t\t}\n\n\t\t// Resets the tool scrollbar\n\t\t// Use if the container size or contents have changes\n\t\tresetScroller() {\n\t\t\tconst scroller = this.querySelector(\".tool-group cq-scroll\");\n\t\t\tif (!scroller) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\tthis.setEvenOdd();\n\t\t\tscroller.refresh();\n\t\t}\n\n\t\tsetActiveTool(toolName) {\n\t\t\tconst toolButton = this.querySelector(`cq-item[cq-tool=${toolName}]`);\n\t\t\tif (toolButton) this.tool({ node: toolButton });\n\t\t}\n\n\t\tsetActiveButton(activeNode) {\n\t\t\tthis.node.find(\".ciq-tool.active\").removeClass(\"active\");\n\t\t\tvar activeToolLabel = \"\";\n\t\t\t// Don't show a label in settings for the No Tool tool\n\t\t\tif (activeNode.getAttribute(\"stxtap\") !== \"noTool()\") {\n\t\t\t\tvar label = activeNode.querySelector(\"label\");\n\t\t\t\tif (label) activeToolLabel = label.innerHTML + \":\";\n\t\t\t}\n\t\t\tactiveNode.classList.add(\"active\");\n\t\t\t// Don't want to automatically show the palette when using the mobile menu\n\t\t\tif (\n\t\t\t\t!CIQ.trulyVisible(\n\t\t\t\t\tthis.ownerDocument.querySelector(\".ciq-mobile-palette-toggle\")\n\t\t\t\t)\n\t\t\t)\n\t\t\t\tthis.togglePalette();\n\t\t}\n\n\t\tsetMode(mode) {\n\t\t\t// Default to grid mode unless list is specified\n\t\t\tmode = mode === \"list\" ? mode : \"grid\";\n\t\t\tthis.mode = mode;\n\t\t\t// Multiple remove calls here because IE supports only one class at a time\n\t\t\tthis.classList.remove(\"list\");\n\t\t\tthis.classList.remove(\"grid\");\n\t\t\tthis.classList.add(this.mode);\n\n\t\t\tthis.resetScroller();\n\t\t\tthis.paletteDock.handleResize({ resizeChart: true });\n\t\t}\n\n\t\tsetEvenOdd() {\n\t\t\t// Give an 'odd' class to odd number buttons in filtered list.\n\t\t\tvar nodes = this.querySelectorAll(\".tool-group cq-scroll cq-item\");\n\t\t\tvar odd = false;\n\t\t\tfor (var n = 0; n < nodes.length; n++) {\n\t\t\t\tif (!CIQ.trulyVisible(nodes[n])) continue;\n\t\t\t\tnodes[n].classList[odd ? \"add\" : \"remove\"](\"odd\");\n\t\t\t\todd = !odd;\n\t\t\t}\n\t\t}\n\n\t\t// Add the favorite badge to relevant tools\n\t\t// Add a favorite toggle star to each tool for use in list view and mobile layout\n\t\tsetFavorites(propagateSettings = true) {\n\t\t\tvar toolButtons = this.querySelectorAll(\".tool-group [cq-tool]\");\n\t\t\tfor (\n\t\t\t\tvar toolButtonIdx = 0;\n\t\t\t\ttoolButtonIdx < toolButtons.length;\n\t\t\t\ttoolButtonIdx++\n\t\t\t) {\n\t\t\t\tvar toolButton = toolButtons[toolButtonIdx];\n\t\t\t\tif (toolButton.querySelector(\".fav-marker\") === null) {\n\t\t\t\t\t// All buttons get the div.fav-marker element to click on in list view.\n\t\t\t\t\tlet favMarker = document.createElement(\"div\");\n\t\t\t\t\tfavMarker.className = \"fav-marker\";\n\t\t\t\t\tfavMarker.addEventListener(\n\t\t\t\t\t\t\"click\",\n\t\t\t\t\t\tthis.handleFavoriteClick.bind(this)\n\t\t\t\t\t);\n\t\t\t\t\tfavMarker.addEventListener(\n\t\t\t\t\t\t\"touchstart\",\n\t\t\t\t\t\tthis.handleFavoriteClick.bind(this),\n\t\t\t\t\t\t{ capture: true, passive: false }\n\t\t\t\t\t);\n\t\t\t\t\tfavMarker.addEventListener(\"pointerdown\", (event) =>\n\t\t\t\t\t\tevent.stopPropagation()\n\t\t\t\t\t);\n\t\t\t\t\ttoolButton.appendChild(favMarker);\n\t\t\t\t}\n\t\t\t\tif (toolButton.getAttribute(\"cq-tool-group\").indexOf(\"favorite\") >= 0) {\n\t\t\t\t\t// Remove favorite group value if it's there.\n\t\t\t\t\ttoolButton.setAttribute(\n\t\t\t\t\t\t\"cq-tool-group\",\n\t\t\t\t\t\ttoolButton.getAttribute(\"cq-tool-group\").replace(\"favorite\", \"\")\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t\tif (\n\t\t\t\t\tthis.toolSettings.favList.indexOf(\n\t\t\t\t\t\ttoolButton.getAttribute(\"cq-tool\")\n\t\t\t\t\t) >= 0\n\t\t\t\t) {\n\t\t\t\t\t// Apply the favorite tool group to tools in the favorites list.\n\t\t\t\t\ttoolButton.setAttribute(\n\t\t\t\t\t\t\"cq-tool-group\",\n\t\t\t\t\t\ttoolButton.getAttribute(\"cq-tool-group\") + \" favorite\"\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t}\n\t\t\tthis.sortToolButtons();\n\t\t\tconst { multiChartContainer } = this.context.topNode;\n\t\t\tif (propagateSettings && multiChartContainer) {\n\t\t\t\t// synchronize favourites in other open palettes.\n\t\t\t\tmultiChartContainer.getCharts().forEach((chart) => {\n\t\t\t\t\tconst contextContainer = chart.uiContext.topNode;\n\t\t\t\t\tconst wrapper = contextContainer.closest(\"cq-context-wrapper\");\n\t\t\t\t\tif (!wrapper || contextContainer === this.context.topNode) return;\n\t\t\t\t\tconst drawingPalette =\n\t\t\t\t\t\tcontextContainer.querySelector(\"cq-drawing-palette\");\n\n\t\t\t\t\tsetTimeout(() => {\n\t\t\t\t\t\tdrawingPalette.loadToolSettings();\n\t\t\t\t\t\tdrawingPalette.setFavorites(false);\n\t\t\t\t\t});\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\n\t\t// Sort buttons in order defined by the config, grouping those marked favorite first.\n\t\tsortToolButtons() {\n\t\t\tconst toolContainer = this.querySelector(\".tool-group cq-scroll\");\n\t\t\tconst scrollbar = toolContainer.querySelector(\".ps__rail-x, .ps__rail-y\");\n\t\t\tfor (let tool of this.context.config.drawingTools) {\n\t\t\t\tconst toolElem = this.querySelector(\n\t\t\t\t\t\".tool-group [cq-tool=\" + tool.tool + \"]\"\n\t\t\t\t);\n\t\t\t\tif (\n\t\t\t\t\ttoolElem &&\n\t\t\t\t\t!toolElem.getAttribute(\"cq-tool-group\").includes(\"favorite\")\n\t\t\t\t) {\n\t\t\t\t\t// insertBefore automatically detaches the element from its current position and reattaches it at the bottom above the scrollbar\n\t\t\t\t\tif (scrollbar) toolContainer.insertBefore(toolElem, scrollbar);\n\t\t\t\t\telse toolContainer.appendChild(toolElem);\n\t\t\t\t}\n\t\t\t}\n\t\t\tthis.setEvenOdd();\n\t\t}\n\n\t\thandleFavoriteClick(event) {\n\t\t\tevent.stopPropagation();\n\t\t\tevent.preventDefault();\n\t\t\tthis.toggleFavorite(event.target.parentElement.getAttribute(\"cq-tool\"));\n\t\t\t// The mobile palette is toggled after the tool selection so hide it now so the toggle will show it again\n\t\t\tthis.hidePalette();\n\t\t}\n\n\t\t// Add the tool to the list of favorites\n\t\taddFavorite(toolName) {\n\t\t\tif (this.toolSettings.favList.indexOf(toolName) < 0) {\n\t\t\t\tthis.toolSettings.favList.push(toolName);\n\t\t\t\tthis.storeToolSettings();\n\t\t\t\tthis.setFavorites();\n\t\t\t}\n\t\t}\n\n\t\tshowToolContextMenu(toolName, top, left) {\n\t\t\tthis.toolContextMenu.style.display = \"block\";\n\t\t\tthis.toolContextMenu.style.top = top + \"px\";\n\t\t\tthis.toolContextMenu.style.left = left + \"px\";\n\t\t\tthis.toolContextMenu.setAttribute(\"context-tool\", toolName);\n\t\t\tthis.paletteDock.startContext(this);\n\t\t}\n\n\t\ttoggleFavorite(toolName) {\n\t\t\tlet toggleIdx = this.toolSettings.favList.indexOf(toolName);\n\t\t\tif (toggleIdx >= 0) {\n\t\t\t\tthis.toolSettings.favList.splice(toggleIdx, 1);\n\t\t\t} else {\n\t\t\t\tthis.toolSettings.favList.push(toolName);\n\t\t\t}\n\t\t\tthis.storeToolSettings();\n\t\t\tthis.setFavorites();\n\t\t}\n\n\t\tsetToolGroup(activator, groupName) {\n\t\t\t// Filter tools by their group.\n\t\t\tthis.toolSettings.toolGroup = groupName;\n\t\t\tthis.querySelector(\".tool-group\").setAttribute(\n\t\t\t\t\"tool-group-filter\",\n\t\t\t\tthis.toolSettings.toolGroup\n\t\t\t);\n\t\t\tthis.querySelector(\".tool-group cq-scroll\").top();\n\t\t\tthis.setEvenOdd();\n\t\t\tfor (\n\t\t\t\tvar i = 0;\n\t\t\t\ti < this.callbacks.length;\n\t\t\t\ti++ // let any callbacks know that the palette mode has changed\n\t\t\t)\n\t\t\t\tthis.callbacks[i].call(this, this.mode);\n\t\t\t// The mobile palette will be hidden if resize is called in the callbacks. Show it again afterward\n\t\t\tthis.showPalette();\n\t\t\tthis.params.toolGroupSelection.html(activator.node.innerHTML);\n\t\t\tthis.storeToolSettings();\n\t\t}\n\n\t\t/*\n\t\t * Used in break-sm context to show/hide the palette for mobile layout\n\t\t */\n\t\ttogglePalette() {\n\t\t\tthis.classList.toggle(\"palette-hide\");\n\t\t}\n\n\t\t/*\n\t\t * Used in break-sm context to hide the palette for mobile layout\n\t\t */\n\t\thidePalette() {\n\t\t\tthis.classList.add(\"palette-hide\");\n\t\t}\n\n\t\t/*\n\t\t * Used in break-sm context to show the palette for mobile layout\n\t\t */\n\t\tshowPalette() {\n\t\t\tthis.classList.remove(\"palette-hide\");\n\t\t}\n\n\t\tactivateTool(activator, toolName) {\n\t\t\tlet buttonRef = null;\n\t\t\tif (!activator.node && toolName) {\n\t\t\t\t// Find the tool button by its cq-tool attribute.\n\t\t\t\t// Necessary for cases then the button is not clicked, such as the drawing context menu \"Edit Settings\"\n\t\t\t\tbuttonRef = this.querySelector(\"[cq-tool=\" + toolName + \"]\");\n\t\t\t} else {\n\t\t\t\tbuttonRef = activator.node;\n\t\t\t}\n\t\t\tthis.setActiveButton(buttonRef);\n\t\t\tvar stx = this.context.stx;\n\t\t\tstx.clearMeasure();\n\t\t\tstx.changeVectorType(toolName == \"notool\" ? \"\" : toolName);\n\t\t}\n\n\t\tnoTool(activator, toolName) {\n\t\t\tthis.tool(activator, \"notool\");\n\t\t}\n\n\t\ttool(activator, toolName) {\n\t\t\tif (!toolName) toolName = activator.node.getAttribute(\"cq-tool\");\n\t\t\tif (!toolName) return;\n\t\t\tvar toolLabel = activator.node.querySelector(\"label\").innerHTML;\n\t\t\tthis.activateTool(activator, toolName);\n\t\t\tif (this.sendMessage) {\n\t\t\t\tthis.sendMessage(\"changeTool\", {\n\t\t\t\t\tactivator: activator,\n\t\t\t\t\ttoolName: toolName,\n\t\t\t\t\ttoolLabel: toolLabel\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\n\t\tclearDrawings() {\n\t\t\tif (this.sendMessage) {\n\t\t\t\tthis.sendMessage(\"clearDrawings\");\n\t\t\t}\n\t\t}\n\n\t\trestoreDefaultConfig(activator, all) {\n\t\t\tif (this.sendMessage) {\n\t\t\t\tthis.sendMessage(\"restoreDefaultConfig\", {\n\t\t\t\t\tactivator: activator,\n\t\t\t\t\tall: all\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\n\t\tgetMarkup(config) {\n\t\t\tconst tools = config.getMenu(\"drawingTools\", true).join(\"\");\n\t\t\tconst toolGrouping = config.drawingToolGrouping\n\t\t\t\t.map((tool) => {\n\t\t\t\t\treturn `${tool}\n\t\t\t\t`;\n\t\t\t\t})\n\t\t\t\t.join(\"\");\n\n\t\t\treturn this.constructor.markup\n\t\t\t\t.replace(\"{{tools}}\", tools)\n\t\t\t\t.replace(\"{{toolGrouping}}\", toolGrouping);\n\t\t}\n\t}\n\n\tDrawingPalette.markup = `\n\t
    \n\t\t
    \n\t\t\t
    \n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t
    \n\t\t\t\n\t\t\t
    \n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\tAll\n\t\t\t\t\t\n\t\t\t\t\t\t{{toolGrouping}}\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t
    \n\t\t\t\n\t\t\t
    \n\t\t\t\t\n\t\t\t\t\t{{tools}}\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t
    \n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t
    \n\t\t\t
    \n\t\t
    \n\t
    \n\t`;\n\tCIQ.UI.addComponentDefinition(\"cq-drawing-palette\", DrawingPalette);\n}\n\n};\n\n\nlet __js_webcomponents_palette_drawingSettings_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\n\n\n\n\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nconst Palette = CIQ.UI._webcomponents.list[\"cq-palette\"];\nif (!Palette) {\n\tconsole.error(\n\t\t\"drawingSettings component requires first activating palette component.\"\n\t);\n} else if (!CIQ.Drawing) {\n\tconsole.error(\n\t\t\"drawingSettings component requires first activating drawing feature.\"\n\t);\n} else {\n\t/**\n\t * Drawing Settings palette web component used to draw and annotate on the chart. Displays a palette\n\t * along the top of the chart for managing tool settings.\n\t *\n\t * Inherits from ``. Palette components must be placed within a `` component.\n\t *\n\t * This works in conjunction with the [cq-drawing-palette]{@link WebComponents.cq-drawing-palette} component\n\t * and replaces the [cq-toolbar]{@link WebComponents.cq-toolbar} component, providing additional functionality\n\t * and an improved user experience.\n\t *\n\t * Emits a `change` event.\n\t *\n\t * @namespace WebComponents.cq-drawing-settings\n\t * @example\n\t\t\n\t\t\t
    \n\t\t\t\tSelect Tool\n\t\t\t\t
    \n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t
    \n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tNone\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t
    \n\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\n\t\t\t\t\t\n\n\t\t\t\t\t\n\t\t\t\t\t\t
    Axis Label:
    \n\t\t\t\t\t\t\n\t\t\t\t\t
    \n\t\t\t\t\t\n\t\t\t\t\t\tI\n\t\t\t\t\t\tB\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t12px\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t8\n\t\t\t\t\t\t\t\t10\n\t\t\t\t\t\t\t\t12\n\t\t\t\t\t\t\t\t13\n\t\t\t\t\t\t\t\t14\n\t\t\t\t\t\t\t\t16\n\t\t\t\t\t\t\t\t20\n\t\t\t\t\t\t\t\t28\n\t\t\t\t\t\t\t\t36\n\t\t\t\t\t\t\t\t48\n\t\t\t\t\t\t\t\t64\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\tDefault\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tDefault\n\t\t\t\t\t\t\t\tHelvetica\n\t\t\t\t\t\t\t\tCourier\n\t\t\t\t\t\t\t\tGaramond\n\t\t\t\t\t\t\t\tPalatino\n\t\t\t\t\t\t\t\tTimes New Roman\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\tSettings\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\tSettings\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t
    \n\t\t\t\t\t\t
    Done Editing
    \n\t\t\t\t\t
    \n\t\t\t\t\t
    \n\t\t\t\t\t\t
    Save Config
    \n\t\t\t\t\t\t
    Restore Config
    \n\t\t\t\t\t
    \n\t\t\t\t
    \n\t\t\t\t\n\t\t\t
    \n\t\t
    \n\t * @since 7.2.0\n\t */\n\tclass DrawingSettings extends Palette.classDefinition {\n\t\tconnectedCallback() {\n\t\t\tif (this.attached) return;\n\t\t\tsuper.connectedCallback();\n\n\t\t\tCIQ.UI.stxtap(this, function (e) {\n\t\t\t\te.stopPropagation();\n\t\t\t});\n\t\t}\n\n\t\tadoptedCallback() {\n\t\t\tsuper.adoptedCallback();\n\t\t\tCIQ.UI.flattenInheritance(this, DrawingSettings);\n\t\t\tthis.constructor = DrawingSettings;\n\t\t}\n\n\t\tsetContext(context) {\n\t\t\tthis.addDefaultMarkup();\n\t\t\tthis.init();\n\t\t\tthis.params = {\n\t\t\t\tlineSelection: this.node.find(\"*[cq-line-style]\"),\n\t\t\t\tfontSizeSelection: this.node.find(\"*[cq-font-size]\"),\n\t\t\t\tfontFamilySelection: this.node.find(\"*[cq-font-family]\"),\n\t\t\t\tfontStyleToggle: this.node.find(\"cq-annotation-italic\"),\n\t\t\t\tfontWeightToggle: this.node.find(\"cq-annotation-bold\"),\n\t\t\t\taxisLabelToggle: this.node.find(\"cq-axis-label .ciq-checkbox\"),\n\t\t\t\tfillColor: this.node.find(\"cq-fill-color\").not(\"cq-cvp-controller\"),\n\t\t\t\tlineColor: this.node.find(\"cq-line-color\").not(\"cq-cvp-controller\"),\n\t\t\t\tcvpControllers: this.node.find(\"cq-cvp-controller\"),\n\t\t\t\twaveParameters: this.node.find(\"cq-wave-parameters\")\n\t\t\t};\n\t\t\tthis.params.cvpControllers.prop(\"toolbar\", this);\n\n\t\t\t// Add a texture to the drag strip\n\t\t\t//this.querySelector('.drag-strip').style.backgroundImage = \"url('css/img/palette-drag-strip.svg')\";\n\t\t\tthis.sync();\n\t\t\tthis.dirty(false);\n\t\t\tif (context.stx.setDrawingContainer)\n\t\t\t\tcontext.stx.setDrawingContainer(this);\n\t\t\tvar self = this;\n\t\t\tcontext.stx.addEventListener(\"theme\", function (obj) {\n\t\t\t\tvar isDirty = self.node\n\t\t\t\t\t.find(\"*[cq-toolbar-dirty]\")\n\t\t\t\t\t.hasClass(\"ciq-active\");\n\t\t\t\tself.sync();\n\t\t\t\tif (!isDirty) self.dirty(false);\n\t\t\t});\n\t\t}\n\n\t\t// Overridden from palette class\n\t\thandleMessage(id, message) {\n\t\t\tswitch (id) {\n\t\t\t\tcase \"changeTool\":\n\t\t\t\t\t// The Order is important as tool setting initiates chart repositioning\n\t\t\t\t\t// and should be last to make sure that updated height is available\n\t\t\t\t\t// A safer approach would be define static label size that may not be\n\t\t\t\t\t// as desirable from UI layout perspective\n\t\t\t\t\tthis.setActiveToolLabel(message.toolLabel);\n\t\t\t\t\tthis.toolSettings(message.activator, message.toolName);\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"clearDrawings\":\n\t\t\t\t\tthis.clearDrawings();\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"restoreDefaultConfig\":\n\t\t\t\t\tthis.restoreDefaultConfig(message.activator, message.all);\n\t\t\t}\n\t\t}\n\n\t\tclearDrawings() {\n\t\t\tthis.context.stx.clearDrawings(null, false);\n\t\t}\n\n\t\tcrosshairs(activator) {\n\t\t\tvar stx = this.context.stx;\n\t\t\tstx.changeVectorType(null);\n\t\t\tstx.layout.crosshair = true;\n\t\t\tstx.doDisplayCrosshairs();\n\t\t\tstx.findHighlights(false, true);\n\t\t\tstx.changeOccurred(\"layout\");\n\t\t\tstx.draw();\n\t\t\tstx.updateChartAccessories();\n\t\t\tthis.node.find(\"*[cq-section]\").removeClass(\"ciq-active\");\n\t\t\tthis.emit();\n\t\t}\n\n\t\ttool(activator, toolName) {\n\t\t\tthis.toolSettings(activator, toolName);\n\t\t\tthis.setActiveToolLabel(toolName);\n\t\t\tthis.sendMessage(\"changeToolSettings\", {\n\t\t\t\tactivator: activator,\n\t\t\t\ttoolName: toolName\n\t\t\t});\n\t\t}\n\n\t\ttoolSettings(activator, toolName) {\n\t\t\tvar stx = this.context.stx;\n\t\t\tthis.node.find(\"*[cq-section]\").removeClass(\"ciq-active\");\n\t\t\tvar removeDirty = !this.node\n\t\t\t\t.find(\"*[cq-toolbar-dirty]\")\n\t\t\t\t.hasClass(\"ciq-active\");\n\t\t\tvar drawingParameters = CIQ.Drawing.getDrawingParameters(stx, toolName);\n\t\t\tif (drawingParameters) {\n\t\t\t\tthis.node.find(\"*[cq-toolbar-action='save']\").addClass(\"ciq-active\");\n\t\t\t\tvar drawingPrefs = stx.preferences.drawings;\n\t\t\t\tif (drawingPrefs && drawingPrefs[toolName]) {\n\t\t\t\t\tthis.node\n\t\t\t\t\t\t.find(\"*[cq-toolbar-action='restore']\")\n\t\t\t\t\t\t.addClass(\"ciq-active\");\n\t\t\t\t\tremoveDirty = true;\n\t\t\t\t}\n\t\t\t\t// fibtimezone has no values to display in the settings dialog\n\t\t\t\tif (toolName === \"fibtimezone\") {\n\t\t\t\t\tdelete drawingParameters.parameters;\n\t\t\t\t}\n\n\t\t\t\tvar none = this.params.lineSelection.parent().find(\".ciq-none\");\n\t\t\t\tnone.hide();\n\t\t\t\tvar elements = this.defaultElements(drawingParameters, toolName);\n\t\t\t\tfor (var i = 0; i < elements.length; i++) {\n\t\t\t\t\tthis.node.find(elements[i]).addClass(\"ciq-active\");\n\t\t\t\t\tif (elements[i] == \"cq-fill-color\") none.show();\n\t\t\t\t}\n\t\t\t\telements = CIQ.Drawing[toolName].prototype.$controls;\n\t\t\t\tif (elements) {\n\t\t\t\t\tfor (i = 0; i < elements.length; i++) {\n\t\t\t\t\t\tthis.node.find(elements[i]).addClass(\"ciq-active\");\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (toolName === \"notool\") {\n\t\t\t\tstx.changeVectorType(\"\");\n\t\t\t\tif (stx.preferences.magnet) {\n\t\t\t\t\tthis.toggleMagnet(this);\n\t\t\t\t}\n\t\t\t\tthis.hide = \"true\";\n\t\t\t} else {\n\t\t\t\tthis.hide = \"false\";\n\t\t\t}\n\t\t\t// Resizing the dock because the setting palette is hidden/shown based on the 'no tool' selection\n\t\t\tthis.paletteDock.handleResize();\n\t\t\tthis.sync();\n\t\t\tif (removeDirty) this.dirty(false);\n\t\t}\n\n\t\tdefaultElements(drawingParameters, toolName) {\n\t\t\tvar arr = [];\n\t\t\tfor (var param in drawingParameters) {\n\t\t\t\tif (param == \"color\") arr.push(\"cq-line-color\");\n\t\t\t\telse if (param == \"fillColor\") arr.push(\"cq-fill-color\");\n\t\t\t\telse if (param == \"pattern\" || param == \"lineWidth\")\n\t\t\t\t\tarr.push(\"cq-line-style\");\n\t\t\t\telse if (param == \"axisLabel\") arr.push(\"cq-axis-label\");\n\t\t\t\telse if (param == \"font\") arr.push(\"cq-annotation\");\n\t\t\t\telse if (param == \"parameters\") {\n\t\t\t\t\tif (toolName === \"volumeprofile\") {\n\t\t\t\t\t\tarr.push(\"cq-clickable[cq-volumeprofile-settings]\");\n\t\t\t\t\t} else {\n\t\t\t\t\t\tarr.push(\"cq-clickable[cq-fib-settings]\");\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn arr;\n\t\t}\n\n\t\tdirty(on) {\n\t\t\tthis.node\n\t\t\t\t.find(\"*[cq-toolbar-dirty]\")\n\t\t\t\t[on === false ? \"removeClass\" : \"addClass\"](\"ciq-active\");\n\t\t}\n\n\t\temit() {\n\t\t\tvar event = new Event(\"change\", {\n\t\t\t\tbubbles: true,\n\t\t\t\tcancelable: true\n\t\t\t});\n\t\t\tthis.dirty();\n\t\t\tthis.dispatchEvent(event);\n\t\t}\n\n\t\tgetFillColor(activator) {\n\t\t\tvar node = CIQ.UI.$(activator.node);\n\t\t\tvar color = this.context.stx.currentVectorParameters.fillColor;\n\t\t\tif (color == \"transparent\" || color == \"auto\") color = \"\";\n\t\t\tnode.css({ background: color });\n\t\t\tvar bgColor = CIQ.getBackgroundColor(this.parentNode);\n\t\t\tif (color && Math.abs(CIQ.hsl(bgColor)[2] - CIQ.hsl(color)[2]) < 0.2) {\n\t\t\t\tvar border = CIQ.chooseForegroundColor(bgColor);\n\t\t\t\tnode.css({ border: \"solid \" + border + \" 1px\" });\n\t\t\t} else {\n\t\t\t\tnode.css({ border: \"\" });\n\t\t\t}\n\t\t}\n\n\t\tgetLineColor(activator) {\n\t\t\tvar node = CIQ.UI.$(activator.node);\n\t\t\tvar color = this.context.stx.currentVectorParameters.currentColor;\n\t\t\tif (color == \"transparent\" || color == \"auto\") color = \"\";\n\t\t\tnode.css({ background: color });\n\t\t\tvar bgColor = CIQ.getBackgroundColor(this.parentNode);\n\t\t\tif (!color || Math.abs(CIQ.hsl(bgColor)[2] - CIQ.hsl(color)[2]) < 0.2) {\n\t\t\t\tvar border = CIQ.chooseForegroundColor(bgColor);\n\t\t\t\tnode.css({ border: \"solid \" + border + \" 1px\" });\n\t\t\t\tif (!color)\n\t\t\t\t\tnode.css({\n\t\t\t\t\t\tbackground:\n\t\t\t\t\t\t\t\"linear-gradient(to bottom right, \" +\n\t\t\t\t\t\t\tborder +\n\t\t\t\t\t\t\t\", \" +\n\t\t\t\t\t\t\tborder +\n\t\t\t\t\t\t\t\" 49%, \" +\n\t\t\t\t\t\t\tbgColor +\n\t\t\t\t\t\t\t\" 50%, \" +\n\t\t\t\t\t\t\tbgColor +\n\t\t\t\t\t\t\t\")\"\n\t\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tnode.css({ border: \"\" });\n\t\t\t}\n\t\t}\n\n\t\tpickFillColor(activator) {\n\t\t\tvar node = CIQ.UI.$(activator.node);\n\t\t\tvar colorPicker = this.ownerDocument.querySelector(\"cq-color-picker\");\n\t\t\tif (!colorPicker) {\n\t\t\t\tconsole.log(\n\t\t\t\t\t\"DrawingToolbar.prototype.pickFillColor: no ColorPicker available\"\n\t\t\t\t);\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tvar self = this;\n\t\t\tcolorPicker.callback = function (color) {\n\t\t\t\tself.context.stx.currentVectorParameters.fillColor = color;\n\t\t\t\tself.getFillColor({ node });\n\t\t\t\tself.emit();\n\t\t\t};\n\t\t\tcolorPicker.display({ node, context: self.context });\n\t\t}\n\n\t\tpickLineColor(activator) {\n\t\t\tvar node = CIQ.UI.$(activator.node);\n\t\t\tvar colorPicker = this.ownerDocument.querySelector(\"cq-color-picker\");\n\t\t\tif (!colorPicker) {\n\t\t\t\tconsole.log(\n\t\t\t\t\t\"DrawingToolbar.prototype.pickLineColor: no ColorPicker available\"\n\t\t\t\t);\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tvar self = this;\n\t\t\tcolorPicker.callback = function (color) {\n\t\t\t\tself.context.stx.currentVectorParameters.currentColor = color;\n\t\t\t\tself.getLineColor({ node });\n\t\t\t\tself.emit();\n\t\t\t};\n\t\t\tvar overrides = node.attr(\"cq-overrides\");\n\t\t\tif (overrides) overrides = overrides.split(\",\");\n\t\t\tcolorPicker.display({ node, overrides, context: self.context });\n\t\t}\n\n\t\trestoreDefaultConfig(activator, all) {\n\t\t\tvar stx = this.context.stx;\n\t\t\tCIQ.Drawing.restoreDefaultConfig(\n\t\t\t\tstx,\n\t\t\t\tstx.currentVectorParameters.vectorType,\n\t\t\t\tall\n\t\t\t);\n\t\t\tthis.node\n\t\t\t\t.find(\"*[cq-toolbar-action='restore']\")\n\t\t\t\t.removeClass(\"ciq-active\");\n\t\t\tthis.sync();\n\t\t\tthis.dirty(false);\n\t\t}\n\n\t\tsaveConfig() {\n\t\t\tvar stx = this.context.stx;\n\t\t\tCIQ.Drawing.saveConfig(stx, stx.currentVectorParameters.vectorType);\n\t\t\tthis.node.find(\"*[cq-toolbar-action='restore']\").addClass(\"ciq-active\");\n\t\t\tthis.sync();\n\t\t\tthis.dirty(false);\n\t\t}\n\n\t\tsetFibs(width, pattern) {\n\t\t\tvar fib = this.context.stx.currentVectorParameters.fibonacci;\n\t\t\tif (fib) {\n\t\t\t\tfor (var i = 0; i < fib.fibs.length; i++) {\n\t\t\t\t\tfib.fibs[i].parameters.lineWidth = width;\n\t\t\t\t\tfib.fibs[i].parameters.pattern = pattern;\n\t\t\t\t}\n\t\t\t\tfib.timezone.parameters.lineWidth = width;\n\t\t\t\tfib.timezone.parameters.pattern = pattern;\n\t\t\t}\n\t\t}\n\n\t\tsetFontFamily(activator, fontFamily) {\n\t\t\tvar stx = this.context.stx;\n\n\t\t\tif (stx.currentVectorParameters.annotation) {\n\t\t\t\tif (fontFamily == \"Default\") {\n\t\t\t\t\tstx.currentVectorParameters.annotation.font.family = null;\n\t\t\t\t} else {\n\t\t\t\t\tstx.currentVectorParameters.annotation.font.family = fontFamily;\n\t\t\t\t}\n\t\t\t}\n\t\t\tthis.params.fontFamilySelection.text(fontFamily);\n\t\t\tthis.emit();\n\t\t}\n\n\t\tsetFontSize(activator, fontSize) {\n\t\t\tvar stx = this.context.stx;\n\n\t\t\tif (stx.currentVectorParameters.annotation)\n\t\t\t\tstx.currentVectorParameters.annotation.font.size = fontSize;\n\t\t\tthis.params.fontSizeSelection.text(fontSize);\n\t\t\tthis.emit();\n\t\t}\n\n\t\tsetLine(activator, width, pattern) {\n\t\t\tvar stx = this.context.stx;\n\n\t\t\tstx.currentVectorParameters.lineWidth = width;\n\t\t\tstx.currentVectorParameters.pattern = pattern;\n\t\t\tthis.setFibs(width, pattern);\n\t\t\tif (this.currentLineSelectedClass)\n\t\t\t\tthis.params.lineSelection.removeClass(this.currentLineSelectedClass);\n\t\t\tthis.currentLineSelectedClass =\n\t\t\t\t\"ciq-\" + pattern + \"-\" + parseInt(width, 10);\n\t\t\tif (pattern == \"none\") {\n\t\t\t\tthis.currentLineSelectedClass = null;\n\t\t\t} else {\n\t\t\t\tthis.params.lineSelection.addClass(this.currentLineSelectedClass);\n\t\t\t}\n\t\t\tthis.emit();\n\t\t}\n\n\t\tsetActiveToolLabel(activeToolLabel) {\n\t\t\t// Clean up tool labels\n\t\t\tif (activeToolLabel === \"No Tool\") {\n\t\t\t\tactiveToolLabel = \"\";\n\t\t\t} else if (activeToolLabel === \"freeform\") {\n\t\t\t\tactiveToolLabel = \"Doodle\";\n\t\t\t} else {\n\t\t\t\tactiveToolLabel = activeToolLabel + \":\";\n\t\t\t}\n\t\t\tthis.querySelector(\".ciq-active-tool-label\").innerHTML = activeToolLabel;\n\t\t\tthis.querySelector(\".ciq-mobile-palette-toggle span\").innerHTML =\n\t\t\t\tactiveToolLabel || \"Select Tool\";\n\t\t}\n\n\t\t/**\n\t\t * Synchronizes the drawing toolbar with stx.currentVectorParameters. Poor man's data binding.\n\t\t * @param {object} [cvp=stx.currentVectorParameters] A new drawing object, otherwise defaults to the current one\n\t\t * @memberof WebComponents.cq-toolbar\n\t\t */\n\t\tsync(cvp) {\n\t\t\tvar stx = this.context.stx;\n\t\t\tif (!cvp) cvp = stx.currentVectorParameters;\n\t\t\telse\n\t\t\t\tstx.currentVectorParameters = CIQ.extend(\n\t\t\t\t\tstx.currentVectorParameters || {},\n\t\t\t\t\tcvp\n\t\t\t\t);\n\n\t\t\tvar params = this.params;\n\t\t\tthis.setLine(null, cvp.lineWidth, cvp.pattern);\n\n\t\t\tvar style = stx.canvasStyle(\"stx_annotation\");\n\n\t\t\tvar font = cvp.annotation && cvp.annotation.font;\n\n\t\t\tvar initialSize = (font && font.size) || style.fontSize;\n\t\t\tthis.setFontSize(null, initialSize);\n\n\t\t\tvar initialFamily = (font && font.family) || style.fontFamily;\n\t\t\tthis.setFontFamily(null, initialFamily);\n\n\t\t\tvar initialFontStyle = (font && font.style) || style.fontStyle;\n\t\t\tparams.fontStyleToggle[\n\t\t\t\tinitialFontStyle === \"italic\" ? \"addClass\" : \"removeClass\"\n\t\t\t](\"ciq-active\");\n\n\t\t\tvar initialWeight = (font && font.weight) || style.fontWeight;\n\t\t\tparams.fontWeightToggle[\n\t\t\t\tinitialWeight === \"bold\" || initialWeight >= 700\n\t\t\t\t\t? \"addClass\"\n\t\t\t\t\t: \"removeClass\"\n\t\t\t](\"ciq-active\");\n\n\t\t\tparams.axisLabelToggle[cvp.axisLabel ? \"addClass\" : \"removeClass\"](\n\t\t\t\t\"ciq-active\"\n\t\t\t);\n\n\t\t\tthis.getFillColor({ node: params.fillColor });\n\t\t\tthis.getLineColor({ node: params.lineColor });\n\n\t\t\tparams.cvpControllers.each(function () {\n\t\t\t\tthis.sync(cvp);\n\t\t\t});\n\n\t\t\tvar waveParameters = params.waveParameters;\n\t\t\tif (waveParameters && waveParameters[0]) {\n\t\t\t\twaveParameters[0].activate();\n\t\t\t}\n\t\t}\n\n\t\ttoggleAxisLabel(activator) {\n\t\t\tvar stx = this.context.stx;\n\t\t\tvar node = CIQ.UI.$(activator.node);\n\n\t\t\tif (stx.currentVectorParameters.axisLabel === true) {\n\t\t\t\tstx.currentVectorParameters.axisLabel = false;\n\t\t\t\tnode.removeClass(\"ciq-active\");\n\t\t\t} else {\n\t\t\t\tstx.currentVectorParameters.axisLabel = true;\n\t\t\t\tnode.addClass(\"ciq-active\");\n\t\t\t}\n\t\t\tthis.emit();\n\t\t}\n\n\t\ttoggleFontStyle(activator, fontStyle) {\n\t\t\tvar stx = this.context.stx;\n\t\t\tvar node = CIQ.UI.$(activator.node);\n\n\t\t\tif (fontStyle == \"italic\") {\n\t\t\t\tif (stx.currentVectorParameters.annotation.font.style == \"italic\") {\n\t\t\t\t\tstx.currentVectorParameters.annotation.font.style = null;\n\t\t\t\t\tnode.removeClass(\"ciq-active\");\n\t\t\t\t} else {\n\t\t\t\t\tstx.currentVectorParameters.annotation.font.style = \"italic\";\n\t\t\t\t\tnode.addClass(\"ciq-active\");\n\t\t\t\t}\n\t\t\t} else if (fontStyle == \"bold\") {\n\t\t\t\tif (stx.currentVectorParameters.annotation.font.weight == \"bold\") {\n\t\t\t\t\tstx.currentVectorParameters.annotation.font.weight = null;\n\t\t\t\t\tnode.removeClass(\"ciq-active\");\n\t\t\t\t} else {\n\t\t\t\t\tstx.currentVectorParameters.annotation.font.weight = \"bold\";\n\t\t\t\t\tnode.addClass(\"ciq-active\");\n\t\t\t\t}\n\t\t\t}\n\t\t\tthis.emit();\n\t\t}\n\n\t\ttoggleMagnet(activator) {\n\t\t\tvar toggle = CIQ.UI.$(activator.node);\n\t\t\tvar stx = this.context.stx;\n\t\t\tif (stx.preferences.magnet) {\n\t\t\t\ttoggle.removeClass(\"active\");\n\t\t\t\tstx.preferences.magnet = false;\n\t\t\t} else {\n\t\t\t\ttoggle.addClass(\"active\");\n\t\t\t\tstx.preferences.magnet = true;\n\t\t\t}\n\t\t\tCIQ.clearCanvas(stx.chart.tempCanvas, stx);\n\t\t}\n\n\t\ttogglePalette() {\n\t\t\tthis.sendMessage(\"toggleDrawingPalette\");\n\t\t}\n\t}\n\n\tDrawingSettings.markup = `\n\t
    \n\t\t
    \n\t\t\t
    \n\t\t\t\t\t
    \n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t
    \n\t\t\t\tSelect Tool\n\t\t\t\t\n\t\t\t\t\t
    \n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t
    \n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tNone\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t
    \n\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\n\t\t\t\t\t\n\n\t\t\t\t\t\n\t\t\t\t\t\t
    Axis Label:
    \n\t\t\t\t\t\t\n\t\t\t\t\t
    \n\t\t\t\t\t\n\t\t\t\t\t\tI\n\t\t\t\t\t\tB\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t12px\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t8\n\t\t\t\t\t\t\t\t10\n\t\t\t\t\t\t\t\t12\n\t\t\t\t\t\t\t\t13\n\t\t\t\t\t\t\t\t14\n\t\t\t\t\t\t\t\t16\n\t\t\t\t\t\t\t\t20\n\t\t\t\t\t\t\t\t28\n\t\t\t\t\t\t\t\t36\n\t\t\t\t\t\t\t\t48\n\t\t\t\t\t\t\t\t64\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\tDefault\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tDefault\n\t\t\t\t\t\t\t\tHelvetica\n\t\t\t\t\t\t\t\tCourier\n\t\t\t\t\t\t\t\tGaramond\n\t\t\t\t\t\t\t\tPalatino\n\t\t\t\t\t\t\t\tTimes New Roman\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\tSettings\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\tSettings\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t
    \n\t\t\t\t\t\t
    Done Editing
    \n\t\t\t\t\t
    \n\t\t\t\t\t
    \n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t
    \n\t\t\t\t\t\t
    Save Config
    \n\t\t\t\t\t\t
    Restore Config
    \n\t\t\t\t\t
    \n\t\t\t\t
    \n\t\t\t\t\n\t\t\t
    \n\t\t
    \n\t
    \n\t`;\n\tCIQ.UI.addComponentDefinition(\"cq-drawing-settings\", DrawingSettings);\n}\n\n};\n\n\nlet __js_webcomponents_scroll_menuDropdown_ = (_exports) => {\n\n/* global _CIQ, _timezoneJS, _SplinePlotter */\n\n\nvar CIQ = typeof _CIQ !== \"undefined\" ? _CIQ : _exports.CIQ;\n\nconst Scroll = CIQ.UI._webcomponents.list[\"cq-scroll\"];\nif (!Scroll) {\n\tconsole.error(\n\t\t\"menuDropdown component requires first activating scroll component.\"\n\t);\n} else {\n\t/**\n\t * Menu DropDown web component ``.\n\t *\n\t * Menu DropDown handles holding the items that go inside a custom menu component.\n\t *\n\t * Menu DropDown is a semantic element to be used in menus that has the same functionality as {@link WebComponents.cq-scroll} The main difference is that Menu DropDown sets noMaximize to true which means that the component will not automatically resize.\n\t *\n\t * @namespace WebComponents.cq-menu-dropdown\n\t * @example\n\t \n\t\t Studies\n\t\t \n\t\t\t \n\t\t\t\t \n\t\t\t\t\t Current Studies\n\t\t\t\t\t \n\t\t\t\t\t\t \n\t\t\t\t\t \n\t\t\t\t\t \n\t\t\t\t\t\t
    Clear All
    \n\t\t\t\t\t
    \n\t\t\t\t
    \n\t\t\t
    \n\t\t\t \n\t\t\t\t \n\t\t\t\t \t \n\t\t\t\t\t\t\n\t\t\t\t\t \n\t\t\t\t \n\t\t\t \n\t\t
    \n\t * @since 7.0.0 no longer dual inherits CIQ.UI.BaseComponent and CIQ.UI.Scroll. Now directly inherits Scroll which extends BaseComponent.\n\t */\n\tclass MenuDropDown extends Scroll.classDefinition {\n\t\tconstructor() {\n\t\t\tsuper();\n\t\t\tthis.noMaximize = true;\n\t\t}\n\n\t\tconnectedCallback() {\n\t\t\tsuper.connectedCallback();\n\t\t}\n\n\t\tadoptedCallback() {\n\t\t\tsuper.adoptedCallback();\n\t\t\tCIQ.UI.flattenInheritance(this, MenuDropDown);\n\t\t}\n\n\t\tdisablekeyboardNavigation() {\n\t\t\tif (this.keyboardNavigation) {\n\t\t\t\tthis.keyboardNavigation.setKeyControlElement();\n\t\t\t}\n\t\t}\n\t}\n\n\tCIQ.UI.addComponentDefinition(\"cq-menu-dropdown\", MenuDropDown);\n}\n\n};\n\n\nlet _exports = {CIQ:__CIQ_};\nexport {__js_webcomponents_abstractMarker_ as abstractMarker};\nexport {__js_webcomponents_advertisement_ as advertisement};\nexport {__js_webcomponents_aggregationDialog_ as aggregationDialog};\nexport {__js_webcomponents_attribution_ as attribution};\nexport {__js_webcomponents_chartInstructions_ as chartInstructions};\nexport {__js_webcomponents_chartLegend_ as chartLegend};\nexport {__js_webcomponents_chartTitle_ as chartTitle};\nexport {__js_webcomponents_chartcontrolGroup_ as chartcontrolGroup};\nexport {__js_webcomponents_clickable_ as clickable};\nexport {__js_webcomponents_close_ as close};\nexport {__js_webcomponents_comparison_ as comparison};\nexport {__js_webcomponents_comparisonLookup_ as comparisonLookup};\nexport {__js_webcomponents_cvpController_ as cvpController};\nexport {__js_webcomponents_dataDialog_ as dataDialog};\nexport {__js_webcomponents_dialog_ as dialog};\nexport {__js_webcomponents_doubleSlider_ as doubleSlider};\nexport {__js_webcomponents_drawingContext_ as drawingContext};\nexport {__js_webcomponents_fibSettingsDialog_ as fibSettingsDialog};\nexport {__js_webcomponents_floatingWindow_ as floatingWindow};\nexport {__js_webcomponents_gridSizePicker_ as gridSizePicker};\nexport {__js_webcomponents_heading_ as heading};\nexport {__js_webcomponents_headsupDynamic_ as headsupDynamic};\nexport {__js_webcomponents_headsupStatic_ as headsupStatic};\nexport {__js_webcomponents_help_ as help};\nexport {__js_webcomponents_infoToggle_ as infoToggle};\nexport {__js_webcomponents_infoToggleDropdown_ as infoToggleDropdown};\nexport {__js_webcomponents_instantChart_ as instantChart};\nexport {__js_webcomponents_languageDialog_ as languageDialog};\nexport {__js_webcomponents_loader_ as loader};\nexport {__js_webcomponents_lookup_ as lookup};\nexport {__js_webcomponents_menu_ as menu};\nexport {__js_webcomponents_menuContainer_ as menuContainer};\nexport {__js_webcomponents_messageToaster_ as messageToaster};\nexport {__js_webcomponents_palette_ as palette};\nexport {__js_webcomponents_paletteDock_ as paletteDock};\nexport {__js_webcomponents_redo_ as redo};\nexport {__js_webcomponents_scroll_ as scroll};\nexport {__js_webcomponents_shareButton_ as shareButton};\nexport {__js_webcomponents_shareDialog_ as shareDialog};\nexport {__js_webcomponents_showRange_ as showRange};\nexport {__js_webcomponents_sideNav_ as sideNav};\nexport {__js_webcomponents_sidePanel_ as sidePanel};\nexport {__js_webcomponents_studies_ as studies};\nexport {__js_webcomponents_studyContext_ as studyContext};\nexport {__js_webcomponents_studyDialog_ as studyDialog};\nexport {__js_webcomponents_studyInput_ as studyInput};\nexport {__js_webcomponents_studyLegend_ as studyLegend};\nexport {__js_webcomponents_studyOutput_ as studyOutput};\nexport {__js_webcomponents_studyParameter_ as studyParameter};\nexport {__js_webcomponents_swatch_ as swatch};\nexport {__js_webcomponents_themeDialog_ as themeDialog};\nexport {__js_webcomponents_themePiece_ as themePiece};\nexport {__js_webcomponents_themes_ as themes};\nexport {__js_webcomponents_timezoneDialog_ as timezoneDialog};\nexport {__js_webcomponents_toggle_ as toggle};\nexport {__js_webcomponents_toolbar_ as toolbar};\nexport {__js_webcomponents_undo_ as undo};\nexport {__js_webcomponents_viewDialog_ as viewDialog};\nexport {__js_webcomponents_views_ as views};\nexport {__js_webcomponents_volumeProfileSettingsDialog_ as volumeProfileSettingsDialog};\nexport {__js_webcomponents_waveParameters_ as waveParameters};\nexport {__js_webcomponents_dialog_colorPicker_ as colorPicker};\nexport {__js_webcomponents_palette_drawingPalette_ as drawingPalette};\nexport {__js_webcomponents_palette_drawingSettings_ as drawingSettings};\nexport {__js_webcomponents_scroll_menuDropdown_ as menuDropdown};\n\nexport {__CIQ_ as CIQ};\n\n/* global __TREE_SHAKE__ */\nif (typeof __TREE_SHAKE__ === \"undefined\" || !__TREE_SHAKE__) {\n\t_exports.CIQ.activateImports(\n\t\t__js_webcomponents_abstractMarker_,\n\t\t__js_webcomponents_advertisement_,\n\t\t__js_webcomponents_aggregationDialog_,\n\t\t__js_webcomponents_attribution_,\n\t\t__js_webcomponents_chartInstructions_,\n\t\t__js_webcomponents_chartLegend_,\n\t\t__js_webcomponents_chartTitle_,\n\t\t__js_webcomponents_chartcontrolGroup_,\n\t\t__js_webcomponents_clickable_,\n\t\t__js_webcomponents_close_,\n\t\t__js_webcomponents_comparison_,\n\t\t__js_webcomponents_comparisonLookup_,\n\t\t__js_webcomponents_cvpController_,\n\t\t__js_webcomponents_dataDialog_,\n\t\t__js_webcomponents_dialog_,\n\t\t__js_webcomponents_doubleSlider_,\n\t\t__js_webcomponents_drawingContext_,\n\t\t__js_webcomponents_fibSettingsDialog_,\n\t\t__js_webcomponents_floatingWindow_,\n\t\t__js_webcomponents_gridSizePicker_,\n\t\t__js_webcomponents_heading_,\n\t\t__js_webcomponents_headsupDynamic_,\n\t\t__js_webcomponents_headsupStatic_,\n\t\t__js_webcomponents_help_,\n\t\t__js_webcomponents_infoToggle_,\n\t\t__js_webcomponents_infoToggleDropdown_,\n\t\t__js_webcomponents_instantChart_,\n\t\t__js_webcomponents_languageDialog_,\n\t\t__js_webcomponents_loader_,\n\t\t__js_webcomponents_lookup_,\n\t\t__js_webcomponents_menu_,\n\t\t__js_webcomponents_menuContainer_,\n\t\t__js_webcomponents_messageToaster_,\n\t\t__js_webcomponents_palette_,\n\t\t__js_webcomponents_paletteDock_,\n\t\t__js_webcomponents_redo_,\n\t\t__js_webcomponents_scroll_,\n\t\t__js_webcomponents_shareButton_,\n\t\t__js_webcomponents_shareDialog_,\n\t\t__js_webcomponents_showRange_,\n\t\t__js_webcomponents_sideNav_,\n\t\t__js_webcomponents_sidePanel_,\n\t\t__js_webcomponents_studies_,\n\t\t__js_webcomponents_studyContext_,\n\t\t__js_webcomponents_studyDialog_,\n\t\t__js_webcomponents_studyInput_,\n\t\t__js_webcomponents_studyLegend_,\n\t\t__js_webcomponents_studyOutput_,\n\t\t__js_webcomponents_studyParameter_,\n\t\t__js_webcomponents_swatch_,\n\t\t__js_webcomponents_themeDialog_,\n\t\t__js_webcomponents_themePiece_,\n\t\t__js_webcomponents_themes_,\n\t\t__js_webcomponents_timezoneDialog_,\n\t\t__js_webcomponents_toggle_,\n\t\t__js_webcomponents_toolbar_,\n\t\t__js_webcomponents_undo_,\n\t\t__js_webcomponents_viewDialog_,\n\t\t__js_webcomponents_views_,\n\t\t__js_webcomponents_volumeProfileSettingsDialog_,\n\t\t__js_webcomponents_waveParameters_,\n\t\t__js_webcomponents_dialog_colorPicker_,\n\t\t__js_webcomponents_palette_drawingPalette_,\n\t\t__js_webcomponents_palette_drawingSettings_,\n\t\t__js_webcomponents_scroll_menuDropdown_,\n\t\tnull\n\t);\n}","/**!\n *\t8.7.0\n *\tGeneration date: 2024-05-31T12:44:23.686Z\n *\tClient name: euroland as\n *\tPackage Type: Technical Analysis e98f22c\n *\tLicense type: annual\n *\tExpiration date: \"2025/06/01\"\n *\tDomain lock: [\"127.0.0.1\",\"localhost\",\"euroland.com\",\"eurolandir.cn\",\"eurolandir.com\"]\n *\tFeatures: TypeScript Definitions,SignalIQ\n */\n\n/***********************************************************!\n * Copyright © 2023 S&P Global All rights reserved\n*************************************************************/\n/*************************************! DO NOT MAKE CHANGES TO THIS LIBRARY FILE!! !*************************************\n* If you wish to overwrite default functionality, create a separate file with a copy of the methods you are overwriting *\n* and load that file right after the library has been loaded, but before the chart engine is instantiated. *\n* Directly modifying library files will prevent upgrades and the ability for ChartIQ to support your solution. *\n*************************************************************************************************************************/\n/* eslint-disable no-extra-parens */\n\n\n/* eslint-disable */ /* jshint ignore:start */ /* ignore jslint start */\nk_Cdw[270248]=(function(){var M=2;for(;M !== 9;){switch(M){case 5:var V;M=4;break;case 1:return globalThis;break;case 2:M=typeof globalThis === '\\u006f\\x62\\u006a\\u0065\\x63\\u0074'?1:5;break;case 4:try{var I=2;for(;I !== 6;){switch(I){case 9:delete V['\\x66\\u0067\\x68\\u0032\\x56'];var A=Object['\\x70\\u0072\\x6f\\x74\\u006f\\u0074\\x79\\x70\\x65'];delete A['\\x53\\x44\\u0059\\x44\\u0074'];I=6;break;case 2:Object['\\u0064\\u0065\\u0066\\u0069\\x6e\\u0065\\u0050\\u0072\\x6f\\u0070\\u0065\\x72\\u0074\\x79'](Object['\\u0070\\x72\\x6f\\u0074\\u006f\\x74\\u0079\\u0070\\u0065'],'\\x53\\x44\\u0059\\x44\\x74',{'\\u0067\\x65\\u0074':function(){return this;},'\\x63\\x6f\\x6e\\u0066\\x69\\x67\\u0075\\x72\\u0061\\u0062\\x6c\\x65':true});V=SDYDt;V['\\x66\\x67\\x68\\x32\\u0056']=V;I=4;break;case 4:I=typeof fgh2V === '\\x75\\x6e\\x64\\x65\\x66\\u0069\\x6e\\u0065\\x64'?3:9;break;case 3:throw \"\";I=9;break;}}}catch(N){V=window;}return V;break;}}})();O_I7BV(k_Cdw[270248]);k_Cdw.n8=function(){return typeof k_Cdw[473995].B33JJB6 === 'function'?k_Cdw[473995].B33JJB6.apply(k_Cdw[473995],arguments):k_Cdw[473995].B33JJB6;};k_Cdw[473995]=(function(W4){var H$=2;for(;H$ !== 10;){switch(H$){case 5:Z0=k_Cdw[270248];H$=4;break;case 13:H$=!f9--?12:11;break;case 12:var K7,C6=0,g4;H$=11;break;case 7:C_=A$.g9NQoR(new Z0[m5](\"^['-|]\"),'S');H$=6;break;case 14:W4=W4.g7JRoh(function(c3){var d$=2;for(;d$ !== 13;){switch(d$){case 1:d$=!f9--?5:4;break;case 3:d$=i_ < c3.length?9:7;break;case 14:return H_;break;case 9:H_+=Z0[C_][u0](c3[i_] + 103);d$=8;break;case 8:i_++;d$=3;break;case 4:var i_=0;d$=3;break;case 2:var H_;d$=1;break;case 5:H_='';d$=4;break;case 7:d$=!H_?6:14;break;case 6:return;break;}}});H$=13;break;case 9:A$=typeof u0;H$=8;break;case 11:return {B33JJB6:function(i0){var s1=2;for(;s1 !== 6;){switch(s1){case 3:s1=!f9--?9:8;break;case 4:K7=b7(V2);s1=3;break;case 5:s1=!f9--?4:3;break;case 8:var P3=(function(S$,W7){var e8=2;for(;e8 !== 10;){switch(e8){case 3:var X0,q5=0;e8=9;break;case 11:return X0;break;case 2:e8=typeof S$ === 'undefined' && typeof i0 !== 'undefined'?1:5;break;case 1:S$=i0;e8=5;break;case 14:X0=p2;e8=13;break;case 4:W7=W4;e8=3;break;case 6:e8=q5 === 0?14:12;break;case 5:e8=typeof W7 === 'undefined' && typeof W4 !== 'undefined'?4:3;break;case 9:e8=q5 < S$[W7[5]]?8:11;break;case 12:X0=X0 ^ p2;e8=13;break;case 8:var u4=Z0[W7[4]](S$[W7[2]](q5),16)[W7[3]](2);var p2=u4[W7[2]](u4[W7[5]] - 1);e8=6;break;case 13:q5++;e8=9;break;}}})(undefined,undefined);return P3?K7:!K7;break;case 1:s1=V2 > C6?5:8;break;case 2:var V2=new Z0[W4[0]]()[W4[1]]();s1=1;break;case 9:C6=V2 + 60000;s1=8;break;}}}};break;case 1:H$=!f9--?5:4;break;case 4:var u0='fromCharCode',m5='RegExp';H$=3;break;case 6:H$=!f9--?14:13;break;case 2:var Z0,A$,C_,f9;H$=1;break;case 8:H$=!f9--?7:6;break;case 3:H$=!f9--?9:8;break;}}function b7(q$){var B4=2;for(;B4 !== 25;){switch(B4){case 4:B4=!f9--?3:9;break;case 7:B4=!f9--?6:14;break;case 12:B4=!f9--?11:10;break;case 1:B4=!f9--?5:4;break;case 26:g4='j-002-00003';B4=16;break;case 5:J9=Z0[W4[4]];B4=4;break;case 10:B4=!f9--?20:19;break;case 16:return s7;break;case 15:B4=K9 >= 0 && K9 - q$ <= O0?27:16;break;case 14:B4=!f9--?13:12;break;case 2:var s7,O0,n4,K9,l5,H4,J9;B4=1;break;case 6:K9=n4 && J9(n4,O0);B4=14;break;case 17:g4='j-002-00005';B4=16;break;case 9:B4=!f9--?8:7;break;case 13:l5=W4[7];B4=12;break;case 18:s7=false;B4=17;break;case 8:n4=W4[6];B4=7;break;case 3:O0=25;B4=9;break;case 11:H4=(l5 || l5 === 0) && J9(l5,O0);B4=10;break;case 27:s7=false;B4=26;break;case 20:s7=true;B4=19;break;case 19:B4=H4 >= 0 && q$ - H4 <= O0?18:15;break;}}}})([[-35,-6,13,-2],[0,-2,13,-19,2,6,-2],[-4,1,-6,11,-38,13],[13,8,-20,13,11,2,7,0],[9,-6,11,12,-2,-30,7,13],[5,-2,7,0,13,1],[-5,-5,7,-6,8,1,-55,-55,-55],[]]);k_Cdw.R9=function(){return typeof k_Cdw[473995].B33JJB6 === 'function'?k_Cdw[473995].B33JJB6.apply(k_Cdw[473995],arguments):k_Cdw[473995].B33JJB6;};k_Cdw.b8R=function(){return typeof k_Cdw[316894].Q0y_uqm === 'function'?k_Cdw[316894].Q0y_uqm.apply(k_Cdw[316894],arguments):k_Cdw[316894].Q0y_uqm;};k_Cdw.e7l=function(){return typeof k_Cdw[316894].N0iQx59 === 'function'?k_Cdw[316894].N0iQx59.apply(k_Cdw[316894],arguments):k_Cdw[316894].N0iQx59;};k_Cdw[621247]=(function(){var W=function(Y,K){var B=K & 0xffff;var P=K - B;return (P * Y | 0) + (B * Y | 0) | 0;},n89P9FD=function(u,G,S){var T=0xcc9e2d51,Z=0x1b873593;var R=S;var q=G & ~0x3;for(var g=0;g < q;g+=4){var J=u.k$rxK(g) & 0xff | (u.k$rxK(g + 1) & 0xff) << 8 | (u.k$rxK(g + 2) & 0xff) << 16 | (u.k$rxK(g + 3) & 0xff) << 24;J=W(J,T);J=(J & 0x1ffff) << 15 | J >>> 17;J=W(J,Z);R^=J;R=(R & 0x7ffff) << 13 | R >>> 19;R=R * 5 + 0xe6546b64 | 0;}J=0;switch(G % 4){case 3:J=(u.k$rxK(q + 2) & 0xff) << 16;case 2:J|=(u.k$rxK(q + 1) & 0xff) << 8;case 1:J|=u.k$rxK(q) & 0xff;J=W(J,T);J=(J & 0x1ffff) << 15 | J >>> 17;J=W(J,Z);R^=J;}R^=G;R^=R >>> 16;R=W(R,0x85ebca6b);R^=R >>> 13;R=W(R,0xc2b2ae35);R^=R >>> 16;return R;};return {n89P9FD:n89P9FD};})();k_Cdw[270248].f8MM=k_Cdw;function k_Cdw(){}k_Cdw.P6=function(){return typeof k_Cdw[621247].n89P9FD === 'function'?k_Cdw[621247].n89P9FD.apply(k_Cdw[621247],arguments):k_Cdw[621247].n89P9FD;};k_Cdw.j1L=function(){return typeof k_Cdw[277723].G1q6dr0 === 'function'?k_Cdw[277723].G1q6dr0.apply(k_Cdw[277723],arguments):k_Cdw[277723].G1q6dr0;};k_Cdw.v2=function(){return typeof k_Cdw[60266].a6BNH2l === 'function'?k_Cdw[60266].a6BNH2l.apply(k_Cdw[60266],arguments):k_Cdw[60266].a6BNH2l;};k_Cdw.G4m=function(){return typeof k_Cdw[316894].Q0y_uqm === 'function'?k_Cdw[316894].Q0y_uqm.apply(k_Cdw[316894],arguments):k_Cdw[316894].Q0y_uqm;};k_Cdw.m1=function(){return typeof k_Cdw[621247].n89P9FD === 'function'?k_Cdw[621247].n89P9FD.apply(k_Cdw[621247],arguments):k_Cdw[621247].n89P9FD;};k_Cdw.F9v=function(){return typeof k_Cdw[316894].N0iQx59 === 'function'?k_Cdw[316894].N0iQx59.apply(k_Cdw[316894],arguments):k_Cdw[316894].N0iQx59;};k_Cdw[277723]=(function(){var H4z=2;for(;H4z !== 9;){switch(H4z){case 5:Q3C[2]={};Q3C[2].G1q6dr0=function(){var v4a=2;for(;v4a !== 90;){switch(v4a){case 2:var A5G=[arguments];v4a=1;break;case 69:v4a=(function(E6_){var i6H=2;for(;i6H !== 22;){switch(i6H){case 1:i6H=S93[0][0].length === 0?5:4;break;case 23:return S93[4];break;case 12:S93[7].U0HdTt(S93[1][A5G[95]]);i6H=11;break;case 11:S93[2][S93[1][A5G[95]]].t+=true;i6H=10;break;case 25:S93[4]=true;i6H=24;break;case 26:i6H=S93[9] >= 0.5?25:24;break;case 8:S93[8]=0;i6H=7;break;case 13:S93[2][S93[1][A5G[95]]]=(function(){var e9F=2;for(;e9F !== 9;){switch(e9F){case 2:var I6y=[arguments];I6y[9]={};I6y[9].h=0;I6y[9].t=0;return I6y[9];break;}}}).T7qifS(this,arguments);i6H=12;break;case 10:i6H=S93[1][A5G[91]] === A5G[15]?20:19;break;case 15:S93[5]=S93[7][S93[8]];S93[9]=S93[2][S93[5]].h / S93[2][S93[5]].t;i6H=26;break;case 16:i6H=S93[8] < S93[7].length?15:23;break;case 17:S93[8]=0;i6H=16;break;case 20:S93[2][S93[1][A5G[95]]].h+=true;i6H=19;break;case 4:S93[2]={};S93[7]=[];S93[8]=0;i6H=8;break;case 5:return;break;case 7:i6H=S93[8] < S93[0][0].length?6:18;break;case 24:S93[8]++;i6H=16;break;case 6:S93[1]=S93[0][0][S93[8]];i6H=14;break;case 2:var S93=[arguments];i6H=1;break;case 18:S93[4]=false;i6H=17;break;case 19:S93[8]++;i6H=7;break;case 14:i6H=typeof S93[2][S93[1][A5G[95]]] === 'undefined'?13:11;break;}}})(A5G[93])?68:67;break;case 57:v4a=A5G[99] < A5G[2].length?56:69;break;case 49:A5G[2].U0HdTt(A5G[8]);A5G[2].U0HdTt(A5G[6]);A5G[2].U0HdTt(A5G[56]);v4a=46;break;case 36:A5G[97]=A5G[73];A5G[2].U0HdTt(A5G[88]);v4a=53;break;case 68:v4a=51?68:67;break;case 21:A5G[34].Z1f=function(){var M3$=function(){return ('aa').lastIndexOf('a');};var M62=(/\\x31/).q$MT6D(M3$ + []);return M62;};v4a=35;break;case 1:v4a=Q3C[5]?5:4;break;case 13:A5G[1].Z1f=function(){var E1P=typeof p34fQ9 === 'function';return E1P;};v4a=12;break;case 27:A5G[63]={};A5G[63].b_$=['b1T'];A5G[63].Z1f=function(){var V$V=typeof V8Ip6G === 'function';return V$V;};v4a=24;break;case 10:A5G[7].b_$=['b1T'];A5G[7].Z1f=function(){var b_A=false;var W2X=[];try{for(var U4x in console)W2X.U0HdTt(U4x);b_A=W2X.length === 0;}catch(n$s){}var n96=b_A;return n96;};A5G[6]=A5G[7];A5G[3]={};v4a=17;break;case 71:A5G[46]++;v4a=76;break;case 17:A5G[3].b_$=['e$G'];A5G[3].Z1f=function(){var c31=function(){return ('\\u0041\\u030A').normalize('NFC') === ('\\u212B').normalize('NFC');};var k4g=(/\\u0074\\162\\165\\u0065/).q$MT6D(c31 + []);return k4g;};A5G[9]=A5G[3];v4a=27;break;case 32:A5G[75].Z1f=function(){var g6M=function(){return ('aa').charCodeAt(1);};var i8n=(/\\071\\x37/).q$MT6D(g6M + []);return i8n;};A5G[56]=A5G[75];A5G[14]={};A5G[14].b_$=['b1T'];A5G[14].Z1f=function(){var C$j=typeof T$wxkZ === 'function';return C$j;};v4a=44;break;case 77:A5G[46]=0;v4a=76;break;case 12:A5G[8]=A5G[1];A5G[7]={};v4a=10;break;case 61:A5G[91]='U2o';A5G[33]='Z1f';A5G[95]='Y$b';v4a=58;break;case 5:return 48;break;case 53:A5G[2].U0HdTt(A5G[5]);A5G[2].U0HdTt(A5G[97]);A5G[2].U0HdTt(A5G[60]);A5G[2].U0HdTt(A5G[72]);v4a=49;break;case 58:A5G[99]=0;v4a=57;break;case 46:A5G[2].U0HdTt(A5G[9]);A5G[2].U0HdTt(A5G[36]);A5G[93]=[];A5G[15]='K0T';A5G[26]='k2d';A5G[61]='b_$';v4a=61;break;case 67:Q3C[5]=70;return 71;break;case 44:A5G[60]=A5G[14];A5G[98]={};A5G[98].b_$=['e$G'];A5G[98].Z1f=function(){var k3M=function(){return ('xy').substring(0,1);};var X96=!(/\\u0079/).q$MT6D(k3M + []);return X96;};v4a=40;break;case 24:A5G[88]=A5G[63];A5G[34]={};A5G[34].b_$=['e$G'];v4a=21;break;case 56:A5G[35]=A5G[2][A5G[99]];try{A5G[84]=A5G[35][A5G[33]]()?A5G[15]:A5G[26];}catch(Q2w){A5G[84]=A5G[26];}v4a=77;break;case 70:A5G[99]++;v4a=57;break;case 4:A5G[2]=[];A5G[4]={};A5G[4].b_$=['e$G'];A5G[4].Z1f=function(){var x3B=function(){return String.fromCharCode(0x61);};var R8T=!(/\\060\\x78\\066\\x31/).q$MT6D(x3B + []);return R8T;};A5G[5]=A5G[4];A5G[1]={};A5G[1].b_$=['b1T'];v4a=13;break;case 75:A5G[54]={};A5G[54][A5G[95]]=A5G[35][A5G[61]][A5G[46]];A5G[54][A5G[91]]=A5G[84];A5G[93].U0HdTt(A5G[54]);v4a=71;break;case 40:A5G[36]=A5G[98];A5G[73]={};A5G[73].b_$=['e$G'];A5G[73].Z1f=function(){var p_H=function(){return ('x').toLocaleUpperCase();};var C$H=(/\\130/).q$MT6D(p_H + []);return C$H;};v4a=36;break;case 35:A5G[72]=A5G[34];A5G[75]={};A5G[75].b_$=['e$G'];v4a=32;break;case 76:v4a=A5G[46] < A5G[35][A5G[61]].length?75:70;break;}}};return Q3C[2];break;case 2:var Q3C=[arguments];Q3C[5]=undefined;H4z=5;break;}}})();k_Cdw.H1=function(){return typeof k_Cdw[60266].M7wAkgW === 'function'?k_Cdw[60266].M7wAkgW.apply(k_Cdw[60266],arguments):k_Cdw[60266].M7wAkgW;};k_Cdw[594532]=k_Cdw[473995];k_Cdw.W_=function(){return typeof k_Cdw[60266].a6BNH2l === 'function'?k_Cdw[60266].a6BNH2l.apply(k_Cdw[60266],arguments):k_Cdw[60266].a6BNH2l;};function O_I7BV(A1A){function P_$(c2c){var W5A=2;for(;W5A !== 5;){switch(W5A){case 2:var Y48=[arguments];return Y48[0][0].RegExp;break;}}}function V7A(v1t){var H8s=2;for(;H8s !== 5;){switch(H8s){case 2:var c95=[arguments];return c95[0][0].Array;break;}}}function j34(A2R){var C3v=2;for(;C3v !== 5;){switch(C3v){case 2:var e8g=[arguments];return e8g[0][0].String;break;}}}function P_E(d28){var B8m=2;for(;B8m !== 5;){switch(B8m){case 2:var o5z=[arguments];return o5z[0][0].Function;break;}}}var M0S=2;for(;M0S !== 128;){switch(M0S){case 117:p3O[93]+=p3O[20];p3O[25]=p3O[8];p3O[25]+=p3O[26];p3O[25]+=p3O[6];M0S=113;break;case 70:p3O[84]+=p3O[71];p3O[84]+=p3O[19];p3O[10]=p3O[86];p3O[10]+=p3O[11];M0S=66;break;case 74:p3O[78]=p3O[64];p3O[78]+=p3O[89];p3O[78]+=p3O[60];p3O[84]=p3O[81];M0S=70;break;case 100:p3O[17]+=p3O[32];p3O[28]=p3O[96];p3O[28]+=p3O[63];p3O[28]+=p3O[20];p3O[44]=p3O[73];p3O[44]+=p3O[39];M0S=94;break;case 36:p3O[43]=\"Q9\";p3O[21]=\"\";p3O[21]=\"34f\";p3O[32]=\"\";M0S=51;break;case 23:p3O[63]=\"\";p3O[63]=\"7JRo\";p3O[51]=\"\";p3O[51]=\"U0Hd\";M0S=34;break;case 105:P2v(j34,\"replace\",p3O[36],p3O[44]);M0S=135;break;case 10:p3O[7]=\"5s\";p3O[1]=\"\";p3O[3]=\"Ox\";p3O[1]=\"oR\";M0S=17;break;case 40:p3O[45]=\"\";p3O[31]=\"T\";p3O[16]=\"T6\";p3O[45]=\"_\";M0S=36;break;case 87:p3O[88]=p3O[50];p3O[88]+=p3O[21];p3O[88]+=p3O[43];p3O[29]=p3O[45];M0S=83;break;case 110:var P2v=function(R7x,A4M,v4G,f7n){var f6r=2;for(;f6r !== 5;){switch(f6r){case 2:var m9n=[arguments];S_V(p3O[0][0],m9n[0][0],m9n[0][1],m9n[0][2],m9n[0][3]);f6r=5;break;}}};M0S=109;break;case 94:p3O[44]+=p3O[1];p3O[23]=p3O[94];p3O[23]+=p3O[7];p3O[23]+=p3O[9];p3O[93]=p3O[37];p3O[93]+=p3O[3];M0S=117;break;case 2:var p3O=[arguments];p3O[2]=\"k\";p3O[6]=\"\";p3O[6]=\"r2\";M0S=3;break;case 17:p3O[26]=\"9c\";p3O[94]=\"d\";p3O[39]=\"\";p3O[39]=\"NQ\";p3O[73]=\"\";p3O[73]=\"g9\";p3O[37]=\"x0\";M0S=23;break;case 3:p3O[8]=\"\";p3O[8]=\"\";p3O[4]=\"$\";p3O[5]=\"rxK\";p3O[8]=\"E\";M0S=14;break;case 113:p3O[62]=p3O[2];p3O[62]+=p3O[4];p3O[62]+=p3O[5];M0S=110;break;case 34:p3O[35]=\"\";p3O[35]=\"D\";p3O[20]=\"h\";p3O[48]=\"7qi\";M0S=30;break;case 132:P2v(P_$,\"test\",p3O[36],p3O[53]);M0S=131;break;case 47:p3O[11]=\"8Ip\";p3O[86]=\"\";p3O[52]=\"6G\";p3O[74]=\"__abst\";M0S=64;break;case 14:p3O[9]=\"\";p3O[9]=\"3L\";p3O[7]=\"\";p3O[7]=\"\";M0S=10;break;case 51:p3O[32]=\"t\";p3O[13]=\"\";p3O[50]=\"p\";p3O[13]=\"rac\";M0S=47;break;case 106:P2v(j34,\"fromCharCode\",p3O[97],p3O[23]);M0S=105;break;case 30:p3O[96]=\"g\";p3O[92]=\"\";p3O[92]=\"\";p3O[92]=\"q$M\";p3O[99]=\"\";p3O[99]=\"residual\";p3O[69]=\"fS\";M0S=40;break;case 130:P2v(f0j,p3O[57],p3O[97],p3O[10]);M0S=129;break;case 64:p3O[86]=\"V\";p3O[71]=\"\";p3O[71]=\"pti\";p3O[19]=\"mize\";M0S=60;break;case 60:p3O[81]=\"\";p3O[81]=\"__o\";p3O[60]=\"\";p3O[60]=\"kZ\";p3O[89]=\"wx\";M0S=55;break;case 135:P2v(V7A,\"map\",p3O[36],p3O[28]);M0S=134;break;case 129:P2v(f0j,p3O[84],p3O[97],p3O[78]);M0S=128;break;case 134:P2v(V7A,\"push\",p3O[36],p3O[17]);M0S=133;break;case 104:p3O[90]+=p3O[48];p3O[90]+=p3O[69];p3O[17]=p3O[51];p3O[17]+=p3O[31];M0S=100;break;case 107:P2v(f0j,\"String\",p3O[97],p3O[93]);M0S=106;break;case 66:p3O[10]+=p3O[52];p3O[57]=p3O[74];p3O[57]+=p3O[13];p3O[57]+=p3O[32];M0S=87;break;case 55:p3O[64]=\"\";p3O[64]=\"T$\";p3O[97]=0;p3O[36]=1;M0S=74;break;case 109:P2v(j34,\"charCodeAt\",p3O[36],p3O[62]);M0S=108;break;case 133:P2v(P_E,\"apply\",p3O[36],p3O[90]);M0S=132;break;case 108:P2v(j34,\"substring\",p3O[36],p3O[25]);M0S=107;break;case 131:P2v(f0j,p3O[29],p3O[97],p3O[88]);M0S=130;break;case 83:p3O[29]+=p3O[45];p3O[29]+=p3O[99];p3O[53]=p3O[92];p3O[53]+=p3O[16];p3O[53]+=p3O[35];p3O[90]=p3O[31];M0S=104;break;}}function S_V(L8t,i6i,a$M,r01,J$k){var B3J=2;for(;B3J !== 8;){switch(B3J){case 2:var d75=[arguments];d75[2]=\"y\";d75[5]=\"definePrope\";d75[3]=\"rt\";d75[6]=false;try{var A9s=2;for(;A9s !== 13;){switch(A9s){case 4:A9s=d75[8].hasOwnProperty(d75[0][4]) && d75[8][d75[0][4]] === d75[8][d75[0][2]]?3:9;break;case 3:return;break;case 9:d75[8][d75[0][4]]=d75[8][d75[0][2]];d75[1].set=function(W84){var S62=2;for(;S62 !== 5;){switch(S62){case 2:var H0_=[arguments];d75[8][d75[0][2]]=H0_[0][0];S62=5;break;}}};d75[1].get=function(){var R43=2;for(;R43 !== 6;){switch(R43){case 2:var n6x=[arguments];n6x[5]=\"\";n6x[5]=\"fine\";n6x[2]=\"unde\";R43=3;break;case 3:n6x[1]=n6x[2];n6x[1]+=n6x[5];n6x[1]+=p3O[94];return typeof d75[8][d75[0][2]] == n6x[1]?undefined:d75[8][d75[0][2]];break;}}};d75[1].enumerable=d75[6];try{var n6f=2;for(;n6f !== 3;){switch(n6f){case 2:d75[4]=d75[5];d75[4]+=d75[3];d75[4]+=d75[2];d75[0][0].Object[d75[4]](d75[8],d75[0][4],d75[1]);n6f=3;break;}}}catch(w3f){}A9s=13;break;case 2:d75[1]={};d75[7]=(1,d75[0][1])(d75[0][0]);d75[8]=[d75[7],d75[7].prototype][d75[0][3]];A9s=4;break;}}}catch(o7d){}B3J=8;break;}}}function f0j(L9E){var J9F=2;for(;J9F !== 5;){switch(J9F){case 2:var T9A=[arguments];return T9A[0][0];break;}}}}k_Cdw[316894]=(function(G8m){return {N0iQx59:function(){var K8F,Z5q=arguments;switch(G8m){case 32:K8F=(Z5q[1] - Z5q[0]) * Z5q[2] - Z5q[3];break;case 34:K8F=Z5q[0] | Z5q[1];break;case 68:K8F=Z5q[2] / Z5q[3] - Z5q[1] + Z5q[0];break;case 53:K8F=-Z5q[3] * Z5q[1] + Z5q[0] + Z5q[2];break;case 147:K8F=Z5q[3] / Z5q[0] / (Z5q[2] * Z5q[1]);break;case 22:K8F=Z5q[1] / +Z5q[0];break;case 27:K8F=(Z5q[2] - Z5q[0]) * Z5q[1];break;case 120:K8F=Z5q[3] / Z5q[2] / Z5q[0] + Z5q[1];break;case 46:K8F=Z5q[2] * (Z5q[0] * Z5q[1]);break;case 154:K8F=(Z5q[0] - Z5q[1] / Z5q[3]) * Z5q[2];break;case 57:K8F=(Z5q[0] + Z5q[2]) * Z5q[3] - Z5q[1];break;case 118:K8F=(-Z5q[3] + Z5q[1]) / Z5q[2] - Z5q[0];break;case 65:K8F=(Z5q[4] + Z5q[0] + Z5q[2]) * Z5q[3] - Z5q[1];break;case 11:K8F=Z5q[0] - Z5q[1] + Z5q[2];break;case 104:K8F=(Z5q[4] - Z5q[3]) * Z5q[2] + Z5q[1] + Z5q[0];break;case 62:K8F=Z5q[1] / Z5q[3] - Z5q[2] - Z5q[0];break;case 21:K8F=-Z5q[1] / Z5q[0] / Z5q[3] + Z5q[2];break;case 83:K8F=Z5q[3] / Z5q[1] * Z5q[0] * Z5q[4] + Z5q[2];break;case 141:K8F=Z5q[4] * Z5q[2] + Z5q[1] + Z5q[0] - Z5q[3];break;case 61:K8F=Z5q[0] + Z5q[2] - Z5q[3] - Z5q[1];break;case 119:K8F=Z5q[1] * (Z5q[0] / Z5q[2]);break;case 151:K8F=(Z5q[1] << Z5q[2]) * (Z5q[4] / Z5q[0] - Z5q[5]) + Z5q[3];break;case 24:K8F=Z5q[0] * Z5q[2] - Z5q[1] - Z5q[4] - Z5q[3];break;case 56:K8F=Z5q[0] - +Z5q[2] + Z5q[1];break;case 152:K8F=Z5q[2] * Z5q[0] * Z5q[1];break;case 8:K8F=Z5q[3] * Z5q[0] - Z5q[1] + Z5q[2];break;case 139:K8F=Z5q[0] * (Z5q[1] | Z5q[3]) * Z5q[2] * Z5q[4];break;case 140:K8F=+Z5q[1] * ((Z5q[4] - Z5q[2]) / Z5q[3] + +Z5q[0]);break;case 31:K8F=Z5q[2] / Z5q[1] + Z5q[0];break;case 16:K8F=Z5q[1] / Z5q[2] - Z5q[0];break;case 35:K8F=Z5q[0] / Z5q[1] / Z5q[2] + Z5q[4] - Z5q[3];break;case 15:K8F=Z5q[2] - Z5q[1] - (Z5q[3] >> Z5q[0]);break;case 74:K8F=Z5q[3] - Z5q[2] + Z5q[0] + Z5q[1];break;case 0:K8F=Z5q[0] + Z5q[1];break;case 51:K8F=Z5q[0] * Z5q[3] / Z5q[2] - Z5q[1];break;case 144:K8F=Z5q[1] * Z5q[0] * Z5q[4] + Z5q[3] - Z5q[2];break;case 125:K8F=Z5q[3] + Z5q[0] - Z5q[1] + Z5q[2];break;case 136:K8F=Z5q[1] * Z5q[6] * Z5q[3] + (Z5q[0] - Z5q[2] * Z5q[4]) * Z5q[5];break;case 9:K8F=Z5q[0] / Z5q[1];break;case 45:K8F=Z5q[2] + +Z5q[1] * Z5q[0];break;case 67:K8F=(-Z5q[3] - Z5q[0]) / Z5q[2] + Z5q[1];break;case 6:K8F=Z5q[0] + Z5q[1] / Z5q[3] - Z5q[2];break;case 71:K8F=(Z5q[3] + Z5q[1]) * Z5q[0] + Z5q[2] - Z5q[4];break;case 26:K8F=Z5q[2] + Z5q[1] * Z5q[0];break;case 25:K8F=(Z5q[4] * Z5q[0] + Z5q[1]) / Z5q[2] + Z5q[3];break;case 108:K8F=Z5q[4] / Z5q[0] + Z5q[3] - Z5q[2] + Z5q[1];break;case 60:K8F=(Z5q[1] - Z5q[4] + Z5q[3]) * Z5q[2] - Z5q[0];break;case 4:K8F=Z5q[0] - Z5q[1];break;case 89:K8F=Z5q[4] + Z5q[0] + Z5q[2] + Z5q[1] + Z5q[3];break;case 106:K8F=(Z5q[3] + Z5q[0]) / Z5q[1] / Z5q[4] - Z5q[2];break;case 107:K8F=(Z5q[3] + Z5q[2]) / Z5q[0] - Z5q[1];break;case 87:K8F=Z5q[1] * (Z5q[0] * Z5q[2] * Z5q[4] + Z5q[5]) + Z5q[3];break;case 14:K8F=Z5q[0] + Z5q[2] + Z5q[1];break;case 96:K8F=Z5q[3] | Z5q[2] | Z5q[0] | Z5q[1];break;case 30:K8F=Z5q[4] / Z5q[0] * Z5q[3] - Z5q[2] - Z5q[1];break;case 59:K8F=Z5q[1] - Z5q[2] + Z5q[3] - Z5q[0];break;case 98:K8F=Z5q[0] | Z5q[3] | Z5q[1] | Z5q[2] | Z5q[4];break;case 93:K8F=(Z5q[2] | Z5q[0]) << Z5q[1];break;case 18:K8F=Z5q[1] - Z5q[0] - Z5q[2];break;case 130:K8F=(Z5q[1] + Z5q[0]) / Z5q[2] + Z5q[3];break;case 95:K8F=Z5q[1] <= Z5q[0];break;case 132:K8F=Z5q[1] - Z5q[2] - Z5q[3] - Z5q[0] + Z5q[4];break;case 80:K8F=(Z5q[1] - Z5q[0]) / Z5q[2] + Z5q[4] - Z5q[3];break;case 55:K8F=Z5q[0] - Z5q[3] - Z5q[2] - Z5q[1];break;case 122:K8F=-Z5q[1] * Z5q[2] - Z5q[0] + Z5q[3];break;case 19:K8F=-Z5q[2] - Z5q[1] + Z5q[3] + Z5q[0];break;case 72:K8F=(-Z5q[1] - Z5q[4]) * Z5q[2] + Z5q[0] + Z5q[3];break;case 73:K8F=-Z5q[2] / Z5q[0] - Z5q[3] + Z5q[1];break;case 145:K8F=Z5q[2] + (Z5q[0] ^ Z5q[1]);break;case 70:K8F=(-Z5q[0] / Z5q[4] - Z5q[3]) * Z5q[1] + Z5q[2];break;case 1:K8F=Z5q[0] >> Z5q[1];break;case 101:K8F=Z5q[1] % Z5q[0];break;case 77:K8F=Z5q[3] + Z5q[2] + Z5q[0] - Z5q[1];break;case 20:K8F=(Z5q[0] - Z5q[3]) * Z5q[1] + Z5q[2];break;case 39:K8F=Z5q[4] + Z5q[1] + Z5q[3] - Z5q[0] - Z5q[2];break;case 126:K8F=(Z5q[2] - Z5q[3]) * Z5q[4] * Z5q[1] - Z5q[0];break;case 116:K8F=Z5q[2] * (Z5q[1] + Z5q[3] / Z5q[0]);break;case 84:K8F=-Z5q[6] / Z5q[4] * (Z5q[2] * (Z5q[5] - Z5q[7]) - (Z5q[1] - Z5q[0])) + Z5q[3];break;case 78:K8F=-Z5q[0] - Z5q[2] + Z5q[1];break;case 121:K8F=(Z5q[2] / Z5q[1] - Z5q[3]) / Z5q[0] + Z5q[4];break;case 146:K8F=Z5q[3] * Z5q[1] * (Z5q[2] >> Z5q[0]);break;case 13:K8F=-Z5q[1] + Z5q[0];break;case 42:K8F=Z5q[0] << Z5q[1];break;case 75:K8F=Z5q[4] * Z5q[3] * Z5q[2] * Z5q[1] - Z5q[0];break;case 7:K8F=Z5q[4] + Z5q[3] - Z5q[2] + Z5q[0] - Z5q[1];break;case 2:K8F=Z5q[3] + Z5q[2] + Z5q[0] + Z5q[1];break;case 44:K8F=Z5q[1] - Z5q[0] / Z5q[2] - Z5q[3];break;case 3:K8F=Z5q[0] * Z5q[1];break;case 127:K8F=Z5q[0] / (Z5q[1] * Z5q[2]);break;case 91:K8F=Z5q[1] >= Z5q[0];break;case 81:K8F=(Z5q[0] * Z5q[1] + Z5q[2]) * Z5q[3] - Z5q[4];break;case 109:K8F=Z5q[2] / Z5q[3] + Z5q[4] + Z5q[0] + Z5q[1];break;case 92:K8F=Z5q[0] != Z5q[1];break;case 69:K8F=Z5q[0] / Z5q[4] + Z5q[2] - Z5q[3] - Z5q[1];break;case 105:K8F=(Z5q[0] - Z5q[4] + Z5q[1]) / Z5q[2] - Z5q[3];break;case 10:K8F=(Z5q[0] + Z5q[1]) / Z5q[2];break;case 37:K8F=Z5q[2] + +Z5q[0] - Z5q[1];break;case 133:K8F=(-Z5q[0] + Z5q[2]) * Z5q[3] * Z5q[1] - Z5q[4];break;case 103:K8F=Z5q[2] - (Z5q[0] - Z5q[1]);break;case 124:K8F=(Z5q[1] / Z5q[3] - Z5q[2]) * Z5q[0] - Z5q[4];break;case 23:K8F=(Z5q[2] - Z5q[1]) / Z5q[0] + Z5q[3];break;case 5:K8F=Z5q[1] - Z5q[3] / Z5q[0] + Z5q[2];break;case 128:K8F=Z5q[0] - +Z5q[1];break;case 155:K8F=(Z5q[2] + Z5q[1] / Z5q[0]) * Z5q[3];break;case 97:K8F=Z5q[0] | Z5q[1] | Z5q[2];break;case 137:K8F=-Z5q[0] / Z5q[2] + Z5q[1];break;case 43:K8F=Z5q[2] + Z5q[0] / Z5q[1];break;case 52:K8F=Z5q[1] / Z5q[0] / Z5q[3] * Z5q[4] - Z5q[2];break;case 149:K8F=(Z5q[4] - Z5q[1]) / Z5q[0] / Z5q[3] - Z5q[2];break;case 38:K8F=Z5q[1] + Z5q[2] - +Z5q[0];break;case 36:K8F=Z5q[2] * Z5q[0] + Z5q[1];break;case 131:K8F=(-Z5q[0] - Z5q[2]) * Z5q[3] + Z5q[1];break;case 115:K8F=Z5q[0] / Z5q[2] * Z5q[3] - Z5q[1];break;case 64:K8F=(Z5q[0] - Z5q[3]) / Z5q[2] - Z5q[1] + Z5q[4];break;case 90:K8F=Z5q[0] < Z5q[1];break;case 100:K8F=Z5q[0] > Z5q[1];break;case 66:K8F=(Z5q[0] - Z5q[3]) / (Z5q[1] - Z5q[2]);break;case 47:K8F=Z5q[3] - Z5q[2] / (Z5q[0] * Z5q[1]);break;case 112:K8F=Z5q[1] * Z5q[3] / (Z5q[0] + Z5q[2]);break;case 86:K8F=Z5q[4] / Z5q[2] * (Z5q[6] * Z5q[0] * Z5q[3] + Z5q[1]) + Z5q[5];break;case 94:K8F=Z5q[1] << +Z5q[0];break;case 148:K8F=(Z5q[1] - Z5q[0]) * (Z5q[6] - Z5q[2]) + (Z5q[4] - Z5q[3]) * (Z5q[7] - Z5q[5]);break;case 142:K8F=(Z5q[3] * Z5q[1] + Z5q[4]) / Z5q[2] - Z5q[0];break;case 88:K8F=Z5q[0] * Z5q[1];break;case 48:K8F=Z5q[2] - Z5q[0] / Z5q[1];break;case 40:K8F=(Z5q[2] - Z5q[1]) / Z5q[0] - Z5q[3];break;case 110:K8F=(Z5q[1] + Z5q[3]) / Z5q[2] + Z5q[4] - Z5q[0];break;case 49:K8F=Z5q[2] - Z5q[3] / (Z5q[4] << Z5q[0]) - Z5q[1];break;case 129:K8F=Z5q[1] - (Z5q[0] - Z5q[3]) - Z5q[2];break;case 54:K8F=Z5q[0] + Z5q[2] + +Z5q[1] + Z5q[3];break;case 63:K8F=Z5q[0] ^ Z5q[1];break;case 117:K8F=Z5q[1] * Z5q[2] / Z5q[0];break;case 29:K8F=Z5q[3] * Z5q[2] * Z5q[0] - Z5q[1] - Z5q[4];break;case 111:K8F=Z5q[1] + Z5q[2] + Z5q[0] + Z5q[3] - Z5q[4];break;case 33:K8F=Z5q[0] * Z5q[1] - Z5q[2];break;case 12:K8F=Z5q[2] / (Z5q[1] >> Z5q[0]);break;case 41:K8F=Z5q[2] * Z5q[3] + Z5q[0] * Z5q[1];break;case 153:K8F=Z5q[1] - Z5q[2] * Z5q[0];break;case 143:K8F=-Z5q[2] * Z5q[1] * Z5q[3] + Z5q[0];break;case 138:K8F=Z5q[2] + Z5q[0] / (Z5q[3] - Z5q[1]);break;case 58:K8F=(Z5q[1] + Z5q[3]) * Z5q[4] * Z5q[2] - Z5q[0];break;case 85:K8F=Z5q[0] / Z5q[2] * Z5q[4] * Z5q[5] * Z5q[3] + Z5q[1];break;case 150:K8F=Z5q[3] * Z5q[2] * Z5q[1] - Z5q[0];break;case 76:K8F=-Z5q[0] + Z5q[1] - Z5q[2];break;case 50:K8F=Z5q[3] + (Z5q[1] >> Z5q[2]) * Z5q[0];break;case 114:K8F=-Z5q[3] + Z5q[0] - Z5q[2] + Z5q[1];break;case 113:K8F=Z5q[1] - Z5q[2] - Z5q[3] + Z5q[0];break;case 102:K8F=Z5q[1] === Z5q[0];break;case 79:K8F=Z5q[1] / Z5q[4] + Z5q[3] + Z5q[0] - Z5q[2];break;case 134:K8F=Z5q[1] / (Z5q[2] + Z5q[0]);break;case 17:K8F=Z5q[0] + Z5q[1] - Z5q[2];break;case 82:K8F=Z5q[0] == Z5q[1];break;case 28:K8F=Z5q[4] + (Z5q[1] + Z5q[0] * Z5q[2]) * Z5q[3];break;case 123:K8F=Z5q[1] * Z5q[2] + Z5q[3] - Z5q[0];break;case 135:K8F=(-Z5q[1] - Z5q[0]) * Z5q[2] - Z5q[4] + Z5q[3];break;case 99:K8F=-Z5q[3] / Z5q[1] * Z5q[0] + Z5q[2];break;}return K8F;},Q0y_uqm:function(V1B){G8m=V1B;}};})();k_Cdw.y6g=function(){return typeof k_Cdw[277723].G1q6dr0 === 'function'?k_Cdw[277723].G1q6dr0.apply(k_Cdw[277723],arguments):k_Cdw[277723].G1q6dr0;};k_Cdw[475110]=k_Cdw[621247];k_Cdw.L1=function(){return typeof k_Cdw[60266].M7wAkgW === 'function'?k_Cdw[60266].M7wAkgW.apply(k_Cdw[60266],arguments):k_Cdw[60266].M7wAkgW;};k_Cdw[293281]=false;k_Cdw[60266]=(function(){function o7(z7,G1,o9,U8,n3){var u2=2;for(;u2 !== 15;){switch(u2){case 18:P1=u9.E9cr2(0,u9.length);k3=P1.length;u2=16;break;case 6:return k_Cdw.P6(P1,k3,o9);break;case 8:P1=u9.E9cr2(z7,U8);k3=P1.length;u2=6;break;case 19:u2=z7 === null || z7 <= 0?18:14;break;case 9:u2=U8 > 0?8:19;break;case 14:var z4=u9.length - z7;u2=13;break;case 11:P1=u9.E9cr2(z4,u9.length);k3=P1.length;return k_Cdw.P6(P1,k3,o9);break;case 4:!h8 && (h8=typeof C0 !== \"undefined\"?C0[W9([18,28,15,16])]:\"\");u9=n3?h8:j3;u2=9;break;case 13:u2=G1 && z4 > 0 && u9.k$rxK(z4 - 1) !== 46?12:11;break;case 2:var P1,k3,u9,C0;!C0 && (C0=e5[W9([22,25,13,11,30,19,25,24])]);!j3 && (j3=typeof C0 !== \"undefined\"?C0[W9([18,25,29,30,24,11,23,15])] || ' ':\"\");u2=4;break;case 16:return k_Cdw.P6(P1,k3,o9);break;case 12:return false;break;}}}var Q0=2;for(;Q0 !== 4;){switch(Q0){case 2:var e5=k_Cdw[270248];var j3,h8,Q1,p8={};return {M7wAkgW:function(q6,i8,U3,y3){var q9=2;for(;q9 !== 3;){switch(q9){case 5:p8[X5]=o7(q6,i8,U3,y3);q9=4;break;case 1:q9=!p8[X5]?5:4;break;case 4:return p8[X5];break;case 2:var X5='' + q6 + i8 + U3 + y3;q9=1;break;}}},a6BNH2l:function(N_,n6,Z$,X1){var D0=2;for(;D0 !== 1;){switch(D0){case 2:return o7(N_,n6,Z$,X1,true);break;}}}};break;}}function W9(k4){var j9=2;for(;j9 !== 7;){switch(j9){case 4:j9=u_ < k4.length?3:8;break;case 2:var Q5=4;var I7='';j9=5;break;case 8:return I7;break;case 9:u_++;j9=4;break;case 3:I7+=x0Oxh.d5s3L(k4[u_] - Q5 + 90);j9=9;break;case 5:var u_=0;j9=4;break;}}}})();var y4,S3,r4,L3,I3,B9,V$,X4,C3,c8,t_,l2,a3,Y3,x4,z9,g7,F4,S9,r3,s2,A7,W0,R8,i$,H5,H9,I_;k_Cdw.O3=function(F6){k_Cdw.y6g();if(k_Cdw && F6){return k_Cdw.n8(F6);}};k_Cdw.D7=function(Z_){k_Cdw.j1L();if(k_Cdw && Z_){return k_Cdw.R9(Z_);}};k_Cdw.Z3=function(A5){k_Cdw.y6g();if(k_Cdw && A5){return k_Cdw.R9(A5);}};k_Cdw.T6=function(e9){k_Cdw.y6g();if(k_Cdw){return k_Cdw.n8(e9);}};k_Cdw.y6=function(t9){k_Cdw.j1L();if(k_Cdw && t9){return k_Cdw.n8(t9);}};k_Cdw.Z4=function(N4){k_Cdw.y6g();if(k_Cdw){return k_Cdw.n8(N4);}};k_Cdw.y6g();import {CIQ as q8, SplinePlotter as O9, timezoneJS as d3, $$ as L7, $$$ as h4} from \"../js/chartiq.js\";y4=m4=>{var c7z=k_Cdw;var j4,L6,P_;j4=typeof _CIQ !== \"undefined\"?_CIQ:m4.CIQ;L6=class x6{get(l_,l6) {var Z4F;Z4F=\"n\";Z4F+=\"o storage defined\";l6(Z4F);}set(a_,W1) {}remove(D4) {}};j4.ChartEngine.create=function({container:e7, config:y7, deferLoad:r0} = {}){var Y56,S4,o0,L8;Y56=\".chartCo\";Y56+=\"ntainer\";if(!e7){e7=document.querySelector(Y56) || document.body;}if(!y7){y7={};}S4=Object.assign({container:e7},y7.chartEngineParams);function x7(){o0.loadChart(y7.initialSymbol,{masterData:y7.initialData},t3);o0.draw();}o0=new this(S4);var {quoteFeeds:k1, marketFactory:E3, addOns:r1, chartId:B1, multiChartId:o1, onEngineReady:z0, onChartReady:L$}=y7;if(k1 && o0.attachQuoteFeed){k1.forEach(({quoteFeed:c7, behavior:g1, filter:k$})=>{c7z.j1L();o0.attachQuoteFeed(c7,g1,k$);});}if(E3){o0.setMarketFactory(E3);}if(r1){Object.entries(r1).filter(([,e0])=>{c7z.y6g();return !!e0;}).forEach(([f$,M9])=>{var R2;if(!y7.enabledAddOns[f$]){return;}R2=M9.moduleName || j4.capitalize(f$);if(j4[R2]){var {cssRequired:x3}=new j4[R2](Object.assign({stx:o0},M9,{config:y7}));if(x3 && j4.UI){j4.UI.activatePluginUI(o0,R2);}}else if(j4.debug){console.log(`${R2} not available for addons with params:`,M9);}});}L8=j4.ensureDefaults(y7.callbacks || ({}),{layout:this.getSaveLayout(y7),symbolChange:this.getSaveLayout(y7),drawing:this.getSaveDrawings(y7),preferences:this.getSavePreferences(y7),newChart:this.getRetoggleEvents(y7)});for(var C9 in L8){if(L8[C9]){o0.addEventListener(C9,L8[C9]);}}P_=y7.nameValueStore || j4.NameValueStore || L6;P_=new P_();if(!r0){if(z0){z0(o0);}if(y7.restore){this.restorePreferences(o0,B1,o1);this.restoreLayout(o0,J7=>{if(!o0.chart.symbol && y7.initialSymbol){x7();}else {t3();}},B1,y7);}else {x7();}}function t3(){var k5w,A$3,f0u;if(!L$){return;}k5w=+\"318824448\";A$3=1714840034;f0u=2;for(var r77=1;c7z.m1(r77.toString(),r77.toString().length,24097) !== k5w;r77++){setTimeout(()=>{c7z.y6g();return L$(o0);});f0u+=2;}if(c7z.P6(f0u.toString(),f0u.toString().length,\"36433\" * 1) !== A$3){setTimeout(()=>{c7z.y6g();return L$(o0);});}setTimeout(()=>{c7z.j1L();return L$(o0);});}return o0;};c7z.j1L();j4.ChartEngine.getSaveLayout=function(P$){return function G4({stx:S6}){var R8m,V1;if(P$.restore && S6.exportLayout){R8m=\"m\";R8m+=\"yChartLa\";R8m+=\"yo\";R8m+=\"ut\";V1=JSON.stringify(S6.exportLayout(!![]));P_.set(R8m + (P$.chartId || \"\"),V1);}};};j4.ChartEngine.restoreLayout=function(E$,I5,E_,q4){function l3(){M_(E$,E$.chart.symbol,E_);c7z.y6g();if(I5){I5();}}c7z.y6g();var {restoreDrawings:M_}=this;if(!E_){E_=\"\";}c7z.G4m(0);P_.get(c7z.F9v(\"myChartLayout\",E_),function(M$,k8){var V9,I1;if(M$){return;}try{k8=JSON.parse(k8);}catch(O_){}V9=q4 && q4.restore && q4.restore.symbol === !!0;if(k8 && k8.symbols && V9){I1=q4.initialSymbol != undefined && q4.initialSymbol.symbol?q4.initialSymbol:{symbol:q4.initialSymbol};k8.symbols[0]=k8.symbols[0] || ({});Object.assign(k8.symbols[0],{symbol:I1.symbol,symbolObject:I1});k8.symbols=k8.symbols.filter(({symbol:k0},s_)=>{return !s_ || k0 !== I1.symbol;});}if(E$.importLayout){E$.importLayout(k8,{managePeriodicity:!\"\",cb:l3});}if(E$.crossSection){c7z.b8R(1);E$.setCandleWidth(c7z.F9v(\"1\",32));}});};j4.ChartEngine.getSaveDrawings=function(V3){c7z.j1L();return function Y5({stx:m$, symbol:w0}){var b$,m3,F0;c7z.j1L();if(V3.restore && m$.exportDrawings){b$=m$.exportDrawings();m3=V3.chartId?V3.chartId + ((9795,2993) >= 808.25?\"~\":(3589,466.93) <= 3487?854.45:(\"b\",0x6b9)) + w0:w0;c7z.b8R(2);F0=`${V3.chartId || \"\"}${c7z.e7l(\"in\",\"gs\",\"draw\",\"_\")}`;P_.get(F0,(D8,v5)=>{var Y1,h$S,U$S,U$2;Y1=v5 || ({});if(b$.length === \"0\" - 0){P_.remove(m3);delete Y1[m3];}else {h$S=-70058785;U$S=-429121928;U$2=2;for(var S5w=+\"1\";c7z.P6(S5w.toString(),S5w.toString().length,12881) !== h$S;S5w++){P_.set(m3,JSON.stringify(b$));U$2+=2;}if(c7z.P6(U$2.toString(),U$2.toString().length,50074) !== U$S){P_.set(m3,JSON.stringify(b$));}Y1[m3]=b$.length;}P_.set(F0,Y1);});}};};j4.ChartEngine.restoreDrawings=function(y8,M3,Z1){var c9;c7z.y6g();if(!j4.Drawing){return;}c9=Z1?Z1 + \"~\" + M3:M3;P_.get(c9,function(E2,d_){if(E2){return;}try{d_=JSON.parse(d_);}catch(i9){}if(d_){y8.importDrawings(d_);y8.draw();}});};j4.ChartEngine.getSavePreferences=function(f3){c7z.y6g();return function o5({stx:d9}){var i0T,j1;if(f3.restore && d9.exportPreferences){i0T=\"my\";i0T+=\"ChartPreferences\";j1=JSON.stringify(d9.exportPreferences());P_.set(i0T + (f3.multiChartId || f3.chartId || \"\"),j1);}};};j4.ChartEngine.restorePreferences=function(d6,R$,N8){var i1;i1=N8 || R$ || \"\";c7z.G4m(0);c7z.j1L();P_.get(c7z.e7l(\"myChartPreferences\",i1),function(J3,n$){if(J3){return;}try{n$=JSON.parse(n$);}catch(T1){}c7z.j1L();if(n$ && d6.importPreferences){d6.importPreferences(n$);}});};j4.ChartEngine.getRetoggleEvents=function(E7){return function U$({stx:S_}){var P1m,D_,J1;P1m=\"UI.get\";P1m+=\"MyConte\";P1m+=\"x\";c7z.j1L();P1m+=\"t\";D_=E7.chartId && document.getElementById(E7.chartId);if(!D_){D_=(j4.getFn(P1m)(S_.container) || ({})).topNode;}if(!D_){D_=document;}J1=D_.querySelectorAll(`${E7.selector.markersMenuItem}.ciq-active:not(.span-event)`);J1.forEach(function(j0){var X6u,j5N;X6u=\"stxt\";c7z.y6g();X6u+=\"a\";X6u+=\"p\";j5N=\".c\";j5N+=\"iq-switc\";j5N+=\"h, .ciq-checkbox,\";j5N+=\" .ciq-radio\";j0.querySelector(j5N).dispatchEvent(new Event(X6u));});};};};S3=L2=>{var O0X=k_Cdw;O0X.y6g();var b8;b8=typeof _CIQ !== \"undefined\"?_CIQ:L2.CIQ;b8.ChartEngine.prototype.drawHeatmap=function(N6,J0){var T3,m9,E9,f2,f6,b9,n9,O$,u1,H8,c4,x9,W2,C8;function f1(Y6,H6,X8,m_,z_,g5,a6,N1){var I4,k6,A8,G$,S8,d1r,U0B,J_s,g4M,f7,N$,F_,r9,F7,D6,T9,x5,t8;b9.beginPath();b9.fillStyle=H6;b9.strokeStyle=H6;b9.textAlign=\"center\";I4=x9.layout.candleWidth * z_;k6=Math.floor(x9.pixelFromBar(0,m9.chart) - x9.layout.candleWidth);if(typeof X8 == \"number\"){O0X.b8R(3);b9.globalAlpha=O0X.F9v(X8,O$);}if(typeof X8 == \"object\"){d1r=-2029626705;O0X.b8R(1);U0B=-O0X.e7l(\"531335427\",32);J_s=2;for(var C5c=1;O0X.m1(C5c.toString(),C5c.toString().length,62235) !== d1r;C5c++){S8={minOpacity:X8.min && 1,maxOpacity:X8.max && 7};J_s+=2;}if(O0X.m1(J_s.toString(),J_s.toString().length,\"92698\" | 24) !== U0B){S8={minOpacity:X8.min && 1,maxOpacity:X8.max && \"7\" * 1};}S8={minOpacity:X8.min || 0,maxOpacity:X8.max || \"1\" << 0};}for(var S2=0;S2 < f2.length;S2++){g4M=\"numb\";g4M+=\"er\";f7=f2[S2];if(f7 && f7.candleWidth){if(S2 === +\"0\"){k6+=x9.layout.candleWidth;}else {O0X.G4m(4);var X6r=O0X.F9v(6,4);k6+=(f7.candleWidth + I4 / z_) / X6r;}I4=f7.candleWidth * z_;}else {k6+=x9.layout.candleWidth;}O0X.b8R(5);A8=O0X.F9v(2,k6,a6,I4);O0X.G4m(6);G$=O0X.e7l(k6,I4,a6,2);if(G$ - A8 < +\"2\"){O0X.b8R(0);G$=O0X.F9v(A8,1);}if(!f7)continue;N$=f7[Y6];if(!N$)continue;if(N$[N1]){N$=N$[N1];}if(typeof N$ == g4M){N$=[N$];}for(var B3=0;B3 < N$.length;B3++){F_=N$[B3];r9=0;if(F_ instanceof Array){if(S8){O0X.b8R(7);var s2R=O0X.e7l(5,8,15,14,5);O0X.b8R(8);var g$u=O0X.e7l(13,17,6,1);b9.globalAlpha=O$ * (F_[\"2\" ^ 0] * S8.maxOpacity + (s2R - F_[g$u]) * S8.minOpacity);}O0X.b8R(1);r9=F_[O0X.e7l(\"1\",32)];F_=F_[0];}F7=x9.pixelFromPrice(F_,m9,E9);if(!W2){if(!g5){g5=N6.height;}D6=x9.pixelFromPrice(F_ + g5 * (E9.flipped?\"1\" - 0:-(\"1\" << 0)),m9,E9);b9.lineWidth=1;O0X.G4m(4);H8=O0X.F9v(D6,F7);O0X.b8R(9);c4=O0X.e7l(H8,2);W2=b9.lineWidth;}if(m_){O0X.b8R(4);T9=O0X.e7l(F7,c4);O0X.G4m(0);x5=O0X.e7l(F7,c4);O0X.G4m(4);b9.rect(A8,T9,O0X.F9v(G$,A8),O0X.e7l(x5,T9));}else {O0X.G4m(4);b9.fillRect(A8,O0X.F9v(F7,c4),O0X.F9v(G$,A8),H8);if(N6.showSize && r9 && n9 <= H8 - 2){t8=b9.globalAlpha;b9.fillStyle=x9.defaultColor;O0X.b8R(3);b9.globalAlpha=O0X.F9v(0.5,O$);O0X.G4m(10);b9.fillText(r9,O0X.e7l(G$,A8,2),F7);b9.fillStyle=H6;O0X.b8R(3);b9.globalAlpha=O0X.e7l(t8,O$);}}if(S8 && F_ instanceof Array){b9.globalAlpha=0;}}}if(m_){b9.stroke();}b9.globalAlpha=O$;b9.closePath();}if(!J0 || !J0.length){return;}T3=N6.panel;if(!T3){T3=\"chart\";}m9=this.panels[T3];if(!m9){return;}E9=N6.yAxis?N6.yAxis:m9.yAxis;f2=this.chart.dataSegment;if(!N6.name){N6.name=\"Data\";}if(!N6.widthFactor){N6.widthFactor=1;}if(!N6.height){N6.height=Math.pow(10,1 - (m9.decimalPlaces || m9.chart.decimalPlaces));}f6=\"stx-float-date\";b9=this.chart.context;this.canvasFont(f6,b9);n9=this.getCanvasFontSize(f6);O$=1;if(!N6.highlight && this.highlightedDraggable){O$=0.3;}u1=+\"0.5\";if(m9.chart.tmpWidth <= 1){u1=0;}H8=null;c4=null;x9=this;W2=null;this.startClip(T3);b9.globalAlpha=O$;for(var J2=0;J2 < J0.length;J2++){C8=J0[J2];f1(C8.field,C8.color,C8.opacity,null,N6.widthFactor,C8.height,C8.border_color?u1:-u1 / 4,C8.subField);if(C8.border_color && this.layout.candleWidth >= +\"2\"){f1(C8.field,C8.border_color,C8.opacity,!!({}),N6.widthFactor,C8.height,u1,C8.subField);}}b9.lineWidth=1;b9.globalAlpha=1;this.endClip();};b8.ChartEngine.prototype.drawCandles=function(w7,g6,d7){var k_Z,K_,B0,p$,g_,N2,j_,s4,p6,E5,G0,l$,a7,h7,e2,L_,c$,R1,V7,z8,a9,v4,d1S,r6,P8,X3,U9,I8,i5,w$,g0,l0,v6,p9,s3,i2,C$,Z8,M7;k_Z=\"obj\";k_Z+=\"ec\";k_Z+=\"t\";K_=w7.chart;if(!K_){K_=w7;w7=w7.chart;}B0=!\"1\";p$=!({});g_=null;N2=w7.yAxis;if(d7 && typeof d7 == k_Z){B0=d7.isOutline;p$=d7.isHistogram;g_=d7.field;N2=d7.yAxis;}else {B0=d7;p$=arguments[+\"3\"];}j_=K_.dataSegment;s4=K_.context;p6=N2.top;E5=N2.bottom;h7=new Array(j_.length);e2=\"transparent\";L_=\"transparent\";c$=0;O0X.G4m(11);var u_x=O0X.e7l(0,9,10);R1=K_.dataSet.length - K_.scroll - u_x;V7={};z8=K_.tmpWidth / +\"2\";a9=this.layout.candleWidth;O0X.G4m(4);var k5T=O0X.e7l(21,20);v4=w7.left - 0.5 * a9 + this.micropixels - k5T;for(var k9=0;k9 <= j_.length;k9++){d1S=\"op\";d1S+=\"e\";d1S+=\"n\";r6=z8;O0X.G4m(9);v4+=O0X.e7l(a9,2);a9=this.layout.candleWidth;O0X.G4m(12);v4+=O0X.e7l(96,\"2\",a9);P8=j_[k9];if(!P8)continue;if(!P8.cache || K_.pixelCacheExpired){P8.cache={};}if(P8.projection)continue;if(P8.candleWidth){O0X.G4m(13);var Z1Q=O0X.F9v(17,15);v4+=(P8.candleWidth - a9) / Z1Q;a9=P8.candleWidth;if(d7.isVolume || a9 < K_.tmpWidth){O0X.G4m(9);r6=O0X.e7l(a9,2);}}if(K_.transformFunc && N2 == K_.panel.yAxis && P8.transform){P8=P8.transform;}X3=P8.cache;if(P8 && g_){P8=P8[g_];}if(!P8 && P8 !== 0)continue;U9=d1S;I8=\"close\";if(g_){O0X.b8R(14);U9=O0X.F9v(g_,U9,+\"7048\" != 3788?\".\":934.29 < 1330?(190.69,2713) == 6435?(!0,128.05):\"165.21\" - 0:(549.84,3.56e+3));O0X.G4m(14);I8=O0X.e7l(g_,I8,(7706,9050) <= (786.84,698.58)?(792.67,897.67) != 491.29?(+\"0x17bb\",!!({})):0x13c:\".\");}i5=P8.Close;w$=P8.Open === undefined?i5:P8.Open;if(p$ && K_.defaultPlotField){i5=P8[K_.defaultPlotField];}if(!i5 && i5 !== +\"0\")continue;if(!p$ && (w$ == i5 || w$ === null))continue;g0=g6(this,P8,B0?\"outline\":\"solid\");if(!g0)continue;if(B0){e2=g0;}else {L_=g0;}V7[L_]=1;l0=e2 && !b8.isTransparent(e2);if(l0 && !d7.highlight){c$=0.5;}s4.beginPath();s4.fillStyle=L_;O0X.G4m(0);v6=O0X.e7l(R1,k9);if(v6 < w7.cacheLeft || v6 > w7.cacheRight || !X3[U9]){p9=N2.semiLog?N2.height * ((\"1\" << 64) - (Math.log(Math.max(w$,0)) / Math.LN10 - N2.logLow) / N2.logShadow):(N2.high - w$) * N2.multiplier;s3=N2.semiLog?N2.height * (1 - (Math.log(Math.max(i5,0)) / Math.LN10 - N2.logLow) / N2.logShadow):(N2.high - i5) * N2.multiplier;if(Math.abs(p9 - s3) < 1){p9=s3;}if(N2.flipped){O0X.b8R(4);p9=O0X.e7l(E5,p9);O0X.G4m(4);s3=O0X.e7l(E5,s3);}else {p9+=p6;s3+=p6;}h7[k9]=s3;G0=p$?s3:Math.min(p9,s3);l$=p$?N2.bottom:Math.max(p9,s3);G0=Math.floor(G0);l$=Math.floor(l$);O0X.b8R(4);a7=O0X.e7l(l$,G0);if(G0 < p6){if(G0 + a7 < p6){X3[U9]=G0;X3[I8]=G0;continue;}O0X.b8R(15);a7-=O0X.e7l(32,G0,p6,\"1\");O0X.G4m(4);G0=O0X.F9v(p6,1);}if(G0 + a7 > E5){O0X.G4m(11);a7=O0X.F9v(E5,G0,1);}X3[U9]=G0;O0X.b8R(0);X3[I8]=O0X.e7l(G0,a7);}if(X3[U9] >= E5)continue;if(X3[I8] <= p6)continue;O0X.b8R(16);var H5S=O0X.e7l(2,9,3);i2=Math.floor(v4) + (!d7.highlight && \"0.5\" * H5S);C$=Math.floor(i2 - r6) + c$;Z8=Math.round(i2 + r6) - c$;s4.rect(C$,X3[U9] + c$,Math.max(0,Z8 - C$),Math.max(+\"0\",X3[I8] - X3[U9]));if(!d7.highlight && this.highlightedDraggable){s4.globalAlpha*=0.3;}if(L_ != \"transparent\"){s4.fill();}if(l0){s4.lineWidth=1;if(d7.highlight){s4.lineWidth*=+\"2\";}s4.strokeStyle=e2;s4.stroke();}}K_.pixelCacheExpired=!!\"\";M7={colors:[],cache:h7};for(var N0 in V7){if(!d7.hollow || !b8.equals(N0,this.containerColor)){M7.colors.push(N0);}}return M7;};b8.ChartEngine.prototype.drawShadows=function(S0,a5,V0){var i7,N7,f_,Y2,C7,b6,o8,g8,R6,D2,C2,A20,H0,Z5,R5,t5,X7,m8,O6,w2,G3,Y$,K8,w8,r8,W8,d2,X2,U0,F8;i7=S0.chart;if(!i7){i7=S0;S0=S0.chart;}N7=i7.dataSegment;f_=this.chart.context;f_.lineWidth=1;if(V0.highlight){f_.lineWidth*=2;}if(!V0.highlight && this.highlightedDraggable){f_.globalAlpha*=0.3;}Y2=V0.isHistogram;C7=V0.field;b6=V0.yAxis || S0.yAxis;o8=b6.top;g8=b6.bottom;O0X.b8R(17);var c0h=O0X.F9v(0,16,15);R6=i7.dataSet.length - i7.scroll - c0h;D2=this.layout.candleWidth;O0X.G4m(4);var e5I=O0X.e7l(11,10);C2=S0.left - 0.5 * D2 + this.micropixels - e5I;for(var e4=0;e4 <= N7.length;e4++){A20=\"sha\";A20+=\"dow\";O0X.G4m(9);C2+=O0X.e7l(D2,2);D2=this.layout.candleWidth;O0X.b8R(9);C2+=O0X.F9v(D2,2);H0=N7[e4];if(!H0)continue;if(!H0.cache || i7.pixelCacheExpired){H0.cache={};}if(H0.projection)continue;if(H0.candleWidth){O0X.G4m(4);var k3e=O0X.F9v(26,24);C2+=(H0.candleWidth - D2) / k3e;D2=H0.candleWidth;}Z5=a5(this,H0,A20);if(!Z5)continue;if(i7.transformFunc && b6 == i7.panel.yAxis && H0.transform){H0=H0.transform;}R5=H0.cache;if(H0 && C7){H0=H0[C7];}if(!H0 && H0 !== 0)continue;t5=\"top\";X7=\"bottom\";if(C7){O0X.b8R(14);t5=O0X.F9v(C7,t5,\".\");O0X.b8R(14);X7=O0X.e7l(C7,X7,\".\");}m8=H0.Close;O6=H0.Open === undefined?m8:H0.Open;w2=H0.High === undefined?Math.max(m8,O6):H0.High;G3=H0.Low === undefined?Math.min(m8,O6):H0.Low;if(!m8 && m8 !== 0)continue;O0X.G4m(0);Y$=O0X.e7l(R6,e4);if(Y$ < S0.cacheLeft || Y$ > S0.cacheRight || !R5[t5]){K8=b6.semiLog?b6.height * (1 - (Math.log(Math.max(w2,0)) / Math.LN10 - b6.logLow) / b6.logShadow):(b6.high - w2) * b6.multiplier;w8=b6.semiLog?b6.height * (1 - (Math.log(Math.max(G3,0)) / Math.LN10 - b6.logLow) / b6.logShadow):(b6.high - G3) * b6.multiplier;if(Math.abs(w8 - K8) < 1){w8=K8;}K8=Math.floor(K8);w8=Math.floor(w8);O0X.b8R(4);r8=O0X.F9v(w8,K8);if(b6.flipped){O0X.G4m(4);K8=O0X.F9v(g8,K8);O0X.G4m(4);w8=O0X.e7l(g8,w8);}else {K8+=o8;w8+=o8;}if(K8 < o8){if(K8 + r8 < o8){R5[t5]=K8;R5[X7]=K8;continue;}O0X.G4m(18);r8-=O0X.e7l(K8,o8,1);O0X.G4m(4);K8=O0X.e7l(o8,1);}if(K8 + r8 > g8){O0X.b8R(11);r8=O0X.F9v(g8,K8,1);}R5[t5]=K8;R5[X7]=R5[t5] + r8;}if(R5[t5] >= g8)continue;if(R5[X7] <= o8)continue;W8=Math.floor(C2) + (!V0.highlight && \"0.5\" - 0);f_.beginPath();if(!Y2 && m8 == O6){d2=this.offset;if(V0.isVolume){O0X.G4m(9);d2=O0X.e7l(D2,2);}O0X.b8R(4);X2=O0X.e7l(W8,d2);O0X.b8R(0);U0=O0X.F9v(W8,d2);F8=b6.semiLog?b6.height * (1 - (Math.log(Math.max(m8,0)) / Math.LN10 - b6.logLow) / b6.logShadow):(b6.high - m8) * b6.multiplier;F8=Math.floor(F8) + (!V0.highlight && 0.5);if(b6.flipped){O0X.G4m(4);F8=O0X.F9v(g8,F8);}else {F8+=o8;}if(F8 <= g8 && F8 >= o8){f_.moveTo(X2,F8);f_.lineTo(U0,F8);}}if(w2 != G3){f_.moveTo(W8,R5[t5]);f_.lineTo(W8,R5[X7]);}f_.strokeStyle=Z5;f_.stroke();}i7.pixelCacheExpired=![];};b8.ChartEngine.prototype.drawBarChart=function(s0,j8,B$,d5){var A4,Z7,s9,q2,U7,r7,X9,R4,W5,Y_,f5,W$,w1,A6,R3,k_,r6S,e98,U4P,q1,K1,j2,I6,h1,a1,A0,w6,J_,h3,o6,O7,E4,o4,T_,B5,r5,c_,z3,Y0,I2;A4=s0.chart;if(!A4){A4=s0;s0=s0.chart;}Z7=A4.dataSegment;s9=new Array(Z7.length);q2=A4.context;U7=this.canvasStyle(j8);if(U7.width && parseInt(U7.width,10) <= +\"25\"){q2.lineWidth=Math.max(1,b8.stripPX(U7.width));}else {q2.lineWidth=1;}if(d5.highlight){O0X.b8R(3);q2.lineWidth*=O0X.e7l(\"2\",1);}if(!d5.highlight && this.highlightedDraggable){q2.globalAlpha*=0.3;}r7=d5.field;X9=d5.yAxis || s0.yAxis;R4=X9.top;W5=X9.bottom;O0X.b8R(13);var O7k=O0X.e7l(4,3);f5=A4.dataSet.length - A4.scroll - O7k;W$={};O0X.G4m(19);var h$t=O0X.e7l(18,5,14,3);w1=A4.tmpWidth / h$t;O0X.b8R(20);var O6i=O0X.e7l(0,5,47,9);A6=q2.lineWidth / O6i;R3=this.layout.candleWidth;O0X.b8R(21);var I2v=O0X.F9v(1,7,8,1);k_=s0.left - 0.5 * R3 + this.micropixels - \"1\" * I2v;for(var r_=0;r_ <= Z7.length;r_++){r6S=\"h\";r6S+=\"l\";r6S+=\"c\";e98=\"op\";e98+=\"en\";U4P=\"b\";U4P+=\"ot\";U4P+=\"to\";U4P+=\"m\";O0X.b8R(22);k_+=O0X.e7l(\"2\",R3);R3=this.layout.candleWidth;O0X.G4m(9);k_+=O0X.F9v(R3,2);q1=Z7[r_];if(!q1)continue;if(!q1.cache || A4.pixelCacheExpired){q1.cache={};}if(q1.projection)continue;if(q1.candleWidth){O0X.b8R(23);var K8T=O0X.e7l(1,11,0,13);k_+=(q1.candleWidth - R3) / K8T;R3=q1.candleWidth;}K1=B$(this,q1);if(!K1)continue;W$[K1]=1;q2.strokeStyle=K1;q2.beginPath();if(A4.transformFunc && X9 == A4.panel.yAxis && q1.transform){q1=q1.transform;}j2=q1.cache;if(q1 && r7){q1=q1[r7];}if(!q1 && q1 !== 0)continue;I6=\"top\";h1=U4P;a1=e98;A0=\"close\";if(r7){O0X.b8R(14);I6=O0X.e7l(r7,I6,\".\");O0X.b8R(14);h1=O0X.F9v(r7,h1,(7976,7720) != (681.93,6659)?\".\":(!!0,!({})));O0X.b8R(14);a1=O0X.F9v(r7,a1,1563 == 519.31?9581 > 965.85?!![]:(6.60e+3,3.33e+3):\".\");O0X.b8R(14);A0=O0X.F9v(r7,A0,\".\");}w6=q1.Close;J_=q1.Open === undefined?w6:q1.Open;h3=q1.High === undefined?Math.max(w6,J_):q1.High;o6=q1.Low === undefined?Math.min(w6,J_):q1.Low;if(!w6 && w6 !== 0)continue;O0X.G4m(0);O7=O0X.e7l(f5,r_);if(O7 < s0.cacheLeft || O7 > s0.cacheRight || !j2[I6]){E4=this.pixelFromTransformedValue(h3,s0,X9);o4=this.pixelFromTransformedValue(o6,s0,X9);E4=Math.floor(E4);o4=Math.floor(o4);O0X.b8R(4);Y_=O0X.e7l(o4,E4);j2[a1]=X9.semiLog?X9.height * (1 - (Math.log(Math.max(J_,0)) / Math.LN10 - X9.logLow) / X9.logShadow):(X9.high - J_) * X9.multiplier;j2[A0]=X9.semiLog?X9.height * (+\"1\" - (Math.log(Math.max(w6,0)) / Math.LN10 - X9.logLow) / X9.logShadow):(X9.high - w6) * X9.multiplier;if(Math.abs(j2[A0] - j2[a1]) < \"1\" >> 64){j2[A0]=j2[a1];}j2[a1]=Math.floor(j2[a1]);j2[A0]=Math.floor(j2[A0]);if(X9.flipped){j2[a1]=X9.bottom - j2[a1];j2[A0]=X9.bottom - j2[A0];}else {j2[a1]+=X9.top;j2[A0]+=X9.top;}s9[r_]=j2[A0];if(E4 < R4){if(E4 + Y_ < R4){j2[I6]=E4;j2[h1]=E4;continue;}O0X.G4m(18);Y_-=O0X.e7l(E4,R4,1);O0X.G4m(4);E4=O0X.e7l(R4,1);}if(E4 + Y_ > W5){O0X.b8R(11);Y_=O0X.F9v(W5,E4,1);}j2[I6]=E4;O0X.G4m(0);j2[h1]=O0X.e7l(E4,Y_);}T_=!d5.highlight && 0.5;B5=Math.floor(k_) + T_;r5=j2[a1] + T_;c_=j2[A0] + T_;z3=j2[I6] + T_;Y0=j2[h1] + T_;if(z3 < W5 && Y0 > R4 && q1.High != q1.Low){O0X.G4m(4);q2.moveTo(B5,O0X.e7l(z3,A6));O0X.b8R(0);q2.lineTo(B5,O0X.e7l(Y0,A6));}if(d5.type != r6S && r5 > R4 && r5 < W5){q2.moveTo(B5,r5);O0X.b8R(4);q2.lineTo(O0X.F9v(B5,w1),r5);}if(c_ > R4 && c_ < W5){q2.moveTo(B5,c_);O0X.G4m(0);q2.lineTo(O0X.e7l(B5,w1),c_);}q2.stroke();}q2.lineWidth=+\"1\";A4.pixelCacheExpired=!({});I2={colors:[],cache:s9};for(var E6 in W$){if(!b8.equals(E6,this.containerColor)){I2.colors.push(E6);}}return I2;};b8.ChartEngine.prototype.drawWaveChart=function(T$,h6){var W3,u3,M0,s6,N3,C1,h_,K5,P0,c1,G5,L0,A_,T2,k2,V4,L9,H7,E8,O4,P9,t4,u$;W3=T$.chart;u3=W3.dataSegment;M0=new Array(u3.length);s6=W3.context;if(!h6){h6={};}N3=h6.yAxis || T$.yAxis;this.startClip(T$.name);s6.beginPath();C1=!1;h_=!!\"\";K5=T$.yAxis.top;P0=T$.yAxis.bottom;c1=T$.left + Math.floor(-0.5 * this.layout.candleWidth + this.micropixels);G5=this;for(var c5=0;c5 <= u3.length;c5++){c1+=this.layout.candleWidth;L0=u3[c5];if(!L0)continue;if(L0.projection)break;if(W3.transformFunc && N3 == W3.panel.yAxis && L0.transform){L0=L0.transform;}if(L0 && h6.field){L0=L0[h6.field];}if(!L0 && L0 !== 0)continue;A_=L0.Close;T2=L0.Open === undefined?A_:L0.Open;k2=L0.High === undefined?Math.max(A_,T2):L0.High;V4=L0.Low === undefined?Math.min(A_,T2):L0.Low;if(!A_ && A_ !== 0)continue;O0X.G4m(0);var w68=O0X.e7l(1,2);O0X.b8R(16);var h3d=O0X.e7l(18,26,1);L9=c1 - w68 * this.layout.candleWidth / (\"8\" | h3d);H7=F1(T2);if(H7 < K5){H7=K5;if(h_){s6.moveTo(L9,H7);continue;}h_=!!({});}else if(H7 > P0){H7=P0;if(h_){s6.moveTo(L9,H7);continue;}h_=!!({});}else {h_=![];}if(!C1){C1=!0;O0X.b8R(24);var H_K=O0X.e7l(10,11,4,16,12);E8=W3.dataSet.length - W3.scroll - H_K;if(E8 < 0){s6.moveTo(L9,H7);}else if(E8 >= 0){O4=W3.dataSet[E8];if(O4.transform){O4=O4.transform;}P9=O4.Close;P9=F1(P9);P9=Math.min(Math.max(P9,K5),P0);s6.moveTo(T$.left + (c5 - 1) * this.layout.candleWidth + this.micropixels,P9);s6.lineTo(L9,H7);}s6.moveTo(L9,H7);}else {s6.lineTo(L9,H7);}L9+=this.layout.candleWidth / +\"4\";if(T2 < A_){H7=F1(V4);if(H7 < K5){H7=K5;}if(H7 > P0){H7=P0;}s6.lineTo(L9,H7);O0X.b8R(25);var S9y=O0X.F9v(3,14,79,2,48);L9+=this.layout.candleWidth / S9y;H7=F1(k2);if(H7 < K5){H7=K5;}if(H7 > P0){H7=P0;}s6.lineTo(L9,H7);}else {H7=F1(k2);if(H7 < K5){H7=K5;}if(H7 > P0){H7=P0;}s6.lineTo(L9,H7);O0X.G4m(0);var X0z=O0X.e7l(0,4);L9+=this.layout.candleWidth / X0z;H7=F1(V4);if(H7 < K5){H7=K5;}if(H7 > P0){H7=P0;}s6.lineTo(L9,H7);}L9+=this.layout.candleWidth / +\"4\";H7=F1(A_);M0[c5]=H7;if(H7 < K5){H7=K5;}if(H7 > P0){H7=P0;}s6.lineTo(L9,H7);}t4=this.canvasStyle(\"stx_line_chart\");if(t4.width && parseInt(t4.width,10) <= 25){s6.lineWidth=Math.max(1,b8.stripPX(t4.width));}else {O0X.b8R(4);s6.lineWidth=O0X.F9v(\"1\",0);}if(h6.highlight){s6.lineWidth*=2;}this.canvasColor(\"stx_line_chart\");if(h6.color){s6.strokeStyle=h6.color;}function F1(T8){O0X.j1L();return G5.pixelFromTransformedValue(T8,T$,N3);}O0X.y6g();if(!h6.highlight && this.highlightedDraggable){s6.globalAlpha*=0.3;}s6.stroke();s6.closePath();u$={colors:[s6.strokeStyle],cache:M0};this.endClip();s6.lineWidth=1;return u$;};b8.ChartEngine.prototype.drawHistogram=function(V6,k7){var F2,j7,c2,F5,i3,R7,v_,u6,P4,m6,o$,i6,m0,U6,n0,e1,F0P,t14,E0,D9,P2,h9,B2,G2,V5,q7,U2,p3,w7D,q3,X$,o3,I$,d4,i8M;if(!k7 || !k7.length){return;}F2=V6.panel;if(!F2){F2=\"chart\";}j7=this.panels[F2];function M5(b_,i4,w4,u7,D1,Z9,A3,D3,K3){O0X.y6g();var g$,b2,v7,L3Y,v2E,w3,P7,v3,x$,R0,P5,D$,z6,b4,h$,l9;if(!u7){u7=1;}B2.globalAlpha=u7;B2.beginPath();O0X.b8R(26);g$=O0X.e7l(1,\"0.5\",E0);b2=Math.floor(U2.pixelFromBar(+\"0\",j7.chart) - U2.layout.candleWidth / 2);v7=b2;for(var N9=0;N9 < i3.length;N9++){L3Y=\"c\";L3Y+=\"lu\";L3Y+=\"stered\";v2E=\"ob\";v2E+=\"je\";v2E+=\"ct\";w3=q7[N9] || E0;if(N9 === 0){g$=w3;}if(!i3[N9] || !i3[N9][b_]){g$=w3;v7+=U2.layout.candleWidth;continue;}P7=i3[N9];v3=P7[b_];if(typeof v3 == v2E && v3[i4]){v3=v3[i4];}O0X.b8R(27);x$=O0X.F9v(m0,o$,v3);if(isNaN(x$))continue;R0=U2.layout.candleWidth;if(P7.candleWidth){R0=P7.candleWidth;if(N9 === 0){b2=v7=Math.floor(U2.pixelFromBar(\"0\" | 0,j7.chart) - P7.candleWidth / 2);}}P5=Math.floor(w3 - x$) + 0.5;if(P5 > w3 && !D9){P5=w3;}if(K3 && K3.indexOf(N9) == -1 || !K3 && (Z9 && P7.Close < P7.iqPrevClose || !Z9 && P7.Close >= P7.iqPrevClose)){g$=P5;v7+=R0;continue;}D$=R0 / U2.layout.candleWidth;if(G2){O0X.G4m(28);z6=Math.round(O0X.F9v(A3,G2,D3,D$,v7));O0X.G4m(0);b4=O0X.e7l(z6,D1?0:h9);h$=z6 + Math.round(D3 * D$) - (D1?0:h9);}else {O0X.G4m(28);z6=O0X.F9v(A3,G2,D3,D$,v7);b4=Math.round(z6) + (D1?0:h9);h$=Math.round(z6 + D3 * D$) - (D1?+\"0\":h9);}if(h$ - b4 < 2){O0X.b8R(0);h$=O0X.F9v(b4,1);}l9=D1?+\"0\":0.5;if(b4 % 1 == l9){b4+=0.5;}if(h$ % 1 == l9){h$+=0.5;}B2.moveTo(h$,w3);if(E0 != w3 && D1 && !G2 && q7[N9 + 1]){B2.moveTo(h$,Math.max(P5,Math.min(w3,q7[N9 + 1])));}B2.lineTo(h$,P5);B2.lineTo(b4,P5);if(D1 && A3){if(V5[N9] > P5 || N9 === 0){B2.lineTo(b4,Math.min(w3,V5[N9]));}}else if(D1 && !G2 && F5 == \"clustered\"){if(N9 > 0 && V5[N9 - 1] && V5[N9 - +\"1\"] > P5){B2.lineTo(b4,Math.min(w3,V5[N9 - 1]));}}else if(D1 && !G2){if(g$ > P5 || N9 === 0){B2.lineTo(b4,Math.min(w3,g$));}}else {B2.lineTo(b4,w3);}g$=P5;v7+=R0;if(F5 != L3Y || D1){V5[N9]=P5;}}if(D1){B2.strokeStyle=!w4 || w4 == \"auto\"?U2.defaultColor:w4;B2.stroke();}else {B2.fillStyle=!w4 || w4 == \"auto\"?U2.defaultColor:w4;B2.fill();}B2.closePath();}if(!j7){return;}c2=V6.yAxis?V6.yAxis:j7.yAxis;F5=V6.type;i3=this.chart.dataSegment;R7=!({});v_=+\"1\";u6=1;for(m6=0;m6 < k7.length;m6++){R7|=k7[m6].border_color_up && !b8.isTransparent(k7[m6].border_color_up);R7|=k7[m6].border_color_down && !b8.isTransparent(k7[m6].border_color_down);v_=k7[m6].opacity_up;u6=k7[m6].opacity_down;if(!V6.highlight && this.highlightedDraggable){v_*=0.3;u6*=0.3;}}if(V6.borders === !1){R7=![];}if(!V6.name){V6.name=\"Data\";}o$=c2.multiplier;if(!V6.heightPercentage){V6.heightPercentage=0.7;}O0X.j1L();if(!V6.widthFactor){O0X.G4m(3);V6.widthFactor=O0X.e7l(\"0.8\",1);}i6=0;m0=+\"0\";for(var a8=0;a8 < this.chart.maxTicks;a8++){U6=i3[a8];if(!U6)continue;n0=0;for(m6=0;m6 < k7.length;m6++){e1=U6[k7[m6].field];if(e1 || e1 === 0){F0P=\"st\";F0P+=\"acke\";F0P+=\"d\";t14=\"o\";t14+=\"b\";t14+=\"j\";t14+=\"ect\";P4=k7[m6].subField || this.chart.defaultPlotField || \"Close\";if(typeof e1 == t14 && e1[P4]){e1=e1[P4];}if(F5 == F0P){n0+=e1;}else {n0=e1;}if(n0 > i6){i6=n0;}if(n0 < m0){m0=n0;}}}}if(i6 === 0 && m0 === 0){this.displayErrorAsWatermark(F2,this.translateIf(V6.name + \" Not Available\"));return;}D9=![];if(!V6.bindToYAxis){if(c2.flipped){E0=Math.floor(c2.top) - 0.5;P2=Math.floor(c2.bottom) - 0.5;}else {E0=Math.floor(c2.bottom) + 0.5;P2=Math.floor(c2.top) + 0.5;}o$=Math.abs(E0 - P2) * V6.heightPercentage / (i6 - m0);}else {if(c2.baseline){m0=c2.baseline.value;D9=!\"\";}E0=Math.floor(this.pixelFromPrice(m0,j7,c2)) + (c2.flipped?-0.5:0.5);}this.startClip(F2);h9=this.layout.candleWidth <= 1 || !R7?0:\"0.5\" - 0;B2=this.chart.context;if(c2.flipped){B2.translate(0,2 * c2.top);B2.scale(1,-+\"1\");}G2=Math.max(0,(1 - V6.widthFactor) * this.layout.candleWidth / 2);V5=new Array(i3.length);q7=[];U2=this;p3=+\"1\";for(m6=0;m6 < k7.length;m6++){w7D=\"Clos\";w7D+=\"e\";q3=k7[m6];p3=this.layout.candleWidth * V6.widthFactor;if(G2){if(this.layout.candleWidth - p3 <= 2){R7=!!\"\";}}X$=0;if(F5 == \"clustered\"){X$=m6;p3/=k7.length;}P4=q3.subField || this.chart.defaultPlotField || w7D;if(typeof q3.color_function == \"function\"){I$={};for(var O5=0;O5 < i3.length;O5++){if(i3[O5]){i8M=\"border_o\";i8M+=\"paci\";i8M+=\"ty\";o3=q3.color_function(i3[O5]);if(typeof o3 == \"string\"){o3={fill_color:o3,border_color:o3};}if(!o3.hasOwnProperty(i8M)){o3.border_opacity=o3.opacity;}O0X.b8R(29);var q06=O0X.e7l(9,16,5,2847,127150);O0X.b8R(30);var V0Z=O0X.e7l(1,145608,19,19,8090);O0X.b8R(31);var h3N=O0X.e7l(1566,5495,21980);O0X.b8R(31);var w$l=O0X.F9v(6306,5,7905);O0X.G4m(32);var s7R=O0X.e7l(8,4014,3,11349);d4=o3.fill_color + (q06 > +\"7550\"?V0Z:(h3N,285.07) < w$l?\",\":+\"7868\" < 27.51?(\"F\",s7R):(\"Q\",!!\"\")) + o3.border_color;if((d4 in I$)){I$[d4].positions.push(O5);}else {o3.positions=[O5];I$[d4]=o3;}}}for(d4 in I$){o3=I$[d4];M5(q3.field,P4,o3.fill_color,o3.opacity,null,null,X$,p3,o3.positions);M5(q3.field,P4,o3.border_color,o3.border_opacity,!!({}),null,X$,p3,o3.positions);}}else {M5(q3.field,P4,q3.fill_color_up,v_,null,!!({}),X$,p3);M5(q3.field,P4,q3.fill_color_down,u6,null,null,X$,p3);if(this.layout.candleWidth >= +\"2\" && R7){M5(q3.field,P4,q3.border_color_up,v_,!![],!\"\",X$,p3);M5(q3.field,P4,q3.border_color_down,u6,!\"\",null,X$,p3);}}if(F5 == \"stacked\"){q7=b8.shallowClone(V5);}}B2.globalAlpha=1;this.endClip();};b8.ChartEngine.prototype.scatter=function(a2,u5){var R0y,O2,o2,f0,k5,K0,K2,l4,e_,o_,l7,C5,Q9,U_,J6,J5,K$,b0,S5;R0y=\"stx_sca\";R0y+=\"tter_chart\";O2=a2.chart;o2=O2.dataSegment;f0=new Array(o2.length);k5=this.chart.context;this.canvasColor(R0y);if(!u5){u5={};}O0X.j1L();K0=u5.field || O2.defaultPlotField;K2=u5.yAxis || a2.yAxis;l4=u5.subField || O2.defaultPlotField || \"Close\";this.startClip(a2.name);k5.beginPath();k5.lineWidth=u5.lineWidth || 4;if(u5.highlight){k5.lineWidth*=2;}if(!u5.highlight && this.highlightedDraggable){k5.globalAlpha*=0.3;}if(u5.color){k5.strokeStyle=u5.color;}e_=K2.top;o_=K2.bottom;l7=this.layout.candleWidth;O0X.b8R(33);var K$I=O0X.F9v(8,8,63);C5=a2.left - 0.5 * l7 + this.micropixels - K$I;var {tickFilter:n5}=u5;for(var U5=+\"0\";U5 <= o2.length;U5++){O0X.G4m(9);C5+=O0X.F9v(l7,2);l7=this.layout.candleWidth;O0X.b8R(9);C5+=O0X.e7l(l7,2);Q9=o2[U5];if(!Q9)continue;if(Q9.candleWidth){O0X.G4m(17);var Y2p=O0X.F9v(0,4,2);C5+=(Q9.candleWidth - l7) / Y2p;l7=Q9.candleWidth;}if(n5){if(n5.length === 0)break;if(!n5.has(Q9.tick))continue;n5.delete(Q9.tick);}if(!Q9.projection){if(O2.transformFunc && K2 == O2.panel.yAxis && Q9.transform){Q9=Q9.transform;}U_=Q9[K0];if(U_ && U_[l4] !== undefined){U_=U_[l4];}if(!(U_ instanceof Array)){U_=[U_];}if((\"Scatter\" in Q9)){U_=Q9.Scatter;}for(var C4=0;C4 < U_.length;C4++){if(!U_[C4] && U_[C4] !== 0)continue;J6=U_[C4];J5=+\"0\";if(U_[C4] instanceof Array){J6=U_[C4][0];J5=U_[C4][2];}K$=K2.semiLog?K2.height * (1 - (Math.log(Math.max(J6,0)) / Math.LN10 - K2.logLow) / K2.logShadow):(K2.high - J6) * K2.multiplier;if(K2.flipped){O0X.b8R(4);K$=O0X.F9v(o_,K$);}else {K$+=e_;}if(K$ < e_)continue;if(K$ > o_)continue;b0=2;if(J5){O0X.b8R(3);b0=O0X.F9v(l7,J5);}O0X.b8R(4);k5.moveTo(O0X.e7l(C5,b0),K$);O0X.G4m(0);k5.lineTo(O0X.F9v(C5,b0),K$);f0[U5]=K$;}}}k5.stroke();k5.closePath();S5={colors:[k5.strokeStyle],cache:f0};this.endClip();k5.lineWidth=1;return S5;};};r4=L4=>{var F4L,t6r,a_b,o8s,V9O,b$$,Z5S,E2E,G_0,h$7,y4w,w8K,Q6F,y0A,l96,P0y,T7N,g2K,E1e,E9q,s1j,D5,Q6;F4L=\"p\";F4L+=\"atter\";F4L+=\"n\";t6r=\"l\";t6r+=\"ineWidt\";t6r+=\"h\";a_b=\"fi\";a_b+=\"l\";a_b+=\"lColor\";o8s=\"c\";o8s+=\"o\";o8s+=\"l\";o8s+=\"or\";V9O=\"colo\";V9O+=\"r\";b$$=\"f\";b$$+=\"o\";b$$+=\"n\";b$$+=\"t\";Z5S=\"c\";Z5S+=\"olo\";Z5S+=\"r\";E2E=\"s\";E2E+=\"o\";E2E+=\"li\";E2E+=\"d\";G_0=\"au\";G_0+=\"to\";h$7=\"a\";h$7+=\"u\";h$7+=\"t\";h$7+=\"o\";y4w=\"so\";y4w+=\"lid\";w8K=\"au\";w8K+=\"to\";Q6F=\"au\";Q6F+=\"t\";Q6F+=\"o\";y0A=\"au\";y0A+=\"t\";y0A+=\"o\";l96=\"au\";l96+=\"t\";l96+=\"o\";P0y=\"a\";P0y+=\"ut\";P0y+=\"o\";T7N=\"s\";T7N+=\"ol\";T7N+=\"id\";g2K=\"s\";g2K+=\"ol\";g2K+=\"i\";g2K+=\"d\";E1e=\"a\";E1e+=\"u\";E1e+=\"t\";E1e+=\"o\";E9q=\"a\";E9q+=\"u\";E9q+=\"t\";E9q+=\"o\";s1j=\"undefin\";s1j+=\"ed\";D5=typeof _CIQ !== \"undefined\"?_CIQ:L4.CIQ;Q6=typeof _timezoneJS !== s1j?_timezoneJS:L4.timezoneJS;D5.ChartEngine.drawingTools={};D5.ChartEngine.currentVectorParameters={vectorType:null,pattern:\"solid\",lineWidth:+\"1\",fillColor:\"#7DA6F5\",currentColor:\"auto\",axisLabel:!!({}),fibonacci:{trend:{color:E9q,parameters:{pattern:\"solid\",opacity:0.25,lineWidth:+\"1\"}},fibs:[{level:-0.786,color:E1e,parameters:{pattern:g2K,opacity:0.25,lineWidth:1}},{level:-0.618,color:\"auto\",parameters:{pattern:T7N,opacity:0.25,lineWidth:1},display:!!1},{level:-0.5,color:\"auto\",parameters:{pattern:\"solid\",opacity:0.25,lineWidth:1}},{level:-+\"0.382\",color:\"auto\",parameters:{pattern:\"solid\",opacity:0.25,lineWidth:1},display:!![]},{level:-0.236,color:\"auto\",parameters:{pattern:\"solid\",opacity:0.25,lineWidth:1}},{level:0,color:P0y,parameters:{pattern:\"solid\",lineWidth:\"1\" >> 0},display:!0},{level:0.236,color:l96,parameters:{pattern:\"solid\",opacity:0.25,lineWidth:1}},{level:0.382,color:\"auto\",parameters:{pattern:\"solid\",opacity:0.25,lineWidth:1},display:!!\"1\"},{level:0.5,color:y0A,parameters:{pattern:\"solid\",opacity:0.25,lineWidth:\"1\" * 1},display:!!({})},{level:\"0.618\" * 1,color:\"auto\",parameters:{pattern:\"solid\",opacity:\"0.25\" - 0,lineWidth:1},display:!![]},{level:0.786,color:\"auto\",parameters:{pattern:\"solid\",opacity:0.25,lineWidth:\"1\" ^ 0}},{level:+\"1\",color:\"auto\",parameters:{pattern:\"solid\",lineWidth:1},display:!![]},{level:\"1.272\" * 1,color:Q6F,parameters:{pattern:\"solid\",opacity:0.25,lineWidth:1}},{level:\"1.382\" - 0,color:\"auto\",parameters:{pattern:\"solid\",opacity:\"0.25\" - 0,lineWidth:1},display:!\"\"},{level:1.618,color:w8K,parameters:{pattern:y4w,opacity:0.25,lineWidth:1},display:!!({})},{level:2.618,color:h$7,parameters:{pattern:\"solid\",opacity:0.25,lineWidth:\"1\" ^ 0}},{level:4.236,color:G_0,parameters:{pattern:E2E,opacity:0.25,lineWidth:1}}],extendLeft:!!0,printLevels:!0,printValues:!\"1\",timezone:{color:\"auto\",parameters:{pattern:\"solid\",opacity:+\"0.25\",lineWidth:1}}},volumeProfile:{priceBuckets:30},annotation:{font:{style:null,size:null,weight:null,family:null}}};D5.ChartEngine.registerDrawingTool=function(y_,F$){D5.ChartEngine.drawingTools[y_]=F$;};D5.ChartEngine.completeDrawing=function(n_){var A7K=k_Cdw;var i7Y,P1r,P$o,H3;i7Y=-1157233522;P1r=-329840989;P$o=2;for(var L2O=1;A7K.P6(L2O.toString(),L2O.toString().length,70943) !== i7Y;L2O++){if(!n_ || !n_.activeDrawing){return;}A7K.G4m(3);P$o+=A7K.e7l(\"2\",1);}if(A7K.m1(P$o.toString(),P$o.toString().length,29284) !== P1r){if(+n_ && +n_.activeDrawing){return;}}A7K.y6g();H3=n_.activeDrawing;if(!n_.keepDrawingToolSelected){if(n_.drawingContainer && n_.drawingContainer.tool){n_.drawingContainer.tool({node:null},\"notool\");}else {n_.changeVectorType(\"\");}}n_.dispatch(\"drawingComplete\",{stx:n_,drawing:H3});};D5.ChartEngine.prototype.keepDrawingToolSelected=!({});D5.ChartEngine.prototype.setDrawingContainer=function(z2){k_Cdw.y6g();this.drawingContainer=z2;};D5.ChartEngine.prototype.exportDrawings=function(){var B6;B6=[];for(var A2=0;A2 < this.drawingObjects.length;A2++){B6.push(this.drawingObjects[A2].serialize());}return B6;};D5.ChartEngine.prototype.abortDrawings=function(U1){var e6;if(U1 !== !\"1\"){U1=!0;}k_Cdw.j1L();for(var t$=this.drawingObjects.length - 1;t$ >= 0;t$--){e6=this.drawingObjects[t$];e6.abort(!!\"1\");if(U1 || !e6.permanent){this.drawingObjects.splice(t$,1);}}};D5.ChartEngine.prototype.importDrawings=function(O1){var j6,Q8,t7;if(!D5.Drawing){return;}for(var L5=0;L5 < O1.length;L5++){j6=O1[L5];if(j6.name == \"fibonacci\"){j6.name=\"retracement\";}Q8=D5.ChartEngine.drawingTools[j6.name];if(!Q8){if(D5.Drawing[j6.name]){Q8=D5.Drawing[j6.name];D5.ChartEngine.registerDrawingTool(j6.name,Q8);}}if(Q8){t7=new Q8();t7.reconstruct(this,j6);this.drawingObjects.push(t7);}}};D5.ChartEngine.prototype.clearDrawings=function(U4,G9){var N5,X6,I7n;if(G9 !== !({})){G9=!![];}N5=this.exportDrawings();this.abortDrawings(G9);k_Cdw.y6g();if(U4){this.undoStamps=[];}else {this.undoStamp(N5,this.exportDrawings());}this.changeOccurred(\"vector\");this.cancelTouchSingleClick=!\"\";D5.clearCanvas(this.chart.tempCanvas,this);this.draw();X6=this.controls.mSticky;if(X6){I7n=\"no\";I7n+=\"ne\";X6.style.display=I7n;X6.children[0].innerHTML=\"\";}};D5.ChartEngine.prototype.createDrawing=function(a4,f8){var A9,B_;if(!D5.Drawing){return;}A9=new D5.Drawing[a4]();A9.reconstruct(this,f8);B_=new D5.Drawing[a4]();B_.stx=this;B_.copyConfig();for(var c6 in B_){A9[c6]=A9[c6] || B_[c6];}this.drawingObjects.push(A9);this.draw();return A9;};D5.ChartEngine.prototype.removeDrawing=function(j5){k_Cdw.j1L();for(var e$=0;e$ < this.drawingObjects.length;e$++){if(this.drawingObjects[e$] == j5){k_Cdw.b8R(34);this.drawingObjects.splice(e$,k_Cdw.F9v(\"1\",0));this.changeOccurred(\"vector\");this.draw();return;}}};D5.ChartEngine.prototype.undo=function(){k_Cdw.y6g();var C2G,W7q;if(this.runPrepend(\"undo\",arguments)){return;}if(this.activeDrawing){C2G=\"stx\";C2G+=\"_crossha\";C2G+=\"ir\";W7q=\"stx\";W7q+=\"_\";W7q+=\"c\";W7q+=\"rosshair_drawing\";this.activeDrawing.abort();this.activeDrawing.hidden=!\"1\";this.drawingSnapshot=null;this.activateDrawing(null);D5.clearCanvas(this.chart.tempCanvas,this);this.draw();this.controls.crossX.classList.replace(W7q,\"stx_crosshair\");this.controls.crossY.classList.replace(\"stx_crosshair_drawing\",C2G);D5.ChartEngine.drawingLine=!({});}this.runAppend(\"undo\",arguments);};D5.ChartEngine.prototype.undoStamp=function(B7,w9){this.undoStamps.push(B7);this.dispatch(\"undoStamp\",{before:B7,after:w9,stx:this});};D5.ChartEngine.prototype.undoLast=function(){if(this.activeDrawing){this.undo();}else {if(this.undoStamps.length){this.drawingObjects=[];this.importDrawings(this.undoStamps.pop());this.changeOccurred(\"vector\");this.draw();}}};D5.ChartEngine.prototype.addDrawing=function(s8){var v$;v$=this.exportDrawings();this.drawingObjects.push(s8);this.undoStamp(v$,this.exportDrawings());};D5.ChartEngine.prototype.repositionDrawing=function(p_,S7){var y$,p5,r$;if(this.currentPanel.name != p_.panelName){return;}y$=this.panels[p_.panelName];p5=this.adjustIfNecessary(y$,this.crosshairTick,p_.valueFromPixel(this.backOutY(D5.ChartEngine.crosshairY),y$,this.getYAxisByField(y$,p_.field)));r$=this.chart.tempCanvas;k_Cdw.j1L();D5.clearCanvas(r$,this);if(S7){this.drawingSnapshot=this.exportDrawings();p_.render(r$.context);}else {p_.reposition(r$.context,p_.repositioner,this.crosshairTick,p5);if(this.drawingSnapshot){this.undoStamp(D5.shallowClone(this.drawingSnapshot),this.exportDrawings());}this.drawingSnapshot=null;}if(p_.measure){p_.measure();}};D5.ChartEngine.prototype.activateRepositioning=function(b5){var U40,Z3N,g3;U40=\"n\";U40+=\"one\";Z3N=\"b\";k_Cdw.y6g();Z3N+=\"l\";Z3N+=\"oc\";Z3N+=\"k\";g3=this.repositioningDrawing=b5;if(b5){this.draw();this.repositionDrawing(b5,!!1);}this.chart.tempCanvas.style.display=b5?Z3N:U40;};D5.ChartEngine.prototype.activateDrawing=function(V_,Z6){var W44,T1o,M2;W44=\"bl\";W44+=\"o\";W44+=\"ck\";if(!Z6){Z6=this.currentPanel;}this.drawingSnapshot=null;if(!V_){T1o=\"n\";T1o+=\"o\";T1o+=\"n\";T1o+=\"e\";this.activeDrawing=null;this.chart.tempCanvas.style.display=T1o;M1(this);return !1;}M2=D5.ChartEngine.drawingTools[V_];if(!M2){if(D5.Drawing[V_]){M2=D5.Drawing[V_];D5.ChartEngine.registerDrawingTool(V_,M2);}}if(M2){this.activeDrawing=new M2();this.activeDrawing.construct(this,Z6);if(!this.charts[Z6.name]){if(this.activeDrawing.chartsOnly){this.activeDrawing=null;M1(this);return !({});}}}this.chart.tempCanvas.style.display=W44;if(this.controls.drawOk){this.controls.drawOk.style.display=\"none\";}function M1(t6){var n7;if(!t6.layout.studies){return;}n7=t6.layout.studies[Z6.name];if(n7 && !n7.overlay){delete t6.overlays[n7.name];}}M1(this);return !![];};D5.ChartEngine.prototype.drawingClick=function(p4,Y7,z5){var z8f,I9,q_,Q4,O8,e3,c0,i9M,L_W;if(!D5.Drawing){return;}if(!p4){return;}if(this.openDialog !== \"\"){return;}if(!this.activeDrawing){if(!this.activateDrawing(this.currentVectorParameters.vectorType,p4)){return;}}if(this.activeDrawing){if(this.userPointerDown && !this.activeDrawing.dragToDraw){if(!D5.ChartEngine.drawingLine){this.activateDrawing(null);}return;}else if(!this.activeDrawing.p0){z8f=\"C\";z8f+=\"l\";z8f+=\"o\";z8f+=\"se\";I9=this.highlightedDataSetField;if(this.magnetizedPrice !== null && (p4 !== this.chart.panel || [\"Open\",\"High\",\"Low\",z8f].indexOf(this.magneticHold) < 0)){I9=D5.getObjectChainRoot(this.magneticHold);}if(!I9 && p4 != this.chart.panel){for(var G7 in this.chart.seriesRenderers){q_=this.chart.seriesRenderers[G7];if(q_.params.panel == p4.name){I9=q_.seriesParams[0].field;break;}}for(var J$ in this.layout.studies){Q4=this.layout.studies[J$];if(Q4.panel == p4.name){I9=Object.keys(Q4.outputMap)[0];break;}}}this.activeDrawing.field=I9;}O8=this.tickFromPixel(Y7,p4.chart);e3=this.panels[this.activeDrawing.panelName];if(this.magnetizedPrice || this.magnetizedPrice === 0){c0=this.adjustIfNecessary(e3,O8,this.magnetizedPrice);}else {c0=this.adjustIfNecessary(e3,O8,this.activeDrawing.valueFromPixel(z5,e3,this.getYAxisByField(e3,this.activeDrawing.field)));}if(this.activeDrawing.click(this.chart.tempCanvas.context,O8,c0)){if(this.activeDrawing){i9M=\"stx_crosshair_d\";i9M+=\"rawing\";L_W=\"stx\";L_W+=\"_c\";L_W+=\"rosshair\";L_W+=\"_drawing\";D5.ChartEngine.drawingLine=!({});D5.clearCanvas(this.chart.tempCanvas,this);this.addDrawing(this.activeDrawing);D5.ChartEngine.completeDrawing(this);this.activateDrawing(null);this.adjustDrawings();this.draw();this.changeOccurred(\"vector\");this.controls.crossX.classList.replace(L_W,\"stx_crosshair\");this.controls.crossY.classList.replace(i9M,\"stx_crosshair\");}}else {this.changeOccurred(\"drawing\");D5.ChartEngine.drawingLine=!![];this.controls.crossX.classList.replace(\"stx_crosshair\",\"stx_crosshair_drawing\");this.controls.crossY.classList.replace(\"stx_crosshair\",\"stx_crosshair_drawing\");}return !!({});}return ![];};D5.ChartEngine.prototype.rightClickDrawing=function(u8,m7,g2){var A7S,J4,v8;if(this.runPrepend(\"rightClickDrawing\",arguments)){return;}if(u8.permanent){return;}k_Cdw.j1L();if(this.callbackListeners.drawingEdit.length){A7S=\"draw\";A7S+=\"i\";A7S+=\"ngEdit\";this.dispatch(A7S,{stx:this,drawing:u8,forceEdit:m7,forceText:g2});}else {J4=u8.abort();if(!J4){v8=this.exportDrawings();this.removeDrawing(u8);this.undoStamp(v8,this.exportDrawings());}this.changeOccurred(\"vector\");}this.runAppend(\"rightClickDrawing\",arguments);};D5.ChartEngine.prototype.magnetize=function(){var z6y=k_Cdw;var a5N,D7c,y7_,A52,V2V,g9,A_Q,v49,X_,S8m,u8L,q2K,W6,H6w,p7C,u_u,r8i,m2d,S5p,i4D,i1D,A1n,u7M,d6j,m4M,l8,A1U;a5N=\"stx-d\";a5N+=\"r\";a5N+=\"aggable\";D7c=\"blo\";D7c+=\"c\";D7c+=\"k\";y7_=\"O\";y7_+=\"pen\";A52=\"p\";A52+=\"r\";A52+=\"oje\";A52+=\"ction\";V2V=\"ma\";V2V+=\"gnetiz\";V2V+=\"e\";g9=this;this.magnetizedPrice=null;if(!this.preferences.magnet){return;}if(this.runPrepend(V2V,arguments)){return;}if(this.repositioningDrawing){return;}A_Q=this.currentVectorParameters.vectorType;if(!A_Q || A_Q == A52 || A_Q == \"freeform\"){return;}if((A_Q == \"annotation\" || A_Q == \"callout\") && D5.ChartEngine.drawingLine){return;}v49=this.activeDrawing?this.panels[this.activeDrawing.panelName]:this.currentPanel;X_=v49.chart;S8m=this.crosshairTick;if(S8m > X_.dataSet.length){return;}u8L=X_.dataSet[S8m];if(!u8L){return;}W6=this.getRenderedItems();H6w=[y7_,\"High\",\"Low\",\"Close\"];if(this.activeDrawing && this.activeDrawing.penDown){if(this.magneticHold){p7C=\"H\";p7C+=\"i\";p7C+=\"g\";p7C+=\"h\";if(H6w.indexOf(this.magneticHold) != -+\"1\" && W6.indexOf(p7C) != -1){W6=H6w;}else {W6=[this.magneticHold];}}else {return;}}else {this.magneticHold=null;}u_u=1000000000;r8i=parseFloat(this.preferences.magnet);m2d=function(){var k_f,A$V;S5p=g9.getYAxisByField(v49,W6[M_p]) || v49.yAxis;i4D=X_.transformFunc && S5p === X_.yAxis;if(i4D && u8L.transform){u8L=u8L.transform;}i1D=u8L[W6[M_p]];A1n=D5.existsInObjectChain(u8L,W6[M_p]);if(A1n){i1D=A1n.obj[A1n.member];}if(i1D || i1D === 0){u7M=g9.pixelFromTransformedValue(i1D,v49,S5p);if(Math.abs(g9.cy - u7M) < u_u){u_u=Math.abs(g9.cy - u7M);if(r8i && r8i <= u_u){return 1;}g9.magnetizedPrice=i1D;if(i4D){k_f=X_.untransformFunc;A$V=D5.getObjectChainRoot(W6[M_p]);if(k_f && X_.series[A$V]){X_.untransformFunc=(W8m,O6g,m6G,o$3)=>{return k_f(W8m,O6g,m6G,o$3,A$V);};}g9.magnetizedPrice=g9.valueFromPixel(u7M,v49);X_.untransformFunc=k_f;}q2K=u7M;g9.magneticHold=W6[M_p];}}};for(var M_p=0;M_p < W6.length;M_p++){if(m2d())continue;}d6j=this.pixelFromTick(S8m,X_);m4M=q2K;D5.clearCanvas(X_.tempCanvas,this);l8=X_.tempCanvas.context;l8.beginPath();l8.lineWidth=1;z6y.G4m(19);z6y.j1L();var e$J=z6y.e7l(5,7,6,20);z6y.G4m(0);var Y9m=z6y.e7l(2,1);A1U=Math.max(this.layout.candleWidth,e$J) / Y9m;l8.arc(d6j,m4M,Math.min(A1U,\"8\" ^ 0),\"0\" * 1,+\"2\" * Math.PI,!!0);l8.fillStyle=\"#398dff\";l8.strokeStyle=\"#398dff\";l8.fill();l8.stroke();l8.closePath();X_.tempCanvas.style.display=D7c;if(this.anyHighlighted){this.container.classList.remove(a5N);}if(this.activeDrawing){this.activeDrawing.move(l8,this.crosshairTick,this.activeDrawing.valueFromPixel(m4M,v49,this.getYAxisByField(v49,this.activeDrawing.field)));}this.runAppend(\"magnetize\",arguments);};D5.ChartEngine.prototype.changeVectorType=function(E1p){var k_i,s7s,L03;k_i=\"st\";k_i+=\"x-cros\";k_i+=\"shair\";k_i+=\"-on\";this.currentVectorParameters.vectorType=E1p;if(D5.Drawing){D5.Drawing.initializeSettings(this,E1p);}if(D5.ChartEngine.drawingLine){this.undo();}if(!this.container.classList.contains(k_i) && E1p){var {chart:h$Y, left:n$y, top:B8f}=this;s7s=h$Y.width / (\"2\" ^ 0) + n$y + h$Y.left;k_Cdw.G4m(29);var t28=k_Cdw.e7l(7,8,16,12,1334);L03=h$Y.height / t28 + B8f + h$Y.top;this.mousemoveinner(s7s,L03);}k_Cdw.j1L();this.doDisplayCrosshairs();};D5.ChartEngine.prototype.changeVectorParameter=function(E4V,J7I){var M9h,O2b;M9h=\"p\";M9h+=\"x\";if(E4V == \"axisLabel\"){J7I=J7I.toString() === \"true\" || Number(J7I);}else if(E4V == \"lineWidth\"){J7I=Number(J7I);}else if(E4V == \"fontSize\"){k_Cdw.G4m(35);var l5X=k_Cdw.F9v(16,2,4,11,19);J7I=parseInt(J7I,l5X) + M9h;}O2b=this.currentVectorParameters;if(typeof O2b[E4V] !== \"undefined\"){O2b[E4V]=J7I;return !!({});}else if(E4V.substr(0,4) == \"font\"){E4V=E4V.substr(4).toLowerCase();if(E4V == \"family\" && J7I.toLowerCase() == \"default\"){J7I=null;}O2b=O2b.annotation.font;if(typeof O2b[E4V] !== \"undefined\"){O2b[E4V]=J7I;return !!\"1\";}}k_Cdw.y6g();return !({});};D5.ChartEngine.prototype.drawVectors=function(){var a$r,w18,F7U,r7Z,e0Z;if(this.vectorsShowing){return;}if(this.runPrepend(\"drawVectors\",arguments)){return;}this.vectorsShowing=!!1;if(!this.chart.hideDrawings && !this.highlightedDraggable){a$r={};for(F7U=0;F7U < this.drawingObjects.length;F7U++){r7Z=this.drawingObjects[F7U];if(r7Z.hidden)continue;if(this.repositioningDrawing === r7Z)continue;w18=r7Z.panelName;if(!this.panels[r7Z.panelName] || this.panels[r7Z.panelName].hidden)continue;if(!a$r[w18]){a$r[w18]=[];}a$r[w18].push(r7Z);}for(w18 in a$r){this.startClip(w18);e0Z=a$r[w18];for(F7U=0;F7U < e0Z.length;F7U++){e0Z[F7U].render(this.chart.context);}this.endClip();}}this.runAppend(\"drawVectors\",arguments);};D5.ChartEngine.prototype.adjustDrawings=function(){k_Cdw.j1L();var N8k;for(var J3h=0;J3h < this.drawingObjects.length;J3h++){N8k=this.drawingObjects[J3h];if(this.panels[N8k.panelName]){N8k.adjust();}}};D5.Drawing=D5.Drawing || (function(){this.chartsOnly=!!0;k_Cdw.y6g();this.penDown=!!0;});D5.Drawing.getDrawingParameters=function(m60,A$h){var m$h,A$r,d1L,z8A;try{m$h=new D5.Drawing[A$h]();}catch(P0X){}k_Cdw.j1L();if(!m$h){return null;}m$h.stx=m60;m$h.copyConfig(!!1);A$r={};d1L=m$h.configs;for(var i$z=0;i$z < d1L.length;i$z++){A$r[d1L[i$z]]=m$h[d1L[i$z]];}z8A=m60.canvasStyle(\"stx_annotation\");if(z8A && A$r.font){A$r.font.size=z8A.fontSize;A$r.font.family=z8A.fontFamily;A$r.font.style=z8A.fontStyle;A$r.font.weight=z8A.fontWeight;}return A$r;};D5.Drawing.saveConfig=function(s0A,M4h){var e1L,m59,L_0;e1L=\"pr\";e1L+=\"ef\";e1L+=\"ere\";e1L+=\"nces\";if(!M4h){return;}m59=s0A.preferences;if(!m59.drawings){m59.drawings={};}m59.drawings[M4h]={};L_0=new D5.Drawing[M4h]();L_0.stx=s0A;D5.Drawing.copyConfig(L_0);L_0.configs.forEach(function(F5x){m59.drawings[M4h][F5x]=L_0[F5x];});s0A.changeOccurred(e1L);};D5.Drawing.restoreDefaultConfig=function(H9h,p2A,b3y){if(b3y){H9h.preferences.drawings=null;}else {H9h.preferences.drawings[p2A]=null;}H9h.changeOccurred(\"preferences\");H9h.currentVectorParameters=D5.clone(D5.ChartEngine.currentVectorParameters);H9h.currentVectorParameters.vectorType=p2A;};D5.Drawing.initializeSettings=function(R1n,J$$){var J9x,o3E;J9x=D5.Drawing[J$$];if(J9x){o3E=new J9x();if(o3E.initializeSettings){o3E.initializeSettings(R1n);}}};D5.Drawing.updateSource=function(r4H,K1n,M3A,O9b){var D0X,d7Y;if(!K1n){return;}D0X=!\"1\";for(var k9d in r4H.drawingObjects){d7Y=r4H.drawingObjects[k9d];if(!d7Y.field)continue;if(M3A){if(d7Y.field == K1n){d7Y.field=M3A;D0X=!!\"1\";}else if(d7Y.field.indexOf(K1n) > -(\"1\" | 0) && d7Y.field.indexOf(K1n + \"-\") == -1){d7Y.field=d7Y.field.replace(K1n,M3A);D0X=!\"\";}}else {if(d7Y.field.split(\"-->\")[0] == K1n || d7Y.panelName == K1n){d7Y.panelName=O9b;D0X=!!({});}}}if(D0X){r4H.changeOccurred(\"vector\");}};D5.Drawing.prototype.copyConfig=function(L7z){D5.Drawing.copyConfig(this,L7z);};D5.Drawing.copyConfig=function(p27,i35){var S5K,Y5O,z$Z,h2x,d6y,F6o;S5K=p27.stx.currentVectorParameters;Y5O=p27.configs;for(z$Z=\"0\" | 0;z$Z < Y5O.length;z$Z++){d6y=\"p\";d6y+=\"arameters\";h2x=Y5O[z$Z];if(h2x == \"color\"){p27.color=S5K.currentColor;}else if(h2x == d6y){p27.parameters=D5.clone(S5K.fibonacci);}else if(h2x == \"font\"){p27.font=D5.clone(S5K.annotation.font);}else {p27[h2x]=S5K[h2x];}}if(!i35){return;}F6o=p27.stx.preferences;if(F6o && F6o.drawings){D5.extend(p27,F6o.drawings[S5K.vectorType]);for(z$Z=0;z$Z < Y5O.length;z$Z++){h2x=Y5O[z$Z];if(h2x == \"color\"){S5K.currentColor=p27.color;}else if(h2x == \"parameters\"){S5K.fibonacci=D5.clone(p27.parameters);}else if(h2x == \"font\"){S5K.annotation.font=D5.clone(p27.font);}else {S5K[h2x]=p27[h2x];}}}};D5.Drawing.prototype.dragToDraw=!({});D5.Drawing.prototype.permanent=!({});D5.Drawing.prototype.chartsOnly=!!0;D5.Drawing.prototype.abort=function(L9X){};D5.Drawing.prototype.measure=function(){};D5.Drawing.prototype.construct=function(y4A,Z_d){this.stx=y4A;this.panelName=Z_d.name;};D5.Drawing.prototype.isAllowed=function(c91,I6W){return !0;};D5.Drawing.prototype.render=function(I4T){k_Cdw.y6g();console.warn(\"must implement render function!\");};D5.Drawing.prototype.click=function(l3G,W7w,R3O){k_Cdw.j1L();console.warn(\"must implement click function!\");};D5.Drawing.prototype.move=function(x8E,J00,p3g){console.warn(\"must implement move function!\");};D5.Drawing.prototype.reposition=function(W72,a41,S_N,w5r){};D5.Drawing.prototype.intersected=function(M98,y4z,h9h){console.warn(\"must implement intersected function!\");};D5.Drawing.prototype.reconstruct=function(T40,a8P){console.warn(\"must implement reconstruct function!\");};D5.Drawing.prototype.serialize=function(){console.warn(\"must implement serialize function!\");};D5.Drawing.prototype.adjust=function(){console.warn(\"must implement adjust function!\");};D5.Drawing.prototype.highlight=function(W5j){if(W5j && !this.highlighted){this.highlighted=W5j;}else if(!W5j && this.highlighted){this.highlighted=W5j;}return this.highlighted;};D5.Drawing.prototype.littleCircleRadius=function(){var y0D;y0D=6;k_Cdw.j1L();return y0D;};D5.Drawing.prototype.littleCircle=function(R3c,a44,a5J,Z65){var y7y,t5o;if(this.permanent){return;}y7y=this.stx.defaultColor;t5o=D5.chooseForegroundColor(y7y);R3c.beginPath();R3c.lineWidth=1;R3c.arc(a44,a5J,this.littleCircleRadius(),0,2 * Math.PI,!!0);if(Z65){R3c.fillStyle=y7y;}else {R3c.fillStyle=t5o;}R3c.strokeStyle=y7y;R3c.setLineDash([]);R3c.fill();R3c.stroke();R3c.closePath();};D5.Drawing.prototype.rotator=function(g_L,a3m,q5j,y5j){var a6d=k_Cdw;var p28,U$9,A0L;if(this.permanent){return;}p28=this.littleCircleRadius();U$9=this.stx.defaultColor;g_L.beginPath();g_L.lineWidth=2;if(!y5j){g_L.globalAlpha=0.5;}a6d.G4m(36);A0L=a6d.F9v(1,p28,\"4\");g_L.arc(a3m,q5j,A0L,0,3 * Math.PI / 2,![]);a6d.G4m(14);g_L.moveTo(a6d.e7l(a3m,A0L,2),a6d.e7l(q5j,2,a6d.G4m(0)));a6d.b8R(0);g_L.lineTo(a6d.F9v(a3m,A0L),q5j);a6d.b8R(11);g_L.lineTo(a6d.F9v(a3m,2,A0L),a6d.e7l(q5j,2,a6d.G4m(0)));a6d.G4m(4);g_L.moveTo(a6d.F9v(a3m,2),a6d.e7l(\"2\",A0L,q5j,a6d.b8R(37)));a6d.j1L();a6d.G4m(4);g_L.lineTo(a3m,a6d.e7l(q5j,A0L));a6d.b8R(4);g_L.lineTo(a6d.F9v(a3m,2),a6d.e7l(2,q5j,A0L,a6d.b8R(18)));g_L.strokeStyle=U$9;g_L.stroke();g_L.closePath();g_L.globalAlpha=1;};D5.Drawing.prototype.mover=function(r$U,i1H,Z5l,s8c){var u0j=k_Cdw;var g2y,T$q,w8n,w1M;if(this.permanent){return;}g2y=this.littleCircleRadius();T$q=this.stx.defaultColor;w8n=5;u0j.b8R(0);w1M=u0j.F9v(g2y,1);r$U.save();r$U.lineWidth=+\"2\";r$U.strokeStyle=T$q;r$U.translate(i1H,Z5l);if(!s8c){r$U.globalAlpha=0.5;}for(var J1W=0;J1W < 4;J1W++){r$U.rotate(Math.PI / +\"2\");r$U.beginPath();u0j.b8R(34);r$U.moveTo(u0j.F9v(\"0\",0),w1M);u0j.b8R(34);r$U.lineTo(u0j.e7l(\"0\",0),u0j.F9v(w1M,w8n,u0j.b8R(0)));u0j.b8R(3);r$U.moveTo(-u0j.e7l(\"2\",1),u0j.F9v(\"2\",w1M,w8n,u0j.b8R(38)));u0j.G4m(0);r$U.lineTo(0,u0j.e7l(w1M,w8n));u0j.b8R(17);r$U.lineTo(2,u0j.F9v(w1M,w8n,2));r$U.closePath();r$U.stroke();}r$U.globalAlpha=+\"1\";r$U.restore();};D5.Drawing.prototype.resizer=function(C9O,c6b,W7F,R6q){var J7v=k_Cdw;var z$i,l6P,H5t,w3m;if(this.permanent){return;}z$i=this.littleCircleRadius();l6P=this.stx.defaultColor;J7v.G4m(39);var q2Z=J7v.e7l(18,10,16,14,15);J7v.b8R(40);var G7m=J7v.e7l(1,10,12,0);H5t=q2Z * Math.sqrt(G7m);J7v.G4m(0);w3m=J7v.F9v(z$i,1);C9O.save();J7v.b8R(4);C9O.lineWidth=J7v.F9v(\"2\",0);C9O.strokeStyle=l6P;C9O.translate(c6b,W7F);C9O.rotate(-(c6b * W7F) / Math.abs(c6b * W7F) * Math.PI / 4);if(!R6q){C9O.globalAlpha=0.5;}for(var K1_=0;K1_ < +\"2\";K1_++){C9O.rotate(Math.PI);C9O.beginPath();C9O.moveTo(0,w3m);J7v.G4m(0);C9O.lineTo(0,J7v.e7l(w3m,H5t));J7v.G4m(17);C9O.moveTo(-2,J7v.e7l(w3m,H5t,2));J7v.G4m(0);C9O.lineTo(0,J7v.e7l(w3m,H5t));J7v.b8R(17);C9O.lineTo(2,J7v.F9v(w3m,H5t,2));C9O.closePath();C9O.stroke();}C9O.globalAlpha=1;C9O.restore();};D5.Drawing.prototype.pointIntersection=function(E2I,S_3,M9b,d4k){var l7b,x5L;l7b=this.stx;x5L=l7b.panels[this.panelName];if(!x5L){return !({});}if(this.field && !d4k){S_3=this.pixelFromValue(x5L,E2I,S_3,l7b.getYAxisByField(x5L,this.field));E2I=l7b.pixelFromTick(E2I,x5L.chart);d4k=!!({});}if(d4k){if(E2I >= M9b.cx0 && E2I <= M9b.cx1 && S_3 >= M9b.cy0 && S_3 <= M9b.cy1){return !!({});}}else {if(E2I >= M9b.x0 && E2I <= M9b.x1 && S_3 >= Math.min(M9b.y0,M9b.y1) && S_3 <= Math.max(M9b.y0,M9b.y1)){return !!({});}}return !({});};D5.Drawing.prototype.setPoint=function(P8D,F7V,S4g,U__){var D4n=k_Cdw;var R0_,W3g,i52,j26,w6K,Q0u,n7t,c$4,J9a,c0O,K3t;R0_=\"nu\";R0_+=\"m\";R0_+=\"b\";R0_+=\"er\";var {stx:W_M}=this;var {maxTicks:j8K = 100, dataSet:k63 = []}=U__ || W_M.chart || ({});W3g=-j8K;D4n.G4m(13);var d_F=D4n.e7l(10,9);i52=k63.length - d_F + j8K;j26=null;w6K=null;if(typeof F7V == R0_){j26=F7V;}else if(F7V.length >= 8){w6K=F7V;}else {j26=Number(F7V);}if(S4g || S4g === 0){D4n.G4m(0);this[D4n.F9v(\"v\",P8D)]=S4g;}if(j26 !== null){j26=Math.max(j26,W3g);j26=Math.min(j26,i52);Q0u=W_M.dateFromTick(j26,U__,!!1);D4n.b8R(0);this[D4n.e7l(\"tzo\",P8D)]=Q0u.getTimezoneOffset();D4n.b8R(0);this[D4n.F9v(4550 == 6070?\"z\":\"d\",P8D)]=D5.yyyymmddhhmmssmmm(Q0u);D4n.G4m(0);this[D4n.F9v((+\"6080\",832.88) < (5560,663.61)?!({}):\"p\",P8D)]=[j26,S4g];}else if(w6K !== null){n7t=\"t\";n7t+=\"zo\";c$4=\"tz\";c$4+=\"o\";J9a=D5.strToDateTime(w6K);if(!this[\"tzo\" + P8D] && this[c$4 + P8D] !== +\"0\"){D4n.G4m(0);this[D4n.F9v(\"tzo\",P8D)]=J9a.getTimezoneOffset();}D4n.b8R(0);this[D4n.F9v(+\"3653\" == +\"2155\"?(6.90e+3,\"a\"):500.84 !== (8190,\"9400\" * 1)?\"d\":0x283,P8D)]=w6K;c0O=this[n7t + P8D] - J9a.getTimezoneOffset();J9a.setMinutes(J9a.getMinutes() + c0O);K3t=!!\"\";if(this.name != \"freeform\" && !D5.ChartEngine.isDailyInterval(W_M.layout.interval) && !J9a.getHours() && !J9a.getMinutes() && !J9a.getSeconds() && !J9a.getMilliseconds()){K3t=!\"\";}D4n.G4m(0);this[D4n.F9v(\"p\",P8D)]=[W_M.tickFromDate(D5.yyyymmddhhmmssmmm(J9a),U__,null,K3t),S4g];}};D5.Drawing.prototype.getLineColor=function(R3u,a8z){var E3Z,K_k,F7n,z0y,O5J,k37,m8k,h23,K2T,L3w,B4c,x6r;E3Z=\"a\";E3Z+=\"u\";E3Z+=\"to\";K_k=\"au\";K_k+=\"t\";K_k+=\"o\";if(!R3u){R3u=this.color;}F7n=this.stx;z0y=R3u;if(!a8z && this.highlighted){O5J=\"stx\";O5J+=\"_highlight_ve\";O5J+=\"ctor\";z0y=F7n.getCanvasColor(O5J);}else if(D5.isTransparent(z0y)){z0y=F7n.defaultColor;}else if(z0y == K_k){z0y=F7n.defaultColor;if(this.field){for(k37 in F7n.layout.studies){m8k=F7n.layout.studies[k37];h23=m8k.outputs[m8k.outputMap[this.field]];if(h23){z0y=h23.color || h23;break;}}for(k37 in F7n.chart.seriesRenderers){L3w=F7n.chart.seriesRenderers[k37];for(var p2k=0;p2k < L3w.seriesParams.length;p2k++){B4c=L3w.seriesParams[p2k];x6r=B4c.field;if(!x6r && !L3w.highLowBars){x6r=this.defaultPlotField || \"Close\";}if(B4c.symbol && B4c.subField){x6r+=\"-->\" + B4c.subField;}if(this.field == x6r){z0y=B4c.color;break;}if(B4c.field && B4c.field == this.field.split(\"-->\")[+\"0\"]){K2T=B4c.color;}}}if(K2T){z0y=K2T;}}}if(z0y == E3Z){z0y=F7n.defaultColor;}return z0y;};D5.Drawing.prototype.valueFromPixel=function(x9d,X_R,U9m){var k6k=k_Cdw;var p6E,J0j,I2M,J6V,q7w,l4J;p6E=X_R.chart.untransformFunc;k6k.j1L();J0j=this.field;I2M=-1196961821;J6V=-1069618572;q7w=+\"2\";for(var W_Q=1;k6k.m1(W_Q.toString(),W_Q.toString().length,43339) !== I2M;W_Q++){if(p6E && X_R.chart.series[J0j]){X_R.chart.untransformFunc=(x5y,b8i,n_e,n5n)=>{k6k.y6g();return p6E(x5y,b8i,n_e,n5n,J0j);};}l4J=this.stx.valueFromPixel(x9d,X_R,U9m);X_R.chart.untransformFunc=p6E;return l4J;}if(k6k.m1(q7w.toString(),q7w.toString().length,36958) !== J6V){if(p6E || X_R.chart.series[J0j]){X_R.chart.untransformFunc=(x5y,b8i,n_e,n5n)=>{return p6E(x5y,b8i,n_e,n5n,J0j);};}l4J=this.stx.valueFromPixel(x9d,X_R,U9m);X_R.chart.untransformFunc=p6E;return l4J;}};D5.Drawing.prototype.pixelFromValue=function(Z9Z,d09,B_y,z4B){var K6q,D8T,y53;K6q=Z9Z.chart.transformFunc;D8T=this.field;if(K6q && Z9Z.chart.series[D8T]){Z9Z.chart.transformFunc=(I6_,W_j,A3Z,v79)=>{return K6q(I6_,W_j,A3Z,v79,D8T);};}y53=this.stx.pixelFromValueAdjusted(Z9Z,d09,B_y,z4B);Z9Z.chart.transformFunc=K6q;return y53;};D5.Drawing.prototype.boxToPixels=function(X1S,j_n,E7g,y8S){var H2v,J3S,X2$,R1W;H2v=X1S.panels[j_n];k_Cdw.j1L();J3S=H2v.chart.transformFunc;X2$=this.field;if(J3S && H2v.chart.series[X2$]){H2v.chart.transformFunc=(J_U,A7I,k3F,G1E)=>{k_Cdw.y6g();return J3S(J_U,A7I,k3F,G1E,X2$);};}R1W=D5.convertBoxToPixels(X1S,j_n,E7g,y8S);H2v.chart.transformFunc=J3S;return R1W;};D5.Drawing.BaseTwoPoint=function(){var V8g,K7H,t4i;this.p0=null;V8g=-611609008;K7H=-166355683;t4i=2;for(var F2X=1;k_Cdw.P6(F2X.toString(),F2X.toString().length,85825) !== V8g;F2X++){this.p1=null;this.color=\"\";t4i+=2;}k_Cdw.j1L();if(k_Cdw.m1(t4i.toString(),t4i.toString().length,16836) !== K7H){this.p1=1;this.color=\"\";}};D5.inheritsFrom(D5.Drawing.BaseTwoPoint,D5.Drawing);D5.Drawing.BaseTwoPoint.prototype.configs=[];D5.Drawing.BaseTwoPoint.prototype.lineIntersection=function(j_H,U$7,s6F,c67,o8R,V0Y,H92){var b7z,I1Y;if(!o8R){o8R=this.p0;}if(!V0Y){V0Y=this.p1;}b7z=this.stx;if(!(o8R && V0Y)){return !({});}k_Cdw.y6g();if(s6F.cx0 === undefined){return ![];}I1Y={x0:o8R[0],x1:V0Y[0],y0:o8R[1],y1:V0Y[1]};if(!H92){I1Y=this.boxToPixels(b7z,this.panelName,I1Y,b7z.getYAxisByField(b7z.panels[this.panelName],this.field));}return D5.boxIntersects(s6F.cx0,s6F.cy0,s6F.cx1,s6F.cy1,I1Y.x0,I1Y.y0,I1Y.x1,I1Y.y1,c67);};D5.Drawing.BaseTwoPoint.prototype.boxIntersection=function(m8l,A$b,H5I){k_Cdw.y6g();var t3X,m7Z;if(!this.p0 || !this.p1){return !!0;}var {x0:J6z, x1:f6$, y0:k_A, y1:g97, cy0:E15, cy1:s22}=H5I;if(J6z > Math.max(this.p0[0],this.p1[0]) || f6$ < Math.min(this.p0[\"0\" << 64],this.p1[0])){return !!\"\";}var {field:z6k, panelName:U2I, stx:e1e}=this;if(z6k){t3X=e1e.panels[U2I];m7Z=e1e.getYAxisByField(t3X,z6k);k_A=this.valueFromPixel(E15,t3X,m7Z);g97=this.valueFromPixel(s22,t3X,m7Z);}if(g97 > Math.max(this.p0[\"1\" ^ 0],this.p1[1]) || k_A < Math.min(this.p0[\"1\" - 0],this.p1[1])){return ![];}return !\"\";};D5.Drawing.BaseTwoPoint.prototype.accidentalClick=function(H_m,X7z){var F_5=k_Cdw;var f18,j7b,S2N,P1y,l6O,d9t,C$r,C$w,s9g,f9_;f18=this.stx;j7b=f18.panels[this.panelName];S2N=f18.pixelFromTick(this.p0[0],j7b.chart);P1y=f18.pixelFromTick(H_m,j7b.chart);l6O=f18.getYAxisByField(j7b,this.field);d9t=this.pixelFromValue(j7b,this.p0[0],this.p0[\"1\" * 1],l6O);C$r=this.pixelFromValue(j7b,H_m,X7z,l6O);F_5.b8R(4);C$w=Math.abs(F_5.F9v(P1y,S2N));F_5.b8R(4);s9g=Math.abs(F_5.F9v(C$r,d9t));F_5.G4m(41);f9_=Math.sqrt(F_5.F9v(s9g,s9g,C$w,C$w));if(f9_ < 10){this.penDown=!1;f18.undo();return !!\"1\";}};D5.Drawing.BaseTwoPoint.prototype.click=function(R5X,t2v,v3O){var w_c,M8V;this.copyConfig();w_c=this.stx;M8V=w_c.panels[this.panelName];if(!this.penDown){this.setPoint(0,t2v,v3O,M8V.chart);this.penDown=!!1;return ![];}if(this.accidentalClick(t2v,v3O)){return !!({});}this.setPoint(1,t2v,v3O,M8V.chart);this.penDown=!1;return !0;};D5.Drawing.BaseTwoPoint.prototype.adjust=function(){var k40;k40=this.stx.panels[this.panelName];k_Cdw.j1L();if(!k40){return;}this.setPoint(0,this.d0,this.v0,k40.chart);this.setPoint(1,this.d1,this.v1,k40.chart);};D5.Drawing.BaseTwoPoint.prototype.move=function(M7_,t7$,j9U){if(!this.penDown){return;}this.copyConfig();this.p1=[t7$,j9U];this.render(M7_);};D5.Drawing.BaseTwoPoint.prototype.measure=function(){var d00,d0M,D$D,c0D,J4m;d00=this.stx;k_Cdw.j1L();if(this.p0 && this.p1){d00.setMeasure(this.p0[1],this.p1[1],this.p0[0],this.p1[0],!0,this.name);d0M=d00.controls.mSticky;D$D=d0M && d0M.querySelector(\".mStickyInterior\");if(D$D){c0D=\"Clos\";c0D+=\"e\";J4m=[];J4m.push(D5.capitalize(this.name));if(this.getYValue){J4m.push(this.field || d00.defaultPlotField || c0D);}J4m.push(D$D.innerHTML);D$D.innerHTML=J4m.join(\"
    \");}}};D5.Drawing.BaseTwoPoint.prototype.reposition=function(x29,z$a,C2b,r2P){k_Cdw.j1L();var O_v,D3g,O7x;if(!z$a){return;}O_v=this.stx.panels[this.panelName];D3g=z$a.tick - C2b;O7x=z$a.value - r2P;if(z$a.action == \"move\"){this.setPoint(0,z$a.p0[0] - D3g,z$a.p0[1] - O7x,O_v.chart);k_Cdw.b8R(42);this.setPoint(k_Cdw.F9v(\"1\",64),z$a.p1[0] - D3g,z$a.p1[\"1\" ^ 0] - O7x,O_v.chart);this.render(x29);}else if(z$a.action == \"drag\"){this[z$a.point]=[C2b,r2P];this.setPoint(+\"0\",this.p0[0],this.p0[1],O_v.chart);this.setPoint(1,this.p1[0],this.p1[1],O_v.chart);this.render(x29);}};D5.Drawing.BaseTwoPoint.prototype.drawDropZone=function(i3s,y79,F7F,a07,n0J){var Q4v=k_Cdw;var K2$,r_G,I9P,B_6,l47,f0V,g5y;K2$=this.stx.panels[this.panelName];if(!K2$){return;}r_G=this.stx;I9P=K2$.left;B_6=K2$.width;if(a07 || a07 === 0){I9P=r_G.pixelFromTick(a07,K2$.chart);}if(n0J || n0J === 0){B_6=r_G.pixelFromTick(n0J,K2$.chart);}l47=r_G.getYAxisByField(K2$,this.field);f0V=this.pixelFromValue(K2$,a07,y79,l47);g5y=this.pixelFromValue(K2$,n0J,F7F,l47);i3s.fillStyle=\"#008000\";i3s.globalAlpha=0.2;Q4v.G4m(4);i3s.fillRect(I9P,f0V,Q4v.e7l(B_6,I9P),Q4v.e7l(g5y,f0V));Q4v.b8R(4);i3s.globalAlpha=Q4v.e7l(\"1\",0);};D5.Drawing.BaseTwoPoint.prototype.valueOnDrawingAxis=function(o3B,y$N){var Z_E;var {stx:N9M, panelName:J71, field:J0K}=this;Z_E=N9M.panels[J71];return this.valueFromPixel(N9M.pixelFromValueAdjusted(Z_E,o3B,y$N),Z_E,N9M.getYAxisByField(Z_E,J0K));};D5.Drawing.annotation=function(){var z7k=k_Cdw;this.name=\"annotation\";this.arr=[];z7k.G4m(42);this.w=z7k.F9v(\"0\",64);this.h=0;z7k.G4m(1);this.padding=z7k.e7l(\"5\",0);this.text=\"\";this.ta=null;this.border=!![];this.fontSize=0;this.font={};this.defaultWidth=25;z7k.y6g();this.whitespace=30;this.fontModifier=3;};D5.inheritsFrom(D5.Drawing.annotation,D5.Drawing.BaseTwoPoint);D5.Drawing.annotation.prototype.getFontString=function(){var U1C,Y3h;this.fontDef={style:null,weight:null,size:\"12px\",family:null};U1C=this.stx.canvasStyle(\"stx_annotation\");if(U1C){if(U1C.fontStyle){this.fontDef.style=U1C.fontStyle;}if(U1C.fontWeight){this.fontDef.weight=U1C.fontWeight;}if(U1C.fontSize){this.fontDef.size=U1C.fontSize;}if(U1C.fontFamily){this.fontDef.family=U1C.fontFamily;}}if(this.font.style){this.fontDef.style=this.font.style;}if(this.font.weight){this.fontDef.weight=this.font.weight;}if(this.font.size){this.fontDef.size=this.font.size;}if(this.font.family){this.fontDef.family=this.font.family;}this.fontString=\"\";Y3h=!![];for(var s6t in this.fontDef){if(this.fontDef[s6t]){if(!Y3h){this.fontString+=\" \";}else {Y3h=!!0;}this.fontString+=this.fontDef[s6t];}}};D5.Drawing.annotation.prototype.configs=[Z5S,b$$];D5.Drawing.annotation.prototype.measure=function(){};D5.Drawing.annotation.prototype.render=function(x2Y){var k_K=k_Cdw;var W$_,S1i,p4e,W$7,N7P,R17,h3b,w7S,V0C,N7y,K7A,d5x,K0u,J98,C1X,G6n,H3B,j3d,z6Y,E4h;W$_=\"al\";k_K.y6g();W$_+=\"phabetic\";if(this.ta){return;}S1i=this.stx;p4e=S1i.panels[this.panelName];W$7=S1i.getYAxisByField(p4e,this.field);if(!p4e || this.field && !W$7){return;}N7P=S1i.pixelFromTick(this.p0[0],p4e.chart);R17=this.pixelFromValue(p4e,this.p0[0],this.p0[1],W$7);x2Y.font=this.fontString;x2Y.textBaseline=\"middle\";h3b=N7P;w7S=R17;V0C=this.w;N7y=this.h;K7A=this.getLineColor();if(this.stem){if(this.stem.d){d5x=S1i.pixelFromTick(this.stem.t);J98=this.pixelFromValue(p4e,this.stem.t,this.stem.v,W$7);k_K.G4m(43);K0u=k_K.F9v(V0C,2,h3b);k_K.b8R(43);C1X=k_K.e7l(N7y,2,w7S);}else if(this.stem.x){d5x=h3b;J98=w7S;h3b+=this.stem.x;w7S+=this.stem.y;k_K.b8R(43);K0u=k_K.e7l(V0C,2,h3b);k_K.G4m(43);C1X=k_K.e7l(N7y,2,w7S);}x2Y.beginPath();if(this.borderColor){x2Y.strokeStyle=this.borderColor;}else {x2Y.strokeStyle=K7A;}x2Y.moveTo(d5x,J98);x2Y.lineTo(K0u,C1X);x2Y.stroke();}G6n=x2Y.lineWidth;if(this.highlighted){H3B=\"stx_annotation_hig\";H3B+=\"hlight_bg\";S1i.canvasColor(H3B,x2Y);k_K.b8R(4);x2Y.fillRect(k_K.F9v(h3b,G6n),k_K.F9v(N7y,w7S,2,G6n,k_K.b8R(44)),k_K.e7l(G6n,\"2\",V0C,k_K.b8R(45)),k_K.e7l(G6n,2,N7y,k_K.b8R(26)));}else {if(this.fillColor){j3d=404257969;z6Y=788299381;E4h=2;for(var y4B=\"1\" | 1;k_K.m1(y4B.toString(),y4B.toString().length,46635) !== j3d;y4B++){x2Y.fillStyle=this.fillColor;k_K.b8R(46);x2Y.fillRect(h3b,k_K.e7l(N7y,6,w7S),V0C,N7y);E4h+=2;}if(k_K.m1(E4h.toString(),E4h.toString().length,16638) !== z6Y){x2Y.fillStyle=this.fillColor;k_K.G4m(47);x2Y.fillRect(h3b,k_K.e7l(\"2\",1,N7y,w7S),V0C,N7y);}}else if(this.stem){x2Y.fillStyle=S1i.containerColor;k_K.G4m(48);x2Y.fillRect(h3b,k_K.e7l(N7y,2,w7S),V0C,N7y);}}if(this.borderColor){x2Y.beginPath();x2Y.strokeStyle=this.highlighted?S1i.getCanvasColor(\"stx_highlight_vector\"):this.borderColor;k_K.b8R(4);x2Y.rect(k_K.e7l(h3b,G6n),k_K.e7l(64,G6n,w7S,N7y,\"2\",k_K.b8R(49)),k_K.F9v(G6n,\"2\",32,V0C,k_K.G4m(50)),k_K.F9v(G6n,2,N7y,k_K.b8R(26)));x2Y.stroke();}if(this.highlighted){S1i.canvasColor(\"stx_annotation_highlight\",x2Y);}else {x2Y.fillStyle=K7A;}k_K.b8R(51);var c_J=k_K.F9v(21,2,84,16);w7S+=this.padding / c_J;if(!this.ta){for(var R__=+\"0\";R__ < this.arr.length;R__++){x2Y.fillText(this.arr[R__],h3b + this.padding,w7S - N7y / 2 + this.fontSize / 2);k_K.b8R(52);var b7s=k_K.e7l(1,10,34,5,18);w7S+=this.fontSize + b7s;}}x2Y.textBaseline=W$_;};D5.Drawing.annotation.prototype.onChange=function(y5V){};D5.Drawing.annotation.prototype.edit=function(L2I,l78){var v74=k_Cdw;var e28,T5e,g5b,j4l,n$p,d6i,J1_,Q6V,l8R,d8y,r3_,d9$,Z69,l2v,L1J,y2N,P_D,h_I,N8R,Q2B,m2s,S3R;function z9B(l$Y){v74.y6g();return function(d52){if(l$Y.manageTouchAndMouse && D5.ChartEngine.drawingLine){l$Y.mouseup(d52);}};}e28=\"p\";e28+=\"x\";T5e=\"annotat\";T5e+=\"io\";T5e+=\"n\";g5b=this.stx.panels[this.panelName];if(!g5b){return;}j4l=this.stx.controls.annotationSave;n$p=this.stx.controls.annotationCancel;if(!j4l || !n$p){return;}d6i=this.stx;J1_=this.ta;d6i.editingAnnotation=!!1;function X_K(s6d){return function(C9E){var N7r;N7r=s6d.stx;N7r.editingAnnotation=!!\"\";N7r.undo();N7r.cancelTouchSingleClick=!!\"1\";};}function M87(s2B){v74.y6g();return function(j8W){var d6m;if(s2B.ta.value === \"\"){return;}s2B.text=s2B.ta.value;d6m=s2B.stx;d6m.editingAnnotation=!({});s2B.adjust();if(d6m.drawingSnapshot){d6m.undoStamp(D5.shallowClone(d6m.drawingSnapshot),d6m.exportDrawings());}else {D5.ChartEngine.completeDrawing(d6m);d6m.addDrawing(s2B);}d6m.undo();d6m.cancelTouchSingleClick=!!1;d6m.changeOccurred(\"vector\");};}d6i.undisplayCrosshairs();d6i.openDialog=T5e;if(!J1_){Q6V=\"har\";Q6V+=\"d\";l8R=\"w\";l8R+=\"ra\";l8R+=\"p\";J1_=this.ta=document.createElement(\"TEXTAREA\");J1_.className=\"stx_annotation\";J1_.onkeyup=E1d(this);J1_.onmouseup=z9B(d6i);J1_.setAttribute(l8R,Q6V);if(D5.isIOS7or8){J1_.setAttribute(\"placeholder\",\"Enter Text\");}d6i.chart.container.appendChild(J1_);J1_.style.position=\"absolute\";J1_.style.paddingLeft=this.padding + \"px\";J1_.value=this.text;if(D5.touchDevice){J1_.ontouchstart=function(K03){v74.y6g();K03.stopPropagation();};}}d8y=this;J1_.oninput=function(N$u){if(N$u.inputType != \"historyUndo\" && N$u.inputType != \"historyRedo\"){d8y.onChange(N$u);}};J1_.style.font=this.fontString;if(this.color){if(this.color == \"transparent\" || this.color == \"auto\"){r3_=getComputedStyle(J1_);if(r3_ && D5.isTransparent(r3_.backgroundColor)){d9$=-163026662;Z69=-1929117023;l2v=2;for(var N4V=1;v74.m1(N4V.toString(),N4V.toString().length,+\"87762\") !== d9$;N4V++){J1_.style.color=this.getLineColor();l2v+=2;}if(v74.P6(l2v.toString(),l2v.toString().length,93905) !== Z69){J1_.style.color=this.getLineColor();}}else {L1J=\"#00\";L1J+=\"0\";J1_.style.color=L1J;}}else {J1_.style.color=this.color;}}y2N=d6i.pixelFromTick(this.p0[\"0\" >> 32],g5b.chart);P_D=this.pixelFromValue(g5b,this.p0[0],this.p0[\"1\" - 0],d6i.getYAxisByField(g5b,this.field));v74.y6g();J1_.style.left=y2N + 140 < d6i.chart.canvasRight?y2N + e28:d6i.chart.canvasRight - 200 + \"px\";J1_.style.top=P_D + 60 < d6i.chart.canvasHeight?P_D - (!isNaN(this.h)?this.h / 2:this.defaultHeight) + \"px\":P_D - 60 + \"px\";if(this.repositionTextArea){this.repositionTextArea(J1_);}D5.safeClickTouch(j4l,M87(this));D5.safeClickTouch(n$p,X_K(this));E1d(this)();function E1d(G4J){v74.y6g();return function(U2c){var H9c,t32,L3U,C29,v3y,A3o,z3y,G31,i92,C3T,l4i,N_0,T0j,o7v,k$6,a_a,R7L,X8K;H9c=\"n\";H9c+=\"o\";H9c+=\"ne\";t32=\"p\";t32+=\"x\";if(U2c){L3U=U2c.keyCode;switch(L3U){case +\"27\":G4J.stx.undo();return;}}C29=G4J.stx;v3y=G4J.ta;A3o=v3y.value.split(4505 > 4120?\"\\n\":(412.98,+\"7654\") === (436.04,874)?\"5.46e+3\" ^ 0:0xd09);z3y=0;C29.chart.context.font=G4J.fontString;for(var c$N=+\"0\";c$N < A3o.length;c$N++){G31=C29.chart.context.measureText(A3o[c$N]).width;if(G31 > z3y){z3y=G31;}}v74.G4m(53);var c9Y=v74.F9v(15,15,61,5);i92=(A3o.length + c9Y) * (G4J.fontSize + G4J.fontModifier);z3y=Math.max(z3y,G4J.defaultWidth * 2);v3y.style.width=z3y + G4J.whitespace + \"px\";v74.G4m(0);v3y.style.height=v74.F9v(i92,t32);C3T=parseInt(D5.stripPX(v3y.style.top),10);l4i=D5.stripPX(v3y.style.left);z3y=v3y.clientWidth;i92=v3y.clientHeight;v3y.focus();if(G4J.border === !!0){v3y.style.border=H9c;}if(l4i + z3y + 100 < G4J.stx.chart.canvasWidth){N_0=\"p\";N_0+=\"x\";T0j=\"inline-bl\";T0j+=\"ock\";o7v=\"p\";o7v+=\"x\";v74.b8R(0);j4l.style.top=v74.F9v(C3T,\"px\");v74.b8R(0);n$p.style.top=v74.F9v(C3T,\"px\");v74.G4m(2);j4l.style.left=v74.F9v(10,o7v,z3y,l4i);j4l.style.display=T0j;v74.G4m(4);var j5A=v74.F9v(65,60);n$p.style.left=l4i + z3y + j4l.clientWidth + j5A + N_0;n$p.style.display=\"inline-block\";}else if(C3T + i92 + (\"30\" >> 64) < G4J.stx.chart.canvasHeight){k$6=\"p\";k$6+=\"x\";a_a=\"p\";a_a+=\"x\";R7L=\"p\";R7L+=\"x\";v74.G4m(54);j4l.style.top=v74.F9v(C3T,\"10\",i92,R7L);v74.G4m(2);n$p.style.top=v74.e7l(10,a_a,i92,C3T);v74.b8R(0);j4l.style.left=v74.F9v(l4i,\"px\");j4l.style.display=\"inline-block\";v74.b8R(55);var f5o=v74.e7l(55,31,4,15);n$p.style.left=l4i + j4l.clientWidth - f5o + k$6;n$p.style.display=\"inline-block\";}else {X8K=\"p\";X8K+=\"x\";v74.b8R(11);j4l.style.top=v74.F9v(C3T,35,X8K);v74.b8R(56);n$p.style.top=v74.e7l(C3T,\"px\",\"35\");v74.b8R(0);j4l.style.left=v74.F9v(l4i,\"px\");j4l.style.display=\"inline-block\";v74.b8R(55);var R8V=v74.F9v(30,11,8,6);n$p.style.left=l4i + j4l.clientWidth - R8V + \"px\";n$p.style.display=\"inline-block\";}};}if(l78){d6i.drawingSnapshot=d6i.exportDrawings();this.hidden=!!\"1\";d6i.draw();d6i.activeDrawing=this;D5.ChartEngine.drawingLine=!!({});L2I=d6i.chart.tempCanvas.context;d6i.chart.tempCanvas.style.display=\"block\";this.w=J1_.clientWidth;this.h=J1_.clientHeight;D5.clearCanvas(L2I.canvas,d6i);this.render(L2I);this.highlighted=!\"1\";this.edit(L2I);}if(D5.isAndroid && !D5.is_chrome && !D5.isFF){this.priorBottom=d6i.container.style.bottom;h_I=400;v74.G4m(0);var T$i=v74.e7l(26,6);N8R=d6i.resolveY(P_D) + (\"100\" | T$i);Q2B=d6i.container.ownerDocument.defaultView;if(N8R > D5.pageHeight(Q2B) - h_I){m2s=D5.pageHeight(Q2B) - N8R;v74.b8R(4);S3R=v74.F9v(h_I,m2s);v74.b8R(0);d6i.chart.container.style.bottom=v74.F9v(S3R,\"px\");}}};D5.Drawing.annotation.prototype.click=function(p4R,I9E,x0D){var B4q;if(this.stx.overXAxis || this.stx.overYAxis){return;}B4q=this.stx.panels[this.panelName];this.copyConfig();this.setPoint(0,I9E,x0D,B4q.chart);this.adjust();this.edit(p4R);return ![];};D5.Drawing.annotation.prototype.reposition=function(e9X,L8D,R$W,P_x){var V$J,q9S,H6D;if(!L8D){return;}V$J=this.stx.panels[this.panelName];q9S=L8D.tick - R$W;k_Cdw.j1L();H6D=L8D.value - P_x;this.setPoint(0,L8D.p0[0] - q9S,L8D.p0[1] - H6D,V$J.chart);this.render(e9X);};D5.Drawing.annotation.prototype.intersected=function(l0Z,c1N,t4h){var p1T=k_Cdw;var V1j,H0q,c$V,s_S,q5Z,u5f,a6a,m2i,Q_P;V1j=this.stx;H0q=V1j.panels[this.panelName];if(!this.p0){return null;}c$V=V1j.pixelFromTick(this.p0[0],H0q.chart);s_S=V1j.getYAxisByField(H0q,this.field);p1T.G4m(57);var y49=p1T.e7l(8,63,8,4);p1T.G4m(58);var s2I=p1T.e7l(418,1,6,9,7);q5Z=this.pixelFromValue(H0q,this.p0[0],this.p0[y49],s_S) - this.h / s2I;u5f=c$V + this.w;a6a=q5Z + this.h;if(this.stem && this.stem.x){c$V+=this.stem.x;u5f+=this.stem.x;q5Z+=this.stem.y;a6a+=this.stem.y;}m2i=V1j.pixelFromTick(l0Z,H0q.chart);Q_P=V1j.pixelFromValueAdjusted(H0q,l0Z,c1N);if(m2i + t4h.r >= c$V && m2i - t4h.r <= u5f && Q_P + t4h.r >= q5Z && Q_P - t4h.r <= a6a){this.highlighted=!!({});return {p0:D5.clone(this.p0),tick:l0Z,value:this.valueOnDrawingAxis(l0Z,c1N)};}return !\"1\";};D5.Drawing.annotation.prototype.abort=function(){var b_g,S1l,f8V,d8h,n80;b_g=\"n\";b_g+=\"o\";b_g+=\"ne\";S1l=\"n\";S1l+=\"one\";f8V=this.stx;d8h=f8V.controls.annotationSave;n80=f8V.controls.annotationCancel;if(d8h){d8h.style.display=S1l;}if(n80){n80.style.display=b_g;}if(this.ta){f8V.chart.container.removeChild(this.ta);}this.ta=null;k_Cdw.y6g();f8V.openDialog=\"\";f8V.showCrosshairs();f8V.editingAnnotation=!!\"\";D5.clearCanvas(f8V.chart.tempCanvas,f8V);if(D5.isAndroid && !D5.is_chrome && !D5.isFF){f8V.chart.container.style.bottom=this.priorBottom;}D5.fixScreen();};D5.Drawing.annotation.prototype.reconstruct=function(h4Y,i84){var h_c,b$9;h_c=\"si\";h_c+=\"z\";h_c+=\"e\";b$9=\"s\";b$9+=\"ty\";k_Cdw.y6g();b$9+=\"le\";this.stx=h4Y;this.color=i84.col;this.panelName=i84.pnl;this.d0=i84.d0;this.tzo0=i84.tzo0;this.v0=i84.v0;this.field=i84.fld;this.text=h4Y.escapeOnSerialize?decodeURIComponent(i84.text):i84.text;this.stem=i84.stem;this.borderColor=i84.bc;this.fillColor=i84.bg;this.lineWidth=i84.lw;this.pattern=i84.ptrn;this.font=D5.replaceFields(i84.fnt,{st:b$9,sz:h_c,wt:\"weight\",fl:\"family\"});if(!this.font){this.font={};}this.adjust();};D5.Drawing.annotation.prototype.serialize=function(){var Z56,I8B,Q_n,w0$;Z56={name:this.name,pnl:this.panelName,col:this.color,d0:this.d0,tzo0:this.tzo0,v0:this.v0,fld:this.field,text:this.stx.escapeOnSerialize?encodeURIComponent(this.text):this.text};if(this.font){I8B=\"s\";I8B+=\"z\";Q_n=\"s\";Q_n+=\"t\";w0$=D5.removeNullValues(D5.replaceFields(this.font,{style:Q_n,size:I8B,weight:\"wt\",family:\"fl\"}));if(!D5.isEmpty(w0$)){Z56.fnt=w0$;}}if(this.stem){Z56.stem={d:this.stem.d,v:this.stem.v,x:this.stem.x,y:this.stem.y};}if(this.borderColor){Z56.bc=this.borderColor;}if(this.fillColor){Z56.bg=this.fillColor;}if(this.lineWidth){Z56.lw=this.lineWidth;}if(this.pattern){Z56.ptrn=this.pattern;}return Z56;};D5.Drawing.annotation.prototype.renderText=function(){var U9G=k_Cdw;var b1k,a9J,T$s,U2x,n0C,S9E,I5L,c6n;this.getFontString();b1k=this.stx;a9J=b1k.panels[this.panelName];if(!a9J){return;}U9G.y6g();this.arr=this.text.split(507.35 == (5500,5478)?!\"1\":\"\\n\");T$s=+\"0\";b1k.chart.context.font=this.fontString;for(var G2C=0;G2C < this.arr.length;G2C++){U2x=b1k.chart.context.measureText(this.arr[G2C]).width;if(U2x > T$s){T$s=U2x;}}if(T$s === +\"0\"){U9G.b8R(59);var F5j=U9G.F9v(11,0,2,15);T$s=F5j * this.defaultWidth;}this.fontSize=D5.stripPX(this.fontDef.size);U9G.b8R(60);var M3R=U9G.F9v(550,15,19,20,6);n0C=(this.arr.length + M3R) * (this.fontSize + this.fontModifier);if(D5.touchDevice){n0C+=5;}this.w=T$s + this.whitespace + this.padding;this.h=n0C;S9E=b1k.pixelFromTick(this.p0[0],a9J.chart) + T$s;I5L=b1k.getYAxisByField(a9J,this.field);U9G.G4m(61);var A42=U9G.F9v(21,23,11,8);c6n=this.pixelFromValue(a9J,this.p0[0],this.p0[A42],I5L) + n0C;this.p1=[b1k.tickFromPixel(S9E,a9J.chart),this.valueFromPixel(c6n,a9J,I5L)];if(this.stem && this.stem.d){this.stem.t=b1k.tickFromDate(this.stem.d,a9J.chart);}};D5.Drawing.annotation.prototype.adjust=function(){var z_S;z_S=this.stx.panels[this.panelName];if(!z_S){return;}this.setPoint(0,this.d0,this.v0,z_S.chart);k_Cdw.y6g();this.renderText();};D5.Drawing.segment=function(){this.name=\"segment\";};D5.inheritsFrom(D5.Drawing.segment,D5.Drawing.BaseTwoPoint);D5.Drawing.segment.prototype.render=function(j6d){var U2s,z0W,A4e,s7o,r6r,M19,P2Z,s_Y,A3J,d9I,a1g,f65,W$k,p5_,q73,B0W,U5U,I_X;U2s=this.stx;z0W=U2s.panels[this.panelName];A4e=U2s.getYAxisByField(z0W,this.field);if(!z0W || this.field && !A4e){return;}A4e=A4e || z0W.yAxis;s7o=U2s.pixelFromTick(this.p0[0],z0W.chart);r6r=U2s.pixelFromTick(this.p1[0],z0W.chart);M19=this.pixelFromValue(z0W,this.p0[0],this.p0[1],A4e);P2Z=this.pixelFromValue(z0W,this.p1[0],this.p1[1],A4e);s_Y=this.lineWidth;A3J=this.getLineColor();d9I={pattern:this.pattern,lineWidth:s_Y};if(d9I.pattern == \"none\"){d9I.pattern=\"solid\";}U2s.plotLine(s7o,r6r,M19,P2Z,A3J,this.name,j6d,z0W,d9I);if(this.axisLabel && !this.repositioner){a1g=\"hor\";a1g+=\"iz\";a1g+=\"on\";a1g+=\"tal\";if(this.name == a1g){U2s.endClip();f65=this.p0[1];if(z0W.chart.transformFunc){f65=z0W.chart.transformFunc(U2s,z0W.chart,f65);}if(A4e.priceFormatter){f65=A4e.priceFormatter(U2s,z0W,f65);}else {f65=U2s.formatYAxisPrice(f65,z0W,null,A4e);}U2s.createYAxisLabel(z0W,f65,M19,A3J,null,null,A4e);U2s.startClip(z0W.name);}else if(this.name == \"vertical\" && this.p0[0] >= 0 && !U2s.chart.xAxis.noDraw){W$k=U2s.dateFromTick(this.p0[0],z0W.chart,!\"\");if(!D5.ChartEngine.isDailyInterval(U2s.layout.interval)){k_Cdw.b8R(62);var V40=k_Cdw.F9v(982,10000,18,5);q73=W$k.getSeconds() * V40 + W$k.getMilliseconds();if(Q6.Date && U2s.displayZone){p5_=new Q6.Date(W$k.getTime(),U2s.displayZone);W$k=new Date(p5_.getFullYear(),p5_.getMonth(),p5_.getDate(),p5_.getHours(),p5_.getMinutes());W$k=new Date(W$k.getTime() + q73);}}else {W$k.setHours(0,0,0,0);}B0W=D5.mmddhhmm(D5.yyyymmddhhmm(W$k));if(z0W.chart.xAxis.formatter){B0W=z0W.chart.xAxis.formatter(W$k,this.name,null,null,B0W);}else if(this.stx.internationalizer){B0W=D5.displayableDate(U2s,U2s.chart,W$k);}U2s.endClip();U2s.createXAxisLabel({panel:z0W,txt:B0W,x:s7o,backgroundColor:A3J,color:null,pointed:!\"\",padding:2});U2s.startClip(z0W.name);}}if(this.highlighted && this.name != \"horizontal\" && this.name != \"vertical\"){U5U=this.highlighted == \"p0\"?!0:![];I_X=this.highlighted == \"p1\"?!!\"1\":![];this.littleCircle(j6d,s7o,M19,U5U);this.littleCircle(j6d,r6r,P2Z,I_X);}};D5.Drawing.segment.prototype.abort=function(){this.stx.setMeasure(null,null,null,null,!({}));};D5.Drawing.segment.prototype.intersected=function(d9n,g9C,e$c){var a4C=k_Cdw;var a9a,q04,c6i,y90,H1Z,p6I,y5v,G5o,z0t,f9G;a9a=\"l\";a9a+=\"i\";a9a+=\"n\";a9a+=\"e\";a4C.j1L();q04=\"v\";q04+=\"e\";q04+=\"rtical\";c6i=\"v\";c6i+=\"er\";c6i+=\"tic\";c6i+=\"al\";y90=\"horizon\";y90+=\"t\";y90+=\"al\";if(!this.p0 || !this.p1){return null;}H1Z=this.name;if(H1Z != y90 && H1Z != c6i && H1Z != \"gartley\"){p6I=1479296426;a4C.G4m(3);y5v=-a4C.e7l(\"36617636\",1);G5o=2;for(var c0k=\"1\" << 32;a4C.P6(c0k.toString(),c0k.toString().length,55984) !== p6I;c0k++){z0t={0:this.p0,1:this.p1};a4C.b8R(42);G5o+=a4C.F9v(\"2\",32);}if(a4C.P6(G5o.toString(),G5o.toString().length,77814) !== y5v){z0t={0:this.p0,1:this.p1};}for(var K9X in z0t){if(this.pointIntersection(z0t[K9X][0],z0t[K9X][+\"1\"],e$c)){a4C.G4m(0);this.highlighted=a4C.e7l(\"p\",K9X);return {action:\"drag\",point:\"p\" + K9X};}}}if(H1Z == \"horizontal\" || H1Z == q04){H1Z=a9a;}f9G=this.lineIntersection(d9n,g9C,e$c,H1Z);if(f9G){this.highlighted=!!({});return {action:\"move\",p0:D5.clone(this.p0),p1:D5.clone(this.p1),tick:d9n,value:this.valueOnDrawingAxis(d9n,g9C)};}return null;};D5.Drawing.segment.prototype.configs=[V9O,\"lineWidth\",\"pattern\"];D5.Drawing.segment.prototype.copyConfig=function(h6u){D5.Drawing.copyConfig(this,h6u);if(this.pattern == \"none\" && this.configs.indexOf(\"fillColor\") == -1){this.pattern=\"solid\";}};D5.Drawing.segment.prototype.reconstruct=function(W1M,I79){this.stx=W1M;this.color=I79.col;this.panelName=I79.pnl;this.pattern=I79.ptrn;this.lineWidth=I79.lw;this.d0=I79.d0;this.d1=I79.d1;this.tzo0=I79.tzo0;this.tzo1=I79.tzo1;this.v0=I79.v0;this.v1=I79.v1;this.field=I79.fld;this.adjust();};D5.Drawing.segment.prototype.serialize=function(){k_Cdw.y6g();return {name:this.name,pnl:this.panelName,col:this.color,ptrn:this.pattern,lw:this.lineWidth,d0:this.d0,d1:this.d1,tzo0:this.tzo0,tzo1:this.tzo1,v0:this.v0,v1:this.v1,fld:this.field};};D5.Drawing.line=function(){var D2Y;D2Y=\"l\";D2Y+=\"i\";D2Y+=\"ne\";k_Cdw.j1L();this.name=D2Y;};D5.inheritsFrom(D5.Drawing.line,D5.Drawing.segment);D5.Drawing.line.prototype.dragToDraw=!!0;D5.Drawing.line.prototype.click=function(o9K,x8z,T66){var U9A;U9A=this.stx.panels[this.panelName];if(!U9A){return;}this.copyConfig();if(!this.penDown){this.setPoint(0,x8z,T66,U9A.chart);this.penDown=!!({});return !({});}if(this.accidentalClick(x8z,T66)){return !!1;}this.setPoint(1,x8z,T66,U9A.chart);this.penDown=!!\"\";return !\"\";};D5.Drawing.line.prototype.reconstruct=function(p3s,t9f){this.stx=p3s;this.color=t9f.col;this.panelName=t9f.pnl;this.pattern=t9f.ptrn;this.lineWidth=t9f.lw;this.v0=t9f.v0;this.v1=t9f.v1;this.d0=t9f.d0;this.d1=t9f.d1;k_Cdw.j1L();this.tzo0=t9f.tzo0;this.tzo1=t9f.tzo1;this.field=t9f.fld;this.adjust();};D5.Drawing.line.prototype.serialize=function(){k_Cdw.y6g();return {name:this.name,pnl:this.panelName,col:this.color,ptrn:this.pattern,lw:this.lineWidth,d0:this.d0,d1:this.d1,tzo0:this.tzo0,tzo1:this.tzo1,v0:this.v0,v1:this.v1,fld:this.field};};D5.Drawing.line.prototype.adjust=function(){var x5_;x5_=this.stx.panels[this.panelName];if(!x5_){return;}k_Cdw.j1L();this.setPoint(0,this.d0,this.v0,x5_.chart);this.setPoint(+\"1\",this.d1,this.v1,x5_.chart);if(D5.ChartEngine.isDailyInterval(this.stx.layout.interval) && this.d0B){this.setPoint(0,this.d0B,this.v0B,x5_.chart);k_Cdw.G4m(63);this.setPoint(k_Cdw.e7l(\"1\",0),this.d1B,this.v1B,x5_.chart);}};D5.Drawing.horizontal=function(){this.name=\"horizontal\";};D5.inheritsFrom(D5.Drawing.horizontal,D5.Drawing.segment);D5.Drawing.horizontal.prototype.dragToDraw=!({});D5.Drawing.horizontal.prototype.measure=function(){};D5.Drawing.horizontal.prototype.click=function(J9s,w8v,d6o){var K3a;K3a=this.stx.panels[this.panelName];if(!K3a){return;}this.copyConfig();this.setPoint(0,w8v,d6o,K3a.chart);return !!1;};D5.Drawing.horizontal.prototype.intersected=function(t_F,f_Z,q2J){var W8z,U2A,M0Z;if(this.lineIntersection(t_F,f_Z,q2J,\"line\")){W8z=this.stx;U2A=W8z.chart.dataSet.length;M0Z=this.p0[1];this.highlighted=!!\"1\";return {action:\"move\",p0:[U2A - 2,M0Z],p1:[U2A - 1,M0Z],tick:t_F,value:this.valueOnDrawingAxis(t_F,f_Z)};}k_Cdw.y6g();return null;};D5.Drawing.horizontal.prototype.reconstruct=function(b5j,E9m){this.stx=b5j;this.color=E9m.col;this.panelName=E9m.pnl;this.pattern=E9m.ptrn;this.lineWidth=E9m.lw;this.v0=E9m.v0;this.d0=E9m.d0;this.tzo0=E9m.tzo0;this.axisLabel=E9m.al;this.field=E9m.fld;this.adjust();};D5.Drawing.horizontal.prototype.serialize=function(){var l7I;k_Cdw.y6g();l7I={name:this.name,pnl:this.panelName,col:this.color,ptrn:this.pattern,lw:this.lineWidth,v0:this.v0,d0:this.d0,tzo0:this.tzo0,al:this.axisLabel,fld:this.field};return l7I;};D5.Drawing.horizontal.prototype.adjust=function(){var N9N=k_Cdw;var m23;m23=this.stx.panels[this.panelName];N9N.j1L();if(!m23){return;}N9N.b8R(34);this.setPoint(N9N.F9v(\"0\",0),this.d0,this.v0,m23.chart);N9N.G4m(64);var A7W=N9N.F9v(7,6,4,15,108);this.p1=[this.p0[0] + A7W,this.p0[1]];};D5.Drawing.horizontal.prototype.configs=[\"color\",\"lineWidth\",\"pattern\",\"axisLabel\"];D5.Drawing.vertical=function(){var h7a;h7a=\"ve\";h7a+=\"rt\";h7a+=\"ica\";h7a+=\"l\";k_Cdw.j1L();this.name=h7a;};D5.inheritsFrom(D5.Drawing.vertical,D5.Drawing.horizontal);D5.Drawing.vertical.prototype.measure=function(){};D5.Drawing.vertical.prototype.intersected=D5.Drawing.segment.prototype.intersected;D5.Drawing.vertical.prototype.adjust=function(){var e3l=k_Cdw;var n32;n32=this.stx.panels[this.panelName];if(!n32){return;}this.setPoint(0,this.d0,this.v0,n32.chart);e3l.b8R(65);var S38=e3l.e7l(5,526,8,17,18);e3l.G4m(4);var U4j=e3l.F9v(12,11);this.p1=[this.p0[0],this.p0[S38] + U4j];};D5.Drawing.measure=function(){this.name=\"measure\";};D5.inheritsFrom(D5.Drawing.measure,D5.Drawing.segment);D5.Drawing.measure.prototype.click=function(n6h,f6p,i3i){this.copyConfig();if(!this.penDown){this.p0=[f6p,i3i];this.penDown=!!({});return !1;}this.stx.undo();k_Cdw.y6g();this.penDown=!\"1\";return !!\"1\";};D5.Drawing.rectangle=function(){k_Cdw.y6g();this.name=\"rectangle\";};D5.inheritsFrom(D5.Drawing.rectangle,D5.Drawing.BaseTwoPoint);D5.Drawing.rectangle.prototype.render=function(i40){var N37=k_Cdw;var O_n,j7d,t$u,U32,e79,R6F,l3w,y1V,Z2w,N2f,h1K,O9l,K1T,I$O,K6y,U73,U8a,B1q,w$S;O_n=\"segm\";O_n+=\"en\";O_n+=\"t\";j7d=\"n\";j7d+=\"on\";j7d+=\"e\";t$u=this.stx;U32=t$u.panels[this.panelName];e79=t$u.getYAxisByField(U32,this.field);if(!U32 || this.field && !e79){return;}R6F=t$u.pixelFromTick(this.p0[0],U32.chart);l3w=t$u.pixelFromTick(this.p1[0],U32.chart);N37.y6g();y1V=this.pixelFromValue(U32,this.p0[0],this.p0[1],e79);Z2w=this.pixelFromValue(U32,this.p1[0],this.p1[1],e79);N2f=Math.round(Math.min(R6F,l3w)) + 0.5;h1K=Math.min(y1V,Z2w);O9l=Math.max(R6F,l3w) - N2f;K1T=Math.max(y1V,Z2w) - h1K;I$O=this.getLineColor();K6y=this.fillColor;if(K6y && !D5.isTransparent(K6y) && K6y != \"auto\"){i40.beginPath();i40.rect(N2f,h1K,O9l,K1T);i40.fillStyle=K6y;i40.globalAlpha=0.2;i40.fill();i40.closePath();i40.globalAlpha=1;}U73={pattern:this.pattern,lineWidth:this.lineWidth};if(this.highlighted && U73.pattern == j7d){U73.pattern=\"solid\";if(U73.lineWidth == +\"0.1\"){U73.lineWidth=1;}}t$u.plotLine(R6F,l3w,y1V,y1V,I$O,\"segment\",i40,U32,U73);N37.G4m(4);t$u.plotLine(l3w,l3w,N37.F9v(y1V,0.5),N37.F9v(Z2w,0.5,N37.b8R(0)),I$O,\"segment\",i40,U32,U73);t$u.plotLine(l3w,R6F,Z2w,Z2w,I$O,O_n,i40,U32,U73);N37.b8R(0);t$u.plotLine(R6F,R6F,N37.e7l(Z2w,0.5),N37.F9v(y1V,0.5,N37.b8R(4)),I$O,\"segment\",i40,U32,U73);if(this.highlighted){U8a=\"p\";U8a+=\"0\";B1q=this.highlighted == U8a?!!({}):!!0;w$S=this.highlighted == \"p1\"?!!\"1\":!1;this.littleCircle(i40,R6F,y1V,B1q);this.littleCircle(i40,l3w,Z2w,w$S);}};D5.Drawing.rectangle.prototype.intersected=function(w7v,w_V,k6L){var u3B,E7P;if(!this.p0 || !this.p1){return null;}u3B={0:this.p0,1:this.p1};for(var Y1p in u3B){if(this.pointIntersection(u3B[Y1p][0],u3B[Y1p][1],k6L)){E7P=\"d\";E7P+=\"r\";E7P+=\"ag\";k_Cdw.b8R(0);this.highlighted=k_Cdw.F9v((\"855.13\" - 0,395) !== (\"65.8\" * 1,596)?\"p\":0xd89,Y1p);return {action:E7P,point:((8722,3750) >= +\"3690\"?\"p\":5620 > (7134,6790)?(!!1,0x110f):(62.19,483.29)) + Y1p};}}if(this.boxIntersection(w7v,w_V,k6L)){this.highlighted=!!1;return {action:\"move\",p0:D5.clone(this.p0),p1:D5.clone(this.p1),tick:w7v,value:this.valueOnDrawingAxis(w7v,w_V)};}k_Cdw.j1L();return null;};D5.Drawing.rectangle.prototype.configs=[o8s,a_b,t6r,F4L];D5.Drawing.rectangle.prototype.reconstruct=function(U$4,c7g){this.stx=U$4;this.color=c7g.col;this.fillColor=c7g.fc;this.panelName=c7g.pnl;this.pattern=c7g.ptrn;this.lineWidth=c7g.lw;this.d0=c7g.d0;this.d1=c7g.d1;this.tzo0=c7g.tzo0;this.tzo1=c7g.tzo1;this.v0=c7g.v0;this.v1=c7g.v1;k_Cdw.j1L();this.field=c7g.fld;this.adjust();};D5.Drawing.rectangle.prototype.serialize=function(){return {name:this.name,pnl:this.panelName,col:this.color,fc:this.fillColor,ptrn:this.pattern,lw:this.lineWidth,d0:this.d0,d1:this.d1,tzo0:this.tzo0,tzo1:this.tzo1,v0:this.v0,v1:this.v1,fld:this.field};};D5.Drawing.shape=function(){this.name=\"shape\";this.radians=0;this.a=0;this.rotating=!!\"\";this.textMeasure=!({});this.configurator=\"shape\";this.dimension=[0,0];this.points=[];};D5.inheritsFrom(D5.Drawing.shape,D5.Drawing.BaseTwoPoint);D5.Drawing.shape.prototype.setRotationOnInitialDraw=!\"1\";D5.Drawing.shape.prototype.measure=function(){};D5.Drawing.shape.prototype.render=function(Y1Z){var c70=k_Cdw;var E0N,s3L,q05,l$p,t8Q,k_b,X6d,b4Z,p_M,g_Y,V45,N$V,E5I,c2j,E8$,J8h,K48,f$T,I8P,Q0B,j4K,P5x,X8s,F3n,B8X,M$p;if(!this.points.length){return;}E0N=this.stx;s3L=E0N.panels[this.panelName];q05=E0N.getYAxisByField(s3L,this.field);if(!s3L || this.field && !q05){return;}l$p=E0N.pixelFromTick(this.p0[0],s3L.chart);t8Q=this.pixelFromValue(s3L,this.p0[\"0\" - 0],this.p0[\"1\" * 1],q05);if(this.p1){k_b=E0N.pixelFromTick(this.p1[0],s3L.chart);X6d=this.pixelFromValue(s3L,this.p1[0],this.p1[1],q05);Y1Z.globalAlpha=0.5;Y1Z.fillStyle=this.getLineColor();if(this.rotating){c70.b8R(66);this.radians=Math.atan(c70.e7l(X6d,k_b,l$p,t8Q));if(k_b < l$p){this.radians+=Math.PI;}else if(X6d < t8Q){c70.G4m(18);var h$M=c70.F9v(13,18,3);this.radians+=h$M * Math.PI;}c70.b8R(67);var R8a=c70.e7l(3,23,1,10);c70.G4m(68);var C3j=c70.F9v(5,5,60,12);this.a=parseInt((this.radians * 36 / Math.PI).toFixed(0),R8a) * C3j;this.a%=360;c70.b8R(33);var j0z=c70.e7l(165,8,1140);this.radians=this.a * Math.PI / j0z;if(this.textMeasure){Y1Z.fillText(this.a + (5540 === (7140,+\"8458\")?149.54:\"\\u00b0\"),k_b + 10,X6d + 10);}}else if(this.penDown){this.sx=Math.max(+\"1\",parseFloat(Math.abs(2 * (k_b - l$p) / this.dimension[0]).toFixed(\"1\" ^ 0)));if(k_b < l$p){this.sx*=-1;}this.sy=Math.max(1,parseFloat(Math.abs(2 * (X6d - t8Q) / this.dimension[1]).toFixed(1)));if(X6d < t8Q){this.sy*=-+\"1\";}if(this.textMeasure){Y1Z.fillText(this.sx + \"x,\" + this.sy + (9860 === \"763.78\" * 1?3545 > 29?(+\"809.3\",1940) <= +\"4368\"?(2.87e+3,7.64e+3):5.00e+3:(\"j\",+\"9.58e+3\"):\"x\"),k_b + this.sx + +\"5\",X6d + this.sy + 5);}}Y1Z.globalAlpha=+\"1\";}if(typeof this.sx === \"undefined\"){this.sx=this.sy=1;}c70.y6g();b4Z=this.lineWidth;if(!b4Z){b4Z=1.1;}p_M={pattern:this.pattern,lineWidth:b4Z};if(this.highlighted && p_M.pattern == \"none\"){p_M.pattern=\"solid\";if(p_M.lineWidth == \"0.1\" - 0){p_M.lineWidth=1;}}g_Y=this.getLineColor();if(this.highlighted && b4Z == 0.1){b4Z=1.1;}V45=this.fillColor;c70.G4m(13);var t1e=c70.F9v(9,7);b4Z/=Math.abs(this.sx * this.sy) * t1e / (Math.abs(this.sx) + Math.abs(this.sy));Y1Z.save();Y1Z.translate(l$p,t8Q);Y1Z.rotate(this.radians);Y1Z.scale(this.sx,(q05 || s3L.yAxis).flipped?-this.sy:this.sy);c2j={x:(this.dimension[0] - (\"1\" | 0)) / +\"2\",y:(this.dimension[1] - 1) / +\"2\"};for(N$V=0;N$V < this.points.length;N$V++){E8$=\"a\";E8$+=\"u\";E8$+=\"t\";E8$+=\"o\";Y1Z.beginPath();for(E5I=0;E5I < this.points[N$V].length;E5I++){P5x=this.points;if(P5x[N$V][E5I] == \"M\"){J8h=P5x[N$V][++E5I] - c2j.x;K48=P5x[N$V][++E5I] - c2j.y;Y1Z.moveTo(J8h,K48);}else if(P5x[N$V][E5I] == \"L\"){J8h=P5x[N$V][++E5I] - c2j.x;K48=P5x[N$V][++E5I] - c2j.y;Y1Z.lineTo(J8h,K48);}else if(P5x[N$V][E5I] == (1800 != (2770,+\"6765\")?\"Q\":310.71)){f$T=P5x[N$V][++E5I] - c2j.x;Q0B=P5x[N$V][++E5I] - c2j.y;J8h=P5x[N$V][++E5I] - c2j.x;K48=P5x[N$V][++E5I] - c2j.y;Y1Z.quadraticCurveTo(f$T,Q0B,J8h,K48);}else if(P5x[N$V][E5I] == ((8470,\"7157\" ^ 0) == (3330,+\"3744\")?0x801:8367 <= 618?\"b\":(1348,346.58) == (306,939.95)?+\"2.04e+3\":\"B\")){f$T=P5x[N$V][++E5I] - c2j.x;Q0B=P5x[N$V][++E5I] - c2j.y;I8P=P5x[N$V][++E5I] - c2j.x;j4K=P5x[N$V][++E5I] - c2j.y;J8h=P5x[N$V][++E5I] - c2j.x;K48=P5x[N$V][++E5I] - c2j.y;Y1Z.bezierCurveTo(f$T,Q0B,I8P,j4K,J8h,K48);}}Y1Z.closePath();if(V45 && !D5.isTransparent(V45) && V45 != E8$){Y1Z.fillStyle=V45;Y1Z.fill();}if(g_Y && this.pattern != \"none\"){Y1Z.strokeStyle=g_Y;Y1Z.lineWidth=b4Z;if(Y1Z.setLineDash){Y1Z.setLineDash(D5.borderPatternToArray(b4Z,this.pattern));Y1Z.lineDashOffset=0;}Y1Z.stroke();}}Y1Z.restore();Y1Z.save();Y1Z.translate(l$p,t8Q);Y1Z.rotate(this.radians);if(this.highlighted){X8s=this.highlighted == \"p0\"?!!1:!({});F3n=this.highlighted == \"p1\"?!![]:!({});B8X=this.highlighted == \"p2\"?!!({}):!!\"\";this.littleCircle(Y1Z,0,+\"0\",X8s);this.mover(Y1Z,0,0,X8s);this.littleCircle(Y1Z,this.sx * this.dimension[0] / +\"2\",this.sy * this.dimension[+\"1\"] / 2,F3n);this.resizer(Y1Z,this.sx * this.dimension[0] / +\"2\",this.sy * this.dimension[1] / 2,F3n);this.littleCircle(Y1Z,this.sx * this.dimension[0] / 2,0,B8X);this.rotator(Y1Z,this.sx * this.dimension[0] / 2,0,B8X);c70.G4m(3);Y1Z.globalAlpha=c70.F9v(\"0.5\",1);Y1Z.fillStyle=this.getLineColor(null,![]);if(this.textMeasure){M$p=\"x\";M$p+=\",\";Y1Z.fillText(this.sx + M$p + this.sy + (8093 > 5253?7920 < +\"1326\"?622.2 >= (8620,6169)?872.67:+\"0x331\":\"x\":(0xc19,706.78)),this.sx * this.dimension[\"0\" >> 0] / 2 + +\"12\",this.sy * this.dimension[1] / 2 + (\"5\" << 32));Y1Z.fillText(this.a + ((7569,\"5100\" | 36) < 204.01?7183 != 1996?(9777,+\"442.09\") === (458.78,5794)?!0:!0:!({}):\"\\u00b0\"),this.sx * this.dimension[0] / 2 + 12,\"5\" * 1);}Y1Z.globalAlpha=1;}else if(this.penDown){if(this.rotating){this.rotator(Y1Z,this.sx * this.dimension[0] / 2,0,!!({}));}else {this.resizer(Y1Z,this.sx * this.dimension[0] / 2,this.sy * this.dimension[1] / +\"2\",!!\"1\");}}Y1Z.restore();};D5.Drawing.shape.prototype.reposition=function(K6j,L89,E_u,C74){var N7m=k_Cdw;var c0w,l2t,X7K,R9M,a2L,D4F,W_S,I5x,w8w;if(!L89){return;}c0w=this.stx;N7m.y6g();l2t=c0w.panels[this.panelName];if(L89.action == \"move\"){X7K=L89.tick - E_u;R9M=L89.value - C74;this.setPoint(0,L89.p0[0] - X7K,L89.p0[+\"1\"] - R9M,l2t.chart);this.render(K6j);}else {a2L=c0w.getYAxisByField(l2t,this.field);D4F=c0w.pixelFromTick(this.p0[0],l2t.chart);W_S=this.pixelFromValue(l2t,this.p0[0],this.p0[1],a2L);I5x=c0w.pixelFromTick(E_u,l2t.chart);w8w=this.pixelFromValue(l2t,E_u,C74,a2L);if(L89.action == \"scale\"){this[L89.point]=[E_u,C74];this.sx=parseFloat((((I5x - D4F) * Math.cos(this.radians) + (w8w - W_S) * Math.sin(this.radians)) / (this.dimension[0] / 2)).toFixed(+\"1\"));if(Math.abs(this.sx) < (\"1\" ^ 0)){this.sx/=Math.abs(this.sy);}this.sy=parseFloat((((w8w - W_S) * Math.cos(this.radians) - (I5x - D4F) * Math.sin(this.radians)) / (this.dimension[1] / 2)).toFixed(1));if(Math.abs(this.sy) < (\"1\" ^ 0)){this.sy/=Math.abs(this.sy);}this.render(K6j);}else if(L89.action == \"rotate\"){this[L89.point]=[E_u,C74];N7m.b8R(66);this.radians=Math.atan(N7m.e7l(w8w,I5x,D4F,W_S));if(I5x < D4F){this.radians+=Math.PI;}else if(w8w < W_S){N7m.b8R(4);var F7P=N7m.F9v(16,14);this.radians+=F7P * Math.PI;}N7m.G4m(4);var g7K=N7m.e7l(140,130);N7m.G4m(69);var j0B=N7m.e7l(95,90,15,15,1);this.a=parseInt((this.radians * +\"36\" / Math.PI).toFixed(0),g7K) * j0B;if(this.sx < 0){N7m.b8R(31);var E9O=N7m.e7l(173,25,175);this.a=this.a + E9O;}this.a%=360;N7m.G4m(0);var k15=N7m.F9v(173,7);this.radians=this.a * Math.PI / k15;this.render(K6j);}}};D5.Drawing.shape.prototype.intersected=function(R0r,B6l,S5M){var I2p=k_Cdw;var z$r,y7t,K3k,r1a,h9b,Y1Q,j73,n8f,b5o,s75,a0J,B21,c_y,U98,f7o,v_U,K4d,W0P,z2e,h40;z$r=this.stx;if(!this.p0){return null;}if(z$r.repositioningDrawing == this && z$r.repositioningDrawing.repositioner){return z$r.repositioningDrawing.repositioner;}y7t=z$r.panels[this.panelName];K3k=z$r.getYAxisByField(y7t,this.field);r1a=z$r.pixelFromTick(this.p0[0],y7t.chart);I2p.j1L();h9b=this.pixelFromValue(y7t,this.p0[+\"0\"],this.p0[\"1\" - 0],K3k);Y1Q=z$r.pixelFromTick(R0r,y7t.chart);j73=z$r.pixelFromValueAdjusted(y7t,R0r,B6l);Y1Q-=r1a;j73-=h9b;n8f=j73;b5o=Y1Q;Y1Q=Math.cos(this.radians) * b5o + Math.sin(this.radians) * n8f;j73=Math.cos(this.radians) * n8f - Math.sin(this.radians) * b5o;Y1Q/=this.sx;j73/=this.sy;this.padding=D5.ensureDefaults(this.padding || ({}),{left:0,right:0,top:+\"0\",bottom:0});s75=this.padding.right + this.padding.left;a0J=this.padding.bottom + this.padding.top;B21=Math.pow(D5.touchDevice?25:5 + this.littleCircleRadius(),2);c_y=Math.abs(B21 / (this.sx * this.sy));U98=3;I2p.b8R(70);var d2N=I2p.F9v(8,10,72,3,2);I2p.b8R(13);var h9Z=I2p.e7l(4,3);I2p.G4m(71);var f9l=I2p.e7l(6,16,13,20,227);I2p.b8R(72);var O21=I2p.F9v(11,1,2,33,20);I2p.G4m(73);var Z3X=I2p.e7l(1,26,15,9);I2p.G4m(4);var S82=I2p.F9v(4,2);I2p.G4m(74);var Y7d=I2p.F9v(15,2,20,5);f7o=Math.pow((this.dimension[+\"0\"] - s75 + U98) / d2N,\"2\" - 0) + Math.pow((this.dimension[h9Z] - a0J + U98) / f9l,O21) > Math.pow(Y1Q - s75 / Z3X,S82) + Math.pow(j73 - a0J / Y7d,2);I2p.G4m(75);var R9s=I2p.e7l(1902,4,14,2,17);I2p.b8R(76);var V63=I2p.e7l(2,15,11);v_U=(B21 - (Math.pow(Y1Q * this.sx,R9s) + Math.pow(j73 * this.sy,V63))) / Math.abs(this.sx * this.sy);I2p.b8R(77);var P1P=I2p.e7l(11,57,8,40);I2p.b8R(78);var m65=I2p.F9v(18,30,11);I2p.b8R(79);var m2g=I2p.e7l(19,1,24,6,1);K4d=c_y - Math.pow(Y1Q - this.dimension[0] / P1P,\"2\" - 0) - Math.pow(j73 - this.dimension[m65] / +\"2\",m2g);I2p.G4m(80);var Y9S=I2p.e7l(15,18,1,15,14);I2p.G4m(20);var r5u=I2p.F9v(0,9,38,4);I2p.G4m(4);var X7M=I2p.e7l(9,7);W0P=c_y - Math.pow(Y1Q - this.dimension[0] / Y9S,r5u) - Math.pow(j73,X7M);if(f7o){z2e=\"m\";z2e+=\"ov\";z2e+=\"e\";if(K4d >= W0P && K4d >= v_U && K4d > -1){h40=\"p\";h40+=\"1\";this.highlighted=h40;return {action:\"scale\"};}if(W0P >= K4d && W0P >= v_U && W0P > -1){this.highlighted=\"p2\";return {action:\"rotate\"};}this.highlighted=v_U > -1?\"p0\":!!\"1\";return {action:z2e,p0:D5.clone(this.p0),tick:R0r,value:this.valueOnDrawingAxis(R0r,B6l)};}return null;};D5.Drawing.shape.prototype.configs=[\"color\",\"fillColor\",\"lineWidth\",\"pattern\"];D5.Drawing.shape.prototype.littleCircleRadius=function(){k_Cdw.y6g();return 3;};D5.Drawing.shape.prototype.click=function(Q2R,X1i,z9T){var A1Z;if(!this.points.length){return !!\"\";}this.copyConfig();A1Z=this.stx.panels[this.panelName];if(!this.penDown){this.setPoint(0,X1i,z9T,A1Z.chart);this.penDown=!!({});return !({});}this.setPoint(1,X1i,z9T,A1Z.chart);k_Cdw.y6g();if(this.rotating || !this.setRotationOnInitialDraw){this.penDown=!({});this.rotating=!({});return !!({});}this.rotating=!!1;return !!\"\";};D5.Drawing.shape.prototype.adjust=function(){var W1H,d5w,A7T;W1H=this.stx.panels[this.panelName];if(!W1H){return;}d5w=this.name + \"_v\" + (this.version || 0);k_Cdw.j1L();if(D5.Drawing[d5w]){A7T=new D5.Drawing[d5w]();this.name=A7T.name;this.dimension=A7T.dimension;this.padding=A7T.padding;this.points=A7T.points;this.version=A7T.version;}this.setPoint(0,this.d0,this.v0,W1H.chart);k_Cdw.b8R(81);var O4t=k_Cdw.F9v(41,4,3,2,298);this.radians=Math.round(this.a / (\"5\" - 0)) * Math.PI / O4t;};D5.Drawing.shape.prototype.reconstruct=function(Z6h,q0e){this.stx=Z6h;k_Cdw.y6g();this.color=q0e.col;this.fillColor=q0e.fc;this.panelName=q0e.pnl;this.pattern=q0e.ptrn;this.lineWidth=q0e.lw;this.d0=q0e.d0;this.v0=q0e.v0;this.tzo0=q0e.tzo0;this.a=q0e.a;this.sx=q0e.sx;this.sy=q0e.sy;this.field=q0e.fld;this.version=q0e.ver;this.adjust();};D5.Drawing.shape.prototype.serialize=function(){k_Cdw.y6g();return {name:this.name,pnl:this.panelName,col:this.color,fc:this.fillColor,ptrn:this.pattern,lw:this.lineWidth,d0:this.d0,v0:this.v0,tzo0:this.tzo0,a:this.a,sx:this.sx,sy:this.sy,fld:this.field,ver:this.version};};D5.Drawing.arrow=function(){this.name=\"arrow\";this.version=1;this.dimension=[11,22];this.padding={left:0,right:0,top:11,bottom:0};k_Cdw.y6g();k_Cdw.G4m(34);this.points=[[\"M\",3,21,(3140,3500) == (1970,4282)?(418.59,\"C\"):\"L\",7,21,\"L\",7,16,3336 <= 532?(+\"1.40e+2\",+\"0x1098\"):(628.51,7420) === 9320?177 < (1412,4130)?(0xb91,+\"785.76\"):(830.51,!!1):\"L\",10,+\"16\",(756,516) > 157.03?\"L\":5065 != 122.84?+\"893.27\":0x1bbb,5,11,\"L\",k_Cdw.F9v(\"0\",0),16,\"L\",3,16,(\"4410\" | 16) == (3655,1900)?+\"0xab2\":+\"8570\" !== (34.57,8028)?\"L\":235.37,3,+\"21\"]];};D5.inheritsFrom(D5.Drawing.arrow,D5.Drawing.shape);D5.Drawing.getDrawingToolList=function(Q9o){k_Cdw.j1L();var l6D,V_A;l6D={};V_A={arrow_v0:!![],BaseTwoPoint:!!\"1\",fibonacci:!!\"1\",shape:!!({})};D5.extend(V_A,Q9o);for(var K8j in D5.Drawing){if(!V_A[K8j] && D5.Drawing[K8j].prototype.render){l6D[new D5.Drawing[K8j]().name]=K8j;}}return l6D;};};L3=X0h=>{var M39=k_Cdw;var Q$q,g7F,P_T,M6p,w9_;Q$q=1618593315;g7F=2088675151;P_T=2;for(var k$F=1;M39.P6(k$F.toString(),k$F.toString().length,91438) !== Q$q;k$F++){M6p=+_CIQ === \"\"?_CIQ:X0h.CIQ;P_T+=2;}if(M39.m1(P_T.toString(),P_T.toString().length,43682) !== g7F){w9_=\"un\";w9_+=\"de\";w9_+=\"f\";w9_+=\"ined\";M6p=typeof _CIQ !== w9_?_CIQ:X0h.CIQ;}M6p.EaseMachine=function(V1k,K5r,P4n,M1w){var B9K;B9K=\"stri\";B9K+=\"n\";B9K+=\"g\";if(typeof V1k === B9K){this.fc=M6p.EaseMachine[V1k];}else {this.fc=V1k;}this.ms=K5r;if(P4n || P4n === \"0\" * 1){this.reset(P4n,M1w);}};M6p.EaseMachine.prototype.reset=function(e6H,r6l){if(!e6H && e6H !== (\"0\" | 0)){e6H=this.currentValues;}this.hasCompleted=![];this.running=![];this.okayToRun=!!({});M39.G4m(82);this.useNameValuePairs=M39.e7l(typeof r6l,\"object\");this.startTime=Date.now();if(this.useNameValuePairs){this.startValues=e6H;this.endValues=r6l;}else {this.startValues={default:e6H};this.endValues={default:r6l};}this.changeValues={};this.currentValues={};M39.y6g();for(var l11 in this.startValues){this.changeValues[l11]=this.endValues[l11] - this.startValues[l11];}};M6p.EaseMachine.prototype.next=function(){var U_0;U_0=Date.now();if(U_0 >= this.startTime + this.ms){U_0=this.startTime + this.ms;this.hasCompleted=!![];this.running=!\"1\";}this.currentValues={};for(var F9c in this.changeValues){this.currentValues[F9c]=this.fc(U_0 - this.startTime,this.startValues[F9c],this.changeValues[F9c],this.ms);}if(!this.useNameValuePairs){return this.currentValues[\"default\"];}M39.y6g();return this.currentValues;};M39.y6g();M6p.EaseMachine.prototype.hasCompleted=!!({});M6p.EaseMachine.prototype.run=function(n2p,h3G,i2N,Y6y){var g2d;if(this.afid){cancelAnimationFrame(this.afid);}if(h3G || h3G === 0){this.reset(h3G,i2N);}else if(i2N || i2N === 0){this.reset(this.currentValues,i2N);}g2d=this;this.running=!![];M39.y6g();if(Y6y){this.afid=requestAnimationFrame(B4R);}else {B4R();}function B4R(){M39.j1L();var E0X;g2d.afid=null;if(!g2d.okayToRun){return;}E0X=g2d.next();n2p(E0X);if(g2d.hasCompleted){return;}g2d.afid=requestAnimationFrame(B4R);}};M6p.EaseMachine.prototype.stop=function(){M39.y6g();if(this.afid){cancelAnimationFrame(this.afid);}this.afid=null;this.okayToRun=!1;this.hasCompleted=!!\"1\";this.running=![];if(typeof this.useNameValuePairs == \"undefined\"){return {};}if(!this.useNameValuePairs){return this.currentValues[\"default\"];}return this.currentValues;};M6p.EaseMachine.easeInOutQuad=function(M3n,U0A,E24,n_B){M39.b8R(9);M3n/=M39.F9v(n_B,2);if(M3n < 1){M39.b8R(83);return M39.F9v(M3n,2,U0A,E24,M3n);}M3n--;M39.b8R(84);return M39.F9v(0,\"1\",M3n,U0A,2,M3n,E24,2);};M6p.EaseMachine.easeInOutCubic=function(R51,b52,F2E,m88){M39.b8R(9);R51/=M39.e7l(m88,2);if(R51 < 1){M39.G4m(85);return M39.e7l(F2E,b52,2,R51,R51,R51);}R51-=+\"2\";M39.b8R(86);return M39.F9v(R51,2,2,R51,F2E,b52,R51);};M6p.EaseMachine.easeOutCubic=function(s8g,t3Y,c9v,v29){s8g/=v29;s8g--;M39.y6g();M39.G4m(87);return M39.e7l(s8g,c9v,s8g,t3Y,s8g,1);};if(M6p.ChartEngine.prototype.animations.zoom.isStub){M6p.ChartEngine.prototype.animations.zoom=new M6p.EaseMachine(\"easeOutCubic\",400);}};I3=G1w=>{var r5r,u9q,r2f;r5r=\"u\";r5r+=\"nde\";r5r+=\"fin\";r5r+=\"ed\";u9q=typeof _CIQ !== r5r?_CIQ:G1w.CIQ;r2f=function(){var p$V=k_Cdw;var j1y,e32,r9q,c64,o9B,P4S,r8o,h9G,A21,O2t,A06,b_D,h0g,g4w,Y8a,s6Z,e57,e_J,T_K;j1y=\"\\\\\";function k$q(U2t){C7L.prototype=U2t;function C7L(){}return new C7L();}function c8w(m11,N90){p$V.b8R(4);p$V.j1L();return p$V.F9v(m11,N90);}function n7r(Y59){p$V.j1L();return Math.acosh?Math.acosh(Y59):Math.log(Y59 + Math.sqrt(Y59 * Y59 - 1));}function A2d(j4B,K21){p$V.y6g();return Number(j4B) + Number(K21);}function a3w(h7T){p$V.j1L();return Math.log(h7T) * Math.LOG10E;}j1y+=\"f\";function p7w(n3p){p$V.j1L();return -n3p;}function F8J(R$A,g8M){p$V.y6g();p$V.G4m(9);return p$V.F9v(R$A,g8M);}function A78(A98,N2x){p$V.y6g();return Boolean(A98 || N2x);}function j_d(b9k){return Math.cosh?Math.cosh(b9k):(Math.exp(b9k) + Math.exp(-b9k)) / +\"2\";}e32=\"\\\\\";e32+=\"t\";function G88(G56){var A9W;G56=Math.floor(G56);A9W=G56;while(G56 > 1){p$V.G4m(88);A9W=p$V.e7l(A9W,--G56);}return A9W;}r9q=0;c64=1;function g_N(u11){if(Math.asinh){return Math.asinh(u11);}if(u11 === -Infinity){return u11;}return Math.log(u11 + Math.sqrt(u11 * u11 + 1));}o9B=2;function t5l(b5k){p$V.j1L();return Math.sinh?Math.sinh(b5k):(Math.exp(b5k) - Math.exp(-b5k)) / 2;}function j_2(G6G){if(Math.trunc){return Math.trunc(G6G);}return G6G < 0?Math.ceil(G6G):Math.floor(G6G);}function o50(){this.success=!\"1\";this.errormsg=\"\";this.expression=\"\";this.pos=0;this.tokennumber=0;this.tokenprio=0;this.tokenindex=0;this.tmpprio=0;this.ops1={sin:Math.sin,cos:Math.cos,tan:Math.tan,asin:Math.asin,acos:Math.acos,atan:Math.atan,sinh:t5l,cosh:j_d,tanh:E5L,asinh:g_N,acosh:n7r,atanh:R5g,sqrt:Math.sqrt,log:Math.log,lg:a3w,log10:a3w,abs:Math.abs,ceil:Math.ceil,floor:Math.floor,round:Math.round,trunc:j_2,\"-\":p7w,exp:Math.exp};this.ops2={\"+\":A2d,\"-\":c8w,\"*\":a3y,\"/\":F8J,\"%\":P6Z,\"^\":Math.pow,\",\":Y7i,\"||\":l5r,\"==\":U4K,\"!=\":X4M,\">\":j85,\"<\":V7U,\">=\":q1W,\"<=\":I22,and:S$z,or:A78};this.functions={fac:G88,min:Math.min,max:Math.max,hypot:M64,pyt:M64,pow:Math.pow,atan2:Math.atan2,if:z2M};this.consts={E:Math.E,PI:Math.PI};}function E5L(b6U){if(Math.tanh){return Math.tanh(b6U);}if(b6U === Infinity){return 1;}if(b6U === -Infinity){return -1;}return (Math.exp(b6U) - Math.exp(-b6U)) / (Math.exp(b6U) + Math.exp(-b6U));}P4S=3;function R5g(w7q){return Math.atanh?Math.atanh(w7q):Math.log((1 + w7q) / (1 - w7q)) / 2;}function Y7i(G2p,S7E){if(Object.prototype.toString.call(G2p) != \"[object Array]\"){return [G2p,S7E];}G2p=G2p.slice();G2p.push(S7E);return G2p;}function V8K(k3A,T1T,N14,Q_E){this.type_=k3A;this.index_=T1T || 0;this.prio_=N14 || \"0\" * 1;this.number_=Q_E !== undefined && Q_E !== null?Q_E:0;this.toString=function(){switch(this.type_){case r9q:return this.number_;case c64:case o9B:case P4S:return this.index_;case r8o:return \"CALL\";default:return \"Invalid Token\";}};}r8o=+\"4\";h9G=/[\\u00ad\\u0600-\\u200c-\\u200f\\u2028-\\u202f\\u2060-\\u206f\\ufeff\\ufff0-\\uffff]|\\u070f|\\u17b4|\\u0604|\\u17b5/g;A21=/[\\\\'\\x7f-\\x9f\\u00ad\\u0600-\\u200c-\\u200f\\u2028-\\u202f\\u2060-\\u206f\\ufeff\\ufff0-\\uffff]|\\u070f|\\u17b4|\\u0604|\\u17b5/g;O2t={\"\\b\":\"\\\\b\",\"\\t\":e32,\"\\n\":\"\\\\n\",\"\\f\":j1y,\"\\r\":\"\\\\r\",\"'\":\"\\\\'\",\"\\\\\":\"\\\\\\\\\"};u9q.extend(K4e.prototype,{simplify:function(L_y){var S$m,b_x,w3k,J5a,V1F,y0h,q4e,Q4E,e7_;L_y=L_y || ({});S$m=[];b_x=[];y0h=this.tokens.length;Q4E=0;for(Q4E=0;Q4E < y0h;Q4E++){q4e=this.tokens[Q4E];e7_=q4e.type_;if(e7_ === r9q){S$m.push(q4e);}else if(e7_ === P4S && (q4e.index_ in L_y)){q4e=new V8K(r9q,0,0,L_y[q4e.index_]);S$m.push(q4e);}else if(e7_ === o9B && S$m.length > 1){J5a=S$m.pop();w3k=S$m.pop();V1F=this.ops2[q4e.index_];q4e=new V8K(r9q,0,0,V1F(w3k.number_,J5a.number_));S$m.push(q4e);}else if(e7_ === c64 && S$m.length > \"0\" >> 0){w3k=S$m.pop();V1F=this.ops1[q4e.index_];q4e=new V8K(r9q,0,0,V1F(w3k.number_));S$m.push(q4e);}else {while(S$m.length > 0){b_x.push(S$m.shift());}b_x.push(q4e);}}while(S$m.length > 0){b_x.push(S$m.shift());}return new K4e(b_x,k$q(this.ops1),k$q(this.ops2),k$q(this.functions));},substitute:function(P3X,u1C){var U3u,b1g,e2c,b2c,t$Q,B1w,N6S,l_Z;if(!(u1C instanceof K4e)){u1C=new o50().parse(String(u1C));}U3u=[];b1g=this.tokens.length;p$V.j1L();b2c=0;for(b2c=0;b2c < b1g;b2c++){e2c=this.tokens[b2c];t$Q=e2c.type_;if(t$Q === P4S && e2c.index_ === P3X){for(var e_D=0;e_D < u1C.tokens.length;e_D++){B1w=u1C.tokens[e_D];N6S=new V8K(B1w.type_,B1w.index_,B1w.prio_,B1w.number_);U3u.push(N6S);}}else {U3u.push(e2c);}}l_Z=new K4e(U3u,k$q(this.ops1),k$q(this.ops2),k$q(this.functions));return l_Z;},evaluate:function(d3G){var Q7I,D7u,v3Z,Z72,t7o,T0g,R8b,M6B,u1k;d3G=d3G || ({});Q7I=[];t7o=this.tokens.length;R8b=0;for(R8b=0;R8b < t7o;R8b++){T0g=this.tokens[R8b];M6B=T0g.type_;if(M6B === r9q){Q7I.push(T0g.number_);}else if(M6B === o9B){v3Z=Q7I.pop();D7u=Q7I.pop();Z72=this.ops2[T0g.index_];Q7I.push(Z72(D7u,v3Z));}else if(M6B === P4S){if((T0g.index_ in d3G)){Q7I.push(d3G[T0g.index_]);}else if((T0g.index_ in this.functions)){Q7I.push(this.functions[T0g.index_]);}else {throw new Error(\"undefined variable: \" + T0g.index_);}}else if(M6B === c64){D7u=Q7I.pop();Z72=this.ops1[T0g.index_];Q7I.push(Z72(D7u));}else if(M6B === r8o){D7u=Q7I.pop();Z72=Q7I.pop();if(Z72.apply && Z72.call){u1k=\"[o\";u1k+=\"b\";u1k+=\"ject\";u1k+=\" Array]\";if(Object.prototype.toString.call(D7u) == u1k){Q7I.push(Z72.apply(undefined,D7u));}else {Q7I.push(Z72.call(undefined,D7u));}}else {p$V.b8R(0);throw new Error(p$V.F9v(Z72,\" is not a function\"));}}else {throw new Error(\"invalid Expression\");}}if(Q7I.length > 1){throw new Error(\"invalid Expression (parity)\");}return Q7I[0];},toString:function(y8V){p$V.y6g();var P18,Z39,j8v,k6w,W7g,C4d,W$i,S2q,d_Y;P18=[];W7g=this.tokens.length;W$i=0;for(W$i=0;W$i < W7g;W$i++){C4d=this.tokens[W$i];S2q=C4d.type_;if(S2q === r9q){P18.push(P7W(C4d.number_));}else if(S2q === o9B){j8v=P18.pop();Z39=P18.pop();k6w=C4d.index_;if(y8V && k6w == (4539 == (251.91,\"2131\" - 0)?\"G\":(\"4581\" >> 0,569.34) != (9257,7182)?\"^\":0x372)){d_Y=\"Math.\";d_Y+=\"pow(\";p$V.b8R(89);P18.push(p$V.e7l(Z39,j8v,\",\",(4760,4625) === 1270?(\"p\",455.35):\")\",d_Y));}else {p$V.b8R(89);P18.push(p$V.F9v(Z39,j8v,k6w,\")\",(529.87,\"5310\" ^ 0) > (711.43,9045)?(+\"159.86\",9830) > 184.32?1141 < (844,2035)?+\"0x1f6b\":9.06e+3:(\"g\",!({})):\"(\"));}}else if(S2q === P4S){P18.push(C4d.index_);}else if(S2q === c64){Z39=P18.pop();k6w=C4d.index_;if(k6w === (6997 >= (4830,197.03)?\"-\":(6.88e+3,6.70e+3))){p$V.G4m(2);P18.push(p$V.F9v(Z39,1432 !== (4639,3710)?(\"213.11\" * 1,5520) < 909.33?(511,2470) <= 941?+\"0x2449\":7.73e+3:\")\":\"E\",k6w,(685.74,429) >= (122.58,8559)?\"8.02e+3\" | 4:\"(\"));}else {p$V.G4m(2);P18.push(p$V.F9v(Z39,2481 > 1392?6870 < (8480,5725)?\"U\":(5405,563) === (617.57,+\"1120\")?(\"D\",!({})):\")\":!!\"1\",\"(\",k6w));}}else if(S2q === r8o){Z39=P18.pop();k6w=P18.pop();p$V.G4m(2);P18.push(p$V.e7l(Z39,+\"264\" == 7920?+\"655\":\")\",(2849,+\"307.03\") < (+\"132.89\",\"561.67\" - 0)?\"(\":(\"3363\" ^ 0,713.3) == (3970,224.61)?!!({}):\"a\",k6w));}else {throw new Error(\"invalid Expression\");}}if(P18.length > 1){throw new Error(\"invalid Expression (parity)\");}return P18[0];},variables:function(){var F4H,H1m,O56;F4H=this.tokens.length;H1m=[];for(var g2Y=0;g2Y < F4H;g2Y++){O56=this.tokens[g2Y];if(O56.type_ === P4S && H1m.indexOf(O56.index_) == -1){H1m.push(O56.index_);}}return H1m;}},!!1);function M64(){var h$g,S2k;if(Math.hypot){return Math.hypot.apply(this,arguments);}h$g=0;p$V.y6g();S2k=arguments.length;for(var j0Z=0;j0Z < S2k;j0Z++){if(arguments[j0Z] === Infinity || arguments[j0Z] === -Infinity){return Infinity;}h$g+=arguments[j0Z] * arguments[j0Z];}return Math.sqrt(h$g);}o50.parse=function(m5T){return new o50().parse(m5T);};function P7W(y3Z){p$V.y6g();if(typeof y3Z === \"string\"){A21.lastIndex=0;return A21.test(y3Z)?\"'\" + y3Z.replace(A21,function(f5n){var N3b,Z22,S77;N3b=\"0\";N3b+=\"000\";Z22=\"st\";Z22+=\"ring\";S77=O2t[f5n];return typeof S77 === Z22?S77:\"\\\\u\" + (N3b + f5n.charCodeAt(+\"0\").toString(\"16\" | 0)).slice(-4);}) + \"'\":\"'\" + y3Z + ((516,8470) != (6738,1450)?(413.84,9184) > 507?\"'\":(585.76,7.28e+3):(\"r\",882.99));}return y3Z;}o50.evaluate=function(N7s,g49){return o50.parse(N7s).evaluate(g49);};function q1W(U0L,F4_){var h$P,y4l,r1r;h$P=118816472;p$V.b8R(34);y4l=p$V.e7l(\"118923817\",8);r1r=2;for(var n$v=1;p$V.P6(n$v.toString(),n$v.toString().length,\"53626\" ^ 0) !== h$P;n$v++){p$V.G4m(90);return p$V.e7l(U0L,F4_);}p$V.y6g();if(p$V.P6(r1r.toString(),r1r.toString().length,\"66774\" | 20) !== y4l){p$V.G4m(90);return p$V.e7l(U0L,F4_);}p$V.b8R(91);return p$V.F9v(F4_,U0L);}function a3y(E3I,H4u){p$V.y6g();p$V.b8R(3);return p$V.e7l(E3I,H4u);}function V7U(X9F,m2q){p$V.b8R(90);return p$V.F9v(X9F,m2q);}o50.Expression=K4e;function X4M(B6h,q0a){p$V.G4m(92);return p$V.e7l(B6h,q0a);}o50.values={sin:Math.sin,cos:Math.cos,tan:Math.tan,asin:Math.asin,acos:Math.acos,atan:Math.atan,sinh:t5l,cosh:j_d,tanh:E5L,asinh:g_N,acosh:n7r,atanh:R5g,sqrt:Math.sqrt,log:Math.log,lg:a3w,log10:a3w,abs:Math.abs,ceil:Math.ceil,floor:Math.floor,round:Math.round,trunc:j_2,fac:G88,exp:Math.exp,min:Math.min,max:Math.max,hypot:M64,pyt:M64,pow:Math.pow,atan2:Math.atan2,if:z2M,E:Math.E,PI:Math.PI};p$V.b8R(42);A06=p$V.F9v(1,0);p$V.G4m(42);b_D=p$V.e7l(1,1);p$V.G4m(42);h0g=p$V.F9v(1,2);p$V.b8R(42);g4w=p$V.e7l(1,3);function z2M(v3G,l06,A7e){return v3G?l06:A7e;}p$V.b8R(42);Y8a=p$V.F9v(1,4);p$V.b8R(42);s6Z=p$V.F9v(1,5);p$V.b8R(93);e57=p$V.F9v(1,6,\"1\");p$V.G4m(42);e_J=p$V.e7l(1,7);function U4K(U5g,f2i){p$V.y6g();var A2x,v$P,s_d;A2x=321204831;v$P=+\"427609581\";p$V.b8R(4);s_d=p$V.e7l(\"2\",0);for(var e3U=1;p$V.m1(e3U.toString(),e3U.toString().length,75790) !== A2x;e3U++){p$V.b8R(92);return p$V.F9v(U5g,f2i);}if(p$V.m1(s_d.toString(),s_d.toString().length,51002) !== v$P){p$V.b8R(92);return p$V.F9v(U5g,f2i);}p$V.b8R(82);return p$V.F9v(U5g,f2i);}function S$z(K1B,A0B){p$V.y6g();return Boolean(K1B && A0B);}p$V.G4m(94);T_K=p$V.F9v(\"8\",1);function l5r(G1o,m5X){p$V.b8R(14);return p$V.F9v(\"\",m5X,G1o);}function K4e(a99,w2I,E4I,c2S){this.tokens=a99;this.ops1=w2I;this.ops2=E4I;p$V.j1L();this.functions=c2S;}function I22(Q$Q,b6s){p$V.b8R(95);return p$V.F9v(b6s,Q$Q);}u9q.extend(o50.prototype,{parse:function(l77){var e1y,K6l,r0U,x9f,R4E,l2U,l6K,r9h,V$p,z2G,L0l,o$F,d9c,k08;this.errormsg=\"\";this.success=!!({});p$V.j1L();e1y=[];K6l=[];p$V.G4m(63);this.tmpprio=p$V.F9v(\"0\",0);p$V.G4m(96);r0U=p$V.e7l(h0g,e57,g4w,A06);x9f=0;this.expression=l77;p$V.G4m(63);this.pos=p$V.F9v(\"0\",0);while(this.pos < this.expression.length){if(this.isOperator()){if(this.isSign() && r0U & e57){if(this.isNegativeSign()){this.tokenprio=2;this.tokenindex=\"-\";x9f++;this.addfunc(K6l,e1y,c64);}p$V.G4m(96);r0U=p$V.F9v(h0g,e57,g4w,A06);}else if(this.isComment()){}else {if((r0U & b_D) === 0){l2U=\"unexpected o\";l2U+=\"perator\";this.error_parsing(this.pos,l2U);}x9f+=+\"2\";this.addfunc(K6l,e1y,o9B);p$V.b8R(96);r0U=p$V.e7l(h0g,e57,g4w,A06);}}else if(this.isNumber()){if((r0U & A06) === 0){this.error_parsing(this.pos,\"unexpected number\");}R4E=new V8K(r9q,0,0,this.tokennumber);K6l.push(R4E);p$V.G4m(97);r0U=p$V.e7l(b_D,Y8a,s6Z);}else if(this.isString()){if((r0U & A06) === 0){l6K=\"u\";l6K+=\"nex\";l6K+=\"pected string\";this.error_parsing(this.pos,l6K);}R4E=new V8K(r9q,0,0,this.tokennumber);K6l.push(R4E);p$V.G4m(97);r0U=p$V.F9v(b_D,Y8a,s6Z);}else if(this.isLeftParenth()){if((r0U & g4w) === 0){r9h=\"unexpe\";r9h+=\"cted \\\"(\\\"\";this.error_parsing(this.pos,r9h);}if(r0U & e_J){x9f+=2;this.tokenprio=-2;this.tokenindex=-1;this.addfunc(K6l,e1y,r8o);}p$V.G4m(98);r0U=p$V.F9v(A06,h0g,e57,g4w,T_K);}else if(this.isRightParenth()){if(r0U & T_K){R4E=new V8K(r9q,0,0,[]);K6l.push(R4E);}else if((r0U & Y8a) === 0){this.error_parsing(this.pos,'unexpected \")\"');}p$V.G4m(98);r0U=p$V.F9v(b_D,s6Z,g4w,Y8a,e_J);}else if(this.isComma()){if((r0U & s6Z) === 0){this.error_parsing(this.pos,'unexpected \",\"');}this.addfunc(K6l,e1y,o9B);x9f+=2;p$V.G4m(96);r0U=p$V.F9v(h0g,e57,g4w,A06);}else if(this.isConst()){if((r0U & A06) === 0){this.error_parsing(this.pos,\"unexpected constant\");}V$p=new V8K(r9q,0,0,this.tokennumber);K6l.push(V$p);p$V.G4m(97);r0U=p$V.F9v(b_D,Y8a,s6Z);}else if(this.isOp2()){if((r0U & h0g) === 0){this.error_parsing(this.pos,\"unexpected function\");}this.addfunc(K6l,e1y,o9B);x9f+=2;r0U=g4w;}else if(this.isOp1()){if((r0U & h0g) === +\"0\"){z2G=\"unexpect\";z2G+=\"e\";z2G+=\"d fun\";z2G+=\"ction\";this.error_parsing(this.pos,z2G);}this.addfunc(K6l,e1y,c64);x9f++;r0U=g4w;}else if(this.isVar()){if((r0U & A06) === 0){this.error_parsing(this.pos,\"unexpected variable\");}L0l=new V8K(P4S,this.tokenindex,0,0);K6l.push(L0l);p$V.b8R(98);r0U=p$V.e7l(b_D,s6Z,g4w,Y8a,e_J);}else if(this.isWhite()){}else {if(this.errormsg === \"\"){o$F=\"unkno\";o$F+=\"wn character\";this.error_parsing(this.pos,o$F);}else {this.error_parsing(this.pos,this.errormsg);}}}if(this.tmpprio < +\"0\" || this.tmpprio >= \"10\" * 1){this.error_parsing(this.pos,'unmatched \"()\"');}while(e1y.length > 0){d9c=e1y.pop();K6l.push(d9c);}if(x9f + 1 !== K6l.length){k08=\"pari\";k08+=\"t\";k08+=\"y\";this.error_parsing(this.pos,k08);}return new K4e(K6l,k$q(this.ops1),k$q(this.ops2),k$q(this.functions));},evaluate:function(Z6$,k$S){return this.parse(Z6$).evaluate(k$S);},error_parsing:function(v54,h7M){var L2J;L2J=\"parse error \";L2J+=\"[column \";this.success=!!0;p$V.b8R(2);this.errormsg=p$V.e7l(\"]: \",h7M,v54,L2J);this.column=v54;throw new Error(this.errormsg);},addfunc:function(W6b,w9Q,E$L){var v_m;v_m=new V8K(E$L,this.tokenindex,this.tokenprio + this.tmpprio,0);while(w9Q.length > 0){if(v_m.prio_ <= w9Q[w9Q.length - 1].prio_){W6b.push(w9Q.pop());}else {break;}}p$V.j1L();w9Q.push(v_m);},isNumber:function(){var g8s,V9x,M8c;g8s=!\"1\";V9x=\"\";while(this.pos < this.expression.length){M8c=this.expression.charCodeAt(this.pos);if(M8c >= 48 && M8c <= 57 || M8c === 46){V9x+=this.expression.charAt(this.pos);this.pos++;this.tokennumber=parseFloat(V9x);g8s=!![];}else {break;}}return g8s;},unescape:function(o6L,r_d){var W4I,w4j,L3s,p2r;p$V.j1L();W4I=[];w4j=![];for(var M00=0;M00 < o6L.length;M00++){L3s=o6L.charAt(M00);if(w4j){switch(L3s){case +\"2530\" > 281.17?\"'\":+\"5.15e+3\":W4I.push(\"'\");break;case \"\\\\\":W4I.push(\"\\\\\");break;case 768.79 <= 343.9?(0x116d,166.17):\"/\":W4I.push(8550 < (15.58,1810)?(+\"8.26e+3\",\"E\"):(\"6900\" - 0,8228) !== 6836?3840 === (640.65,\"904\" | 0)?(!!({}),\"H\"):\"/\":0x1369);break;case (6061,4180) == (2940,2664)?5430 !== +\"56.03\"?486:0x1e0a:\"b\":W4I.push(\"\\b\");break;case 9052 >= (\"8263\" - 0,2050)?\"f\":\"4411\" * 1 != 5430?0x258d:6.82e+3:W4I.push((\"6170\" << 64,100) !== +\"3490\"?6660 !== 38.24?\"\\f\":(!\"1\",!\"\"):(0x10c2,453.44));break;case (3383,5187) == 764.41?(383.81,\"i\"):(5212,1210) == (324.43,9794)?(599.31,577.24) <= (9792,\"1161\" << 32)?(!!({}),0x952):868.76:\"n\":W4I.push(342.85 === (1307,\"291.36\" * 1)?(0x909,!!({})):(5137,1960) === (7724,492)?(\"9058\" ^ 0,1632) > +\"5973\"?(240.50,9.35e+3):42.62:\"\\n\");break;case \"r\":W4I.push((\"3563\" << 64,4266) <= 7092?\"\\r\":2.28e+3);break;case \"t\":W4I.push(\"\\t\");break;case \"u\":p2r=parseInt(o6L.substring(M00 + 1,M00 + 5),16);W4I.push(String.fromCharCode(p2r));p$V.b8R(1);M00+=p$V.F9v(\"4\",0);break;default:p$V.G4m(0);throw this.error_parsing(p$V.F9v(r_d,M00),p$V.e7l(\"Illegal escape sequence: '\\\\\",\"'\",L3s,p$V.G4m(14)));}w4j=!\"1\";}else {if(L3s == ((\"6535\" ^ 0,747.24) > (+\"2822\",138.35)?\"\\\\\":(1390,\"607\" >> 64) == 3770?(+\"0x25a2\",!\"1\"):3.35e+3)){w4j=!![];}else {W4I.push(L3s);}}}return W4I.join(\"\");},isString:function(){var m1e,G8F,P_L,h17;m1e=!!0;p$V.y6g();G8F=\"\";P_L=this.pos;if(this.pos < this.expression.length && this.expression.charAt(this.pos) == ((502.38,1956) == (904.42,7610)?(\"j\",702.88):305.25 >= (3617,478.34)?209.02 >= (106.3,222.39)?\"0x1058\" ^ 0:(938.64,4.28e+2):\"'\")){this.pos++;while(this.pos < this.expression.length){h17=this.expression.charAt(this.pos);if(h17 != \"'\" || G8F.slice(-1) == (3120 < (210.37,919.57)?532.19 !== 9510?(+\"350.38\",2680) > 675.23?3.53e+3:(6.37e+3,3.55e+3):654:\"\\\\\")){G8F+=this.expression.charAt(this.pos);this.pos++;}else {this.pos++;this.tokennumber=this.unescape(G8F,P_L);m1e=!![];break;}}}return m1e;},isConst:function(){var y2I,o5C;for(var e3Y in this.consts){if(!!\"1\"){o5C=e3Y.length;y2I=this.expression.substr(this.pos,o5C);if(e3Y === y2I){this.tokennumber=this.consts[e3Y];this.pos+=o5C;return !\"\";}}}return !({});},isOperator:function(){var j2b,S_F,P3_,J8q,j0U;j2b=this.expression.charCodeAt(this.pos);if(j2b === 43){this.tokenprio=2;this.tokenindex=(5047,5302) <= (7951,203.72)?(!!0,808.47):\"+\";}else if(j2b === 45){this.tokenprio=+\"2\";this.tokenindex=\"-\";}else if(j2b === 62){if(this.expression.charCodeAt(this.pos + 1) === 61){this.pos++;this.tokenprio=1;this.tokenindex=\">=\";}else {this.tokenprio=1;this.tokenindex=\">\";}}else if(j2b === \"60\" - 0){if(this.expression.charCodeAt(this.pos + 1) === 61){this.pos++;S_F=-884997576;P3_=-797118731;J8q=2;for(var n9e=\"1\" ^ 0;p$V.P6(n9e.toString(),n9e.toString().length,39552) !== S_F;n9e++){this.tokenprio=5;this.tokenindex=\"\";J8q+=2;}if(p$V.P6(J8q.toString(),J8q.toString().length,5739) !== P3_){this.tokenprio=1;this.tokenindex=\"<=\";}}else {this.tokenprio=1;this.tokenindex=884.83 != 7520?(9759,646) === (1730,4133)?\"r\":\"<\":!1;}}else if(j2b === 124){if(this.expression.charCodeAt(this.pos + 1) === (\"124\" | 28)){j0U=\"|\";j0U+=\"|\";this.pos++;this.tokenprio=1;this.tokenindex=j0U;}else {return !!0;}}else if(j2b === 61){if(this.expression.charCodeAt(this.pos + 1) === 61){this.pos++;this.tokenprio=1;this.tokenindex=\"==\";}else {return !({});}}else if(j2b === 33){if(this.expression.charCodeAt(this.pos + 1) === 61){this.pos++;this.tokenprio=1;this.tokenindex=\"!=\";}else {return !({});}}else if(j2b === 97){if(this.expression.charCodeAt(this.pos + 1) === 110 && this.expression.charCodeAt(this.pos + 2) === 100){this.pos++;this.pos++;this.tokenprio=0;this.tokenindex=\"and\";}else {return ![];}}else if(j2b === 111){if(this.expression.charCodeAt(this.pos + 1) === 114){this.pos++;this.tokenprio=0;this.tokenindex=\"or\";}else {return !({});}}else if(j2b === 42 || j2b === 8729 || j2b === 8226){this.tokenprio=3;this.tokenindex=5540 === (9161,771.2)?\"l\":9580 !== 5880?\"*\":(2590,+\"649.18\") > (2012,51.11)?(!0,2.95e+3):386.57;}else if(j2b === 47){p$V.b8R(34);this.tokenprio=p$V.e7l(\"4\",4);this.tokenindex=\"/\";}else if(j2b === 37){this.tokenprio=4;this.tokenindex=(9111,+\"7400\") < (697.22,\"535.11\" * 1)?750.59:\"%\";}else if(j2b === 94){this.tokenprio=5;this.tokenindex=(6996,119.37) !== 3626?\"^\":+\"0x239d\";}else {return !\"1\";}this.pos++;return !!({});},isSign:function(){var D5Q;D5Q=this.expression.charCodeAt(this.pos - 1);p$V.y6g();if(D5Q === 45 || D5Q === 43){return !!({});}return !!0;},isPositiveSign:function(){var W9g;p$V.j1L();W9g=this.expression.charCodeAt(this.pos - 1);if(W9g === 43){return !!\"1\";}return !\"1\";},isNegativeSign:function(){var g90;g90=this.expression.charCodeAt(this.pos - 1);if(g90 === 45){return !\"\";}return !!\"\";},isLeftParenth:function(){var Q_w;Q_w=this.expression.charCodeAt(this.pos);if(Q_w === 40){this.pos++;this.tmpprio+=+\"10\";return !!1;}return ![];},isRightParenth:function(){var s56;s56=this.expression.charCodeAt(this.pos);p$V.j1L();if(s56 === 41){this.pos++;this.tmpprio-=10;return !![];}return !\"1\";},isComma:function(){var C5o;C5o=this.expression.charCodeAt(this.pos);if(C5o === 44){this.pos++;this.tokenprio=-+\"1\";this.tokenindex=5020 === 7075?6.87e+2:\",\";return !!({});}return !!\"\";},isWhite:function(){var W2E;p$V.y6g();W2E=this.expression.charCodeAt(this.pos);if(W2E === +\"32\" || W2E === 9 || W2E === 10 || W2E === 13){this.pos++;return !![];}return !!\"\";},isOp1:function(){var g1t,W$X;g1t=\"\";for(var o5t=this.pos;o5t < this.expression.length;o5t++){W$X=this.expression.charAt(o5t);if(W$X.toUpperCase() === W$X.toLowerCase()){if(o5t === this.pos || W$X != (+\"4856\" !== (+\"937.84\",6350)?6351 != (716.84,9506)?\"_\":(+\"175.67\",3.24e+3):0x837) && (W$X < \"0\" || W$X > \"9\")){break;}}g1t+=W$X;}if(g1t.length > 0 && (g1t in this.ops1)){this.tokenindex=g1t;p$V.G4m(4);this.tokenprio=p$V.e7l(\"5\",0);this.pos+=g1t.length;return !0;}return !({});},isOp2:function(){var r8k,L6I;r8k=\"\";p$V.y6g();for(var m2D=this.pos;m2D < this.expression.length;m2D++){L6I=this.expression.charAt(m2D);if(L6I.toUpperCase() === L6I.toLowerCase()){if(m2D === this.pos || L6I != (+\"6240\" == (6.47,+\"951.33\")?(9558,\"455.96\" - 0) <= (7864,9054)?(8689,740.1) > (711.96,4380)?\"G\":!!0:!!({}):\"_\") && (L6I < \"0\" || L6I > (590.68 === 1438?(0x192,0x12f2):(3210,3790) === (522.66,1910)?(\"403.17\" * 1,9028) != 21?(331.02,\"P\"):358.55:\"9\"))){break;}}r8k+=L6I;}if(r8k.length > 0 && (r8k in this.ops2)){this.tokenindex=r8k;this.tokenprio=+\"5\";this.pos+=r8k.length;return !!({});}return !!\"\";},isVar:function(){var a9t,G6T;a9t=\"\";for(var b7G=this.pos;b7G < this.expression.length;b7G++){G6T=this.expression.charAt(b7G);if(G6T.toUpperCase() === G6T.toLowerCase()){if(b7G === this.pos || G6T != ((3723,7590) === 8038?466.08:2863 >= (4850,104.5)?\"_\":549.81) && (G6T < (3248 <= (\"6989\" * 1,\"41.82\" - 0)?(118.81,!\"1\"):\"0\") || G6T > (\"4880\" * 1 == (5244,278)?(\"O\",!!0):\"9\"))){break;}}a9t+=G6T;}if(a9t.length > 0){this.tokenindex=a9t;this.tokenprio=4;this.pos+=a9t.length;return !0;}return !({});},isComment:function(){var P4N;P4N=this.expression.charCodeAt(this.pos - +\"1\");p$V.y6g();if(P4N === 47 && this.expression.charCodeAt(this.pos) === 42){p$V.G4m(99);var C6C=p$V.F9v(3,1,11,3);this.pos=this.expression.indexOf(\"*/\",this.pos) + C6C;if(this.pos === +\"1\"){this.pos=this.expression.length;}return !!({});}return !({});}},!!\"1\");function j85(A8s,V5g){p$V.G4m(100);return p$V.F9v(A8s,V5g);}function P6Z(w2$,e0X){p$V.b8R(101);p$V.j1L();return p$V.F9v(e0X,w2$);}return o50;};u9q.computeEquationChart=function(U96,g3s){var F4U=k_Cdw;var B4N,f0A,d3j,k7W,v_6,s_Q,j60,s0f,B1S,B78,Y_S,h4c,V6X,v4i,x8f,z$v,s$z,m_0,u3b,Y6N,G7H,R3Y,V5a,O2B,P1f;U96=U96.replace(/[:]/,(868,5580) <= 6710?\"/\":(8.48e+3,!!0));F4U.G4m(1);B4N=F4U.e7l(\"0\",0);for(var v3j in g3s){f0A=\"s\";f0A+=\"ym\";f0A+=\"bol\";d3j=\"\\\\\";d3j+=\"$&\";k7W=\"\\\\\";k7W+=\"[\";v_6=\"\\\\\";v_6+=\"[\";s_Q=new RegExp(v_6 + v3j.replace(/\\[/g,k7W).replace(/\\]/g,\"\\\\]\").replace(/\\$/g,\"\\\\$\").replace(/\\^/g,\"\\\\^\").replace(/[+\\-*/%()]/g,d3j) + \"\\\\]\",(+\"320.47\",2621) > (+\"964.55\",566)?\"g\":(5.73e+3,917.24));F4U.b8R(0);U96=U96.replace(s_Q,F4U.e7l(f0A,B4N));B4N++;}j60=r2f().parse(U96);s0f=[];B1S={};B78=0;h4c=null;V6X=!({});v4i=[];function g9o(d5z){d5z.i++;if(g3s[d5z.s]){if(d5z.i >= g3s[d5z.s].length){return 0;}Y_S=g3s[d5z.s][d5z.i];}if(!Y_S.DT){Y_S.DT=u9q.strToDateTime(Y_S.Date);}d5z.d=Y_S.DT;return 1;}function z2E(){var s$Z,C9w;s$Z=null;C9w=null;for(var H2F in B1S){if(!C9w){C9w=B1S[H2F];}else if(B1S[H2F].d.getTime() < C9w.d.getTime()){s$Z=C9w=B1S[H2F];}else if(B1S[H2F].d.getTime() > C9w.d.getTime()){s$Z=C9w;}}F4U.y6g();if(s$Z){if(!g9o(s$Z)){return +\"0\";}return -1;}return 1;}for(v3j in g3s){x8f={sym:v3j,map:g3s[v3j]};if(g3s[v3j]){v4i.unshift(x8f);}else {v4i.push(x8f);}}for(var x_c=+\"0\";x_c < v4i.length;x_c++){z$v=v4i[x_c];B1S[z$v.sym]={i:0,s:z$v.sym};if(z$v.map){B78++;Y_S=z$v.map[0];}else if(B78 == 1){V6X=z$v.sym;}if(!Y_S.DT){Y_S.DT=u9q.strToDateTime(Y_S.Date);}B1S[z$v.sym].d=Y_S.DT;if(!h4c){h4c=B1S[z$v.sym];}}F4U.b8R(102);s$z=F4U.F9v(0,B78);m_0=B78 == 1 && U96.indexOf((+\"187\",1840) <= (8873,3110)?868.52 > 291.09?(4100,\"3200\" ^ 0) !== 1370?\"%\":328.64:0xe15:0x22a7) == -1;a:while(!![]){u3b=z2E();if(!u3b)break;if(u3b == 1){if(V6X){G7H=g3s[h4c.s][h4c.i][V6X];if(G7H && (G7H.Close || G7H.Close === 0)){G7H=G7H.Close;}R3Y=j60.evaluate({symbol0:g3s[h4c.s][h4c.i].Close,symbol1:G7H});R3Y=Number(R3Y.toFixed(8));Y6N={DT:h4c.d,Close:R3Y,Adj_Close:R3Y};Y6N[h4c.s]=g3s[h4c.s][h4c.i].Close;if(!isNaN(R3Y) && R3Y != Infinity){s0f.push(Y6N);}}else if(s$z){V5a=j60.evaluate({});F4U.b8R(14);u9q.alert(F4U.e7l(U96,V5a,\"=\"));throw {name:\"NoException\",message:\"\"};}else {B4N=0;O2B={Adj_Close:{},Close:{},Open:{},High:{},Low:{},Volume:{}};for(v3j in g3s){for(var B$r in O2B){P1f=\"sy\";P1f+=\"mbol\";F4U.b8R(0);O2B[B$r][F4U.F9v(P1f,B4N)]=g3s[v3j][B1S[v3j].i][B$r];}B4N++;}Y6N={DT:h4c.d};Y6N.Adj_Close=j60.evaluate(O2B.Adj_Close);Y6N.Close=j60.evaluate(O2B.Close);Y6N.Open=j60.evaluate(O2B.Open);Y6N.Volume=j60.evaluate(O2B.Volume);if(isNaN(Y6N.Volume)){Y6N.Volume=+\"0\";}if(m_0){Y6N.High=j60.evaluate(O2B.High);Y6N.Low=j60.evaluate(O2B.Low);}else {Y6N.High=Math.max(Y6N.Open,Y6N.Close);Y6N.Low=Math.min(Y6N.Open,Y6N.Close);}if(!isNaN(Y6N.Close) && Y6N.Close != Infinity){s0f.push(Y6N);}if(!isNaN(Y6N.High)){Y6N.High=Number(Y6N.High.toFixed(8));}if(!isNaN(Y6N.Low)){Y6N.Low=Number(Y6N.Low.toFixed(8));}if(!isNaN(Y6N.Open)){Y6N.Open=Number(Y6N.Open.toFixed(8));}if(!isNaN(Y6N.Close)){Y6N.Close=Number(Y6N.Close.toFixed(+\"8\"));}if(!isNaN(Y6N.Adj_Close)){Y6N.Adj_Close=Number(Y6N.Adj_Close.toFixed(8));}else {Y6N.Adj_Close=Y6N.Close;}}for(v3j in g3s){if(!g9o(B1S[v3j]))break a;}}}return s0f;};};B9=z28=>{var e1K=k_Cdw;var C24,s5u;C24=\"e\";C24+=\"n\";s5u=typeof _CIQ !== \"undefined\"?_CIQ:z28.CIQ;s5u.ChartEngine.prototype.setLocale=function(W2r,y20){var r_f,B6R,d85,C4P,H$N,u5s,O5o,C2E,E2B,m6M;r_f=\"numer\";r_f+=\"ic\";B6R=\"2\";B6R+=\"-di\";B6R+=\"gi\";B6R+=\"t\";d85=\"2-di\";d85+=\"gi\";d85+=\"t\";C4P=\"2-d\";C4P+=\"igit\";H$N=\"num\";H$N+=\"er\";H$N+=\"i\";H$N+=\"c\";u5s=\"un\";u5s+=\"def\";u5s+=\"ine\";u5s+=\"d\";if(typeof Intl == u5s){return;}if(this.locale != W2r){this.locale=W2r;}else {return;}C2E=this.internationalizer={};C2E.hourMinute=new Intl.DateTimeFormat(this.locale,{hour:\"numeric\",minute:H$N,hourCycle:\"h23\"});C2E.hourMinuteSecond=new Intl.DateTimeFormat(this.locale,{hour:\"numeric\",minute:\"numeric\",second:\"numeric\",hourCycle:\"h23\"});C2E.mdhm=new Intl.DateTimeFormat(this.locale,{year:\"2-digit\",month:C4P,day:d85,hour:B6R,minute:\"2-digit\"});C2E.monthDay=new Intl.DateTimeFormat(this.locale,{month:\"numeric\",day:\"numeric\"});C2E.yearMonthDay=new Intl.DateTimeFormat(this.locale,{year:\"numeric\",month:r_f,day:\"numeric\"});C2E.yearMonth=new Intl.DateTimeFormat(this.locale,{year:\"numeric\",month:\"numeric\"});C2E.month=new Intl.DateTimeFormat(this.locale,{month:\"short\"});C2E.numbers=new Intl.NumberFormat(this.locale);C2E.priceFormatters=[];if(!y20){y20=8;}for(O5o=\"0\" << 0;O5o < y20 + 1;O5o++){C2E.priceFormatters.push(new Intl.NumberFormat(this.locale,{maximumFractionDigits:O5o,minimumFractionDigits:O5o}));}for(O5o=\"0\" - 0;O5o < 5;O5o++){E2B=O5o;m6M=O5o;if(!O5o){E2B=\"\";m6M=+\"2\";}e1K.b8R(0);C2E[e1K.F9v(\"percent\",E2B)]=new Intl.NumberFormat(this.locale,{style:\"percent\",minimumFractionDigits:m6M,maximumFractionDigits:m6M});}if(s5u.I18N.createMonthArrays){s5u.I18N.createMonthArrays(this,C2E.month,this.locale);}};s5u.ChartEngine.prototype.translateUI=function(N8z){e1K.j1L();if(s5u.I18N.localized){s5u.I18N.translateUI(this.preferences.language,N8z);}};s5u.I18N=function(){};s5u.I18N.hereDoc=function(K5l){e1K.y6g();return K5l.toString().replace(/^[^/]+\\/\\*!?/,\"\").replace(/\\*\\/[^/]+$/,\"\");};s5u.I18N.language=C24;s5u.I18N.longMonths={zh:!!({})};s5u.I18N.reverseColorsByLocale={zh:!![],ja:!!1};s5u.I18N.findAllTextNodes=function(o0o){var f3E,k2I,x5Y,w_E,M4I,m35,J9I,B5J,f3H,l6$,i8C,h1v,o52,j$q,y8a,r0y,D7n,H$i,X2a,h9W,g6t,r87;if(!o0o){o0o=document.body;}if(o0o == document.body){f3E=\".c\";f3E+=\"iq_\";f3E+=\"stashed_tex\";f3E+=\"ts\";if(!document.querySelector(f3E)){k2I=\"n\";k2I+=\"o\";k2I+=\"n\";k2I+=\"e\";x5Y=document.createElement(\"div\");x5Y.className=\"ciq_stashed_texts\";x5Y.style.display=k2I;o0o.appendChild(x5Y);w_E=document.querySelectorAll(\"input,textarea,.editable_content\");for(var C7J=\"0\" << 0;C7J < w_E.length;C7J++){M4I=w_E[C7J].getAttribute(\"placeholder\");if(M4I){m35=\"orig\";m35+=\"in\";m35+=\"al\";J9I=x5Y.appendChild(document.createElement(\"cq-translate\"));J9I.setAttribute(m35,M4I);J9I.placeholderFor=w_E[C7J];J9I.appendChild(document.createTextNode(M4I));}}}}B5J=document.createTreeWalker(o0o,NodeFilter.SHOW_TEXT,null,![]);f3H=B5J.nextNode();l6$=new RegExp(\"^\\\\s*$\");i8C=new RegExp(\"\\n|\\t|\\f\",\"g\");h1v={};o52={SCRIPT:!!({}),STYLE:!![],TEXTAREA:!!({})};e1K.y6g();while(f3H){j$q=f3H.nodeValue;if(!l6$.test(j$q)){y8a=f3H.parentNode;r0y=f3H.nextSibling;D7n=y8a.tagName;if(!o52[D7n]){if(D7n != \"CQ-TRANSLATE\"){H$i=\"o\";H$i+=\"rigi\";H$i+=\"n\";H$i+=\"al\";X2a=\"c\";X2a+=\"q-tr\";X2a+=\"ansla\";X2a+=\"te\";h9W=document.createElement(X2a);h9W.setAttribute(H$i,j$q);h9W.appendChild(f3H);y8a.insertBefore(h9W,r0y);}else {j$q=y8a.getAttribute(\"original\");}if(i8C.test(j$q)){j$q=j$q.replace(i8C,\"\");}if(!h1v[j$q]){h1v[j$q]=[];}h1v[j$q].push(f3H);}}f3H=B5J.nextNode();}if(o0o == document.body){g6t=s5u.Studies?s5u.Studies.studyLibrary:null;if(g6t){for(var L6J in g6t){if(h1v[L6J] === null){h1v[L6J]=[];}r87=g6t[L6J];if(r87.inputs){for(var F$1 in r87.inputs){if(!h1v[F$1]){h1v[F$1]=[];}}}if(r87.outputs){for(var F8j in r87.outputs){if(!h1v[F8j]){h1v[F8j]=[];}}}}}}return h1v;};s5u.I18N.missingWordList=function(p3P){var O4E,S$l,X7O,h21,p$7,Z4_;if(!p3P){p3P=s5u.I18N.language;}O4E=s5u.I18N.findAllTextNodes();S$l={};X7O=s5u.I18N.wordLists[p3P];if(!X7O){X7O={};}h21=function(i4A){var H4Z;H4Z=\"u\";H4Z+=\"ndef\";H4Z+=\"ined\";if(typeof X7O[i4A] == H4Z){S$l[i4A]=\"\";}};for(var D5t in O4E){h21(D5t);}if(!(s5u.Studies && s5u.Studies.studyLibrary)){return S$l;}for(var p8f in s5u.Studies.studyLibrary){p$7=s5u.Studies.studyLibrary[p8f];h21(p$7.name);for(var h7L in p$7.inputs){h21(h7L);Z4_=p$7.inputs[h7L];switch(Object.prototype.toString.call(Z4_)){case \"[object String]\":h21(Z4_);break;case \"[object Array]\":for(var E$2=0;E$2 < Z4_.length;++E$2){h21(Z4_[E$2]);}break;}}for(var M8i in p$7.outputs){h21(M8i);}}h21(\"Show Zones\");h21(\"OverBought\");h21(\"OverSold\");h21(\"Panel\");h21(\"Show as Underlay\");h21(\"Y-Axis\");h21(\"Invert Y-Axis\");return S$l;};s5u.I18N.printableMissingWordList=function(S7p){var Y4T;e1K.y6g();Y4T=JSON.stringify(s5u.I18N.missingWordList(S7p));Y4T=Y4T.replace(/\",\"/g,'\",\\n\"');return Y4T;};s5u.I18N.translateUI=function(n26,t$t){var v42,Z1C,C5B,L3x,v$t,r9a,W$s,F7B;if(n26 == \"pu\"){n26=\"pt\";}if(!s5u.I18N.wordLists){return;}if(!n26){n26=s5u.I18N.language;}v42=s5u.I18N.findAllTextNodes(t$t);Z1C=s5u.I18N.wordLists[n26];if(!Z1C){return;}for(var o6Y in v42){C5B=s5u.I18N.translateSections(o6Y,Z1C);L3x=v42[o6Y];for(var V7$=0;V7$ < L3x.length;V7$++){v$t=L3x[V7$];r9a=v$t.parentNode;W$s=r9a.getAttribute(\"original\");if(C5B === \",\" || !C5B){C5B=W$s;}F7B=r9a.placeholderFor;if(F7B){F7B.placeholder=C5B;}else {v$t.data=C5B;}}}};s5u.I18N.translate=function(C36,s9R){var Q4j,h1z;if(!s9R){s9R=s5u.I18N.language;}if(!s5u.I18N.wordLists){console.log(\"Must include translations.js in order to use CIQ.I18N.translate()\");return C36;}Q4j=s5u.I18N.wordLists[s9R];h1z=null;if(Q4j){h1z=s5u.I18N.translateSections(C36,Q4j) || C36;}return h1z === \",\"?C36:h1z;};s5u.I18N.translateSections=function(D4J,V69){var E5u,L7A;E5u=(8294,\"959.72\" * 1) < (600,\"1830\" ^ 0)?4940 == 5040?(8534,7680) == (336.28,2220)?(0x2143,0x1ff0):0x1f5c:\"\\u200c\":(831.22,1.22e+2);if(typeof D4J == \"string\" && D4J.indexOf(E5u) != -1){e1K.b8R(14);D4J=D4J.replace(/([(),])/g,e1K.e7l(E5u,E5u,\"$1\"));L7A=D4J.split(E5u);L7A.forEach(function(l0V,V3Y,W3q){var f2E,f6n;f2E=l0V.match(/^(\\s*).{0,100}\\S(\\s*)$/);f6n=V69[l0V.trim()];if(f6n){if(f2E){f6n=f2E[\"1\" - 0] + f6n + f2E[+\"2\"];}W3q[V3Y]=f6n;}});return L7A.join(\"\");}return V69[D4J];};e1K.j1L();s5u.I18N.convertCSV=function(X9q){e1K.y6g();var t5D,k$I,q64,A64,L7e,T4V,P6U,n83,E5H,X44,X6c,w$_;t5D=\"[\\u201C\";t5D+=\"\\u201D]|[\\u2018\\u2019]\";k$I=new RegExp(t5D,(40.8,7030) != 1990?\"g\":(0x1fa,0x1088));q64=s5u.I18N.wordLists;if(!X9q){X9q=s5u.I18N.csv;}if(!X9q){return;}A64=X9q.split((8583,553.34) != (+\"7520\",919.05)?746.49 < 3408?\"\\n\":(0xf0f,0x9e7):(\"g\",8.55e+3));L7e=A64[0];T4V=L7e.split((\"2280\" - 0,514) !== 4970?760.59 != (+\"254.92\",395.39)?+\"878.17\" < 494.11?(212.76,\"R\"):\",\":(0xa10,\"V\"):(4.25e+3,!({})));for(var B1v=0;B1v < T4V.length;B1v++){P6U=T4V[B1v];if(!q64[P6U]){q64[P6U]={};}}for(var H1O=1;H1O < A64.length;H1O++){n83=A64[H1O].match(/(\".{0,1000}\"|[^\",]{1,1000})(?=\\s{0,100},|\\s{0,100}$)|(,(?=,))/g) || [];E5H=n83[0];X44=E5H.charAt(0);X6c=E5H.charAt(E5H.length - 1);if(X44 === '\"' && X6c === ((\"868.48\" * 1,61) != 4675?216.97 !== (\"1390\" - 0,317.84)?6394 >= (6930,5410)?'\"':0x409:\"f\":(!!\"1\",\"l\"))){E5H=E5H.substring(1,E5H.length - 1);}if(k$I.test(E5H)){E5H=E5H.replace(k$I,2147 != 6030?6340 != (746.63,989.71)?'\"':654.32:(!0,9.15e+3));}for(var N75=1;N75 < n83.length;N75++){w$_=n83[N75];X44=w$_.charAt(0);X6c=w$_.charAt(w$_.length - 1);if(X44 === ((1050,\"51.62\" - 0) === 3790?0x6af:'\"') && X6c === ((1781,397.39) < 5930?6030 != 7914?4820 >= (3622,3388)?'\"':(0x2100,\"2.96e+2\" - 0):\"Z\":0xac3)){w$_=w$_.substring(1,w$_.length - 1);}q64[T4V[N75]][E5H]=w$_;}}};s5u.I18N.setLanguage=function(v7Q,g6K,h0Y,U4y,S8p){if(!S8p){S8p=(v7Q.uiContext || ({})).topNode || document.body;}if(g6K == \"pu\"){g6K=\"pt\";}s5u.I18N.convertCSV(U4y);s5u.I18N.language=g6K;s5u.I18N.translateUI(g6K,S8p);if(!h0Y){h0Y=s5u.I18N.translate;}v7Q.translationCallback=h0Y;};s5u.I18N.setLocale=function(X5Z,n_F,G3I,i4k,Y$D){var K04,V$b,B7W,l_B,r35,P6Y,T2b,i2z;K04=\"SC\";K04+=\"R\";K04+=\"I\";K04+=\"PT\";V$b=\"u\";V$b+=\"nd\";V$b+=\"efined\";if(s5u.xor(this.reverseColorsByLocale[n_F],this.reverseColorsByLocale[X5Z.locale])){this.reverseCandles(X5Z);}if(typeof Intl == \"undefined\" || !Intl.__addLocaleData){X5Z.setLocale(n_F,Y$D);if(G3I){G3I(null);}return;}i4k=typeof i4k == V$b?\"locale-data/jsonp\":i4k;e1K.G4m(2);B7W=e1K.e7l(n_F,\".js\",1660 <= (9752,3103)?1800 != (\"5010\" | 18,874.62)?\"/\":\"m\":\"6.47e+3\" << 32,i4k);l_B=document.createElement(K04);r35=111029250;P6Y=-1453108733;T2b=2;for(var R8c=1;e1K.m1(R8c.toString(),R8c.toString().length,95496) !== r35;R8c++){l_B.async=!({});T2b+=2;}if(e1K.P6(T2b.toString(),T2b.toString().length,9879) !== P6Y){l_B.async=!!({});}l_B.async=!\"\";l_B.src=B7W;i2z=document.getElementsByTagName(\"script\")[+\"0\"];i2z.parentNode.insertBefore(l_B,i2z.nextSibling);l_B.onload=function(){X5Z.setLocale(n_F,Y$D);if(G3I){G3I(null);}};l_B.onerror=function(){if(G3I){G3I(\"cannot load script\");}};};s5u.I18N.createMonthArrays=function(P59,n7J,w90){var e02,E11,V$A,L2b,I1K,g36;P59.monthAbv=[];P59.monthLetters=[];e1K.y6g();e02=new Date();E11=!![];if(s5u.I18N.longMonths && s5u.I18N.longMonths[w90]){E11=!!0;}for(var L3j=0;L3j < 12;L3j++){e02.setDate(1);e02.setMonth(L3j);V$A=n7J.format(e02);if(E11){L2b=\"\";for(var B2c=0;B2c < V$A.length;B2c++){I1K=V$A.charAt(B2c);g36=I1K.charCodeAt(0);if(g36 < 65)continue;L2b+=I1K;}P59.monthAbv[L3j]=L2b;e1K.b8R(1);P59.monthLetters[L3j]=L2b[e1K.F9v(\"0\",64)];}else {P59.monthAbv[L3j]=V$A;P59.monthLetters[L3j]=V$A;}}};s5u.I18N.localize=function(C1l,G2h){G2h=this.langConversionMap[G2h] || G2h;e1K.y6g();this.setLocale(C1l,G2h);this.setLanguage(C1l,G2h);s5u.I18N.localized=!![];};s5u.I18N.reverseCandles=function(b7Q){var R0C,o5e,P65;R0C=b7Q.styles;o5e=b7Q.cloneStyle(R0C.stx_candle_down);P65=b7Q.cloneStyle(R0C.stx_candle_up);R0C.stx_candle_up=o5e;R0C.stx_candle_down=P65;};s5u.I18N.wordLists={en:{}};s5u.I18N.languages={en:\"English\"};s5u.I18N.langConversionMap={};s5u.I18N.localized=!!0;};V$=N3g=>{var g0X,o6w,b24,a$K,s0$;g0X=\"
    \";o6w=\"
    \";b24=\"\";a$K=typeof _CIQ !== \"undefined\"?_CIQ:N3g.CIQ;a$K.ChartEngine.prototype.pointerEvents={down:[],up:[]};a$K.ChartEngine.prototype.manageTouchAndMouse=!0;a$K.ChartEngine.prototype.registerTouchAndMouseEvents=function(){var w17,Z_I,L4O,G9_,Y8X,F6x,F0G,p$L,Y9M,r7q,h6s,h1A,O$h,q2W,x2b,i$b;if(this.touchAndMouseEventsRegistered){return;}this.touchAndMouseEventsRegistered=!!1;w17=this.controls.chartControls || document;Z_I=w17.querySelector(\".stx-zoom-in\");L4O=w17.querySelector(\".stx-zoom-out\");G9_=this.chart.container;Y8X=this;F6x=function(H8A,S6B,r1S){Y8X.addDomEventListener(G9_,H8A,s4f,r1S);function s4f(I0N){if(Y8X.mainSeriesRenderer && Y8X.mainSeriesRenderer.nonInteractive){return;}k_Cdw.j1L();S6B(I0N);}};if(!a$K.touchDevice){F0G=\"m\";F0G+=\"ous\";F0G+=\"edow\";F0G+=\"n\";F6x(\"mousemove\",function(O1b){k_Cdw.y6g();Y8X.mousemove(O1b);});F6x(\"mouseenter\",function(E_2){Y8X.mousemove(E_2);});F6x(F0G,function(r17){k_Cdw.y6g();Y8X.mousedown(r17);});F6x(\"mouseup\",function(o2R){k_Cdw.j1L();Y8X.mouseup(o2R);});}else {if(a$K.isSurface){p$L=\"pointer\";p$L+=\"up\";Y9M=\"p\";Y9M+=\"ointe\";Y9M+=\"renter\";r7q=\"poin\";r7q+=\"te\";r7q+=\"rmov\";r7q+=\"e\";h6s=\"pointer\";h6s+=\"down\";h1A=\"mouse\";h1A+=\"enter\";F6x(\"mousemove\",function(K40){Y8X.msMouseMoveProxy(K40);});F6x(h1A,function(v4F){k_Cdw.j1L();Y8X.msMouseMoveProxy(v4F);});F6x(\"mousedown\",function(e0n){Y8X.msMouseDownProxy(e0n);});F6x(\"mouseup\",function(t5y){Y8X.msMouseUpProxy(t5y);});F6x(h6s,function(j_m){k_Cdw.y6g();return Y8X.startProxy(j_m);});F6x(r7q,function(Q6Y){k_Cdw.j1L();Y8X.moveProxy(Q6Y);});F6x(Y9M,function(f55){return Y8X.moveProxy(f55);});F6x(p$L,function(Z4O){return Y8X.endProxy(Z4O);});}else {if(!a$K.isMobile){O$h=\"mo\";O$h+=\"usedown\";q2W=\"mou\";q2W+=\"s\";q2W+=\"e\";q2W+=\"move\";F6x(q2W,function(a50){Y8X.iosMouseMoveProxy(a50);});F6x(\"mouseenter\",function(n0S){k_Cdw.j1L();Y8X.iosMouseMoveProxy(n0S);});F6x(O$h,function(C70){Y8X.iosMouseDownProxy(C70);});F6x(\"mouseup\",function(r47){Y8X.iosMouseUpProxy(r47);});}F6x(\"touchstart\",function(k9J){k_Cdw.y6g();Y8X.touchstart(k9J);},{passive:![]});F6x(\"touchmove\",function(W$O){Y8X.touchmove(W$O);},{passive:!({})});F6x(\"touchend\",function(F6z){k_Cdw.y6g();Y8X.touchend(F6z);});F6x(\"pointerdown\",function(S$I){k_Cdw.y6g();Y8X.touchPointerType=S$I.pointerType;});if(Z_I){x2b=\"on\";x2b+=\"MouseOut\";Z_I.removeAttribute(\"onMouseOver\");Z_I.removeAttribute(x2b);}if(L4O){L4O.removeAttribute(\"onMouseOver\");L4O.removeAttribute(\"onMouseOut\");}}}i$b=a$K.wheelEvent;if(this.captureMouseWheelEvents){F6x(i$b,function(m4I){k_Cdw.j1L();Y8X.mouseWheel(m4I);},{passive:![]});}};a$K.ChartEngine.prototype.mousedown=function(v2Q){var X3Z,H_O,f$N,z9f,R4C,F_c,D84,b3L;X3Z=\"m\";X3Z+=\"oused\";X3Z+=\"own\";if(this.runPrepend(\"mousedown\",arguments)){return;}this.grabOverrideClick=!({});if(!this.displayInitialized){return;}if(!this.displayCrosshairs){return;}if(this.repositioningDrawing){return;}if(this.editingAnnotation){return;}if(v2Q.button && v2Q.button >= (\"2\" ^ 0)){return;}H_O=this.container.getBoundingClientRect();this.top=H_O.top;this.left=H_O.left;this.right=this.left + this.width;this.bottom=this.top + this.height;if(v2Q.clientX >= this.left && v2Q.clientX <= this.right && v2Q.clientY >= this.top && v2Q.clientY <= this.bottom){this.insideChart=!\"\";}else {this.insideChart=!({});return;}if(!this.currentPanel){return;}if(this.manageTouchAndMouse && v2Q && v2Q.preventDefault && this.captureTouchEvents){v2Q.preventDefault();}this.mouseTimer=Date.now();this.longHoldTookEffect=!1;this.hasDragged=![];this.userPointerDown=!!\"1\";if(this.openDialog === \"\"){this.registerPointerEvent({x:v2Q.clientX,y:v2Q.clientY,time:this.mouseTimer},\"down\");}f$N=this.currentPanel.chart;for(var g3H=0;g3H < this.drawingObjects.length;g3H++){z9f=this.drawingObjects[g3H];if(z9f.highlighted && !z9f.permanent){if(this.cloneDrawing){R4C=a$K.ChartEngine.drawingTools[z9f.name];F_c=new R4C();F_c.reconstruct(this,z9f.serialize());this.drawingObjects.push(F_c);this.activateRepositioning(F_c);F_c.repositioner=z9f.repositioner;return;}D84=this.currentVectorParameters.vectorType;if(!a$K.Drawing || !D84 || !a$K.Drawing[D84] || !new a$K.Drawing[D84]().dragToDraw){this.activateRepositioning(z9f);return;}}}b3L=this.mainSeriesRenderer || ({});var {baselineHelper:k0q}=this;if(k0q.size){if(this.findBaselineHandle(v2Q,!![])){return;}}var {anchorHandles:L5j}=this.controls;if(L5j){for(var w6j in L5j){var {handle:l_4, sd:Y_k, highlighted:M5L}=L5j[w6j];if(M5L){this.repositioningAnchorSelector={sd:Y_k};l_4.classList.add(\"stx-grab\");return;}}}if(this.drawingClick){if(this.currentPanel.subholder === v2Q.target){this.drawingClick(this.currentPanel,this.cx,this.cy);}if(this.activeDrawing && this.activeDrawing.dragToDraw){return;}}k_Cdw.j1L();this.grabbingScreen=!0;f$N.spanLock=!!\"\";this.yToleranceBroken=!1;this.grabStartX=v2Q.clientX;this.grabStartY=v2Q.clientY;this.grabStartMicropixels=this.micropixels;this.grabStartScrollX=f$N.scroll;this.grabStartScrollY=this.currentPanel.yAxis.scroll;this.grabStartCandleWidth=this.layout.candleWidth;this.grabStartYAxis=this.whichYAxis(this.currentPanel);this.grabStartZoom=this.grabStartYAxis?this.grabStartYAxis.zoom:0;this.grabStartPanel=this.currentPanel;setTimeout((function(w2g){k_Cdw.j1L();return function(){k_Cdw.y6g();w2g.grabbingHand();};})(this),100);if(this.swipeStart){this.swipeStart(f$N);}if(this.longHoldTime || this.longHoldTime === 0){this.startLongHoldTimer();}this.runAppend(X3Z,arguments);};a$K.ChartEngine.prototype.mousemove=function(s8J){var j8r;j8r=s8J;a$K.ChartEngine.crosshairX=j8r.clientX;a$K.ChartEngine.crosshairY=j8r.clientY;if(j8r.type.toLowerCase().indexOf(\"enter\") > -1){this.positionCrosshairsAtPointer();return;}if(this.runPrepend(\"mousemove\",arguments)){return;}if(!this.displayInitialized){return;}if(this.openDialog !== \"\"){return;}if(this.baselineHelper.size){this.findBaselineHandle(j8r);}if(this.grabbingScreen && j8r.buttons !== 1){this.cancelLongHold=!![];this.displayDragOK();this.grabbingScreen=!({});this.findHighlights(!!0,!![]);}this.mousemoveinner(j8r.clientX,j8r.clientY);this.runAppend(\"mousemove\",arguments);};a$K.ChartEngine.prototype.mouseup=function(Z3i){var z0A=k_Cdw;var Y9B,a1R,o3m,R6k,l_m,A9h,z8Z,f4R,W94,e4I,C1U,H1b,s$g,b1e,V3v,X0K;Y9B=\"stx-d\";z0A.y6g();Y9B+=\"ra\";Y9B+=\"g-char\";Y9B+=\"t\";if(this.runPrepend(\"mouseup\",arguments)){return;}this.swipe.end=!![];this.cancelLongHold=!!\"1\";if(this.repositioningDrawing){if(!this.currentVectorParameters.vectorType || Date.now() - this.mouseTimer > 250){a1R=\"vect\";a1R+=\"or\";this.changeOccurred(a1R);a$K.clearCanvas(this.chart.tempCanvas,this);this.activateRepositioning(null);this.adjustDrawings();this.draw();return;}this.activateRepositioning(null);}if(this.repositioningBaseline){o3m=\"mo\";o3m+=\"unta\";o3m+=\"in\";R6k=\"stx-gr\";R6k+=\"ab\";var {handle:q4D}=this.repositioningBaseline;var {mainSeriesRenderer:a7g = {}}=this;this.repositioningBaseline=null;q4D.classList.remove(R6k);if(a7g.params && a7g.params.baseline && a7g.params.type != o3m){}this.draw();return;}if(this.repositioningAnchorSelector){var {sd:x3m}=this.repositioningAnchorSelector;a$K.Studies.repositionAnchor(this,x3m);this.repositioningAnchorSelector=null;this.controls.anchorHandles[x3m.uniqueId].highlighted=![];a$K.Studies.displayAnchorHandleAndLine(this,x3m,this.chart.dataSegment);Object.values(this.controls.anchorHandles || ({})).forEach(({handle:T9n})=>{var E8T;E8T=\"st\";z0A.j1L();E8T+=\"x-gra\";E8T+=\"b\";return T9n.classList.remove(E8T);});this.findHighlights();return;}l_m=this.userPointerDown;this.userPointerDown=!\"1\";if(!this.displayInitialized){return;}A9h=this.backOutY(Z3i.clientY);z8Z=this.backOutX(Z3i.clientX);f4R=Z3i.which && Z3i.which >= 2 || Z3i.button && Z3i.button >= 2;W94=this.openDialog !== \"\";if(!W94 && !f4R){this.registerPointerEvent({x:Z3i.clientX,y:Z3i.clientY,time:Date.now()},\"up\");}e4I=this.isDoubleClick();this.grabbingScreen=!({});if(this.highlightedDraggable){if(this.dragPlotOrAxis){this.dragPlotOrAxis(z8Z,A9h);}this.currentPanel=this.whichPanel(A9h);}C1U=this.currentPanel;this.grabStartYAxis=null;this.displayDragOK();if(this.openDialog !== \"\"){if(this.insideChart){this.container.classList.remove(\"stx-drag-chart\");}return;}if(this.grabOverrideClick){if(!this.overXAxis && !this.overYAxis && this.swipeRelease){this.swipeRelease();}this.container.classList.remove(\"stx-drag-chart\");this.grabOverrideClick=![];this.doDisplayCrosshairs();this.updateChartAccessories();return;}if(this.insideChart){this.container.classList.remove(Y9B);}if(a$K.ChartEngine.resizingPanel){this.releaseHandle();return;}if(f4R || Z3i.ctrlKey){H1b=\"rightC\";H1b+=\"lick\";if(this.anyHighlighted && this.bypassRightClick !== !![]){s$g=-1819864163;b1e=-913361587;z0A.G4m(4);V3v=z0A.F9v(\"2\",0);for(var F9y=1;z0A.m1(F9y.toString(),F9y.toString().length,61011) !== s$g;F9y++){this.rightClickHighlighted();if(Z3i.preventDefault || this.captureTouchEvents){Z3i.preventDefault();}Z3i.stopPropagation();return !!({});}if(z0A.m1(V3v.toString(),V3v.toString().length,2169) !== b1e){this.rightClickHighlighted();if(Z3i.preventDefault && this.captureTouchEvents){Z3i.preventDefault();}Z3i.stopPropagation();return !({});}this.rightClickHighlighted();if(Z3i.preventDefault && this.captureTouchEvents){Z3i.preventDefault();}Z3i.stopPropagation();return ![];}this.dispatch(H1b,{stx:this,panel:C1U,x:z8Z,y:A9h});return !![];}if(Z3i.clientX < this.left || Z3i.clientX > this.right){return;}if(Z3i.clientY < this.top || Z3i.clientY > this.bottom){return;}X0K=C1U && C1U.subholder === Z3i.target;if(e4I && (X0K || this.overYAxis || this.overXAxis)){this.doubleClick(Z3i.button,z8Z,A9h);}else {if(l_m && X0K){if(!this.longHoldTookEffect || this.activeDrawing){this.drawingClick(C1U,z8Z,A9h);}if(!this.longHoldTookEffect && this.activeMarker){this.activeMarker.click({cx:z8Z,cy:A9h,panel:C1U});}}if(!this.longHoldTookEffect && !this.activeDrawing){this.dispatch(\"tap\",{stx:this,panel:C1U,x:z8Z,y:A9h});}}this.runAppend(\"mouseup\",arguments);};a$K.ChartEngine.prototype.registerPointerEvent=function(Q1n,H_S){k_Cdw.j1L();if(this.pointerEvents[H_S].length > \"1\" - 0){this.pointerEvents[H_S].pop();}this.pointerEvents[H_S].unshift(Q1n);};a$K.ChartEngine.prototype.resetPointerEvent=function(V9_){this.pointerEvents[V9_].splice(0);};a$K.ChartEngine.prototype.isDoubleClick=function(v9W){var y9w,q4G;y9w=v9W?1200:+\"400\";k_Cdw.j1L();var {up:U4_, down:x7C}=this.pointerEvents;this.cancelTouchSingleClick=!({});if(U4_.length < 2 || x7C.length < 2){return !!\"\";}q4G=x7C[0].time - U4_[1].time < this.doubleClickTime && Math.pow(x7C[1].x - x7C[0].x,2) + Math.pow(x7C[1].y - x7C[0].y,2) <= y9w && Math.pow(U4_[1].x - U4_[+\"0\"].x,2) + Math.pow(U4_[\"1\" ^ 0].y - U4_[\"0\" | 0].y,2) <= y9w && U4_[1].time - x7C[1].time < this.longHoldTime && U4_[0].time - x7C[\"0\" >> 64].time < this.longHoldTime;if(q4G){this.resetPointerEvent(\"up\");this.resetPointerEvent(\"down\");this.cancelTouchSingleClick=!!({});}return q4G;};a$K.ChartEngine.prototype.doubleClick=function(M4o,v_I,M4j){var A2H,V_j;A2H=\"do\";A2H+=\"ubleC\";A2H+=\"lick\";if(this.runPrepend(\"doubleClick\",arguments)){return;}if(this.editingAnnotation){return;}if(a$K.ChartEngine.drawingLine){if(this.currentVectorParameters.vectorType == \"continuous\"){a$K.ChartEngine.completeDrawing(this);}return this.undo();}if(this.activeDrawing){return;}V_j=this.activeMarker && this.activeMarker.doubleClick({cx:v_I,cy:M4j,panel:this.currentPanel});if(!V_j){this.dispatch(A2H,{stx:this,button:M4o,x:v_I,y:M4j});}this.runAppend(\"doubleClick\",arguments);};a$K.ChartEngine.prototype.handleMouseOut=function(n$z){var S1V,D2M,r3j;n$z=n$z || window.event;k_Cdw.j1L();if(!n$z.relatedTarget || !a$K.withinElement(this.chart.container,n$z.pageX,n$z.pageY)){S1V=\"handl\";S1V+=\"eMouseOut\";if(this.runPrepend(\"handleMouseOut\",arguments)){return;}if(!this.grabbingScreen){this.findHighlights(null,!!1);}this.undisplayCrosshairs();this.touches=[];this.touching=!!\"\";if(this.activeDrawing && this.userPointerDown){this.userPointerDown=![];this.drawingLine=![];D2M=this.backOutY(n$z.pageY);r3j=this.backOutX(n$z.pageX);this.drawingClick(this.currentPanel,r3j,D2M);}var {sd:L0k, tapToAdd:W80}=this.repositioningAnchorSelector || ({});if(L0k && !W80){this.repositioningAnchorSelector=null;this.controls.anchorHandles[L0k.uniqueId].highlighted=!\"1\";a$K.Studies.displayAnchorHandleAndLine(this,L0k,this.chart.dataSegment);this.draw();}this.insideChart=![];this.overYAxis=!1;this.overXAxis=!!0;this.displaySticky();this.runAppend(S1V,arguments);}};a$K.ChartEngine.prototype.startLongHoldTimer=function(X_t){var T$C,f$6;T$C=this;this.cancelLongHold=!!0;if(this.longHoldTimeout){clearTimeout(this.longHoldTimeout);}k_Cdw.j1L();f$6=function(){var l2W;l2W=\"long\";l2W+=\"hold\";if(T$C.cancelLongHold){return;}T$C.longHoldTookEffect=!0;if(X_t){X_t();}T$C.dispatch(l2W,{stx:T$C,panel:T$C.currentPanel,x:T$C.cx,y:T$C.cy});k_Cdw.y6g();T$C.displayDragOK();};if(this.longHoldTime){this.longHoldTimeout=setTimeout(f$6,this.longHoldTime);}else if(this.longHoldTime === \"0\" * 1){f$6();}};a$K.ChartEngine.prototype.grabHandle=function(E$Q){var z_N;z_N=\"gra\";z_N+=\"bHandle\";if(this.runPrepend(z_N,arguments)){return;}k_Cdw.j1L();if(!E$Q){return;}a$K.ChartEngine.crosshairY=this.resolveY(E$Q.top);a$K.ChartEngine.resizingPanel=E$Q;E$Q.handle.classList.add(\"stx-grab\");this.runAppend(\"grabHandle\",arguments);};a$K.ChartEngine.prototype.grabbingHand=function(){k_Cdw.j1L();if(!this.allowScroll){return;}if(!this.grabbingScreen){return;}if(a$K.touchDevice){return;}this.container.classList.add(\"stx-drag-chart\");};a$K.ChartEngine.prototype.releaseHandle=function(){if(this.runPrepend(\"releaseHandle\",arguments)){return !![];}a$K.clearCanvas(this.chart.tempCanvas,this);this.resizePanels();if(a$K.ChartEngine.resizingPanel){a$K.ChartEngine.resizingPanel.handle.classList.remove(\"stx-grab\");}a$K.ChartEngine.resizingPanel=null;this.runAppend(\"releaseHandle\",arguments);};a$K.ChartEngine.prototype.findHighlights=function(I1U,u7i){var b9p=k_Cdw;var U9J,w2L,p_8,e4M,R01,A_W,U2b,i__,E3x,C9t,f6Q,l92,D8b,q8t,x4T,J88,O8I,j3$,q5s,H$6,m2I,j7c,u03,b2$,x6x,W0J,n6V,O14,c8Q,d4q,G18,y98,g4E,L25,J_o,g$R,N$Y,F6g,b7M,t4H,x24,L8$,C4Q,O7r,Z_R,F4y,L21,w2f,o2F,Z_g,m6o;U9J=this.preferences[I1U?\"highlightsTapRadius\":\"highlightsRadius\"];this.highlightViaTap=I1U;var {cx:E1M, cy:k7T}=this;this.anyHighlighted=!\"1\";function w1A(P$Q,N6a,w3S,T1A,W9J,B80){var d0Y,A0e,e5$,w3Y,n49,c5F,V7m,z8X,O_C,A0v,T0r,Z3Y,O8k,U3I,k8w,t3S,w39,l4w,W_p,K61,S4H,t8H,b7W,t1G,D3o,c9y,r_o,c7Y,S6E,r9Z,o1e,f7f;d0Y=\"seg\";d0Y+=\"m\";d0Y+=\"en\";d0Y+=\"t\";A0e=\"C\";A0e+=\"lose\";e5$=\"-\";e5$+=\"-\";e5$+=\">\";w3Y=this;n49=w3Y.chart;c5F=w3Y.currentPanel;if(!T1A){T1A=c5F.yAxis;}V7m=w3S.split(e5$);z8X=V7m[0];O_C=V7m[1];if(!O_C){O_C=A0e;}A0v=n49.dataSegment[m2I];t3S=null;w39=null;l4w=null;W_p=new Array(3);K61=W9J && W9J.caches[B80];if(A0v && K61){O8k=K61[m2I];t3S=A0v.tick;if(O8k || O8k === 0){W_p[0]=1;}for(S4H=m2I - 1;S4H >= \"0\" >> 64;S4H--){if(K61[S4H] || K61[S4H] === 0){U3I=K61[S4H];b9p.b8R(103);w39=b9p.e7l(m2I,S4H,t3S);W_p[+\"1\"]=1;break;}}for(S4H=m2I + 1;S4H < n49.dataSegment.length;S4H++){if(K61[S4H] || K61[S4H] === 0){k8w=K61[S4H];b9p.G4m(103);l4w=b9p.e7l(m2I,S4H,t3S);b9p.G4m(4);W_p[2]=b9p.F9v(\"1\",0);break;}}}if(w39 === null){T0r=w3Y.getPreviousBar.call(w3Y,n49,w3S,m2I);if(T0r){w39=T0r.tick;U3I=V4y(T0r);}}function V4y(N9C){var y0b;if(!N9C){return null;}y0b=N9C[z8X];if(y0b && (y0b[O_C] || y0b[O_C] === 0)){y0b=y0b[O_C];}if(W9J && W9J.getBasis){y0b+=W9J.getBasis(N9C,z8X,O_C);}if(!n49.transformFunc || T1A != n49.yAxis){return y0b;}else if(N9C.transform && (z8X in N9C.transform)){y0b=N9C.transform[z8X];if(y0b && (y0b[O_C] || y0b[O_C] === 0)){y0b=y0b[O_C];}return y0b;}return n49.transformFunc(w3Y,n49,y0b);}if(l4w === null){b9p.b8R(63);t8H=-b9p.F9v(\"2137635257\",0);b7W=1377752444;t1G=2;for(var C1E=1;b9p.P6(C1E.toString(),C1E.toString().length,27176) !== t8H;C1E++){Z3Y=w3Y.getNextBar.call(w3Y,n49,w3S,m2I);t1G+=2;}if(b9p.P6(t1G.toString(),t1G.toString().length,+\"65319\") !== b7W){Z3Y=w3Y.getNextBar.call(w3Y,n49,w3S,m2I);}Z3Y=w3Y.getNextBar.call(w3Y,n49,w3S,m2I);if(Z3Y){l4w=Z3Y.tick;k8w=V4y(Z3Y);}}if(w39 === null && l4w === null){return ![];}if(!K61){O8k=V4y(A0v);U3I=V4y(T0r);k8w=V4y(Z3Y);t3S=A0v.tick;if(T0r){w39=T0r.tick;}if(Z3Y){l4w=Z3Y.tick;}}if(!U3I && U3I !== 0){U3I=0;b9p.G4m(4);w39=b9p.F9v(\"0\",0);}if(!k8w && k8w !== 0){if(O8k || O8k === 0){k8w=O8k;b9p.b8R(34);W_p[+\"2\"]=W_p[b9p.F9v(\"0\",0)];}else {k8w=U3I;W_p[+\"2\"]=W_p[1];}if(B80 && n49.series[B80].parameters.extendToEndOfDataSet){b9p.b8R(78);var l97=b9p.F9v(9,30,20);l4w=n49.dataSet.length - l97;}else {l4w=w39;}}if(!O8k && O8k !== 0){O8k=k8w;t3S=l4w;D3o=1298694744;c9y=-97092488;r_o=+\"2\";for(var O61=1;b9p.P6(O61.toString(),O61.toString().length,+\"67978\") !== D3o;O61++){W_p[0]=W_p[2];r_o+=2;}if(b9p.P6(r_o.toString(),r_o.toString().length,48667) !== c9y){W_p[1]=W_p[9];}if(U3I === (\"0\" | 0) && w39 === \"0\" * 1){U3I=O8k;w39=t3S;W_p[1]=W_p[0];}}c7Y=w3Y.pixelFromTransformedValue.bind(w3Y);S6E=w3Y.valueFromPixel.bind(w3Y);O8k=S6E(W_p[0]?O8k:c7Y(O8k,c5F,T1A),c5F);U3I=S6E(W_p[1]?U3I:c7Y(U3I,c5F,T1A),c5F);k8w=S6E(W_p[2]?k8w:c7Y(k8w,c5F,T1A),c5F);r9Z=a$K.convertBoxToPixels(w3Y,c5F.name,N6a);o1e=a$K.convertBoxToPixels(w3Y,c5F.name,{x0:w39,y0:U3I,x1:t3S,y1:O8k});f7f=a$K.convertBoxToPixels(w3Y,c5F.name,{x0:t3S,y0:O8k,x1:l4w,y1:k8w});if(a$K.boxIntersects(r9Z.x0,r9Z.y0,r9Z.x1,r9Z.y1,o1e.x0,o1e.y0,o1e.x1,o1e.y1,d0Y) || a$K.boxIntersects(r9Z.x0,r9Z.y0,r9Z.x1,r9Z.y1,f7f.x0,f7f.y0,f7f.x1,f7f.y1,\"segment\")){return Math.min(Math.pow(k7T - (o1e.y1 + o1e.y0) / 2,+\"2\") + Math.pow(E1M - (o1e.x1 + o1e.x0) / 2,\"2\" - 0),Math.pow(k7T - (f7f.y1 + f7f.y0) / 2,2) + Math.pow(E1M - (f7f.x1 + f7f.x0) / 2,2));}return ![];}if(!this.currentPanel){return;}var {chart:n6Y}=this.currentPanel;if(this.activeDrawing){u7i=!![];}w2L=!!\"\";p_8=null;e4M=u7i?{}:{forceShow:!!\"1\",type:\"drawing\"};R01={x0:this.tickFromPixel(E1M - U9J,n6Y),x1:this.tickFromPixel(E1M + U9J,n6Y),y0:this.valueFromPixel(k7T - U9J,this.currentPanel),y1:this.valueFromPixel(k7T + U9J,this.currentPanel),cx0:E1M - U9J,cx1:E1M + U9J,cy0:k7T - U9J,cy1:k7T + U9J,r:U9J};if(this.repositioningDrawing && R01.x1 - R01.x0 < +\"2\"){R01.x1++;R01.x0--;}else if(R01.x1 == R01.x0){R01.x0-=0.5;R01.x1+=0.5;}if(!n6Y.hideDrawings){for(var X$e=this.drawingObjects.length - 1;X$e >= 0;X$e--){A_W=this.drawingObjects[X$e];if(!this.panels[A_W.panelName])continue;if(this.repositioningDrawing && this.repositioningDrawing != A_W)continue;U2b=A_W.highlighted;i__=A_W.panelName == this.currentPanel.name;if(i__){A_W.repositioner=A_W.intersected(this.crosshairTick,this.crosshairValue,R01);}i__=i__ && A_W.repositioner && !this.overXAxis && !this.overYAxis;if(!u7i && i__){if(U2b){p_8=A_W;if(this.anyHighlighted && this.singleDrawingHighlight){A_W.highlighted=!!\"\";}if(A_W.highlighted && A_W.highlighted != U2b){w2L=!0;}}else if(U2b != A_W.highlight(!!({}))){if(!p_8){p_8=A_W;}if(this.anyHighlighted && this.singleDrawingHighlight){A_W.highlighted=!({});}w2L=!![];}this.anyHighlighted=!![];}else {if(U2b != A_W.highlight(!({}))){w2L=!\"\";}}if(A_W.highlighted){e4M.noDelete=A_W.permanent;e4M.noEdit=!this.callbackListeners.drawingEdit.length;e4M.noText=e4M.noEdit || !A_W.edit;e4M.message=a$K.capitalize(A_W.name);}}}for(E3x in this.layout.studies){C9t=this.layout.studies[E3x];C9t.prev=C9t.highlight;C9t.highlight=this.yaxisMatches(C9t,this.grabStartYAxis);}for(E3x in n6Y.seriesRenderers){q8t=n6Y.seriesRenderers[E3x];q8t.params.highlight=this.yaxisMatches(q8t,this.grabStartYAxis);for(var h4U=0;h4U < q8t.seriesParams.length;h4U++){D8b=q8t.seriesParams[h4U];D8b.prev=D8b.highlight;D8b.highlight=q8t.params.highlight;}}var {anchorHandles:H_r}=this.controls;if(H_r){for(var J9E in H_r){H_r[J9E].highlighted=!({});}}x4T=this.markerHelper && this.markerHelper.visibleCanvasMarkers;if(x4T){for(f6Q=+\"0\";f6Q < x4T.length;f6Q++){l92=x4T[f6Q];this.activeMarker=null;l92.prev=x4T[f6Q].highlight;l92.highlight=![];}}if(this.markerHelper){this.markerHelper.highlighted=[];}this.highlightedDataSetField=null;b9p.j1L();this.highlightedDraggable=null;if(!u7i && !this.anyHighlighted && H_r){for(var N1o in H_r){J88=H_r[N1o];if(a$K.getFromNS(J88,\"sd.signalData.reveal\") === !\"1\")continue;if(!this.anyHighlighted){var {sd:r3U, currentPixel:v2P}=J88;b9p.b8R(4);O8I=b9p.F9v(v2P,U9J);b9p.b8R(0);j3$=b9p.e7l(v2P,U9J);q5s=this.panels[r3U.panel];var {top:a48, bottom:T4g}=q5s.yAxis;H$6=a$K.boxIntersects(O8I,a48,j3$,T4g,E1M,k7T,E1M,k7T);if(H$6){this.anyHighlighted=!![];J88.highlighted=!0;w2L=!![];e4M={message:r3U.name,type:\"anchorHandle\",noDelete:!!({})};continue;}}if(J88.highlighted === !!({})){J88.highlighted=![];w2L=!!\"1\";}}}if(!u7i && !this.anyHighlighted && n6Y.dataSegment){m2I=this.barFromPixel(E1M);if(m2I >= 0 && m2I < n6Y.dataSegment.length){u03=a$K.convertBoxToPixels(this,this.currentPanel.name,R01);b2$=Number.MAX_VALUE;if(x4T){for(f6Q=\"0\" | 0;f6Q < x4T.length;f6Q++){l92=x4T[f6Q];x6x=l92.params.box;if(!x6x)continue;if(l92.params.panelName !== this.currentPanel.name)continue;if(a$K.boxIntersects(u03.x0,u03.y0,u03.x1,u03.y1,x6x.x0,x6x.y0,x6x.x1,x6x.y1)){b9p.G4m(16);var h5B=b9p.e7l(1,16,8);b9p.G4m(104);var J3F=b9p.e7l(53,12,9,7,0);b9p.G4m(4);var f9o=b9p.e7l(9,7);W0J=Math.pow(k7T - (x6x.y1 + x6x.y0) / (\"2\" * h5B),+\"2\") + Math.pow(E1M - (x6x.x1 + x6x.x0) / J3F,f9o);if(W0J <= b2$){b2$=W0J;this.activeMarker=l92;}l92.highlight=!!1;this.markerHelper.highlighted.push(l92);}if(l92.prev != l92.highlight){w2L=!![];}}}b2$=Number.MAX_VALUE;n6V=null;for(E3x in this.overlays){O14=\"fun\";O14+=\"c\";O14+=\"t\";O14+=\"ion\";if(x4T && this.markerHelper.highlighted.length)break;C9t=this.overlays[E3x];if(C9t.signalData && !C9t.signalData.reveal)continue;if(C9t.panel != this.currentPanel.name)continue;if(C9t.study.isHighlighted === !\"1\")continue;else if(typeof C9t.study.isHighlighted == O14){if(C9t.study.isHighlighted(this,E1M,k7T)){n6V={o:C9t,out:X5P};b2$=0;break;}continue;}c8Q=n6Y.dataSegment[m2I];if(!c8Q)continue;for(var X5P in C9t.outputMap){d4q=w1A.call(this,m2I,R01,X5P,C9t.getYAxis(this));if(d4q !== !!0 && d4q <= b2$){n6V={o:C9t,out:X5P};b2$=d4q;}}}for(E3x in n6Y.seriesRenderers){if(this.highlightedDataSetField)break;G18=n6Y.seriesRenderers[E3x];y98=G18.params.panel;if(G18 == this.mainSeriesRenderer)continue;if(!G18.params.highlightable && !this.currentVectorParameters.vectorType)continue;if(y98 != this.currentPanel.name)continue;for(f6Q=0;f6Q < G18.seriesParams.length;f6Q++){g4E=\"-\";g4E+=\"-\";g4E+=\">\";D8b=G18.seriesParams[f6Q];L25=D8b.field;if(!L25 && !G18.highLowBars){L25=this.defaultPlotField || \"Close\";}if(D8b.symbol && D8b.subField){L25+=g4E + D8b.subField;}J_o=G18.params.yAxis;if(!J_o && y98){J_o=this.panels[y98].yAxis;}if(G18.params.step && m2I > 0){if(!G18.caches[D8b.id])continue;j7c=G18.caches[D8b.id][m2I];if(!j7c && j7c !== 0)continue;b9p.G4m(4);g$R=G18.caches[D8b.id][b9p.e7l(m2I,1)];if((g$R || g$R === 0) && k7T + U9J >= j7c && k7T - U9J <= g$R || k7T - U9J <= j7c && k7T + U9J >= g$R){n6V={s:D8b,fullField:L25};break;}}else {N$Y=w1A.call(this,m2I,R01,L25,J_o,G18,D8b.id);if(N$Y !== ![] && N$Y <= b2$){n6V={s:D8b,fullField:L25};b2$=N$Y;}}}}if(n6V){C9t=n6V.o;if(C9t){if(C9t.name != C9t.panel){this.anyHighlighted=!![];}C9t.highlight=n6V.out;this.highlightedDataSetField=n6V.out;}else {this.anyHighlighted=!!\"1\";n6V.s.highlight=!![];this.highlightedDataSetField=n6V.fullField;}}}}b7M=this.preferences.dragging;for(E3x in this.overlays){C9t=this.overlays[E3x];if(C9t.highlight){this.anyHighlighted=!![];x24=C9t.inputs.display || C9t.name;x24=this.translateIf(x24);e4M={message:x24,noDelete:C9t.permanent,noEdit:!C9t.editFunction,noText:!C9t.textFunction,type:\"study\"};p_8=null;if(b7M === !![] || b7M && b7M.study){if(!C9t.undraggable(this)){F6g=C9t;}}t4H=C9t.getYAxis(this);}if(C9t.prev != C9t.highlight){w2L=!![];}}for(E3x in n6Y.seriesRenderers){L8$=n6Y.seriesRenderers[E3x];C4Q=L8$.params.yAxis?L8$.params.yAxis.textStyle:null;for(var D8p=0;D8p < L8$.seriesParams.length;D8p++){D8b=L8$.seriesParams[D8p];if(L8$.params.highlightable && D8b.highlight){O7r=\"au\";O7r+=\"to\";this.anyHighlighted=!!\"1\";Z_R=D8b.color || C4Q;if(Z_R == O7r){Z_R=this.defaultColor;}if(D8b.opacity && D8b.opacity !== 1){Z_R=a$K.hexToRgba(a$K.colorToHex(Z_R),parseFloat(D8b.opacity));}e4M={message:D8b.display || D8b.symbol,backgroundColor:Z_R,noDelete:D8b.permanent,type:\"series\"};p_8=null;if(b7M === !!({}) || b7M && b7M.series){F6g=L8$;L8$.params.highlight=!!({});}t4H=L8$.getYAxis(this);}if(D8b.prev != D8b.highlight){w2L=!!({});}}}for(E3x in this.plugins){F4y=this.plugins[E3x];L21={};if(F4y.findHighlights){L21=F4y.findHighlights(this,I1U,u7i);if(L21.somethingChanged){w2L=!!({});}if(L21.anyHighlighted){this.anyHighlighted=!!({});e4M=L21.stickyArgs || ({});}}}w2f=this.whichPanel(k7T);o2F=this.whichYAxis(w2f,E1M);if(!t4H){t4H=o2F;}if(this.currentBaseline){t4H=this.currentBaseline.getYAxis(this);}if(t4H){if(!t4H.highlight){w2L=!!\"1\";}t4H.highlight=!![];}Z_g=[];for(var a3c in this.panels){Z_g=Z_g.concat(this.panels[a3c].yaxisLHS).concat(this.panels[a3c].yaxisRHS);}for(E3x=0;E3x < Z_g.length;E3x++){if(t4H == Z_g[E3x] && !u7i)continue;if(Z_g[E3x].highlight){w2L=!0;}Z_g[E3x].highlight=!!\"\";}if((b7M === !\"\" || b7M && b7M.yaxis) && o2F && !o2F.noDraw){this.anyHighlighted=!0;F6g=o2F;e4M={};}if(w2L){this.draw();e4M.panel=w2f;if(this.anyHighlighted && !this.grabStartYAxis){e4M.panel=w2f;}else {e4M={};}this.displaySticky(e4M);this.clearMeasure();if(p_8){p_8.measure();}}if(!this.anyHighlighted){this.setMeasure();}else if(this.controls.mSticky){if(e4M && e4M.positioner){e4M.positioner.call(this,this.controls.mSticky);}else {this.positionSticky(this.controls.mSticky);}}if(F6g && w2f && !w2f.noDrag){if(this.longHoldTookEffect && !this.cancelLongHold){if(F6g.params){if(F6g.params.dependentOf){F6g=n6Y.seriesRenderers[F6g.params.dependentOf];F6g.params.highlight=!!({});}for(E3x in n6Y.seriesRenderers){if(n6Y.seriesRenderers[E3x].params.dependentOf == F6g.params.name){n6Y.seriesRenderers[E3x].params.highlight=!!\"1\";}}}this.highlightedDraggable=F6g;if(F6g.getDependents){m6o=F6g.getDependents(this,!0);for(E3x in this.overlays){C9t=this.overlays[E3x];if(m6o.indexOf(C9t) > -1){C9t.highlight=!!1;}}}}this.container.classList.add(\"stx-draggable\");}else {this.container.classList.remove(\"stx-draggable\");}this.highlightedDataSetField=this.adjustHighlightedDataSetField(this.highlightedDataSetField);this.displayDrawOK();};a$K.ChartEngine.prototype.rightClickHighlighted=function(){if(this.runPrepend(\"rightClickHighlighted\",arguments)){return;}k_Cdw.y6g();this.deleteHighlighted(!0);this.runAppend(\"rightClickHighlighted\",arguments);};a$K.ChartEngine.prototype.deleteHighlighted=function(c81,i_u,D23){var D4Q,R0K,R8e,J2D,l31,D7k,z3A,h62,c$v,V0W,q2N,z3B,g_0;D4Q=\"de\";D4Q+=\"leteHighlighted\";if(this.runPrepend(\"deleteHighlighted\",arguments)){return;}this.cancelTouchSingleClick=!!({});a$K.clearCanvas(this.chart.tempCanvas,this);R0K=this.bypassRightClick === !!\"\";if(R0K || !this.bypassRightClick.drawing){for(var T0o=this.drawingObjects.length - 1;T0o >= 0;T0o--){R8e=this.drawingObjects[T0o];if(!R8e.highlighted)continue;if(c81){this.rightClickDrawing(R8e,i_u,D23);}else if(!R8e.permanent){J2D=R8e.abort();if(!J2D){l31=this.exportDrawings();this.drawingObjects.splice(T0o,1);this.undoStamp(l31,this.exportDrawings());}this.changeOccurred(\"vector\");}}}if(R0K || !this.bypassRightClick.study){for(var A0F in this.overlays){D7k=this.overlays[A0F];if((D7k.overlay || D7k.underlay) && D7k.highlight && !D7k.permanent){if(c81 || i_u){this.rightClickOverlay(A0F,i_u);}else {this.removeOverlay(A0F);}}}}z3A=this.currentPanel && this.currentPanel.chart;if(z3A && (R0K || !this.bypassRightClick.series)){for(var k2a in z3A.seriesRenderers){h62=z3A.seriesRenderers[k2a];if(h62.params.highlightable){c$v=this.panels[h62.params.panel];V0W=c$v && c$v.yAxis.name;for(var o7B=h62.seriesParams.length - 1;o7B >= 0;o7B--){q2N=h62.seriesParams[o7B];if((h62.params.highlight || q2N.highlight) && !q2N.permanent){h62.removeSeries(q2N.id);if(h62.seriesParams.length < 1){this.removeSeriesRenderer(h62);if(h62.params.name == V0W){this.electNewPanelOwner(h62.params.panel);}else {this.checkForEmptyPanel(h62.params.panel);z3B=this.getYAxisByName(c$v,h62.params.name);if(z3B){z3B.name=z3B.studies[\"0\" << 0] || z3B.renderers[1];}}}}}}}}this.draw();k_Cdw.j1L();this.resizeChart();this.clearMeasure();g_0=this.controls.mSticky;if(g_0){g_0.style.display=\"none\";g_0.children[0].innerHTML=\"\";}this.runAppend(D4Q,arguments);};a$K.ChartEngine.prototype.displayDragOK=function(v0l){var G3j=k_Cdw;var O7J,m85,I_4,o9L,g0h,q$S,f5M,p69,Q_a,j12,f_m,g_1,E3Y,h_D,p5p,H_w,I7t;O7J=this;m85=this.controls.dragOk;G3j.y6g();function i0m(d1y){var F09,Z7Z,X8r;F09=\".fie\";F09+=\"l\";F09+=\"d\";Z7Z=O7J.translateIf(d1y.querySelector(\".field\").getAttribute(\"text\"));G3j.y6g();X8r=O7J.whichYAxis(O7J.whichPanel(O7J.cy),O7J.cx,O7J.cy);if(X8r && X8r.dropzone == \"all\"){Z7Z+=\"-->\" + O7J.translateIf(X8r.name);}d1y.querySelector(F09).innerHTML=Z7Z;}if(m85){if(!v0l){if(!this.tapForHighlighting || !this.touching || this.anyHighlighted){this.findHighlights(this.highlightViaTap);}}I_4=this.highlightedDraggable;o9L=I_4 && I_4.undraggable && I_4.undraggable(this);g0h=this.cx;q$S=this.cy;if(!v0l){if(I_4 && !o9L && this.longHoldTookEffect && !this.cancelLongHold){f5M=\"stx-dr\";f5M+=\"ag-series\";p69=\"stx-\";p69+=\"dra\";p69+=\"g-chart\";Q_a=\"s\";Q_a+=\"tx-drag\";Q_a+=\"-axis\";j12=I_4.inputs && I_4.inputs.display || I_4.params && (I_4.params.display || I_4.params.name) || I_4.name;m85.querySelector(\".field\").setAttribute(\"text\",j12);i0m.call(this,m85);m85.style.display=\"inline-block\";this.draw();this.displaySticky();if(this.grabStartYAxis){this.container.classList.replace(\"stx-drag-chart\",Q_a);}else {this.container.classList.replace(p69,f5M);}}else {f_m=\"n\";f_m+=\"o\";f_m+=\"ne\";m85.style.display=f_m;this.draw();this.container.classList.remove(\"stx-drag-series\");this.container.classList.remove(\"stx-drag-axis\");for(var q5m in this.panels){g_1=\"to\";g_1+=\"p\";E3Y=\"al\";E3Y+=\"l\";h_D=this.panels[q5m].subholder.classList;h_D.remove(\"dropzone\");h_D.remove(E3Y);h_D.remove(\"left\");h_D.remove(\"right\");h_D.remove(g_1);h_D.remove(\"bottom\");for(p5p=0;p5p < this.panels[q5m].yaxisLHS.length;p5p++){this.panels[q5m].yaxisLHS[p5p].dropzone=null;}for(p5p=0;p5p < this.panels[q5m].yaxisRHS.length;p5p++){this.panels[q5m].yaxisRHS[p5p].dropzone=null;}}}this.draw();}if(I_4){H_w=q$S + m85.offsetHeight;I7t=Math.max(0,g0h - m85.offsetWidth);G3j.G4m(0);m85.style.top=G3j.F9v(H_w,\"px\");G3j.b8R(0);m85.style.left=G3j.e7l(I7t,\"px\");i0m.call(this,m85);}}};a$K.ChartEngine.prototype.displayDrawOK=function(){var B1o=k_Cdw;var F3j,G9P,D4y,t0T,p86,o9z;F3j=this.controls.drawOk;if(F3j && a$K.Drawing){G9P=a$K.Drawing[this.currentVectorParameters.vectorType];if(G9P){G9P=new G9P();}if(this.highlightedDataSetField && G9P && G9P.isAllowed(this,this.highlightedDataSetField)){D4y=\".fie\";D4y+=\"l\";D4y+=\"d\";t0T=\"inline\";t0T+=\"-bl\";t0T+=\"oc\";t0T+=\"k\";F3j.style.display=t0T;p86=this.cy + F3j.offsetHeight;o9z=this.cx - F3j.offsetWidth;B1o.b8R(0);F3j.style.top=B1o.e7l(p86,\"px\");B1o.b8R(0);F3j.style.left=B1o.e7l(o9z,\"px\");F3j.querySelector(D4y).innerHTML=this.translateIf(this.highlightedDataSetField);}else {F3j.style.display=\"none\";}}};a$K.ChartEngine.prototype.mouseWheel=function(L5J){var i5L=k_Cdw;var Z9k,Y4p,g0H,c2F,y4F,s96,o7P,Z63,p2h;Z9k=\"u\";Z9k+=\"nd\";Z9k+=\"ef\";Z9k+=\"ined\";Y4p=\"mou\";Y4p+=\"seWh\";Y4p+=\"ee\";Y4p+=\"l\";if(this.runPrepend(Y4p,arguments)){return;}if(L5J.preventDefault){L5J.preventDefault();}if(this.openDialog !== \"\"){return;}g0H=L5J.deltaX;c2F=L5J.deltaY;if(Math.abs(c2F) > Math.abs(g0H)){g0H=0;}else {c2F=0;}this.lastMouseWheelEvent=Date.now();if(Math.abs(g0H) === 0 && Math.abs(c2F) === 0){return;}if(L5J.shiftKey && c2F){g0H=c2F;c2F=0;}if(this.allowSideswipe && g0H !== 0){this.lastMove=\"horizontal\";s96=g0H;this.grabbingScreen=!![];if(!this.currentPanel){this.currentPanel=this.chart.panel;}this.grabStartX=a$K.ChartEngine.crosshairX;this.grabStartY=a$K.ChartEngine.crosshairY;this.grabStartScrollX=this.chart.scroll;this.grabStartScrollY=this.currentPanel.yAxis.scroll;this.grabStartMicropixels=this.micropixels;this.grabStartPanel=this.currentPanel;if(this.mouseWheelAcceleration){y4F=Math.max(Math.pow(Math.abs(s96),0.3),\"1\" >> 64);s96*=y4F;}this.mousemoveinner(a$K.ChartEngine.crosshairX - s96,a$K.ChartEngine.crosshairY);this.updateChartAccessories();this.grabbingScreen=![];return;}this.lastMove=\"vertical\";if(!this.allowZoom || this.activeDrawing && !this.allowDrawingZoom){return;}if(!this.displayInitialized){return;}if(!c2F){if(a$K.wheelEvent == \"mousewheel\"){i5L.G4m(0);var K0M=i5L.e7l(30,10);c2F=-+\"1\" / K0M * L5J.wheelDelta;if(L5J.wheelDeltaX){i5L.b8R(105);var k8Z=i5L.e7l(16,17,1,15,19);g0H=k8Z / +\"40\" * L5J.wheelDeltaX;}}else {c2F=L5J.detail;}}if(typeof L5J.deltaMode == Z9k){L5J.deltaMode=L5J.type == \"MozMousePixelScroll\"?\"0\" * 1:\"1\" << 0;}o7P=-c2F;if(L5J.deltaMode == (\"1\" ^ 0)){o7P*=33;}Z63=null;p2h=null;if(this.mouseWheelAcceleration){y4F=Math.max(Math.pow(Math.abs(o7P),0.3),1);Z63=Math.max(Number.MIN_VALUE,+\"1\" - (\"0.1\" - 0) * y4F);i5L.b8R(9);p2h=i5L.F9v(1,Z63);}this.zoomInitiatedByMouseWheel=!!({});if(o7P > 0){if(this.reverseMouseWheel){this.zoomOut(null,p2h);}else {this.zoomIn(null,Z63);}}else if(o7P < 0){if(this.reverseMouseWheel){this.zoomIn(null,Z63);}else {this.zoomOut(null,p2h);}}if(this.runAppend(\"mouseWheel\",arguments)){return;}return !({});};a$K.ChartEngine.handleContextMenu=function(K8i){var t33,i7E;t33=a$K.ChartEngine.registeredContainers;k_Cdw.j1L();for(var o1a=0;o1a < t33.length;o1a++){if(K8i.target.ownerDocument !== t33[o1a].ownerDocument)continue;i7E=t33[o1a].stx;if(i7E){if(i7E.anyHighlighted){if(K8i.preventDefault){K8i.preventDefault();}return !1;}}}};a$K.ChartEngine.registerGlobalEvent(\"contextmenu\",a$K.ChartEngine.handleContextMenu);a$K.ChartEngine.htmlControls={annotationSave:'',annotationCancel:b24,mSticky:`\n\t\t
    \n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t \n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t \n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t \n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t(\n\t\t\t\t\tright-click to delete\n\t\t\t\t\tright-click to manage\n\t\t\t\t\t)\n\t\t\t\t\n\t\t\t\n\t\t\t(long-press to drag)\n\t\t\t\n\t\t\t\t(\n\t\t\t\t\n\t\t\t\t\tdrag to change anchor time\n\t\t\t\t\n\t\t\t\t)\n\t\t\t\n\t\t
    \n\t`,drawOk:'
    ',dragOk:'
    ',crossX:'
    ',crossY:o6w,chartControls:g0X,home:'
    ',floatDate:'
    ',handleTemplate:'
    ',iconsTemplate:'
    ',baselineHandle:'
    ',notificationTray:'
    '};a$K.ChartEngine.prototype.registerChartControl=function(c2K,Q9a,L7H){var b3k=k_Cdw;var y5F,y44,T$g;y5F=this.controls;if(!y5F || !y5F.chartControls){return;}if(y5F.chartControls.querySelector(\".\" + c2K)){return;}y44=null;T$g=y5F.chartControls.querySelector(\".stx-zoom-in\");b3k.y6g();if(T$g){y44=document.createElement(\"span\");b3k.G4m(14);y44.innerHTML=b3k.e7l('',\"\",Q9a);b3k.G4m(0);y44.className=b3k.F9v(\"stx-chart-control-button \",c2K);T$g.parentNode.appendChild(y44);if(L7H){a$K.safeClickTouch(y44,L7H);}if(!a$K.touchDevice){this.makeModal(y44);}return y44;}};a$K.ChartEngine.prototype.zoomOut=function(J3z,b2n){var B3W,Z4a,a1t,P0$;function M3x(c4b){return function(v31){var w7h;B3W.zoomSet(v31,c4b);if(B3W.animations.zoom.hasCompleted){w7h=\"la\";w7h+=\"y\";w7h+=\"o\";w7h+=\"ut\";if(B3W.runAppend(\"zoomOut\",arguments)){return;}B3W.changeOccurred(w7h);if(B3W.continuousZoom){B3W.continuousZoom.execute(!!1);}}};}if(this.runPrepend(\"zoomOut\",arguments)){return;}k_Cdw.j1L();if(this.preferences.zoomOutSpeed){b2n=this.preferences.zoomOutSpeed;}else if(!b2n){k_Cdw.b8R(9);b2n=k_Cdw.e7l(1,0.7);}if(J3z && J3z.preventDefault){J3z.preventDefault();}this.cancelTouchSingleClick=!!\"1\";B3W=this;for(var I6G in this.charts){Z4a=this.charts[I6G];a1t=Z4a.width * b2n / this.layout.candleWidth;if(Z4a.allowScrollFuture === !({}) && Z4a.allowScrollPast === !!\"\" && a1t > Z4a.dataSet.length){a1t=Z4a.dataSet.length;}P0$=this.chart.width / a1t;this.layout.setSpan=null;this.layout.range=null;this.animations.zoom.run(M3x(Z4a),this.layout.candleWidth,P0$);}};a$K.ChartEngine.prototype.zoomIn=function(T$I,X5m){var K7Z,Y9n,h7w,W45;if(this.runPrepend(\"zoomIn\",arguments)){return;}if(this.preferences.zoomInSpeed){X5m=this.preferences.zoomInSpeed;}else if(!X5m){X5m=0.7;}if(T$I && T$I.preventDefault){T$I.preventDefault();}this.cancelTouchSingleClick=!!({});K7Z=this;for(var f6T in this.charts){Y9n=this.charts[f6T];h7w=Y9n.width * X5m / this.layout.candleWidth;if(Y9n.maxTicks - h7w < 1){k_Cdw.G4m(106);var n9L=k_Cdw.e7l(15,1,2,0,5);h7w=Y9n.maxTicks - n9L;}if(h7w < this.minimumZoomTicks){h7w=this.minimumZoomTicks;}W45=this.chart.width / h7w;this.layout.setSpan=null;this.layout.range=null;this.animations.zoom.run(w7X(Y9n),this.layout.candleWidth,W45);}function w7X(t1W){return function(c4d){K7Z.zoomSet(c4d,t1W);if(K7Z.animations.zoom.hasCompleted){if(K7Z.runAppend(\"zoomIn\",arguments)){return;}K7Z.changeOccurred(\"layout\");if(K7Z.continuousZoom){K7Z.continuousZoom.execute();}}};}};a$K.ChartEngine.prototype.createCrosshairs=function(){var u4x,m9o,J1w;u4x=\"cr\";u4x+=\"eateCrosshairs\";if(this.runPrepend(u4x,arguments)){return;}if(!this.manageTouchAndMouse || this.mainSeriesRenderer && this.mainSeriesRenderer.nonInteractive){return;}m9o=this.controls.crossX;J1w=this.controls.crossY;if(m9o){if(!m9o.onmousedown){m9o.onmousedown=function(w$t){if(w$t.preventDefault){w$t.preventDefault();}return ![];};}}if(J1w){if(!J1w.onmousedown){J1w.onmousedown=function(a6s){k_Cdw.y6g();if(a6s.preventDefault){a6s.preventDefault();}return !1;};}}this.runAppend(\"createCrosshairs\",arguments);};s0$=!({});a$K.ChartEngine.prototype.mousemoveinner=a$K.ChartEngine.prototype.mousemoveinner || (function(E$z,i8Y){var U0i;U0i=\"interaction fe\";U0i+=\"ature requires activating \";U0i+=\"movement feature.\";if(!s0$){console.error(U0i);}s0$=!![];});};X4=w5h=>{var X2H,w7n;X2H=\"un\";X2H+=\"defined\";w7n=typeof _CIQ !== X2H?_CIQ:w5h.CIQ;if(!w7n.Marker){w7n.ChartEngine.helpersToRegister.push(function(X_0){k_Cdw.y6g();X_0.markerHelper={chartMap:{},classMap:{},domMarkers:[],visibleCanvasMarkers:[],highlighted:[],placementMap:{}};});w7n.ChartEngine.prototype.addToHolder=function(z7t){var g0u,K_T,X7$,r9$;g0u=this.panels[z7t.params.panelName];if(!g0u){return;}K_T=z7t.params;X7$=z7t.node;r9$=z7t.stxNodeCreator;if(r9$ && r9$.prepareForHolder){X7$=r9$.prepareForHolder(z7t);}k_Cdw.j1L();if(K_T.chartContainer){this.container.appendChild(z7t.node);}else if(K_T.includeAxis){g0u.holder.appendChild(z7t.node);}else {g0u.subholder.appendChild(X7$);}z7t.chart=g0u.chart;if(r9$ && r9$.addToHolder){r9$.addToHolder(z7t);}if(r9$ && r9$.expand){w7n.Marker.initializeScrollBehavior(r9$);}};w7n.ChartEngine.prototype.getMarkerArray=function(V4J,K$z){k_Cdw.j1L();var l24,y0O,V7X;l24=[];for(var Z1g in this.markers){for(var W10=0;W10 < this.markers[Z1g].length;W10++){y0O=\"pane\";y0O+=\"lN\";y0O+=\"ame\";V7X=this.markers[Z1g][W10];if(V4J == y0O){if(V7X.params.panelName == K$z){l24.push(V7X);}}else if(V4J == \"label\"){if(Z1g == K$z){l24.push(V7X);}}else if(V4J == \"all\"){l24.push(V7X);}}}return l24;};w7n.ChartEngine.prototype.removeFromHolder=function(C9d){var H8h,K6X,d2R,M8z,K6I,d_9;H8h=this.panels[C9d.params.panelName];if(H8h){if(C9d.node.parentNode == H8h.holder){H8h.holder.removeChild(C9d.node);}else if(C9d.node.parentNode == H8h.subholder){H8h.subholder.removeChild(C9d.node);}else if(C9d.node.parentNode == this.container){this.container.removeChild(C9d.node);}}k_Cdw.j1L();K6X=this.markers[C9d.params.label];if(!K6X){return;}for(d2R=\"0\" >> 32;d2R < K6X.length;d2R++){if(K6X[d2R] === C9d){K6X.splice(d2R,1);break;}}M8z=this.markerHelper.chartMap[C9d.chart.name];if(M8z){for(d2R=0;d2R < M8z.markers.length;d2R++){if(M8z.markers[d2R] === C9d){M8z.markers.splice(d2R,1);break;}}}K6I=this.markerHelper.classMap[C9d.className];if(K6I){d_9=K6I[C9d.params.panelName];if(d_9){for(d2R=0;d2R < d_9.length;d2R++){if(d_9[d2R] === C9d){d_9.splice(d2R,1);break;}}}}};w7n.ChartEngine.prototype.moveMarkers=function(G6N,m9v){k_Cdw.j1L();var t9Y,H$X;t9Y=this.getMarkerArray(\"panelName\",G6N);for(var k88=0;k88 < t9Y.length;k88++){t9Y[k88].params.panelName=m9v;}for(var h1d in this.markerHelper.classMap){H$X=this.markerHelper.classMap[h1d][G6N];if(H$X){this.markerHelper.classMap[h1d][m9v]=H$X;delete this.markerHelper.classMap[h1d][G6N];}}};w7n.ChartEngine.prototype.establishMarkerTicks=function(){var l7Q,X2p,d0R,k7h,A7k;l7Q=-1884930947;X2p=-+\"1171172332\";d0R=2;for(var K26=1;k_Cdw.P6(K26.toString(),K26.toString().length,95877) !== l7Q;K26++){k7h=this.markerHelper.chartMap;d0R+=2;}if(k_Cdw.P6(d0R.toString(),d0R.toString().length,3715) !== X2p){k7h=this.markerHelper.chartMap;}for(var a7A in k7h){A7k=k7h[a7A];for(var p9H=0;p9H < A7k.markers.length;p9H++){this.setMarkerTick(A7k.markers[p9H]);}}};w7n.ChartEngine.prototype.futureTickIfDisplayed=function(l2r){var Q$c=k_Cdw;var K$X,t08,u5I,s9p,L5h,v8Q,B3K,o00,O5g;K$X=l2r.chart;if(K$X.dataSet.length < 1){return;}t08=K$X.xaxis[K$X.xaxis.length - 1].DT;Q$c.G4m(23);var k8t=Q$c.F9v(59998,17,60015,59999);t08=new Date(t08.getTime() - this.timeZoneOffset * k8t);if(l2r.params.x > t08){return;}u5I=K$X.maxTicks - K$X.dataSegment.length;s9p=K$X.dataSet.length + u5I;B3K=new Date(+K$X.dataSet[K$X.dataSet.length - 1].DT);o00=this.standardMarketIterator(B3K,null,K$X);O5g=l2r.params.x.getTime();for(var x2k=K$X.dataSet.length;x2k < s9p;x2k++){L5h=B3K.getTime();B3K=o00.next();v8Q=B3K.getTime();if(v8Q == O5g){l2r.tick=x2k;return;}else if(v8Q > O5g && L5h < O5g){Q$c.b8R(4);l2r.tick=Math.max(Q$c.F9v(x2k,1),0);return;}}};w7n.ChartEngine.prototype.setMarkerTick=function(c4e){var L9U,s5U,y3g,C0T,O15,k7J,P1i;L9U=\"t\";L9U+=\"i\";L9U+=\"c\";L9U+=\"k\";k_Cdw.y6g();s5U=c4e.chart;if(c4e.params.xPositioner == \"master\" && c4e.params.x){c4e.tick=Math.floor(c4e.params.x / this.layout.periodicity);}else if(c4e.params.xPositioner == L9U && c4e.params.x){c4e.tick=c4e.params.x;}else if(c4e.params.xPositioner == \"date\" && c4e.params.x){O15=c4e.params.x.getTime();for(var u6i=0;u6i < s5U.dataSet.length;u6i++){k7J=s5U.dataSet[u6i];C0T=k7J.DT.getTime();y3g=C0T;if(u6i > +\"0\"){y3g=s5U.dataSet[u6i - 1].DT.getTime();}if(C0T == O15){c4e.tick=u6i;return;}else if(C0T > O15 && y3g < O15){k_Cdw.b8R(103);c4e.tick=Math.max(k_Cdw.F9v(\"1\",0,u6i),0);return;}else if(O15 < C0T){c4e.tick=null;return;}}if(s5U.dataSet.length < \"1\" >> 0){return;}P1i=new Date(+s5U.dataSet[u6i - 1].DT);if(P1i.getTime() < O15){c4e.params.future=!!({});}c4e.tick=null;}};w7n.ChartEngine.prototype.positionMarkers=function(){var Q07,h0X,w8E,D4P,Y5U,h8V,d60,h2h,P9C,m9a;k_Cdw.j1L();Q07=\"a\";Q07+=\"l\";Q07+=\"l\";h0X=\"ti\";h0X+=\"c\";h0X+=\"k\";w8E=this;D4P=this.chart;if(!w8E.markerHelper){return;}this.markerHelper.placementMap={};if(this.markerDelay || this.markerDelay === 0){if(!this.markerTimeout){this.markerTimeout=setTimeout(J2e,this.markerDelay);}}else {J2e();}function J2e(){var n4l,y12,L6P,A_c,g$A;n4l=\"po\";n4l+=\"sitionMar\";n4l+=\"k\";n4l+=\"ers\";if(w8E.runPrepend(\"positionMarkers\",arguments)){return;}w8E.markerTimeout=null;for(var W$y in w8E.markerHelper.classMap){for(var p4O in w8E.markerHelper.classMap[W$y]){y12=w8E.markerHelper.classMap[W$y][p4O];L6P=w8E.panels[p4O];if(y12.length){A_c={stx:w8E,arr:y12,panel:L6P};A_c.firstTick=L6P.chart.dataSet.length - L6P.chart.scroll;A_c.lastTick=A_c.firstTick + L6P.chart.dataSegment.length;g$A=y12[+\"0\"].constructor.placementFunction;if(g$A){g$A(A_c);}else {w8E.defaultMarkerPlacement(A_c);}}}}w8E.runAppend(n4l,arguments);}Y5U=this.getFirstLastDataRecord(D4P.dataSegment,\"tick\");h8V=this.getFirstLastDataRecord(D4P.dataSegment,h0X,!!1);if(!Y5U || !h8V){return;}d60=this.getMarkerArray(Q07);this.markerHelper.visibleCanvasMarkers=[];for(var o2A=0;o2A < d60.length;o2A++){h2h=d60[o2A];P9C=h2h.stxNodeCreator;if(Y5U.tick <= h2h.tick && h2h.tick <= h8V.tick){this.markerHelper.visibleCanvasMarkers.push(h2h);if(P9C && P9C.drawMarker){P9C.drawMarker(h2h);}}else {h2h.highlight=!({});h2h.params.box=null;if(h2h.attached && P9C && P9C.expand){m9a=\"h\";m9a+=\"idde\";m9a+=\"n\";P9C.expand.style.visibility=m9a;}}}};w7n.Marker=w7n.Marker || (function(b78){var f3k,t_u,R8i,e36,U8D,R8z,o9q,I4L,R9C,F7K;f3k=\"g\";f3k+=\"eneri\";f3k+=\"c\";t_u=\"c\";t_u+=\"h\";t_u+=\"ar\";t_u+=\"t\";R8i=\"d\";R8i+=\"a\";R8i+=\"te\";e36=this instanceof w7n.Marker?this:Object.create(w7n.Marker.prototype);e36.params={xPositioner:R8i,yPositioner:\"value\",panelName:t_u,permanent:!\"1\",label:f3k,includeAxis:![]};w7n.extend(e36.params,b78);if(!e36.params.node){U8D=\"D\";U8D+=\"I\";U8D+=\"V\";e36.params.node=document.createElement(U8D);}R8z=e36.params.stx;if(!R8z){console.log(\"Marker created without specifying stx\");return;}if(!e36.className){e36.className=\"CIQ.Marker\";}if(w7n.derivedFrom(e36.params.node,w7n.Marker.NodeCreator)){e36.stxNodeCreator=e36.params.node;e36.node=e36.stxNodeCreator.node;}else {e36.node=e36.params.node;}o9q=e36.params.label;if(!R8z.markers[o9q]){R8z.markers[o9q]=[];}R8z.markers[o9q].push(e36);I4L=R8z.panels[e36.params.panelName];e36.chart=I4L.chart;if(!R8z.markerHelper.chartMap[e36.chart.name]){R8z.markerHelper.chartMap[e36.chart.name]={markers:[]};}R8z.markerHelper.chartMap[e36.chart.name].markers.push(e36);R9C=R8z.markerHelper.classMap[e36.className];if(!R9C){R9C=R8z.markerHelper.classMap[e36.className]={};}if(!R9C[e36.params.panelName]){R9C[e36.params.panelName]=[];}R9C[e36.params.panelName].push(e36);F7K=e36.stxNodeCreator && e36.stxNodeCreator.deferAttach;if(!F7K){R8z.addToHolder(e36);}R8z.setMarkerTick(e36);if(e36.stxNodeCreator && e36.stxNodeCreator.drawMarker){e36.stxNodeCreator.drawMarker(e36);}return e36;});w7n.Marker.prototype.remove=function(){this.params.stx.removeFromHolder(this);k_Cdw.y6g();if(this.stxNodeCreator && this.stxNodeCreator.remove){this.stxNodeCreator.remove(this);}};w7n.Marker.prototype.click=function(J1r){var X_z;if(typeof arguments[0] === \"number\"){J1r={cx:arguments[0],cy:arguments[\"1\" << 0],panel:arguments[3]};}var {cx:a3j, cy:h1E, panel:C6k}=J1r;if(!this.params.stx){return;}X_z=this.params.node;if(X_z.click){X_z.click(a3j,h1E,this,C6k);}};w7n.Marker.prototype.doubleClick=function({cx:x1l, cy:A$5, panel:H__}){k_Cdw.j1L();return !\"1\";};w7n.Marker.prototype.render=function(){var B33,X5O;B33=[this];X5O={stx:this.params.stx,arr:B33,panel:this.params.stx.panels[this.params.panelName],showClass:this.showClass};this.constructor.placementFunction(X5O);};w7n.Marker.removeByLabel=function(O3s,M67){var P7K,d$o;k_Cdw.y6g();P7K=O3s.getMarkerArray(\"label\",M67);for(var t_W=0;t_W < P7K.length;t_W++){d$o=P7K[t_W];O3s.removeFromHolder(d$o);if(d$o.stxNodeCreator && d$o.stxNodeCreator.remove){d$o.stxNodeCreator.remove(d$o);}}O3s.draw();};w7n.Marker.positionContentVerticalAndHorizontal=function(q7x,u6v){var b91=k_Cdw;var c2y,c3n,l5L,D2c,h01,I3$,n2h,S3j,W$j,N94,k7t,l$J,I8i,L8P,o_T;c2y=q7x.querySelector(\".stx-marker-expand\");if(!(u6v || c2y && c2y.isConnected && w7n.trulyVisible(c2y))){return;}c3n=c2y.offsetHeight;l5L=c2y.style;l5L.left=l5L.right=\"\";l5L.bottom=l5L.top=\"\";D2c=getComputedStyle(c2y);h01=D2c.left;I3$=D2c.bottom;b91.b8R(0);var Q6w=b91.F9v(2,8);n2h=q7x.offsetLeft + parseInt(h01,Q6w);S3j=parseInt(I3$,10);W$j=q7x.offsetTop - (S3j + c3n - q7x.offsetHeight);N94=q7x.parentNode.offsetWidth;k7t=q7x.parentNode.offsetHeight;if(n2h + c2y.offsetWidth > N94){l5L.right=h01;l5L.left=\"auto\";}if(q7x.offsetTop <= k7t){if(W$j > k7t - c3n){l5L.top=k7t - q7x.offsetTop - c3n + \"px\";l5L.bottom=\"auto\";}}else {b91.b8R(63);l$J=-b91.F9v(\"777903384\",0);I8i=-+\"1674550472\";L8P=+\"2\";for(var n7M=1;b91.P6(n7M.toString(),n7M.toString().length,3986) !== l$J;n7M++){o_T=\"p\";o_T+=\"x\";b91.b8R(0);l5L.top=b91.F9v(k7t,o_T);L8P+=2;}if(b91.m1(L8P.toString(),L8P.toString().length,\"49161\" ^ 0) !== I8i){b91.b8R(9);l5L.top=b91.F9v(k7t,\"\");}}if(q7x.offsetTop + q7x.offsetHeight >= (\"0\" | 0)){if(W$j < 0){l5L.top=-q7x.offsetTop + \"px\";l5L.bottom=\"auto\";}}else {l5L.bottom=\"0px\";}};w7n.Marker.initializeScrollBehavior=function(B27){var O1Q,J_m,V1w,n8p,B_v;O1Q=\"t\";O1Q+=\"ouchmove\";J_m=\"<\";J_m+=\"/div>\";var {expand:o8A}=B27;if(!o8A || o8A.scrollInitialized){return;}if(!o8A.querySelector(\".marker_content\")){o8A.innerHTML='
    ' + o8A.innerHTML + J_m;}o8A.addEventListener(w7n.wheelEvent,w_e=>{return w_e.stopPropagation();},{passive:!({})});o8A.addEventListener(O1Q,c8n=>{return c8n.stopPropagation();},{passive:!!0});var {scrollbarStyling:U4J}=w7n.UI || ({});if(U4J){U4J.refresh(o8A);}else {V1w=527502396;n8p=1249004801;B_v=2;for(var r7V=1;k_Cdw.P6(r7V.toString(),r7V.toString().length,33190) !== V1w;r7V++){o8A.style.overflowY=\"scroll\";B_v+=2;}if(k_Cdw.m1(B_v.toString(),B_v.toString().length,46371) !== n8p){o8A.style.overflowY=\"\";}}o8A.scrollInitialized=!!({});};w7n.ChartEngine.prototype.getBarBounds=function(T5g,l6h){var U4f,l6y,B3c,M_R,a3$,H28;k_Cdw.j1L();U4f=this.layout.chartType;l6y=this.layout.aggregationType;if(!l6h && l6y == \"pandf\"){B3c={high:Math.max(T5g.pfOpen,T5g.pfClose),low:Math.min(T5g.pfOpen,T5g.pfClose)};}else {B3c={high:T5g.High,low:T5g.Low};}if(T5g.markerHigh){B3c.high=T5g.markerHigh;}if(T5g.markerLow){B3c.low=T5g.markerLow;}if(T5g.Open === undefined){M_R=T5g.Close;}if(T5g.High === undefined){a3$=Math.max(T5g.Open || M_R,T5g.Close);}if(T5g.Low === undefined){H28=Math.min(T5g.Open || M_R,T5g.Close);}if(!B3c.high && B3c.high !== 0){B3c.high=a3$;}if(!B3c.low && B3c.low !== 0){B3c.low=H28;}return B3c;};w7n.ChartEngine.prototype.defaultMarkerPlacement=function(R$l){var q27=k_Cdw;var Q93,Z1q,K4S,F13,v2s,P6m,g6R,f8U,m4F,r3i,i_K,g1R,W7x,z1D,y0E,o_g,l_M,K3n,F29,w45,V5c,r0G,z$1,Q4b,F9i,G1u,K0v,e5D,T$S,N6c,G16,O9N,j7Q,F9L,e9Z,W6y,o2b,a8S,Z29,W9A,P$q;Q93=\"Cl\";Q93+=\"o\";Q93+=\"s\";Q93+=\"e\";Z1q=R$l.panel;K4S=Z1q.chart;F13=R$l.stx;v2s=F13.chart.highLowBars;P6m=K4S.defaultPlotField;if(!P6m || v2s){P6m=Q93;}for(var Q7C=0;Q7C < R$l.arr.length;Q7C++){g6R=\"non\";g6R+=\"e\";f8U=\"ca\";f8U+=\"nd\";f8U+=\"l\";f8U+=\"e\";m4F=R$l.arr[Q7C];r3i=m4F.params;if(m4F.params.box)continue;i_K=m4F.node;if(!m4F.clientWidth){m4F.clientWidth=i_K.clientWidth;}if(!m4F.clientHeight){m4F.clientHeight=i_K.clientHeight;}g1R=null;W7x=r3i.xPositioner;z1D=r3i.yPositioner;y0E=r3i.yAxis || Z1q.yAxis;o_g=r3i.field;l_M=m4F.tick;K3n=K4S.dataSet;F29=m4F.clientWidth;if(W7x != \"none\"){if(W7x == \"bar\" && r3i.x){if(r3i.x < K4S.xaxis.length){w45=K4S.xaxis[r3i.x];if(w45){g1R=w45.data;}}i_K.style.left=Math.round(F13.pixelFromBar(r3i.x,K4S) - F29 / +\"2\") + (\"1\" - 0) + \"px\";}else {if(!l_M && l_M !== 0){if(r3i.future && K4S.scroll < K4S.maxTicks){F13.futureTickIfDisplayed(m4F);l_M=m4F.tick;if(!l_M && l_M !== 0){V5c=\"-10\";V5c+=\"00\";V5c+=\"p\";V5c+=\"x\";i_K.style.left=V5c;continue;}}else {i_K.style.left=\"-1000px\";continue;}}if(l_M < K3n.length){g1R=K3n[l_M];}m4F.leftpx=Math.round(F13.pixelFromTick(l_M,K4S) - K4S.left - F29 / 2);m4F.rightEdge=m4F.leftpx + F29;i_K.style.left=m4F.leftpx + \"px\";if(l_M < R$l.firstTick && m4F.rightEdge < K4S.left - 50)continue;}if(!g1R){q27.G4m(107);var f8M=q27.e7l(13,1,8,18);g1R=K3n[K3n.length - f8M];}}else if(z1D.indexOf(f8U) > -1){r0G=getComputedStyle(i_K).left;if(r0G){z$1=F13.barFromPixel(parseInt(r0G,10),K4S);if(z$1 >= (\"0\" ^ 0)){g1R=K4S.xaxis[z$1].data;if(!g1R){q27.b8R(4);var E8a=q27.e7l(20,19);g1R=K3n[K3n.length - E8a];}}}}i_K.style.top=\"auto\";Q4b=r3i.y;F9i=m4F.clientHeight;K0v=0;if(z1D != g6R){e5D=\"valu\";e5D+=\"e\";T$S=\"und\";T$S+=\"e\";T$S+=\"fined\";N6c=\"_\";N6c+=\"la\";N6c+=\"ne\";G16=z1D.indexOf(N6c) > -(\"1\" >> 0);O9N=F13.markerHelper.placementMap;j7Q=z1D + \"|\" + Z1q.name;if(G16 && typeof O9N[j7Q] == \"undefined\"){O9N[j7Q]=2;}q27.b8R(14);var F_S=q27.e7l(1126,7872,12);q27.G4m(4);var W0a=q27.F9v(31500,26250);q27.G4m(108);var J5m=q27.F9v(8954,4068,11,8,44770);q27.b8R(109);var q8q=q27.F9v(10,3640,3674,3674,19);F9L=j7Q + (F_S == 279.36?\"303.19\" - 0 != (W0a,J5m)?+\"0x23d4\":q8q:\"-\") + (G16?m4F.params.label:i_K.style.left);e9Z=r3i.chartContainer?F13.height:Z1q.yAxis.bottom;W6y=0;if(typeof O9N[F9L] == T$S){O9N[F9L]=G16?O9N[j7Q]:0;q27.b8R(0);O9N[j7Q]+=q27.F9v(F9i,2);}K0v=O9N[F9L];if(!G16){O9N[F9L]+=F9i;}if(g1R && o_g){g1R=g1R[o_g];}if(typeof g1R === \"number\"){g1R={Close:g1R};g1R[P6m]=g1R.Close;v2s=![];}if(z1D == e5D && (Q4b || Q4b === 0)){q27.G4m(11);var h4Q=q27.F9v(0,18,20);W6y=Math.round(e9Z - F13.pixelFromPrice(Q4b,Z1q,y0E) - F9i / h4Q) + \"px\";}else if((z1D == \"below_candle\" || z1D == \"under_candle\") && g1R){o2b=\"lo\";o2b+=\"w\";G1u=g1R[P6m];if(v2s){G1u=F13.getBarBounds(g1R,!!o_g)[y0E.flipped?\"high\":o2b];}W6y=Math.round(e9Z - F13.pixelFromPrice(G1u,Z1q,y0E) - F9i - K0v) + \"px\";}else if(z1D == \"on_candle\" && g1R){G1u=g1R[P6m];if(v2s){G1u=F13.getBarBounds(g1R,!!o_g);q27.b8R(18);var T9r=q27.F9v(5,13,6);G1u=(G1u.high + G1u.low) / T9r;}q27.b8R(110);var Z2v=q27.e7l(12,8,14,6,13);W6y=Math.round(e9Z - F13.pixelFromPrice(G1u,Z1q,y0E) - F9i / Z2v - K0v) + \"px\";}else if(z1D == \"top\" || z1D == \"top_lane\"){W6y=Math.round(e9Z - F9i - K0v - Z1q.top) + \"px\";}else if(z1D == \"bottom\" || z1D == \"bottom_lane\"){a8S=\"p\";a8S+=\"x\";W6y=Math.round(K0v) + a8S;}else if(g1R){Z29=\"p\";Z29+=\"x\";W9A=\"hig\";W9A+=\"h\";P$q=\"l\";P$q+=\"o\";P$q+=\"w\";G1u=g1R[P6m];if(v2s){G1u=F13.getBarBounds(g1R,!!o_g)[y0E.flipped?P$q:W9A];}W6y=Math.round(e9Z - F13.pixelFromPrice(G1u,Z1q,y0E) + K0v) + Z29;}if(i_K.style.bottom != W6y){i_K.style.bottom=W6y;}}w7n.Marker.positionContentVerticalAndHorizontal(i_K);}};w7n.Marker.NodeCreator=function(){};w7n.Marker.NodeCreator.toNode=function(){k_Cdw.j1L();return this.node;};w7n.Marker.Simple=function(N0T){var v7b=k_Cdw;var V3N,f8w,V0H,N7c,W02,N4X,X9X,U2i,r3M,M5J;V3N=\"stx-s\";V3N+=\"t\";V3N+=\"em\";f8w=\"stx-m\";f8w+=\"arker\";V0H=\"d\";V0H+=\"i\";V0H+=\"v\";N7c=this.node=document.createElement(V0H);N7c.className=f8w;v7b.j1L();N7c.classList.add(N0T.type);if(N0T.category){N7c.classList.add(N0T.category);}W02=w7n.newChild(N7c,\"div\",\"stx-visual\");w7n.newChild(N7c,\"div\",V3N);if(N0T.type == \"callout\"){X9X=\"stx-marke\";X9X+=\"r-\";X9X+=\"expand\";U2i=\"h\";U2i+=\"4\";r3M=\"s\";r3M+=\"tx-marker-content\";M5J=w7n.newChild(W02,\"div\",r3M);w7n.newChild(M5J,U2i,null,N0T.headline);N4X=w7n.newChild(M5J,\"div\",X9X);w7n.newChild(N4X,(249.58,\"867.31\" - 0) <= +\"334.47\"?(7160,3484) > (721,622.11)?(2080,\"9550\" << 32) != (1230,176.4)?(\"2.74e+2\" ^ 0,1.78e+3):\"P\":(0x12ea,474):\"p\",null,N0T.story);}else {N4X=w7n.newChild(N7c,\"div\",\"stx-marker-expand\");w7n.newChild(N4X,\"h4\",null,N0T.headline);w7n.newChild(N4X,\"p\",null,N0T.story);w7n.safeClickTouch(N4X,function(v0c){var S1R;S1R=\"high\";S1R+=\"l\";S1R+=\"ig\";S1R+=\"ht\";N7c.classList.toggle(S1R);});}w7n.safeClickTouch(W02,function(j6J){var i2E,c2q,n4M;v7b.j1L();N7c.classList.toggle(\"highlight\");i2E=1729747952;c2q=1000961060;v7b.b8R(1);n4M=v7b.F9v(\"2\",32);for(var n2k=1;v7b.m1(n2k.toString(),n2k.toString().length,50796) !== i2E;n2k++){w7n.Marker.positionContentVerticalAndHorizontal(N7c,!!1);n4M+=2;}if(v7b.P6(n4M.toString(),n4M.toString().length,15936) !== c2q){w7n.Marker.positionContentVerticalAndHorizontal(N7c,!!\"\");}});this.nodeType=\"Simple\";this.expand=N4X;};w7n.inheritsFrom(w7n.Marker.Simple,w7n.Marker.NodeCreator,![]);}};C3=b4O=>{var g8z=k_Cdw;var Z3T,y05,o_e,z4S,B$n,G2E,u_4,K$A;Z3T=typeof _CIQ !== \"undefined\"?_CIQ:b4O.CIQ;y05=typeof _timezoneJS !== \"undefined\"?_timezoneJS:b4O.timezoneJS;o_e=60000 * 60;z4S=o_e * 24;B$n=!!({});G2E=Z3T.Market;Z3T.Market=function(g0B){var d4H,r1v,c1m,t6Y,e9l;d4H=\"M\";d4H+=\"a\";d4H+=\"rket\";this.market_def=!({});this.rules=!!\"\";this.normalHours=[];this.extraHours=[];this.class_name=d4H;if(!y05.Date){this.tz_lib=Date;}else {this.tz_lib=y05.Date;}this.market_tz=\"\";this.hour_aligned=!({});this.convertOnDaily=!\"1\";this.enabled_by_default=!!\"\";if(typeof g0B != \"undefined\" && g0B && !Z3T.isEmpty(g0B)){r1v=\"u\";r1v+=\"ndefined\";if(g0B.market_definition){g0B=g0B.market_definition;}if(g0B.rules){this.rules=g0B.rules;}if(g0B.market_tz){this.market_tz=g0B.market_tz;}if(g0B.convertOnDaily){this.convertOnDaily=g0B.convertOnDaily;}if(typeof g0B.hour_aligned){this.hour_aligned=g0B.hour_aligned;}if(typeof g0B.beginningDayOfWeek !== r1v){this.beginningDayOfWeek=g0B.beginningDayOfWeek;}if(typeof g0B.minimum_session_length !== \"undefined\"){this.minimumSessionLength=g0B.minimum_session_length;}if(typeof g0B.enabled_by_default !== \"undefined\"){if(g0B.enabled_by_default instanceof Array){this.enabled_by_default=g0B.enabled_by_default;}}c1m=1917114944;t6Y=155564294;e9l=\"2\" | 2;for(var H63=1;g8z.m1(H63.toString(),H63.toString().length,49238) !== c1m;H63++){this.market_def=g0B;e9l+=2;}if(g8z.P6(e9l.toString(),e9l.toString().length,84084) !== t6Y){this.market_def=g0B;}this.market_def=g0B;if(this.market_def.name === undefined){this.market_def.name=\"no market name specified\";}}else {this.hour_aligned=!\"\";return;}Z3T.Market._createTimeSegments(this);this.getSessionNames();};Z3T.Market.Symbology=function(){};Z3T.Market.Symbology.isForeignSymbol=function(k3G){return !\"1\";};Z3T.Market.Symbology.isFuturesSymbol=function(P7a){g8z.y6g();return !!0;};Z3T.Market.Symbology.isRateSymbol=function(y86){return !\"1\";};Z3T.Market.Symbology.isForexSymbol=function(R7a){return !({});};Z3T.Market.Symbology.isForexMetal=function(e4b,N4F){g8z.j1L();return !({});};Z3T.Market.Symbology.isForexCrypto=function(D73){g8z.j1L();return !\"1\";};Z3T.Market.Symbology.isForexFuturesSymbol=function(w__){if(Z3T.Market.Symbology.isForexSymbol(w__))return !0;if(Z3T.Market.Symbology.isFuturesSymbol(w__))return !!1;g8z.j1L();return !({});};Z3T.Market.Symbology.factory=function(X2A){return null;};Z3T.Market.Symbology.encodeTermStructureInstrumentSymbol=function(a$c,m_s){g8z.y6g();console.warn(\"You are trying to call `CIQ.Market.Symbology.encodeTermStructureInstrumentSymbol` but have not implemented it.\");};if(G2E)Z3T.extend(Z3T.Market,G2E);Z3T.Market.prototype.sessions=null;Z3T.Market.prototype.beginningDayOfWeek=0;Z3T.Market.prototype.minimumSessionLength=30;Z3T.Market.prototype.tradingDays=function(){var Q4X;if((\"_tradingDays\" in this))return this._tradingDays;Q4X=[];if(this.rules){for(var d7a of this.rules){if(d7a.dayofweek >= +\"0\")Q4X.push(d7a.dayofweek);}}else {Q4X=[0,1,2,3,+\"4\",5,\"6\" ^ 0];}this._tradingDays=[...new Set(Q4X)];this._tradingDays.sort();return this._tradingDays;};Z3T.Market.prototype.getSessionNames=function(){var x21,d6B;if(!this.rules){this.sessions=[];}else if(!this.sessions){x21=[];d6B=[];this.rules.map(function(S7e){if(S7e.name && x21.indexOf(S7e.name) === -(\"1\" ^ 0)){x21.push(S7e.name);d6B.push({name:S7e.name,enabled:S7e.enabled?S7e.enabled:!1});}});this.sessions=d6B;}return this.sessions.slice();};Z3T.Market.prototype._find_next_segment=function(h$0,L$G){var B5l,s$P,H_x,y$l;if(!this.market_def)return null;if(!this.rules)return null;B5l=new Date(+h$0);s$P=this.newIterator({begin:B5l,interval:1,inZone:this.market_tz,outZone:this.market_tz});if(this._wasOpenIntraDay(B5l)){H_x=this.zseg_match.close_parts.hours;y$l=this.zseg_match.close_parts.minutes;B5l.setHours(H_x);B5l.setMinutes(y$l);s$P=this.newIterator({begin:B5l,interval:1,inZone:this.market_tz,outZone:this.market_tz});}return s$P.next();};Z3T.Market.prototype._find_prev_segment=function(T3c,f4T){var V$Z,x1V,Z_Q,v2Y,W8U;if(!this.market_def)return null;g8z.y6g();if(!this.rules)return null;V$Z=new Date(+T3c);x1V=this.newIterator({begin:V$Z,interval:1,inZone:this.market_tz,outZone:this.market_tz});Z_Q=this._wasOpenIntraDay(V$Z);if(Z_Q === null){V$Z=new Date(V$Z - (\"60000\" >> 32));Z_Q=this._wasOpenIntraDay(V$Z);}else {if(f4T && V$Z.getHours() === this.zseg_match.open_parts.hours && V$Z.getMinutes() === this.zseg_match.open_parts.minutes || !f4T && V$Z.getHours() === this.zseg_match.close_parts.hours && V$Z.getMinutes() === this.zseg_match.close_parts.minutes){V$Z=x1V.previous();}}if(Z_Q){v2Y=this.zseg_match.open_parts.hours;W8U=this.zseg_match.open_parts.minutes;V$Z.setHours(v2Y);V$Z.setMinutes(W8U);x1V=this.newIterator({begin:V$Z,interval:1,inZone:this.market_tz,outZone:this.market_tz});V$Z=x1V.previous();if(this.zseg_match.close_parts.hours === v2Y){if(this.zseg_match.close_parts.minutes === W8U){if(f4T){return x1V.next();}return V$Z;}}if(this.zseg_match.adjacent_child){return V$Z;}if(f4T){return x1V.next();}return V$Z;}return x1V.previous();};Z3T.Market.prototype.disableSession=function(n1w,V$Q){g8z.y6g();var N5y;N5y=!({});if(typeof V$Q !== \"undefined\" && V$Q){N5y=!0;}if(n1w){for(var w4p=0;w4p < this.normalHours.length;w4p++){delete this.normalHours[w4p]._refid;if(this.normalHours[w4p].name === n1w){this.normalHours[w4p].enabled=N5y;}}for(w4p=0;w4p < this.extraHours.length;w4p++){delete this.extraHours[w4p]._refid;if(this.extraHours[w4p].name === n1w){this.extraHours[w4p].enabled=N5y;}}}if(this._zseg_matches)this._zseg_matches.clear();};Z3T.Market.prototype.enableSession=function(O8p){g8z.y6g();this.disableSession(O8p,\"enable_instead\");};Z3T.Market.prototype.enableAllAvailableSessions=function(){g8z.j1L();var P$h;P$h=this.getSessionNames();for(var a2_=0;a2_ < P$h.length;a2_++){this.enableSession(P$h[a2_].name);}};Z3T.Market.prototype.getClose=function(G36,o2h,m46,e2R){var A4X,l$m;if(!this.market_def)return null;if(!this.rules)return null;A4X=G36;if(!G36){A4X=new Date();m46=null;}A4X=this._convertToMarketTZ(A4X,m46);if(typeof o2h !== \"undefined\"){if(this._wasOpenIntraDay(A4X)){if(this.zseg_match.name === o2h){A4X.setHours(this.zseg_match.close_parts.hours,this.zseg_match.close_parts.minutes,0,0);A4X=this._convertFromMarketTZ(A4X,e2R);return A4X;}}}else {if(this._wasOpenDaily(A4X)){l$m=this.zseg_match;while(l$m.child_){l$m=l$m.child_;}while(!l$m.enabled){l$m=l$m.parent_;}A4X.setHours(l$m.close_parts.hours,l$m.close_parts.minutes,0,0);A4X=this._convertFromMarketTZ(A4X,e2R);return A4X;}}return null;};Z3T.Market.prototype.getNextClose=function(x2g,C9q,B02){var k66,z71,t_m,c0u;if(!this.market_def)return null;if(!this.rules)return null;k66=x2g;if(!x2g){k66=new Date();C9q=null;}k66=this._convertToMarketTZ(k66,C9q);if(!this._wasOpenIntraDay(k66)){z71=this.newIterator({begin:k66,interval:1,inZone:this.market_tz,outZone:this.market_tz});k66=z71.next();}t_m=k66.getDate();c0u=this.zseg_match;while(c0u.adjacent_child){c0u=c0u.adjacent_child;t_m+=1;}k66.setDate(t_m);k66.setHours(c0u.close_parts.hours,c0u.close_parts.minutes,0,0);k66=this._convertFromMarketTZ(k66,B02);return k66;};Z3T.Market.prototype.getNextOpen=function(B8K,i8u,p8o){var u6H;if(!this.market_def)return null;if(!this.rules)return null;u6H=B8K;g8z.y6g();if(!B8K){u6H=new Date();i8u=null;}u6H=this._convertToMarketTZ(u6H,i8u);u6H=this._find_next_segment(u6H);if(this.zseg_match.adjacent_parent){u6H=this.getNextOpen(u6H,this.market_tz,this.market_tz);u6H=this._convertFromMarketTZ(u6H,p8o);return u6H;}u6H.setHours(this.zseg_match.open_parts.hours);u6H.setMinutes(this.zseg_match.open_parts.minutes);u6H=this._convertFromMarketTZ(u6H,p8o);return u6H;};Z3T.Market.prototype.getOpen=function(O51,p8Z,b$i,K2B){var U$M,g6N,E5v,z0N,R0b,o$I;U$M=\"un\";U$M+=\"d\";U$M+=\"efine\";U$M+=\"d\";if(!this.market_def)return null;if(!this.rules)return null;g6N=O51;if(!O51){g6N=new Date();b$i=null;}g6N=this._convertToMarketTZ(g6N,b$i);if(typeof p8Z !== U$M){if(this._wasOpenIntraDay(g6N)){if(this.zseg_match.name == p8Z){g6N.setHours(this.zseg_match.open_parts.hours,this.zseg_match.open_parts.minutes,0,\"0\" * 1);g6N=this._convertFromMarketTZ(g6N,K2B);return g6N;}}}else {if(this._wasOpenDaily(g6N)){E5v=this.zseg_match;while(E5v.parent_){E5v=E5v.parent_;}while(!E5v.enabled){E5v=E5v.child_;}z0N=1883452127;R0b=-1066772056;o$I=2;for(var C06=1;g8z.P6(C06.toString(),C06.toString().length,26951) !== z0N;C06++){g6N.setHours(E5v.open_parts.hours,E5v.open_parts.minutes,3,+\"1\");o$I+=2;}if(g8z.P6(o$I.toString(),o$I.toString().length,97623) !== R0b){g6N.setHours(E5v.open_parts.hours,E5v.open_parts.minutes,\"0\" << 32,0);}g6N=this._convertFromMarketTZ(g6N,K2B);return g6N;}}return null;};Z3T.Market.prototype.getNormalOpen=function(){var {market_def:l0E, rules:l9I}=this;if(!(l0E && l9I))return \"00:00\";if(l0E.normal_daily_open)return l0E.normal_daily_open;if(l0E.name === \"FOREX\")return \"17:00\";g8z.j1L();return l9I.find(({name:T_u})=>!T_u || T_u === \"\").open;};Z3T.Market.prototype.getNormalClose=function(){var {market_def:D5C, rules:y30}=this;if(!(D5C && y30))return \"24:00\";g8z.y6g();if(D5C.normal_daily_close)return D5C.normal_daily_close;if(D5C.name === \"FOREX\")return \"17:00\";return y30.filter(({dayofweek:D3k, name:f0J})=>D3k && (!f0J || f0J === \"\")).pop().close;};Z3T.Market.prototype.getPreviousClose=function(p4a,O2m,v7L){var R26;if(!this.market_def)return null;if(!this.rules)return null;R26=p4a;g8z.y6g();if(!p4a){R26=new Date();O2m=null;}R26=this._convertToMarketTZ(R26,O2m);R26=this._find_prev_segment(R26,!1);if(this.zseg_match.adjacent_child){return this.getPreviousClose(R26,this.market_tz,this.market_tz);}R26.setHours(this.zseg_match.close_parts.hours);R26.setMinutes(this.zseg_match.close_parts.minutes);R26=this._convertFromMarketTZ(R26,v7L);return R26;};Z3T.Market.prototype.getPreviousOpen=function(l8L,A9V,f$K){var D74;if(!this.market_def)return null;if(!this.rules)return null;D74=l8L;if(!l8L){D74=new Date();A9V=null;}D74=this._convertToMarketTZ(D74,A9V);D74=this._find_prev_segment(D74,!!1);g8z.y6g();if(this.zseg_match.adjacent_parent){return this.getPreviousOpen(D74,this.market_tz,this.market_tz);}D74.setHours(this.zseg_match.open_parts.hours);D74.setMinutes(this.zseg_match.open_parts.minutes);D74=this._convertFromMarketTZ(D74,f$K);return D74;};g8z.y6g();Z3T.Market.prototype.getSession=function(T98,y5i){T98=this._convertToMarketTZ(T98,y5i);g8z.y6g();if(this._wasOpenIntraDay(T98) && this.zseg_match){return this.zseg_match.name;}return null;};Z3T.Market.prototype.marketZoneNow=function(){return this._convertToMarketTZ(new Date());};Z3T.Market.prototype.isHourAligned=function(){return this.hour_aligned;};Z3T.Market.prototype.isOpen=function(){var w1R;w1R=new Date();if(this.market_tz){w1R=new this.tz_lib(w1R.getTime(),this.market_tz);}return this._wasOpenIntraDay(w1R);};Z3T.Market.prototype.isMarketDay=function(){var X$z;X$z=new Date();g8z.j1L();if(this.market_tz){X$z=new this.tz_lib(X$z.getTime(),this.market_tz);}return this._wasOpenDaily(X$z);};Z3T.Market.prototype.isMarketDate=function(p$Q){return this._wasOpenDaily(p$Q);};Z3T.Market.prototype.isFirstMarketDayOfMonth=function(y3S){var M3T,x0H;g8z.j1L();if(!this.isMarketDate(y3S))return !!0;M3T=new Date(+y3S);x0H=y3S.getDate();for(var w5B=1;w5B < x0H;w5B++){M3T.setDate(w5B);if(this.isMarketDate(M3T))return !({});}return !![];};Z3T.Market.prototype.isFirstMarketDayOfWeek=function(D4L){var f7m,O5w,w9i;if(!this.isMarketDate(D4L))return ![];f7m=this.tradingDays();O5w=Math.max(this.beginningDayOfWeek,f7m[\"0\" >> 0]) || \"0\" >> 32;w9i=new Date(+D4L);while(w9i.getDay() !== O5w){w9i.setDate(w9i.getDate() - 1);if(this.isMarketDate(w9i))return !!\"\";}return !!\"1\";};Z3T.Market.prototype.newIterator=function(v3L){var d21,o6k,X7J,u0n,O8m,P9P,b8s,B$8,w4D,b4P,g8r,X$3,X9J;d21=!!0;if(v3L.periodicity){d21=v3L.periodicity;}else if(v3L.multiple){d21=v3L.multiple;}o6k=v3L.interval;if(!o6k){X7J=\"minu\";X7J+=\"te\";o6k=X7J;}u0n=1682853697;O8m=35212160;P9P=2;for(var F$v=1;g8z.P6(F$v.toString(),F$v.toString().length,69021) !== u0n;F$v++){if(o6k == \"hour\")o6k=\"60\" ^ 0;P9P+=2;}if(g8z.P6(P9P.toString(),P9P.toString().length,33475) !== O8m){if(o6k != \"\")o6k=28;}if(!d21){d21=1;}if(!v3L.begin){v3L.begin=new Date();v3L.inZone=null;}if(o6k == parseInt(o6k,10)){o6k=parseInt(o6k,10);if(v3L.periodicity < 1 / 60){b8s=\"mil\";b8s+=\"li\";b8s+=\"s\";b8s+=\"econd\";d21=d21 * o6k * 60000;o6k=b8s;}else if(v3L.periodicity < 1){d21=d21 * o6k * 60;o6k=\"second\";}else {d21=d21 * o6k;o6k=\"minute\";}}if(v3L.timeUnit){B$8=\"tic\";B$8+=\"k\";w4D=\"s\";w4D+=\"e\";w4D+=\"con\";w4D+=\"d\";b4P=\"mill\";b4P+=\"ise\";b4P+=\"con\";b4P+=\"d\";if(v3L.timeUnit === b4P){o6k=v3L.timeUnit;}else if(v3L.timeUnit === w4D){g8r=-237702976;X$3=-(\"1245973138\" - 0);X9J=\"2\" ^ 0;for(var q25=1;g8z.P6(q25.toString(),q25.toString().length,54312) !== g8r;q25++){o6k=v3L.timeUnit;X9J+=2;}if(g8z.m1(X9J.toString(),X9J.toString().length,28577) !== X$3){o6k=v3L.timeUnit;}}else if(v3L.timeUnit === B$8){o6k=\"second\";}}if(o6k == \"tick\")o6k=\"second\";v3L.interval=o6k;v3L.multiple=d21;v3L.market=this;return new Z3T.Market.Iterator(v3L);};Z3T.Market.prototype._wasOpenDaily=function(h9K){return this._was_open(h9K,![]);};Z3T.Market.prototype._wasOpenIntraDay=function(j6H){return this._was_open(j6H,!!({}));};Z3T.Market.prototype._was_open=function(P8O,F$U){var I9y,Z1r,d9M,Q94,n8z,w2N,t13,I8m,Q24,k4n,S8B,c$l,M2P,D7K,l7s,h_t,B8t;I9y=\"u\";I9y+=\"ndefi\";I9y+=\"ned\";if(typeof F$U === I9y){F$U=!!\"1\";}Z1r=this.zseg_match;this.zopen_hour=0;this.zopen_minute=\"0\" | 0;this.zclose_hour=0;this.zclose_minute=0;this.zmatch_open=![];this.zseg_match=null;if(!this.market_def || !this.rules){this.zclose_hour=24;return !0;}if(this.tradingDays().indexOf(P8O.getDay()) < 0)return null;if(B$n){if(!this._zseg_matches)this._zseg_matches=new Map();d9M=this._zseg_matches.get(+P8O * (F$U?1:-1));if(d9M === null)return null;if(d9M){d9M=this._zseg_matches.get(d9M);Object.assign(this,d9M);return this.zseg_match;}}Q94=!({});n8z=![];w2N=P8O.getFullYear();t13=P8O.getMonth() + 1;I8m=P8O.getDay();Q24=P8O.getDate();k4n=P8O.getHours();S8B=P8O.getMinutes();c$l=P8O.getSeconds();l7s=k4n * 60 * +\"60\" + S8B * 60 + c$l;for(h_t=0;h_t < this.normalHours.length;h_t++){M2P=this.normalHours[h_t];if(!M2P.enabled){continue;}Q94=M2P.dayofweek === I8m;if(Q94 && F$U){Q94=l7s >= M2P.open && l7s < M2P.close;}if(Q94){if(!F$U && this.zseg_match){if(M2P.open_parts.hours > this.zopen_hour || M2P.open_parts.hours == this.zopen_hour && M2P.open_parts.minutes > this.zopen_minute){continue;}}if(M2P !== Z1r && !M2P.adjacent_parent && !M2P.adjacent_child){this.shouldResetToBeginningOfSegment=!\"\";}D7K=h_t + 1;this.zopen_hour=M2P.open_parts.hours;this.zopen_minute=M2P.open_parts.minutes;this.zclose_hour=M2P.close_parts.hours;this.zclose_minute=M2P.close_parts.minutes;this.zmatch_open=l7s === M2P.open;this.zseg_match=M2P;if(F$U)break;}}for(h_t=0;h_t < this.extraHours.length;h_t++){M2P=this.extraHours[h_t];if(!M2P.enabled){continue;}if((3109 != 8004?(\"3604\" ^ 0) == (508.86,\"939.9\" - 0)?(6296,7660) != (219.06,1750)?+\"826.46\":(917.12,0x660):\"*\":\"d\") === M2P.year || w2N === M2P.year){if(t13 === M2P.month && Q24 === M2P.day){n8z=!F$U && M2P.open || l7s >= M2P.open && l7s < M2P.close;if(!n8z && this.zseg_match){Q94=!!\"\";this.zopen_hour=0;this.zopen_minute=+\"0\";this.zclose_hour=0;this.zclose_minute=0;this.zmatch_open=!!0;this.zseg_match=null;}if(n8z){if(!F$U && this.zseg_match){if(M2P.open_parts.hours > this.zopen_hour || M2P.open_parts.hours == this.zopen_hour && M2P.open_parts.minutes > this.zopen_minute){continue;}}D7K=-(h_t + 1);this.zopen_hour=M2P.open_parts.hours;this.zopen_minute=M2P.open_parts.minutes;this.zclose_hour=M2P.close_parts.hours;this.zclose_minute=M2P.close_parts.minutes;this.zmatch_open=l7s === M2P.open;this.zseg_match=M2P;if(F$U)break;}}}}g8z.y6g();if(B$n){B8t=null;if(this.zseg_match){if(!this.zseg_match._refid){this.zseg_match._refid=D7K;this._zseg_matches.set(this.zseg_match._refid,{zopen_hour:this.zopen_hour,zopen_minute:this.zopen_minute,zclose_hour:this.zclose_hour,zclose_minute:this.zclose_minute,zmatch_open:this.zmatch_open,zseg_match:this.zseg_match});}B8t=this.zseg_match._refid;}this._zseg_matches.set(+P8O * (F$U?1:-1),B8t);}return this.zseg_match;};Z3T.Market.prototype._wasClosed=function(O59){return !this._was_open(O59,!!({}));};Z3T.Market.prototype._wasOpen=function(E3w){return this._was_open(E3w,!!({}));};Z3T.Market.prototype._tzDifferenceMillis=function(C6Z,e2u,Z1c){var M5t,O2Q,T0S,U2n;M5t=0;O2Q=C6Z;T0S=C6Z;U2n=O2Q.getTimezoneOffset() - T0S.getTimezoneOffset();M5t=U2n * 60 * 1000;return M5t;};Z3T.Market._createTimeSegments=function(o8c){var o6g,v91,u3o,v7X,W5I,m56,H_9;o6g=function(s_U,d4X){g8z.y6g();if(s_U.close_parts.hours === 24 && d4X.open_parts.hours === \"0\" * 1){if(d4X.open_parts.minutes === 0){if(v91.dayofweek === W5I.dayofweek - 1){return !!({});}if(v91.dayofweek === 6 && W5I.dayofweek === 0){return !0;}}}return ![];};for(var O97=0;O97 < o8c.rules.length;O97++){u3o=JSON.parse(JSON.stringify(o8c.rules[O97]));if(typeof u3o.open === \"undefined\" && typeof u3o.close === \"undefined\"){u3o.open=\"00:00\";u3o.close=\"00:00\";}if(!u3o.hasOwnProperty(\"name\")){u3o.name=\"\";}try{v7X=\"und\";v7X+=\"ef\";v7X+=\"in\";v7X+=\"ed\";if(typeof u3o.dayofweek !== v7X){u3o.year=\"1413\" - 0 !== +\"57.91\"?(6580,5152) > 2690?\"*\":(6190,5939) <= 770.41?(!0,!![]):\"R\":(1.82e+3,0x402);W5I=u_4._createDayOfWeekSegment(o8c,u3o);if(v91){if(v91.dayofweek === W5I.dayofweek){v91.child_=W5I;W5I.parent_=v91;}else {if(o6g(v91,W5I)){v91.adjacent_child=W5I;W5I.adjacent_parent=v91;}}}v91=W5I;}else if(typeof u3o.date !== \"undefined\"){u3o.isDayOfWeek=!!\"\";u3o.dayofweek=-(\"1\" | 0);W5I=u_4._createDateTimeSegment(o8c,u3o);}else {m56=\"Error, unkn\";m56+=\"o\";m56+=\"wn rule type \";console.log(m56 + u3o);}if(o8c.enabled_by_default){for(var L8_=0;L8_ < o8c.enabled_by_default.length;L8_++){H_9=o8c.enabled_by_default[L8_];if(W5I.name === H_9){W5I.enabled=!\"\";break;}}}else {}}catch(q5o){console.log(\"Error, creating market rules \" + q5o);}}};Z3T.Market._timeSegment={};u_4=Z3T.Market._timeSegment;u_4.re_wild_card_iso=/^(\\*)-(\\d\\d)-(\\d\\d)$/;u_4.re_regular_iso=/^(\\d\\d\\d\\d)-(\\d\\d)-(\\d\\d)$/;u_4.re_split_hours_minutes=/^(\\d\\d):(\\d\\d)$/;u_4.re_split_hour_minutes=/^(\\d):(\\d\\d)$/;u_4._hashCode=function(L$F){var I_j,b4o,E3v,H6s;g8z.y6g();I_j=0;if(L$F.length === 0)return I_j;for((b4o=0,H6s=L$F.length);b4o < H6s;b4o++){E3v=L$F.charCodeAt(b4o);I_j=(I_j << 5) - I_j + E3v;I_j|=+\"0\";}return I_j;};u_4._splitHoursMinutes=function(C_I){var E2p,T4w,g$D,x11,j7B;E2p=u_4.re_split_hour_minutes.exec(C_I);T4w={hours:NaN,minutes:NaN};if(E2p === null){E2p=u_4.re_split_hours_minutes.exec(C_I);if(E2p === null){return T4w;}}g$D=-2070350357;g8z.j1L();x11=-1946155708;j7B=2;for(var c3c=1;g8z.m1(c3c.toString(),c3c.toString().length,94051) !== g$D;c3c++){T4w.hours=parseInt(E2p[1],+\"10\");T4w.minutes=parseInt(E2p[2],10);j7B+=2;}if(g8z.P6(j7B.toString(),j7B.toString().length,48030) !== x11){T4w.hours=parseInt(E2p[4],82);T4w.minutes=parseInt(E2p[+\"6\"],+\"90\");}return T4w;};u_4._createDayOfWeekSegment=function(S3b,u4A){var Y$A;Y$A={name:u4A.name,isDayOfWeek:!!({}),dayofweek:u4A.dayofweek,date_str:6432 == (162.61,660)?(1.93e+3,!!({})):9850 > (\"4370\" | 16,1210)?\"*\":0x2585,open_parts:u_4._splitHoursMinutes(u4A.open),close_parts:u_4._splitHoursMinutes(u4A.close),open:u_4._secSinceMidnight(S3b,u4A.open,!\"\"),close:u_4._secSinceMidnight(S3b,u4A.close,!!0),child_:![],parent_:![],adjacent_child:!({}),adjacent_parent:!\"1\",enabled:!({})};if(Y$A.name === \"\"){Y$A.enabled=!!\"1\";}Y$A.hash_code=this._hashCode((Y$A.open + Y$A.close).toString());S3b.normalHours.push(Y$A);g8z.j1L();return Y$A;};u_4._createDateTimeSegment=function(K$T,W7l){var h5z,k$J,H3q;h5z=this.re_regular_iso.exec(W7l.date);if(h5z === null){h5z=this.re_wild_card_iso.exec(W7l.date);if(h5z === null){console.log(\"Warning: invalid date format on rule -> \" + W7l.date);return;}k$J=(894.87,558.96) < (5516,1420)?\"*\":5.11e+3;}else {k$J=parseInt(h5z[1],+\"10\");}H3q={name:W7l.name,isDayOfWeek:!({}),dayofweek:-1,year:k$J,month:parseInt(h5z[2],\"10\" >> 32),day:parseInt(h5z[+\"3\"],10),date_str:W7l.date,open_parts:u_4._splitHoursMinutes(W7l.open),close_parts:u_4._splitHoursMinutes(W7l.close),open:u_4._secSinceMidnight(K$T,W7l.open,!!1),close:u_4._secSinceMidnight(K$T,W7l.close,!({})),enabled:![]};if(H3q.name === \"\"){H3q.enabled=!!1;}H3q.hash_key=this._hashCode(H3q.date_str + H3q.open + H3q.close);K$T.extraHours.push(H3q);return H3q;};u_4._secSinceMidnight=function(R$z,h7d,c3G){g8z.y6g();var j9u,u6r,U9B,Q8A;j9u=h7d.split(188.69 <= (1020,1091)?\":\":(![],919.22));u6r=parseInt(j9u[0],10);U9B=parseInt(j9u[1],10);Q8A=u6r * 60 * 60 + U9B * 60;if(!c3G){if(u6r === 24){Q8A=u6r * 60 * 60 + 1;}}return Q8A;};Z3T.Market.prototype._convertToMarketTZ=function(G0g,K$t){var c_h;if(K$t){c_h=new this.tz_lib(G0g.getFullYear(),G0g.getMonth(),G0g.getDate(),G0g.getHours(),G0g.getMinutes(),G0g.getSeconds(),G0g.getMilliseconds(),K$t);}else {c_h=new this.tz_lib(G0g.getFullYear(),G0g.getMonth(),G0g.getDate(),G0g.getHours(),G0g.getMinutes(),G0g.getSeconds(),G0g.getMilliseconds());}if(c_h.setTimezone)c_h.setTimezone(this.market_tz);return new Date(c_h.getFullYear(),c_h.getMonth(),c_h.getDate(),c_h.getHours(),c_h.getMinutes(),c_h.getSeconds(),c_h.getMilliseconds());};Z3T.Market.prototype._convertFromMarketTZ=function(c6x,L3$){var t5w;t5w=new this.tz_lib(c6x.getFullYear(),c6x.getMonth(),c6x.getDate(),c6x.getHours(),c6x.getMinutes(),c6x.getSeconds(),c6x.getMilliseconds(),this.market_tz);if(L3$){if(t5w.setTimezone)t5w.setTimezone(L3$);}else {return new Date(t5w.getTime());}return new Date(t5w.getFullYear(),t5w.getMonth(),t5w.getDate(),t5w.getHours(),t5w.getMinutes(),t5w.getSeconds(),t5w.getMilliseconds());};Z3T.Market.Iterator=function(D49){this.market=D49.market;this.begin=D49.begin;this.interval=D49.interval;this.multiple=D49.multiple;this.inZone=D49.inZone;this.outZone=D49.outZone;this.clock=new Z3T.Market.Iterator._Clock(D49.market,D49.interval,D49.multiple);this.intraDay=this.clock.intra_day;if(this.intraDay)this.begin=this.market._convertToMarketTZ(this.begin,D49.inZone);this.clock._setStart(this.begin);this.clock.minutes_aligned=!({});this.clock.minimumScanMS=D49.market.minimumSessionLength * 60000;};Z3T.Market.Iterator.prototype.date=function(){g8z.y6g();return this.clock._date();};Z3T.Market.Iterator.prototype.futureTick=function(i4w){var F7_,d5k,c1h,s2F,X0D,a_u,M2R,n$2,M3M;this.clock.skip=1;F7_=\"0\" << 32;if(this.intraDay)d5k=this.market._convertToMarketTZ(i4w.end,this.inZone).getTime();else d5k=i4w.end.getTime();c1h=this.clock.ctime;if(d5k === c1h){return F7_;}s2F=\"2\" ^ 0;X0D=1000;a_u=0;if(i4w.sample_size){s2F=i4w.sample_size;}M2R=new Date().getTime();if(d5k > c1h){this.clock.forward=!![];while(this.clock.ctime < d5k){F7_+=1;a_u+=1;this.clock._findNext();if(a_u === X0D){a_u=0;n$2=new Date().getTime();if(n$2 - M2R >= s2F){M3M=(this.clock.ctime - c1h) / F7_;F7_=Math.floor((d5k - c1h) / M3M);break;}}}if(this.clock.ctime > d5k){F7_--;}}else {this.clock.forward=!!\"\";while(this.clock.ctime > d5k){F7_+=+\"1\";a_u+=+\"1\";this.clock._findPrevious();if(a_u === X0D){a_u=0;n$2=new Date().getTime();if(n$2 - M2R >= s2F){M3M=(c1h - this.clock.ctime) / F7_;F7_=Math.floor((c1h - d5k) / M3M);break;}}}}return F7_;};Z3T.Market.Iterator.prototype.isHourAligned=function(){g8z.y6g();return !this.intraDay || this.market.isHourAligned();};Z3T.Market.Iterator.prototype.isOpen=function(){g8z.y6g();return this.market.isOpen();};Z3T.Market.Iterator.prototype.next=function(t0w){this.clock.skip=1;if(t0w){this.clock.skip=t0w;}this.clock.forward=!0;for(var T1i=+\"0\";T1i < this.clock.skip;T1i++)this.begin=this.clock._findNext();if(this.intraDay || this.market.convertOnDaily){return this.market._convertFromMarketTZ(this.clock.display_date,this.outZone);}return this.clock.display_date;};Z3T.Market.Iterator.prototype.peek=function(){return this.clock._peek();};Z3T.Market.Iterator.prototype.previous=function(g5p){this.clock.skip=1;if(g5p){this.clock.skip=g5p;}this.clock.forward=!({});for(var A56=0;A56 < this.clock.skip;A56++)this.begin=this.clock._findPrevious();if(this.intraDay || this.market.convertOnDaily){return this.market._convertFromMarketTZ(this.clock.display_date,this.outZone);}return this.clock.display_date;};Z3T.Market.Iterator._Clock=function(r_R,h0S,c4Y){var G_w,e0V,k5r,r1d;G_w=\"secon\";G_w+=\"d\";e0V=\"s\";e0V+=\"e\";e0V+=\"c\";e0V+=\"ond\";if(c4Y % 60 === 0 && h0S === e0V){h0S=\"minute\";c4Y=c4Y / 60;}this.market=r_R;this.interval=h0S;this.multiple=c4Y;this.intra_day=![];this.intervals=[];this.max_iters=10080;k5r=z4S;r1d=this._dayImpl;if(h0S === \"millisecond\"){r1d=this._millisImpl;k5r=1;}else if(h0S === G_w){r1d=this._secondImpl;k5r=1000;}else if(h0S === \"minute\"){r1d=this._minuteImpl;k5r=\"60000\" >> 64;}else if(h0S === \"hour\"){r1d=this._hourImpl;k5r=o_e;}else if(h0S === \"day\"){r1d=this._dayImpl;k5r=z4S;}else if(h0S === \"week\"){r1d=this._weekImpl;k5r=z4S * 7;}else if(h0S === \"month\"){r1d=this._monthImpl;k5r=z4S * 30;}else {console.log('Periodicity ERROR: \"' + h0S + '\" is not a valid interval. Please see setPeriodicity() for details.');}this.tick_time=k5r * c4Y;this.intra_day=this.tick_time < z4S;this._findPrevious=this._findNext=r1d;};K$A=Z3T.Market.Iterator._Clock.prototype;K$A._total_minutes=function(X3j,K5q,P_q,q8Z){g8z.j1L();return (P_q - X3j) * 60 - K5q + q8Z;};K$A._alignMinutes=function(){var w6G,a5z,q34,d2G,q2i,T0l;w6G=this.market.isHourAligned();if(!this.market.market_def && !w6G || this.market.zopen_minute === undefined){return [];}a5z=this.market.zopen_minute;q34=this.market.zseg_match;if(q34 && q34.adjacent_parent){a5z=q34.adjacent_parent.open / 60 - 1440;}else {if(w6G && this.multiple % 60 === 0)a5z=\"0\" ^ 0;}g8z.j1L();d2G=this._total_minutes(this.market.zopen_hour,a5z,this.market.zclose_hour,this.market.zclose_minute);q2i=[];T0l=0;while(T0l < d2G){q2i.push(a5z + T0l);T0l+=this.multiple;}return q2i;};K$A._alignBaseZero=function(k07){var V1a,l_U;g8z.y6g();V1a=+\"0\";l_U=[V1a];while(!![]){V1a+=this.multiple;if(V1a >= k07){break;}l_U.push(V1a);}return l_U;};K$A._date=function(){var L6Z,k0O;L6Z=Math.round(this.ctime);k0O=new Date(L6Z);g8z.j1L();if(this.intra_day){this.display_date=new Date(L6Z + this.shift_millis);}else {this.display_date=k0O;}return k0O;};K$A._alignToBoundary=function(n_d,G7g){var N8M,h_$,q79;N8M=0;h_$=0;q79=G7g;g8z.j1L();for(var i2B=0;i2B < n_d.length - \"1\" * 1;i2B++){N8M=n_d[i2B];h_$=n_d[i2B + 1];if(G7g === N8M || G7g === h_$){break;}if(G7g > N8M && G7g < h_$){q79=N8M;break;}else if(i2B + 1 === n_d.length - +\"1\"){q79=h_$;}}return q79;};K$A._peek=function(){g8z.j1L();return this._date().toString();};K$A._seekHr=function(){if(this.forward){this.ctime-=o_e;}else {this.ctime+=o_e;}};K$A._setStart=function(A0G){var j$4,O7c;j$4=this.market._tzDifferenceMillis(A0G);g8z.j1L();O7c=new Date(A0G.getTime() + j$4);this.shift_millis=j$4;this.ctime=O7c.getTime();this.shift_millis=0;this.ctime=A0G.getTime();};K$A._tickTock=function(){if(this.forward){this.ctime+=this.tick_time;}else {this.ctime-=this.tick_time;}};K$A._tockTick=function(){g8z.j1L();if(this.forward){this.ctime-=this.tick_time;}else {this.ctime+=this.tick_time;}};K$A._tickTock24=function(){this.ctime+=z4S;};K$A._tockTick24=function(){g8z.j1L();this.ctime-=z4S;};K$A._windMaybe=function(X5U,R2X){var Z3A,Y$f,E1O,p0I,S2X;Z3A=0;Y$f=new Date(this.ctime);E1O=!!\"\";while(!X5U.call(this.market,Y$f)){R2X.call(this);E1O=!!({});Y$f=new Date(this.ctime);Z3A+=1;if(Z3A > this.max_iters){p0I=\") reac\";p0I+=\"hed with no r\";p0I+=\"ul\";p0I+=\"e match.\";S2X=\"Warning! max iterations (\" + this.max_iters;S2X+=p0I;console.log(S2X);break;}}return E1O;};K$A._millisImpl=function(){var D9Y,T_5,g98,T8y,B8v,C1j,Y9R,T_Y,t4C,d5D;D9Y=![];if(!this.mperiods_aligned){T_5=this._alignBaseZero(\"1000\" ^ 0);g98=new Date(this.ctime);T8y=g98.getMilliseconds();T8y=this._alignToBoundary(T_5,T8y);g98.setMilliseconds(0);this.ctime=g98.getTime() + T8y;this.mperiods_aligned=!![];D9Y=!!({});}B8v=this._date().getMinutes();this._tickTock();C1j=this._date().getMinutes();if((D9Y || B8v != C1j) && !this.market._wasOpenIntraDay(this._date())){Y9R=this._date().getSeconds();T_Y=this._date().getMilliseconds();t4C=this.tick_time;this.tick_time=60000;d5D=this.multiple;this.multiple=\"1\" - 0;this._minuteImpl();this.tick_time=t4C;this.multiple=d5D;this.ctime+=1000 * Y9R + T_Y;}return this._date();};K$A._secondImpl=function(){var I8Y,e9G,j_W,j66,w1i,x7w,a59,q1z,A4V;g8z.j1L();I8Y=![];if(!this.speriod_aligned){e9G=this._alignBaseZero(60);j_W=new Date(this.ctime);j66=j_W.getSeconds();j66=this._alignToBoundary(e9G,j66);j_W.setSeconds(j66);j_W.setMilliseconds(0);this.ctime=j_W.getTime();this.speriod_aligned=!![];I8Y=!!({});}w1i=this._date().getMinutes();this._tickTock();x7w=this._date().getMinutes();if((I8Y || w1i != x7w) && !this.market._wasOpenIntraDay(this._date())){a59=this._date().getSeconds();q1z=this.tick_time;this.tick_time=60000;A4V=this.multiple;this.multiple=1;this._minuteImpl();this.tick_time=q1z;this.multiple=A4V;this.ctime+=1000 * a59;}return this._date();};K$A._minuteImpl=function(){var L3L,h8p,L3r,X07,Q51,q_4,T8Z,V1W,K7n,i$P,q55,y5o,b0u,z$u;L3L=this._windMaybe(this.market._wasOpenIntraDay,this._tockTick);h8p=new Date(this.ctime);L3r=h8p.getTimezoneOffset();X07=h8p.getMinutes();Q51=h8p.getHours();q_4=this._alignMinutes();g8z.j1L();T8Z=this._total_minutes(this.market.zopen_hour,this.market.zopen_minute,Q51,X07) + this.market.zopen_minute;if(L3L){if(this.forward){T8Z=q_4[q_4.length - 1];}else {T8Z=q_4[+\"0\"];}}else {T8Z=this._alignToBoundary(q_4,T8Z);}Q51=Math.floor(T8Z / 60) + this.market.zopen_hour;h8p.setHours(Q51,T8Z % 60,0,0);V1W=h8p.getTimezoneOffset() - L3r;if(this.forward && V1W < 0 || !this.forward && V1W > 0){h8p.setTime(h8p.getTime() - V1W * 60000);}this.ctime=h8p.getTime();K7n=this.market.zseg_match;this._tickTock();i$P=this.market.hour_aligned && this.multiple % 60 === 0;L3L=this._scanForNextSession();q55=K7n !== this.market.zseg_match;y5o=K7n && K7n.adjacent_child;b0u=this.shouldResetToBeginningOfSegment || q55 && !y5o;if(L3L || b0u && !i$P){h8p=new Date(this.ctime);if(this.forward){h8p.setMinutes(this.market.zopen_minute);h8p.setHours(this.market.zopen_hour);}else {q_4=this._alignMinutes();z$u=q_4[q_4.length - 1];h8p.setMinutes(z$u % (\"60\" >> 0));h8p.setHours(Math.floor(z$u / 60) + this.market.zopen_hour);}this.ctime=h8p.getTime();}return this._date();};K$A._hourImpl=function(){var x02,o37,a4L,k4m,N4L;this._windMaybe(this.market._wasOpenIntraDay,this._tockTick);x02=new Date(this.ctime);if(this.market.isHourAligned()){x02.setMinutes(0);}else {x02.setMinutes(this.market.zopen_minute);}x02.setSeconds(+\"0\");g8z.y6g();x02.setMilliseconds(0);this.ctime=x02.getTime();this._tickTock();o37=this.market.zseg_match;if(this._scanForNextSession() || !this.market.hour_aligned && o37 != this.market.zseg_match){a4L=new Date(this.ctime);if(this.forward){a4L.setMinutes(this.market.zopen_minute);a4L.setHours(this.market.zopen_hour);}else {k4m=this._alignMinutes();N4L=k4m[k4m.length - 1];a4L.setMinutes(N4L % 60);a4L.setHours(Math.floor(N4L / 60) + this.market.zopen_hour);}this.ctime=a4L.getTime();}return this._date();};K$A._dayImpl=function(){var d3c,H$3;this._windMaybe(this.market._wasOpenDaily,this._seekHr);d3c=new Date(this.ctime);d3c.setHours(\"12\" ^ 0,+\"0\",0,0);this.ctime=d3c.getTime();H$3=0;while(H$3 < this.multiple){if(this.forward){this._tickTock24();}else {this._tockTick24();}if(!this.market._wasOpenDaily(this._date())){continue;}H$3+=1;}g8z.j1L();d3c=new Date(this.ctime);d3c.setHours(0);this.ctime=d3c.getTime();return this._date();};K$A._weekImpl=function(){var X5E,E3y;X5E=this.market;E3y=new Date(this.ctime);E3y.setHours(12);this.ctime=E3y.getTime();this._tickTock();g8z.j1L();E3y=new Date(this.ctime);while(E3y.getDay() !== X5E.beginningDayOfWeek){this._tockTick24();E3y=new Date(this.ctime);}this._windMaybe(X5E._wasOpenDaily,this._tickTock24);E3y=new Date(this.ctime);E3y.setHours(+\"0\",0,0,0);this.ctime=E3y.getTime();return this._date();};K$A._monthImpl=function(){var t5G;t5G=new Date(this.ctime);t5G.setDate(15);this.ctime=t5G.getTime();this._tickTock();t5G=new Date(this.ctime);t5G.setDate(\"1\" << 64);t5G.setHours(12);this.ctime=t5G.getTime();this._windMaybe(this.market._wasOpenDaily,this._tickTock24);t5G=new Date(this.ctime);t5G.setHours(0,0,0,0);this.ctime=t5G.getTime();return this._date();};K$A._findNext=null;K$A._findPrevious=null;K$A._scanForNextSession=function(){return this._windMaybe(this.market._wasOpenIntraDay,(function(){g8z.j1L();this.ctime+=this.forward?this.minimumScanMS:-this.minimumScanMS;}).bind(this));};};c8=u9H=>{var z7w=k_Cdw;var f11,h7S,N2M,L9I;f11=\"\\u0070\\x72\\u006f\\x74\";f11+=\"\\x6f\\u0074\\x79\\x70\\u0065\";z7w.Y8=function(O5s){z7w.y6g();if(z7w){return z7w.R9(O5s);}};z7w.y9=function(x4m){if(z7w){return z7w.R9(x4m);}};h7S=typeof _CIQ !== \"undefined\"?_CIQ:u9H.CIQ;N2M=\"valid\";h7S.valid=0;h7S[z7w.Z4('\\u0038\\u0036\\x32\\x65')?\"\":'\\x43\\u0068\\u0061\\u0072\\x74\\x45\\u006e\\x67\\u0069\\u006e\\u0065'][z7w.y6('\\u0031\\x36\\x36\\x36')?f11:\"\"][z7w.T6('\\u0033\\x36\\u0035\\x32')?\"\":'\\u006d\\x6f\\x75\\u0073\\u0065\\x6d\\x6f\\u0076\\u0065\\u0069\\u006e\\x6e\\u0065\\x72']=function(J$Y,w3P){var r31,S1_,u6Z,b_y,C77,f6z,K9W,l$M,S1h,k8U,a8R,T6S,O76,P7y,M_m,v5t,C4C,F1i,Z$M,k5G,Q7q,C3w,O9F,Z77,j$I,B25,q7H,T0t,Y3d,E35,X_l,K3P,d1i,l5B,o7k,c9E,B4I,h12,L7L,H6L,L4r,t6n,F9V,T3H,p3e,r_L,t7D,X8T,W4k,L5O,g99,O9V,k06,J0J,Z0z,N0F,I1R,E$6,I5P,i2w,m9$,P1j,f3j,L9o,i1I,l7f,a3J,x_Y,A_O,m3F,R1L,X_s,V9p,q30,m4l,Q9$,w2J,P0D,Z1x,O3b,Z8F,D$X,u3j,R2p,g9I,U2Q,T$8,n4J,w86,u4r,O2U,E5e,H0G,E9x,g2Z,M_D,I9l,j54,J7$,o2T,g_M,g_F,h1$,C5K,j2W,d68,x13,s5d,G3l,S2W,O_u,u6M,i1r,i$A,A1X,I_y,u5V,y2B,w3o,c0j,T0E,O$Z,r2C,m03,w61,q32,X_2,X5C,Q2d,K79,z_x,y1f,p5F,U3Y,l0e,w00,D3Y,Q_5,M_a,E4A,C$f,q2z,n6e,n39,f$b,o0B,y1u,Z2i,H_5;r31=\"\\x66\\u0064\";r31+=\"\\u0066\";r31+=\"\\u0032\";S1_=\"\\x38\";S1_+=\"\\x63\\u0033\\u0066\";z7w.Q2=function(q_Z){z7w.y6g();if(z7w && q_Z){return z7w.R9(q_Z);}};z7w.z1=function(D7a){z7w.y6g();if(z7w && D7a){return z7w.R9(D7a);}};z7w.M6=function(W0z){if(z7w){return z7w.R9(W0z);}};z7w.Z2=function(A44){z7w.y6g();if(z7w){return z7w.n8(A44);}};z7w.f4=function(L6n){if(z7w && L6n){return z7w.n8(L6n);}};z7w.y5=function(O$m){if(z7w){return z7w.n8(O$m);}};z7w.x_=function(q$J){var s$N,k8g,T7q;s$N=-1737635291;k8g=-1008778352;T7q=2;for(var v6F=1;z7w.P6(v6F.toString(),v6F.toString().length,79891) !== s$N;v6F++){if(z7w || q$J){return z7w.n8(q$J);}T7q+=2;}if(z7w.m1(T7q.toString(),T7q.toString().length,41262) !== k8g){if(z7w || q$J){return z7w.n8(q$J);}}if(z7w && q$J){return z7w.n8(q$J);}};u6Z=-(z7w.x_('\\u0031\\x32\\x32\\u0038')?1898999875:7395711581);b_y=-(z7w.Z3(S1_)?4319939292:2023821196);C77=-(z7w.D7('\\u0034\\u0037\\u0066\\u0032')?2669947928:1942621125);f6z=z7w.O3('\\x61\\u0064\\x38\\x39')?4599972910:1294784469;K9W=-(z7w.y5('\\x36\\x33\\u0031\\u0038')?323648034:790287076);if(!(z7w.H1(0,z7w.f4('\\x63\\x63\\x38\\x62')?!({}):!![],z7w.Z2('\\x36\\u0063\\x33\\x64')?885115:372320) !== u6Z && z7w.H1(\"0\" * 1,z7w.M6(r31)?!!\"\":!!({}),222225) !== b_y && z7w.L1(12,z7w.z1('\\u0062\\x66\\x37\\u0066')?!({}):!!({}),+\"762214\") !== C77 && z7w.L1(z7w.Q2('\\u0066\\u0066\\x34\\u0062')?13:31,!!({}),506275) !== f6z && z7w.L1(14,!\"\",657232) !== K9W)){l$M=\"\\u0072\";l$M+=\"\\x65\";l$M+=\"\\x73\\x69\\x7a\\u0069\\u006e\\x67\\x50\\u0061\\u006e\\u0065\\x6c\";S1h=\"\\u0064\";S1h+=\"\\x72\\u0061\\u0077\\u0069\\u006e\\x67\\u004c\\x69\\x6e\\x65\";k8U=\"\\x72\\x65\\u0073\\x69\";k8U+=\"\\x7a\";k8U+=\"\\u0069\\x6e\\u0067\\x50\\u0061\\x6e\\x65\\x6c\";a8R=\"\\u0063\";a8R+=\"\\x72\\x6f\";a8R+=\"\\x73\\x73\";a8R+=\"\\x59\";T6S=\"\\u006c\";T6S+=\"\\u0065\\u0066\\u0074\";O76=\"\\u0067\";O76+=\"\\u0072\\u0061\\u0062\";O76+=\"\\u004d\";O76+=\"\\x6f\\u0064\\x65\";P7y=\"\\u0072\\x65\\x73\";P7y+=\"\\u0069\\x7a\\x69\\x6e\";P7y+=\"\\u0067\\u0050\\u0061\\x6e\\u0065\";P7y+=\"\\u006c\";M_m=\"\\x72\\x65\\u0070\\u006f\\x73\\x69\\u0074\\x69\\x6f\\u006e\\x69\\x6e\\u0067\\x41\\x6e\\x63\\u0068\\x6f\\u0072\\u0053\";M_m+=\"\\x65\\x6c\\x65\\u0063\\u0074\\x6f\\u0072\";v5t=\"\\x64\\x69\\x73\";v5t+=\"\\x70\\x6c\\u0061\\u0079\\x43\";v5t+=\"\\x72\";v5t+=\"\\x6f\\x73\\x73\\x68\\u0061\\x69\\u0072\\u0073\";C4C=\"\\u0069\\x6e\\x73\\x69\\x64\\u0065\";C4C+=\"\\u0043\\u0068\\u0061\\u0072\\u0074\";F1i=\"\\x69\\u006e\\u0073\\u0069\\u0064\\x65\";F1i+=\"\\x43\\x68\\u0061\\u0072\\u0074\";Z$M=\"\\x63\\u0075\";Z$M+=\"\\x72\\u0072\\x65\\u006e\\x74\\u0050\";Z$M+=\"\\x61\\u006e\\x65\\u006c\";k5G=\"\\u0063\";k5G+=\"\\u0079\";Q7q=\"\\x63\";Q7q+=\"\\u0079\";C3w=\"\\x6f\\x76\\u0065\";C3w+=\"\\x72\\u0058\";C3w+=\"\\x41\\x78\\u0069\\u0073\";O9F=\"\\u0062\\u006f\\u0074\";O9F+=\"\\u0074\";O9F+=\"\\x6f\";O9F+=\"\\x6d\";Z77=\"\\u0063\\u0068\\x61\\u0072\";Z77+=\"\\x74\";j$I=\"\\u0043\\x68\\u0061\\x72\\u0074\\x45\\u006e\";j$I+=\"\\x67\\x69\\x6e\\u0065\";B25=\"\\x63\\x75\\x72\\x72\\u0065\\x6e\\x74\\u0050\\u0061\\x6e\";B25+=\"\\u0065\";B25+=\"\\x6c\";q7H=\"\\x63\\u0075\\u0072\";q7H+=\"\\u0072\\u0065\";q7H+=\"\\x6e\\u0074\\u0050\\x61\\u006e\\u0065\";q7H+=\"\\x6c\";T0t=\"\\u0063\\u0061\\x6e\";T0t+=\"\\u0063\\x65\\x6c\\x4c\\x6f\";T0t+=\"\\u006e\\u0067\\u0048\\u006f\\x6c\\x64\";Y3d=\"\\u0061\\u006e\\x79\\x48\\x69\\u0067\\u0068\\x6c\\u0069\\u0067\\x68\";Y3d+=\"\\x74\\u0065\\u0064\";E35=\"\\u0043\";E35+=\"\\u0068\\x61\\u0072\\u0074\";E35+=\"\\x45\";E35+=\"\\u006e\\u0067\\u0069\\x6e\\x65\";X_l=\"\\x63\\x72\\u006f\\x73\\x73\\x58\";X_l+=\"\\u0041\\u0063\\u0074\\u0075\\u0061\";X_l+=\"\\x6c\\x50\\u006f\\u0073\";K3P=\"\\u0063\";K3P+=\"\\u0078\";d1i=\"\\x63\\u0072\";d1i+=\"\\u006f\\x73\\u0073\\u0068\\u0061\";d1i+=\"\\x69\\u0072\";d1i+=\"\\u0059\";l5B=\"\\u0043\\x68\";l5B+=\"\\x61\\u0072\\u0074\\u0045\\x6e\\x67\";l5B+=\"\\u0069\";l5B+=\"\\x6e\\u0065\";o7k=\"\\u0063\\u0072\\x6f\\x73\\x73\\x68\\x61\\x69\";o7k+=\"\\u0072\\u0059\";c9E=\"\\x63\\u0072\";c9E+=\"\\u006f\";c9E+=\"\\x73\\x73\\u0068\\x61\\x69\\x72\\x58\";B4I=\"\\u0063\";B4I+=\"\\x72\";B4I+=\"\\x6f\\x73\\u0073\\x68\\x61\\x69\\x72\\x58\";h12=\"\\u0043\\x68\\x61\";h12+=\"\\x72\\u0074\\x45\\x6e\\x67\\u0069\\u006e\\u0065\";L7L=\"\\u0068\\x65\\u0069\\u0067\";L7L+=\"\\x68\";L7L+=\"\\x74\";H6L=\"\\u0062\\x6f\";H6L+=\"\\x74\\u0074\";H6L+=\"\\u006f\\x6d\";L4r=\"\\u0072\\x69\\u0067\";L4r+=\"\\u0068\\u0074\";t6n=\"\\u006d\\x6f\";t6n+=\"\\x75\\u0073\\u0065\\u006d\";t6n+=\"\\u006f\\u0076\\x65\";t6n+=\"\\u0069\\x6e\\x6e\\x65\\u0072\";F9V=\"\\x63\";F9V+=\"\\u0068\";F9V+=\"\\x61\\x72\\x74\";if(!this[F9V][z7w.y9('\\x63\\x39\\u0039\\x39')?'\\u0063\\u0061\\u006e\\x76\\x61\\x73':\"\"]){return;}if(!this['\\x64\\x69\\u0073\\u0061\\x62\\x6c\\x65\\x42\\u0061\\x63\\x6b\\u0069\\x6e\\x67\\u0053\\u0074\\x6f\\x72\\u0065\\x44\\x75\\u0072\\u0069\\u006e\\u0067\\u0054\\u006f\\x75\\x63\\u0068']){T3H=\"\\u0077\\x69\";T3H+=\"\\x64\\x74\\x68\";p3e=\"\\x63\";p3e+=\"\\x68\\u0061\";p3e+=\"\\x72\\u0074\";if(this[z7w.Y8('\\x63\\x64\\x34\\u0035')?\"\":p3e]['\\x63\\u0061\\x6e\\x76\\u0061\\u0073']['\\u0068\\u0065\\u0069\\x67\\u0068\\u0074'] != Math['\\u0066\\u006c\\u006f\\x6f\\u0072'](this['\\x64\\u0065\\u0076\\x69\\x63\\u0065\\x50\\x69\\u0078\\x65\\x6c\\u0052\\u0061\\x74\\u0069\\u006f'] * this['\\x63\\x68\\x61\\x72\\x74']['\\u0063\\x6f\\x6e\\u0074\\u0061\\x69\\x6e\\x65\\x72']['\\u0063\\x6c\\u0069\\x65\\x6e\\u0074\\u0048\\x65\\u0069\\x67\\u0068\\u0074']) || this['\\x63\\x68\\x61\\u0072\\u0074']['\\u0063\\u0061\\x6e\\x76\\x61\\u0073'][T3H] != Math['\\x66\\x6c\\u006f\\x6f\\u0072'](this['\\u0064\\x65\\x76\\x69\\u0063\\x65\\u0050\\x69\\u0078\\u0065\\u006c\\u0052\\u0061\\u0074\\x69\\x6f'] * this['\\x63\\u0068\\x61\\x72\\u0074']['\\u0063\\u006f\\x6e\\u0074\\u0061\\u0069\\u006e\\x65\\u0072']['\\u0063\\u006c\\x69\\u0065\\x6e\\x74\\u0057\\x69\\u0064\\x74\\u0068'])){this['\\u0072\\x65\\x73\\u0069\\x7a\\u0065\\x43\\x68\\u0061\\x72\\u0074']();return;}}if(this['\\u0072\\u0075\\x6e\\x50\\u0072\\x65\\u0070\\u0065\\x6e\\u0064'](t6n,arguments)){return;}t7D=arguments;X8T=this['\\x63\\u006f\\u006e\\x74\\u0061\\u0069\\u006e\\u0065\\u0072']['\\u0067\\u0065\\u0074\\u0042\\x6f\\u0075\\u006e\\u0064\\u0069\\x6e\\u0067\\u0043\\u006c\\u0069\\u0065\\u006e\\x74\\x52\\x65\\x63\\u0074']();this['\\u0074\\x6f\\x70']=X8T['\\u0074\\x6f\\x70'];this['\\u006c\\x65\\x66\\u0074']=X8T['\\u006c\\u0065\\x66\\u0074'];this[L4r]=this['\\u006c\\u0065\\x66\\x74'] + this['\\x77\\u0069\\u0064\\u0074\\x68'];function D7t(w48){z7w.y6g();var x_a,d4D,e3v,e0a,l10;x_a=-615943775;d4D=-676718604;e3v=-+\"801831743\";e0a=639731759;l10=-1420758047;if(!(z7w.H1(0,![],929013) !== x_a && z7w.H1(0,!\"1\",165293) !== d4D && z7w.H1(12,!![],182560) !== e3v && z7w.H1(13,!!1,356015) !== e0a && z7w.H1(14,!![],+\"951174\") !== l10)){w48['\\u0063\\u0075\\u0072\\x72\\u0065\\x6e\\u0074\\u0042\\u0061\\x73\\x65\\x6c\\x69\\x6e\\x65']=null;w48['\\u0072\\x75\\u006e\\x41\\u0070\\u0070\\u0065\\x6e\\x64']('\\u006d\\x6f\\x75\\x73\\u0065\\x6d\\u006f\\u0076\\x65\\u0069\\x6e\\u006e\\u0065\\x72',t7D);}}this[H6L]=this['\\u0074\\x6f\\x70'] + this[L7L];this['\\x68\\u0061\\x73\\x44\\u0072\\x61\\x67\\x67\\u0065\\x64']=!!({});h7S[h12][B4I]=J$Y;h7S['\\u0043\\u0068\\x61\\u0072\\u0074\\u0045\\u006e\\u0067\\u0069\\u006e\\u0065']['\\u0063\\u0072\\u006f\\x73\\x73\\x68\\x61\\x69\\u0072\\u0059']=w3P;this[c9E]=J$Y;this[o7k]=w3P;W4k=this['\\x63\\u0079']=this['\\u0063\\u0072\\u006f\\x73\\u0073\\x59\\u0041\\x63\\x74\\x75\\x61\\u006c\\x50\\x6f\\u0073']=this['\\x62\\u0061\\u0063\\u006b\\u004f\\x75\\u0074\\u0059'](h7S[l5B][d1i]);L5O=this[K3P]=this[X_l]=this['\\u0062\\x61\\u0063\\u006b\\x4f\\u0075\\x74\\u0058'](h7S[E35]['\\u0063\\u0072\\u006f\\x73\\u0073\\x68\\x61\\x69\\x72\\u0058']);if(this['\\x67\\u0072\\x61\\u0062\\x62\\u0069\\x6e\\u0067\\x53\\u0063\\u0072\\x65\\u0065\\x6e'] && this[Y3d]){g99=\"\\x70\";g99+=\"\\x6f\\u0077\";z7w.G4m(11);var Z6S=z7w.e7l(0,8,10);O9V=Math[g99](this['\\x67\\x72\\u0061\\x62\\u0053\\x74\\u0061\\u0072\\x74\\u0058'] - J$Y,Z6S) + Math['\\x70\\x6f\\x77'](this['\\x67\\u0072\\u0061\\x62\\x53\\u0074\\u0061\\x72\\x74\\u0059'] - w3P,+\"2\");if(O9V < +\"36\"){return;}}this[T0t]=!!1;k06=function(N3W,y92){var Z$q,W3B,b3x,w2q,f_e,k7n;z7w.y6g();Z$q=803851421;W3B=-1953465584;b3x=-1227438013;w2q=797993645;f_e=-1995931359;if(z7w.H1(0,!({}),814712) === Z$q || z7w.H1(0,![],727330) === W3B || z7w.H1(\"12\" >> 0,!\"\",223284) === b3x || z7w.L1(\"13\" * 1,!0,993415) === w2q || z7w.H1(14,!![],802213) === f_e){if(h7S[N2M] === 0){k7n=\"\\u0063\";k7n+=\"\\u0068\\x61\\x72\\x74\";return N3W['\\x77\\x68\\x69\\x63\\u0068\\u0050\\x61\\u006e\\u0065\\x6c'](y92) || N3W[k7n]['\\u0070\\u0061\\u006e\\x65\\u006c'];}if(!N3W['\\x64\\u0072\\u0061\\u0077'][N2M]){N3W['\\u0064\\x72\\x61\\x77']=function(){var r9f,U_8,Q9g,P0H,P7n,B24,j9O;z7w.j1L();r9f=1631982361;z7w.b8R(3);U_8=-z7w.F9v(\"769373568\",1);Q9g=-1444459546;P0H=-176486111;P7n=-807341533;if(z7w.L1(0,!1,560077) === r9f || z7w.L1(\"0\" | 0,!\"1\",934268) === U_8 || z7w.L1(12,!!1,209332) === Q9g || z7w.H1(13,!\"\",752228) === P0H || z7w.H1(\"14\" * 1,!!\"1\",460210) === P7n){B24=\"\\u0063\\u0061\";B24+=\"\\u006e\\u0076\\x61\\u0073\";j9O=\"\\u0063\\u0068\\u0061\\u0072\";j9O+=\"\\u0074\";h7S['\\x63\\x6c\\x65\\x61\\u0072\\u0043\\u0061\\u006e\\x76\\x61\\x73'](this[j9O][B24],this);}};N3W['\\x64\\u0072\\x61\\u0077'][N2M]=!!({});}}};this['\\x63\\x75\\x72\\x72\\x65\\u006e\\u0074\\u0050\\u0061\\u006e\\u0065\\x6c']=k06(this,W4k);if(!this[q7H]){return;}J0J=this[B25]['\\x63\\x68\\x61\\x72\\x74'];if(J0J['\\u0064\\x61\\x74\\u0061\\x53\\x65\\x74']){Z0z=\"\\x63\\x72\\x6f\";Z0z+=\"\\u0073\\u0073\\x68\\x61\\x69\\x72\\u0054\\x69\\x63\\x6b\";N0F=\"\\x63\\x72\";N0F+=\"\\x6f\\u0073\\x73\\x68\\u0061\\u0069\\x72\\x54\\u0069\\x63\\x6b\";this['\\u0063\\x72\\u006f\\x73\\u0073\\x68\\x61\\x69\\u0072\\x54\\x69\\x63\\u006b']=this['\\u0074\\x69\\x63\\x6b\\u0046\\u0072\\u006f\\u006d\\u0050\\x69\\x78\\u0065\\x6c'](L5O,J0J);r_L=this['\\u0076\\u0061\\u006c\\u0075\\x65\\u0046\\x72\\u006f\\u006d\\u0050\\x69\\u0078\\x65\\u006c'](W4k,this['\\x63\\u0075\\u0072\\x72\\x65\\x6e\\u0074\\u0050\\x61\\x6e\\x65\\u006c']);this['\\x63\\x72\\u006f\\u0073\\x73\\x68\\u0061\\x69\\u0072\\x56\\x61\\u006c\\x75\\u0065']=this['\\u0061\\u0064\\u006a\\x75\\u0073\\u0074\\u0049\\x66\\u004e\\x65\\u0063\\u0065\\u0073\\u0073\\x61\\x72\\x79'](this['\\x63\\x75\\x72\\u0072\\u0065\\u006e\\x74\\u0050\\x61\\x6e\\u0065\\u006c'],this[N0F],r_L);I1R=this['\\x63\\u0075\\x72\\x72\\u0065\\u006e\\x74\\u0050\\x61\\u006e\\x65\\u006c']['\\x6e\\u0061\\x6d\\u0065'] == '\\x63\\u0068\\x61\\u0072\\x74'?this['\\x70\\u0072\\u0065\\x66\\u0065\\u0072\\x65\\u006e\\u0063\\u0065\\x73']['\\x68\\u006f\\x72\\x69\\x7a\\x6f\\x6e\\u0074\\u0061\\u006c\\x43\\u0072\\u006f\\x73\\x73\\x68\\x61\\x69\\x72\\x46\\x69\\u0065\\u006c\\x64']:this['\\u0063\\x75\\u0072\\u0072\\u0065\\x6e\\x74\\u0050\\u0061\\u006e\\x65\\x6c']['\\x68\\x6f\\u0072\\u0069\\u007a\\u006f\\x6e\\x74\\u0061\\u006c\\x43\\x72\\u006f\\x73\\x73\\u0068\\x61\\u0069\\x72\\x46\\u0069\\x65\\x6c\\x64'];if(I1R && this[Z0z] < J0J['\\x64\\x61\\u0074\\u0061\\x53\\u0065\\x74']['\\u006c\\u0065\\u006e\\x67\\x74\\u0068'] && this['\\u0063\\x72\\x6f\\x73\\u0073\\x68\\x61\\u0069\\x72\\x54\\u0069\\u0063\\u006b'] > -1){E$6=\"\\u0070\\u0069\\x78\\x65\\x6c\\x46\\u0072\";E$6+=\"\\u006f\\u006d\\u0050\\u0072\";E$6+=\"\\u0069\\x63\\u0065\";I5P=\"\\x63\";I5P+=\"\\u0072\\x6f\";I5P+=\"\\u0073\\u0073\\u0059\\u0041\\u0063\\u0074\\u0075\\u0061\\u006c\\u0050\\x6f\\x73\";r_L=J0J['\\x64\\x61\\u0074\\x61\\u0053\\x65\\u0074'][this['\\x63\\u0072\\u006f\\x73\\x73\\x68\\u0061\\x69\\u0072\\x54\\u0069\\u0063\\u006b']][I1R];this[I5P]=this[E$6](r_L,this['\\u0063\\u0075\\u0072\\u0072\\x65\\u006e\\u0074\\x50\\x61\\x6e\\x65\\u006c']);}}if(h7S['\\x43\\u0068\\u0061\\x72\\u0074\\u0045\\u006e\\x67\\x69\\u006e\\u0065']['\\u0063\\u0072\\x6f\\u0073\\x73\\x68\\x61\\x69\\u0072\\x58'] >= this['\\x6c\\x65\\x66\\u0074'] && h7S['\\u0043\\x68\\x61\\x72\\x74\\x45\\x6e\\x67\\u0069\\x6e\\x65']['\\x63\\x72\\u006f\\x73\\x73\\x68\\x61\\u0069\\x72\\x58'] <= this['\\u0072\\x69\\u0067\\x68\\u0074'] && h7S['\\x43\\u0068\\x61\\u0072\\x74\\x45\\x6e\\x67\\u0069\\u006e\\u0065']['\\u0063\\x72\\x6f\\x73\\x73\\u0068\\x61\\u0069\\u0072\\u0059'] >= this['\\x74\\x6f\\u0070'] && h7S[j$I]['\\x63\\u0072\\u006f\\u0073\\u0073\\x68\\u0061\\u0069\\u0072\\x59'] <= this['\\x62\\x6f\\x74\\u0074\\x6f\\u006d']){this['\\u0069\\x6e\\u0073\\u0069\\x64\\u0065\\x43\\u0068\\x61\\x72\\x74']=!\"\";}else {this['\\u0069\\x6e\\u0073\\x69\\x64\\u0065\\x43\\u0068\\x61\\u0072\\u0074']=!!\"\";}i2w=this['\\x78\\u0041\\x78\\u0069\\u0073\\u0041\\x73\\x46\\x6f\\x6f\\u0074\\x65\\x72'] === !\"\"?this[Z77]['\\u0063\\x61\\u006e\\u0076\\x61\\x73\\u0048\\x65\\u0069\\x67\\x68\\x74']:this['\\x63\\x68\\x61\\x72\\u0074']['\\x70\\u0061\\x6e\\u0065\\u006c'][O9F];this[C3w]=this['\\u0069\\x6e\\x73\\x69\\x64\\x65\\u0043\\u0068\\x61\\x72\\x74'] && this[Q7q] <= i2w && this[k5G] > i2w - this['\\x78\\u0061\\x78\\u0069\\x73\\u0048\\u0065\\x69\\x67\\x68\\x74'];this['\\u006f\\x76\\x65\\u0072\\u0059\\u0041\\x78\\x69\\x73']=(this['\\x63\\x78'] >= this[Z$M]['\\x72\\x69\\x67\\u0068\\u0074'] || this['\\u0063\\u0078'] <= this['\\u0063\\x75\\x72\\u0072\\x65\\u006e\\u0074\\x50\\x61\\u006e\\x65\\x6c']['\\u006c\\u0065\\u0066\\u0074']) && this[F1i];if(this['\\u006f\\u0076\\u0065\\u0072\\u0058\\x41\\u0078\\x69\\x73'] || this['\\x6f\\u0076\\u0065\\x72\\u0059\\x41\\x78\\u0069\\u0073'] || !this[C4C] && !this['\\u0067\\u0072\\u0061\\x62\\x62\\x69\\u006e\\x67\\x53\\u0063\\u0072\\u0065\\x65\\u006e']){m9$=\"\\x6f\\x76\\x65\";m9$+=\"\\x72\";m9$+=\"\\x59\\u0041\\u0078\\u0069\\x73\";this['\\u0075\\x6e\\x64\\x69\\u0073\\u0070\\u006c\\u0061\\u0079\\x43\\x72\\u006f\\x73\\x73\\u0068\\x61\\x69\\u0072\\x73']();if(!this['\\u006f\\x76\\x65\\x72\\u0058\\u0041\\x78\\u0069\\u0073'] && !this[m9$]){return;}}if(!this[v5t] && !h7S['\\u0043\\x68\\u0061\\u0072\\u0074\\x45\\x6e\\u0067\\x69\\x6e\\x65']['\\u0072\\u0065\\x73\\x69\\u007a\\u0069\\u006e\\u0067\\u0050\\x61\\u006e\\u0065\\u006c']){this['\\x75\\u006e\\x64\\u0069\\u0073\\u0070\\x6c\\x61\\x79\\u0043\\x72\\x6f\\x73\\x73\\x68\\u0061\\u0069\\x72\\x73']();return;}if(this['\\u0072\\u0065\\x70\\u006f\\u0073\\u0069\\x74\\u0069\\u006f\\u006e\\x69\\u006e\\u0067\\u0042\\x61\\x73\\u0065\\x6c\\u0069\\x6e\\u0065']){P1j=\"\\x73\\u0065\\x74\\u0042\\u0061\\x73\\u0065\\u006c\";P1j+=\"\\u0069\\u006e\\u0065\\u0055\\x73\\x65\\x72\";P1j+=\"\\x4c\\u0065\\u0076\\x65\";P1j+=\"\\x6c\";this[P1j]();return D7t(this);}if(this[M_m]){f3j=\"\\u0074\\u0069\\x63\\x6b\\u0046\\u0072\";f3j+=\"\\x6f\\u006d\\x50\\x69\\u0078\\x65\\x6c\";L9o=this['\\x72\\u0065\\u0070\\x6f\\x73\\x69\\u0074\\u0069\\x6f\\x6e\\u0069\\u006e\\x67\\u0041\\x6e\\u0063\\x68\\x6f\\u0072\\u0053\\x65\\u006c\\u0065\\x63\\u0074\\x6f\\x72']['\\u0068\\u006f\\x76\\x65\\u0072\\u0054\\x69\\x63\\x6b'];i1I=this[f3j](this['\\u0063\\u0078'],this['\\x63\\u0068\\u0061\\x72\\u0074']);if(i1I >= 0 && i1I < this['\\x63\\u0068\\x61\\u0072\\u0074']['\\u0064\\x61\\u0074\\u0061\\x53\\x65\\x74']['\\x6c\\u0065\\u006e\\x67\\u0074\\u0068'] && (!(L9o && L9o !== 0) || i1I !== L9o)){l7f=\"\\u0068\\x6f\\x76\\x65\\x72\";l7f+=\"\\x54\\x69\";l7f+=\"\\x63\\u006b\";a3J=\"\\x72\";a3J+=\"\\x65\\u0070\\x6f\\u0073\\u0069\\u0074\\x69\\x6f\\u006e\\x69\\u006e\\u0067\\u0041\\u006e\\x63\\x68\\x6f\\x72\\x53\\x65\\u006c\";a3J+=\"\\u0065\\x63\\u0074\\x6f\\u0072\";this[a3J][l7f]=i1I;this['\\x64\\x72\\x61\\u0077']();}return D7t(this);}if(this['\\u0067\\u0072\\x61\\x62\\u0062\\u0069\\u006e\\x67\\x53\\u0063\\x72\\x65\\x65\\x6e'] && !h7S['\\x43\\x68\\u0061\\u0072\\u0074\\x45\\u006e\\x67\\u0069\\u006e\\x65'][P7y] && !this['\\x63\\u0068\\u0061\\x72\\u0074']['\\u0064\\u0072\\x61\\u0067\\x67\\x69\\x6e\\u0067\\x43\\x6f\\u006e\\x74\\u0072\\u006f\\x6c\\u0073']){x_Y=\"\\u0061\\x63\\x74\";x_Y+=\"\\u0069\";x_Y+=\"\\u0076\\u0065\\u0044\";x_Y+=\"\\x72\\x61\\u0077\\u0069\\u006e\\x67\";A_O=\"\\x67\\x72\\u0061\\x62\";A_O+=\"\\u0053\\x74\\u0061\";A_O+=\"\\u0072\";A_O+=\"\\u0074\\u0059\\x41\\x78\\u0069\\x73\";m3F=\"\\x6c\\u0061\\x79\\x6f\";m3F+=\"\\x75\\u0074\";R1L=\"\\u0043\\x68\";R1L+=\"\\u0061\";R1L+=\"\\u0072\\u0074\\u0045\\x6e\\x67\\u0069\\x6e\\x65\";if(this['\\x68\\u0069\\x67\\u0068\\u006c\\u0069\\x67\\x68\\x74\\u0065\\x64\\x44\\u0072\\x61\\u0067\\x67\\x61\\x62\\u006c\\u0065']){this['\\u0064\\u0069\\u0073\\x70\\x6c\\u0061\\u0079\\x44\\u0072\\u0061\\x67\\u004f\\u004b'](!!1);this['\\u0064\\u0072\\x61\\x67\\x50\\x6c\\u006f\\u0074\\x4f\\x72\\x41\\x78\\x69\\x73'](L5O,W4k);return D7t(this);}if(this['\\x61\\x6e\\x79\\u0048\\u0069\\x67\\u0068\\u006c\\x69\\u0067\\x68\\u0074\\x65\\u0064']){X_s=\"\\x63\";X_s+=\"\\u0068\\x61\";X_s+=\"\\x72\\u0074\";V9p=\"\\x63\";V9p+=\"\\x6c\\x65\\x61\\x72\\x43\\u0061\\x6e\\x76\";V9p+=\"\\x61\\u0073\";h7S[V9p](this[X_s]['\\u0074\\x65\\x6d\\x70\\x43\\u0061\\x6e\\u0076\\x61\\x73'],this);this['\\u0061\\x6e\\x79\\x48\\u0069\\u0067\\x68\\u006c\\x69\\x67\\x68\\x74\\x65\\x64']=![];for(q30 in this['\\x6f\\x76\\u0065\\x72\\x6c\\u0061\\x79\\x73']){this['\\x6f\\u0076\\u0065\\x72\\u006c\\u0061\\x79\\u0073'][q30]['\\x68\\x69\\u0067\\u0068\\x6c\\u0069\\u0067\\u0068\\x74']=!!0;}for(q30 in J0J['\\x73\\x65\\x72\\u0069\\u0065\\x73']){J0J['\\x73\\x65\\u0072\\u0069\\x65\\x73'][q30]['\\u0068\\u0069\\x67\\x68\\u006c\\x69\\x67\\u0068\\x74']=!!\"\";}this['\\u0064\\x69\\u0073\\x70\\x6c\\u0061\\x79\\u0053\\x74\\x69\\u0063\\x6b\\x79']();}if(this['\\u0067\\u0072\\u0061\\x62\\u0053\\x74\\u0061\\u0072\\x74\\u0058'] == -1){m4l=\"\\u0073\\x63\\u0072\";m4l+=\"\\u006f\\u006c\\u006c\";Q9$=\"\\x67\\u0072\";Q9$+=\"\\x61\\u0062\\x53\\u0074\\u0061\\u0072\\x74\\u0053\\u0063\\x72\\x6f\\x6c\\x6c\\u0058\";w2J=\"\\u0043\\u0068\";w2J+=\"\\x61\\u0072\\x74\\x45\\x6e\\u0067\\u0069\\x6e\";w2J+=\"\\x65\";this['\\u0067\\x72\\x61\\u0062\\x53\\u0074\\u0061\\u0072\\x74\\u0058']=h7S[w2J]['\\u0063\\x72\\u006f\\x73\\x73\\x68\\u0061\\u0069\\x72\\u0058'];this[Q9$]=J0J[m4l];}if(this['\\u0067\\x72\\x61\\u0062\\u0053\\u0074\\x61\\x72\\u0074\\u0059'] == -1){P0D=\"\\u0073\";P0D+=\"\\x63\\x72\";P0D+=\"\\x6f\\x6c\";P0D+=\"\\u006c\";Z1x=\"\\x67\\u0072\\x61\\x62\\x53\\x74\";Z1x+=\"\\u0061\\x72\\u0074\\u0059\";this[Z1x]=h7S['\\x43\\x68\\x61\\x72\\u0074\\u0045\\u006e\\x67\\x69\\u006e\\u0065']['\\u0063\\x72\\u006f\\x73\\u0073\\x68\\u0061\\x69\\u0072\\x59'];this['\\x67\\u0072\\x61\\u0062\\u0053\\x74\\x61\\u0072\\u0074\\u0053\\u0063\\x72\\x6f\\x6c\\u006c\\u0059']=this['\\x63\\u0075\\u0072\\u0072\\u0065\\u006e\\x74\\u0050\\u0061\\x6e\\x65\\u006c']['\\u0079\\x41\\u0078\\u0069\\u0073'][P0D];}O3b=h7S['\\x43\\x68\\u0061\\u0072\\u0074\\x45\\u006e\\u0067\\u0069\\u006e\\u0065']['\\x63\\u0072\\u006f\\u0073\\x73\\u0068\\u0061\\u0069\\x72\\u0058'] - this['\\x67\\u0072\\x61\\x62\\u0053\\x74\\x61\\u0072\\u0074\\x58'];Z8F=h7S[R1L]['\\u0063\\x72\\x6f\\x73\\x73\\u0068\\x61\\x69\\x72\\u0059'] - this['\\x67\\u0072\\u0061\\x62\\u0053\\x74\\u0061\\u0072\\u0074\\u0059'];if(O3b === +\"0\" && Z8F === 0){return;}if(Math['\\u0061\\u0062\\x73'](O3b) + Math['\\u0061\\u0062\\u0073'](Z8F) > 5){this['\\u0067\\u0072\\x61\\u0062\\x4f\\u0076\\u0065\\u0072\\x72\\u0069\\x64\\x65\\u0043\\x6c\\u0069\\x63\\x6b']=!!({});}u3j=this[m3F]['\\x63\\x61\\x6e\\u0064\\x6c\\x65\\u0057\\x69\\x64\\u0074\\u0068'];if(this['\\x61\\u006c\\u006c\\u006f\\u0077\\x5a\\u006f\\u006f\\u006d'] && this['\\u0067\\u0072\\x61\\u0062\\u004d\\x6f\\x64\\x65'] != '\\x70\\x61\\x6e' && (this['\\u0067\\x72\\u0061\\x62\\u004d\\u006f\\u0064\\u0065']['\\x69\\u006e\\x64\\x65\\x78\\u004f\\x66']('\\x7a\\x6f\\x6f\\x6d') === 0 || this['\\u006f\\x76\\u0065\\u0072\\u0058\\x41\\x78\\u0069\\u0073'] || this[A_O])){R2p=\"\\x67\";R2p+=\"\\x72\\u0061\\x62\\u004d\\u006f\\u0064\\x65\";g9I=\"\\u007a\";g9I+=\"\\x6f\\x6f\\x6d\";g9I+=\"\\u002d\";g9I+=\"\\x78\";if(this['\\x67\\u0072\\u0061\\u0062\\x4d\\x6f\\x64\\x65'] === \"\"){U2Q=\"\\x7a\\u006f\";U2Q+=\"\\x6f\";U2Q+=\"\\x6d\\x2d\";U2Q+=\"\\x78\";if(this['\\x6f\\u0076\\u0065\\u0072\\u0058\\u0041\\u0078\\u0069\\u0073']){this['\\x67\\u0072\\u0061\\x62\\x4d\\x6f\\x64\\u0065']=U2Q;}else if(this['\\u0067\\u0072\\x61\\u0062\\u0053\\u0074\\u0061\\x72\\x74\\x59\\u0041\\x78\\x69\\x73']){this['\\u0067\\x72\\x61\\u0062\\u004d\\x6f\\x64\\u0065']='\\u007a\\x6f\\u006f\\x6d\\x2d\\u0079';}}if(this['\\x67\\x72\\x61\\x62\\u004d\\u006f\\x64\\x65'] == g9I){Z8F=0;}else if(this[R2p] == '\\x7a\\u006f\\u006f\\x6d\\u002d\\x79'){O3b=0;}if(O3b){T$8=\"\\x63\";T$8+=\"\\u0068\\u0061\\x72\\u0074\";n4J=\"\\u0063\\u0068\\u0061\\x72\";n4J+=\"\\u0074\";w86=\"\\x63\\u0072\\u006f\\u0073\";w86+=\"\\x73\";w86+=\"\\u0068\\u0061\";w86+=\"\\x69\\x72\\x58\";this['\\x67\\x72\\x61\\u0062\\x53\\x74\\x61\\u0072\\u0074\\u0058']=h7S['\\x43\\u0068\\x61\\x72\\u0074\\x45\\u006e\\u0067\\x69\\u006e\\u0065'][w86];u4r=u3j - O3b / this[n4J]['\\u006d\\u0061\\x78\\u0054\\x69\\u0063\\u006b\\x73'];this['\\u007a\\x6f\\u006f\\x6d\\x53\\x65\\x74'](u4r,this[T$8]);}if(this['\\x6c\\u0061\\x79\\u006f\\u0075\\u0074']['\\u0073\\u0065\\x74\\x53\\u0070\\u0061\\u006e']){O2U=\"\\u0073\";O2U+=\"\\u0065\\x74\\u0053\\x70\\u0061\\x6e\";E5e=\"\\u006c\\x61\";E5e+=\"\\x79\";E5e+=\"\\u006f\\u0075\";E5e+=\"\\u0074\";this[E5e][O2U]=null;this['\\u0063\\u0068\\u0061\\u006e\\x67\\u0065\\u004f\\u0063\\u0063\\u0075\\x72\\u0072\\x65\\x64']('\\u006c\\u0061\\u0079\\u006f\\x75\\u0074');}D$X=this['\\u0067\\x72\\u0061\\x62\\x53\\x74\\u0061\\x72\\x74\\u0059\\x41\\u0078\\x69\\x73'];if(D$X){H0G=\"\\x68\\x65\\x69\\x67\";H0G+=\"\\u0068\";H0G+=\"\\x74\";E9x=\"\\u0067\\x72\";E9x+=\"\\u0061\";E9x+=\"\\u0062\\u0053\\x74\\u0061\\u0072\\x74\\u005a\\x6f\\u006f\\u006d\";if(D$X['\\u0066\\u006c\\x69\\x70\\x70\\x65\\x64']){Z8F*=-1;}D$X['\\u007a\\x6f\\x6f\\x6d']=Math['\\x72\\u006f\\u0075\\x6e\\x64'](this[E9x] + Z8F);if(this['\\u0067\\x72\\u0061\\u0062\\u0053\\u0074\\x61\\x72\\x74\\u005a\\x6f\\u006f\\x6d'] < D$X[H0G]){g2Z=\"\\x7a\";g2Z+=\"\\u006f\";g2Z+=\"\\x6f\";g2Z+=\"\\u006d\";if(D$X[g2Z] >= D$X['\\x68\\x65\\u0069\\u0067\\x68\\u0074']){z7w.b8R(78);var g9E=z7w.F9v(18,27,8);D$X['\\x7a\\u006f\\x6f\\u006d']=D$X['\\x68\\x65\\u0069\\x67\\x68\\u0074'] - g9E;}}else {if(D$X['\\u007a\\x6f\\u006f\\u006d'] <= D$X['\\u0068\\u0065\\x69\\u0067\\x68\\u0074']){z7w.G4m(16);var v2C=z7w.e7l(5,6,1);D$X['\\u007a\\x6f\\u006f\\x6d']=D$X['\\x68\\x65\\u0069\\x67\\x68\\u0074'] + v2C;}}}}else if(!this['\\x6f\\u0076\\u0065\\x72\\u0059\\x41\\u0078\\u0069\\u0073']){M_D=\"\\u0061\\u006c\\u006c\\u006f\\x77\\u0053\";M_D+=\"\\x63\\x72\\x6f\\u006c\\x6c\";I9l=\"\\u0064\\x69\";I9l+=\"\\u0073\\u0070\";I9l+=\"\\u0061\\x74\\u0063\";I9l+=\"\\u0068\";this[I9l]('\\x6d\\u006f\\u0076\\x65',{stx:this,panel:this['\\u0063\\u0075\\u0072\\u0072\\u0065\\u006e\\x74\\u0050\\x61\\u006e\\u0065\\x6c'],x:this['\\u0063\\u0078'],y:this['\\u0063\\x79'],grab:!![]});if(this[M_D]){j54=\"\\u0063\";j54+=\"\\u0079\";J7$=\"\\u0067\\u0072\\u0061\\u0062\\x53\\u0074\";J7$+=\"\\u0061\";J7$+=\"\\u0072\\x74\\x50\\u0061\\x6e\";J7$+=\"\\u0065\\x6c\";o2T=\"\\u0063\\x75\\x72\";o2T+=\"\\u0072\\x65\\u006e\\u0074\\u0050\\x61\\x6e\\x65\";o2T+=\"\\u006c\";g_M=\"\\x6d\\u0061\\x78\\u0054\\x69\\u0063\\u006b\";g_M+=\"\\u0073\";g_F=\"\\u006c\\x69\\u006e\\x65\\u0054\\x72\\x61\\x76\\u0065\";g_F+=\"\\u006c\\x53\\u0070\\x61\\u0063\\u0069\\x6e\";g_F+=\"\\x67\";h1$=\"\\u0070\";h1$+=\"\\x61\";h1$+=\"\\x6e\";C5K=\"\\u0067\\x72\";C5K+=\"\\x61\\x62\\u0053\\u0074\\u0061\\u0072\\u0074\";C5K+=\"\\u004d\\x69\\x63\\u0072\\x6f\\u0070\\u0069\\x78\\u0065\\x6c\\u0073\";if(Math['\\u0061\\x62\\x73'](Z8F) < this['\\x79\\u0054\\x6f\\x6c\\x65\\x72\\x61\\x6e\\x63\\u0065']){j2W=\"\\u0079\\x54\\u006f\";j2W+=\"\\x6c\\x65\\u0072\\u0061\\u006e\\x63\\u0065\\x42\";j2W+=\"\\u0072\\u006f\\x6b\\u0065\";j2W+=\"\\u006e\";if(!this[j2W]){Z8F=0;if(O3b === 0){return;}}}else {d68=\"\\u0079\\x54\\u006f\\u006c\\u0065\\x72\\x61\\u006e\\x63\\u0065\";d68+=\"\\u0042\\u0072\\u006f\\x6b\\u0065\\x6e\";this[d68]=!!({});}if(!this[C5K]){this['\\x67\\u0072\\x61\\x62\\u0053\\x74\\u0061\\x72\\u0074\\u004d\\x69\\u0063\\u0072\\x6f\\u0070\\x69\\u0078\\u0065\\x6c\\u0073']=0;}this['\\x67\\u0072\\x61\\x62\\x4d\\u006f\\u0064\\u0065']=h1$;J0J['\\x73\\u0063\\u0072\\u006f\\u006c\\u006c']=this['\\u0067\\x72\\x61\\u0062\\x53\\x74\\u0061\\u0072\\x74\\u0053\\x63\\x72\\x6f\\u006c\\u006c\\x58'];z7w.G4m(4);var I$N=z7w.F9v(85,80);z7w.G4m(111);var o2X=z7w.e7l(3,19,7,7,35);this['\\x6d\\u0069\\u0063\\u0072\\x6f\\x70\\x69\\x78\\x65\\x6c\\x73']=this['\\x67\\x72\\x61\\u0062\\x53\\u0074\\x61\\u0072\\x74\\u004d\\u0069\\x63\\x72\\u006f\\u0070\\x69\\u0078\\x65\\x6c\\u0073'] + O3b * (this['\\x73\\x68\\x69\\x66\\u0074']?I$N:o2X);if(!this[g_F]){x13=\"\\x6d\\x69\\u0063\\x72\\u006f\\x70\\x69\\u0078\";x13+=\"\\u0065\";x13+=\"\\u006c\\x73\";s5d=\"\\u006d\\x69\";s5d+=\"\\u0063\\x72\\u006f\\u0070\\x69\\x78\";s5d+=\"\\x65\\x6c\\u0073\";while(this[s5d] > 0){G3l=\"\\x6d\\x69\";G3l+=\"\\u0063\\x72\\u006f\";G3l+=\"\\u0070\\x69\\x78\\u0065\\u006c\\u0073\";this[G3l]-=u3j;J0J['\\u0073\\x63\\x72\\x6f\\u006c\\u006c']++;}while(this[x13] < -u3j){S2W=\"\\u006d\\u0069\\x63\\x72\";S2W+=\"\\u006f\\x70\\x69\\u0078\\u0065\\u006c\\x73\";this[S2W]+=u3j;J0J['\\u0073\\u0063\\u0072\\x6f\\u006c\\u006c']--;}}if(J0J['\\u0073\\x63\\u0072\\u006f\\x6c\\u006c'] >= J0J[g_M]){this['\\u0070\\x72\\u0065\\x66\\u0065\\x72\\u0065\\x6e\\u0063\\u0065\\u0073']['\\x77\\u0068\\x69\\x74\\u0065\\x73\\u0070\\x61\\u0063\\u0065']=this['\\x69\\x6e\\x69\\x74\\u0069\\x61\\u006c\\x57\\u0068\\x69\\x74\\u0065\\x73\\x70\\u0061\\x63\\x65'];}else {O_u=\"\\x73\\u0063\";O_u+=\"\\u0072\\u006f\\u006c\";O_u+=\"\\u006c\";u6M=\"\\x77\\x68\\u0069\";u6M+=\"\\x74\\u0065\";u6M+=\"\\x73\";u6M+=\"\\x70\\u0061\\u0063\\x65\";this['\\u0070\\u0072\\u0065\\u0066\\x65\\u0072\\u0065\\x6e\\u0063\\x65\\x73'][u6M]=(J0J['\\u006d\\x61\\x78\\u0054\\x69\\u0063\\x6b\\x73'] - J0J[O_u]) * u3j;}if(this[o2T] == this[J7$]){D$X=this['\\u0063\\u0075\\u0072\\u0072\\x65\\u006e\\u0074\\x50\\u0061\\u006e\\u0065\\u006c']['\\x79\\u0041\\x78\\u0069\\u0073'];if(D$X['\\u0066\\x6c\\u0069\\u0070\\u0070\\u0065\\x64']){Z8F*=-1;}D$X['\\x73\\u0063\\u0072\\x6f\\u006c\\u006c']=this['\\u0067\\u0072\\u0061\\x62\\x53\\u0074\\x61\\x72\\u0074\\x53\\u0063\\u0072\\x6f\\x6c\\x6c\\u0059'] + Z8F;}this['\\x64\\x69\\x73\\x70\\x61\\u0074\\x63\\x68']('\\u0073\\u0063\\x72\\x6f\\u006c\\x6c',{stx:this,panel:this['\\u0063\\u0075\\u0072\\u0072\\x65\\u006e\\x74\\u0050\\x61\\u006e\\u0065\\x6c'],x:this['\\u0063\\x78'],y:this[j54]});}}i1r=function(m8W){var i2t,q6C,t4u,c__,k$E;i2t=-1944438762;q6C=1900245295;t4u=-2139698605;c__=-149543859;k$E=910759872;if(!(z7w.H1(0,!({}),129407) !== i2t && z7w.L1(0,!\"1\",646873) !== q6C && z7w.L1(12,!!1,482689) !== t4u && z7w.L1(13,!0,579568) !== c__ && z7w.L1(14,!!\"1\",815693) !== k$E)){return function(){var H80,q88,i3E,p9y,A_4,F$j;H80=-1294134368;z7w.b8R(34);q88=z7w.e7l(\"1272795663\",15);i3E=-17554150;z7w.b8R(3);p9y=z7w.F9v(\"1710782423\",1);A_4=-1484180092;if(!(z7w.H1(0,!!0,958719) !== H80 && z7w.H1(\"0\" << 0,!!0,344993) !== q88 && z7w.L1(12,!!({}),752727) !== i3E && z7w.L1(13,!![],\"665437\" - 0) !== p9y && z7w.H1(14,!0,349548) !== A_4)){F$j=\"\\x75\\x70\\u0064\\u0061\\u0074\\x65\\u0043\";F$j+=\"\\x68\";F$j+=\"\\x61\\x72\\x74\\u0041\\u0063\\x63\\x65\\x73\\x73\\x6f\\u0072\\x69\\u0065\\u0073\";m8W['\\x64\\u0072\\x61\\u0077']();m8W[F$j]();}};}};if(h7S['\\u0043\\u0068\\u0061\\u0072\\u0074\\x45\\x6e\\u0067\\x69\\u006e\\x65']['\\x75\\x73\\u0065\\x41\\u006e\\u0069\\x6d\\x61\\x74\\x69\\u006f\\u006e']){window['\\u0072\\u0065\\x71\\x75\\x65\\u0073\\x74\\x41\\u006e\\u0069\\u006d\\x61\\u0074\\u0069\\u006f\\x6e\\x46\\u0072\\u0061\\u006d\\u0065'](i1r(this));}else {this['\\u0064\\x72\\u0061\\u0077']();i$A=-1640906279;A1X=-+\"176647206\";I_y=2;for(var e6M=1;z7w.m1(e6M.toString(),e6M.toString().length,+\"70496\") !== i$A;e6M++){this['\\u0075\\x70\\u0064\\u0061\\x74\\u0065\\u0043\\x68\\u0061\\x72\\u0074\\x41\\u0063\\x63\\u0065\\u0073\\x73\\u006f\\u0072\\u0069\\u0065\\x73']();I_y+=2;}if(z7w.P6(I_y.toString(),I_y.toString().length,35176) !== A1X){this[\"\"]();}}if(this[x_Y]){u5V=\"\\u0074\";u5V+=\"\\u0065\\x6d\\u0070\\x43\\u0061\\u006e\";u5V+=\"\\x76\";u5V+=\"\\x61\\u0073\";y2B=\"\\u0063\";y2B+=\"\\x68\\u0061\\u0072\\u0074\";w3o=\"\\u0072\";w3o+=\"\\x65\";w3o+=\"\\u006e\\u0064\\x65\\x72\";h7S['\\u0063\\u006c\\x65\\u0061\\u0072\\u0043\\u0061\\u006e\\u0076\\u0061\\u0073'](this['\\x63\\u0068\\x61\\x72\\u0074']['\\u0074\\x65\\x6d\\u0070\\x43\\u0061\\u006e\\x76\\x61\\u0073'],this);this['\\x61\\u0063\\x74\\u0069\\x76\\x65\\x44\\x72\\u0061\\u0077\\x69\\u006e\\x67'][w3o](this[y2B][u5V]['\\x63\\u006f\\x6e\\x74\\x65\\x78\\x74']);this['\\x61\\u0063\\u0074\\u0069\\x76\\x65\\x44\\u0072\\x61\\x77\\x69\\u006e\\u0067']['\\x6d\\x65\\u0061\\u0073\\x75\\u0072\\u0065']();}this['\\u0075\\x6e\\u0064\\x69\\u0073\\u0070\\x6c\\x61\\x79\\u0043\\u0072\\u006f\\x73\\u0073\\u0068\\x61\\x69\\u0072\\u0073']();return;}this[O76]=\"\";if(this['\\u006f\\x76\\x65\\u0072\\x58\\x41\\x78\\u0069\\u0073'] || this['\\u006f\\u0076\\x65\\u0072\\x59\\u0041\\x78\\x69\\u0073']){c0j=\"\\u0074\\u0061\\u0070\";c0j+=\"\\x46\";c0j+=\"\\x6f\\u0072\\u0048\\u0069\\u0067\\x68\\u006c\\u0069\\u0067\\x68\\x74\\x69\\u006e\";c0j+=\"\\u0067\";this['\\x75\\x70\\x64\\u0061\\u0074\\u0065\\x43\\u0068\\x61\\u0072\\u0074\\u0041\\x63\\x63\\x65\\u0073\\u0073\\u006f\\x72\\u0069\\x65\\x73']();if(!this[c0j] || !this['\\x74\\u006f\\u0075\\x63\\u0068\\u0069\\u006e\\u0067'] || this['\\x61\\u006e\\u0079\\x48\\x69\\u0067\\x68\\x6c\\u0069\\u0067\\u0068\\u0074\\u0065\\u0064']){this['\\u0066\\x69\\u006e\\x64\\u0048\\x69\\u0067\\x68\\x6c\\u0069\\x67\\u0068\\u0074\\x73']();}return D7t(this);}if(this['\\u0063\\u006f\\u006e\\u0074\\x72\\x6f\\x6c\\x73']['\\x63\\x72\\x6f\\u0073\\u0073\\u0058']){this['\\x63\\x6f\\x6e\\x74\\u0072\\u006f\\x6c\\u0073']['\\u0063\\u0072\\u006f\\u0073\\u0073\\x58']['\\u0073\\x74\\x79\\u006c\\x65'][T6S]=this['\\x70\\x69\\u0078\\u0065\\u006c\\u0046\\x72\\x6f\\x6d\\x54\\u0069\\u0063\\x6b'](this['\\x63\\x72\\u006f\\x73\\x73\\x68\\x61\\x69\\u0072\\x54\\u0069\\u0063\\u006b'],J0J) - 0.5 + '\\x70\\x78';}if(this['\\u0063\\u006f\\x6e\\x74\\u0072\\u006f\\x6c\\x73']['\\u0063\\u0072\\x6f\\x73\\x73\\x59']){this['\\x63\\x6f\\u006e\\u0074\\x72\\u006f\\x6c\\u0073'][a8R]['\\u0073\\u0074\\u0079\\x6c\\u0065']['\\u0074\\x6f\\x70']=this['\\u0063\\u0072\\u006f\\u0073\\x73\\u0059\\x41\\u0063\\u0074\\x75\\u0061\\u006c\\u0050\\u006f\\x73'] + '\\u0070\\x78';}if(this['\\x69\\u006e\\x73\\x69\\x64\\x65\\x43\\u0068\\u0061\\x72\\u0074'] && !h7S['\\u0043\\x68\\u0061\\u0072\\u0074\\x45\\x6e\\u0067\\x69\\x6e\\x65'][k8U]){T0E=\"\\u0044\\u0072\\u0061\\u0077\";T0E+=\"\\x69\\x6e\\u0067\";O$Z=this['\\u0063\\x75\\u0072\\x72\\u0065\\u006e\\u0074\\u0056\\u0065\\u0063\\u0074\\x6f\\x72\\u0050\\x61\\u0072\\x61\\x6d\\u0065\\u0074\\x65\\x72\\x73']['\\x76\\x65\\u0063\\x74\\u006f\\u0072\\u0054\\u0079\\u0070\\x65'];if(this['\\u006c\\u0061\\u0079\\u006f\\u0075\\u0074']['\\u0073\\u0074\\x75\\x64\\u0069\\u0065\\u0073']){r2C=this['\\u006c\\x61\\x79\\x6f\\u0075\\u0074']['\\u0073\\u0074\\x75\\u0064\\x69\\u0065\\x73'][this['\\x63\\x75\\x72\\u0072\\x65\\u006e\\u0074\\u0050\\x61\\u006e\\x65\\x6c']['\\x6e\\u0061\\u006d\\x65']];if(r2C){m03=\"\\x6f\";m03+=\"\\u0076\\u0065\\x72\\x6c\";m03+=\"\\x61\\u0079\";m03+=\"\\u0073\";w61=\"\\x6e\\x61\";w61+=\"\\x6d\";w61+=\"\\x65\";q32=\"\\x64\\u0072\\u0061\\x67\\u0067\";q32+=\"\\x69\\u006e\";q32+=\"\\u0067\";if(!this['\\x70\\u0072\\x65\\x66\\u0065\\u0072\\u0065\\x6e\\u0063\\u0065\\x73'][q32] || !this['\\x70\\x72\\x65\\x66\\u0065\\x72\\u0065\\x6e\\x63\\x65\\u0073']['\\u0064\\u0072\\u0061\\x67\\u0067\\x69\\x6e\\u0067']['\\x73\\x74\\u0075\\x64\\x79']){delete this['\\x6f\\x76\\u0065\\x72\\x6c\\x61\\u0079\\u0073'][r2C[w61]];}if(O$Z){this[m03][r2C['\\u006e\\x61\\x6d\\u0065']]=r2C;}}}if(!h7S['\\u0044\\x72\\u0061\\u0077\\u0069\\u006e\\u0067'] || !O$Z || !h7S[T0E][O$Z] || !new h7S['\\u0044\\u0072\\x61\\u0077\\x69\\x6e\\u0067'][O$Z]()['\\x64\\u0072\\x61\\u0067\\u0054\\u006f\\u0044\\x72\\x61\\u0077']){X_2=\"\\x64\\x6f\\x44\\x69\\x73\\u0070\\x6c\\x61\\x79\\x43\";X_2+=\"\\x72\\x6f\\u0073\\x73\\u0068\\x61\\x69\\x72\\u0073\";this[X_2]();}this['\\x75\\u0070\\u0064\\x61\\u0074\\x65\\u0043\\u0068\\x61\\x72\\x74\\u0041\\u0063\\x63\\x65\\u0073\\u0073\\x6f\\u0072\\u0069\\u0065\\u0073']();}else {this['\\u0075\\u006e\\u0064\\u0069\\x73\\u0070\\x6c\\x61\\u0079\\u0043\\x72\\u006f\\x73\\u0073\\u0068\\u0061\\u0069\\u0072\\x73']();}if(this['\\u006d\\u0061\\x67\\x6e\\x65\\u0074\\u0069\\x7a\\u0065']){this['\\x6d\\u0061\\x67\\u006e\\x65\\u0074\\x69\\x7a\\x65']();}if(this['\\x72\\x65\\u0070\\x6f\\x73\\u0069\\u0074\\x69\\u006f\\u006e\\u0069\\x6e\\x67\\u0044\\x72\\x61\\x77\\u0069\\u006e\\x67']){Q2d=\"\\x72\\u0065\\u0070\\u006f\\u0073\";Q2d+=\"\\u0069\\u0074\";Q2d+=\"\\u0069\\x6f\\x6e\\u0069\\x6e\\x67\\u0044\\u0072\\u0061\\x77\";Q2d+=\"\\u0069\\x6e\\x67\";K79=\"\\x72\\u0065\\u0070\\x6f\\x73\\x69\\x74\\x69\\x6f\\u006e\";K79+=\"\\x44\\u0072\\u0061\\x77\";K79+=\"\\u0069\\u006e\";K79+=\"\\u0067\";this[K79](this[Q2d]);}else if(h7S['\\u0043\\x68\\x61\\x72\\u0074\\x45\\u006e\\u0067\\x69\\x6e\\x65'][S1h]){z_x=\"\\u0061\\x63\\x74\\u0069\\x76\\x65\\x44\";z_x+=\"\\x72\";z_x+=\"\\x61\\x77\\u0069\\x6e\\x67\";if(this[z_x]){y1f=\"\\x61\\x63\\x74\\x69\\x76\\x65\\x44\\u0072\";y1f+=\"\\x61\\x77\\u0069\";y1f+=\"\\u006e\";y1f+=\"\\u0067\";if(this['\\u006d\\u0061\\u0067\\x6e\\x65\\x74\\u0069\\x7a\\x65\\x64\\x50\\u0072\\u0069\\u0063\\u0065'] === null){p5F=\"\\u006d\";p5F+=\"\\x6f\\u0076\\x65\";U3Y=\"\\x74\\x65\\x6d\\x70\\x43\";U3Y+=\"\\u0061\\x6e\\u0076\\x61\\u0073\";l0e=\"\\u0063\\u006c\\x65\\u0061\\u0072\\x43\";l0e+=\"\\u0061\\u006e\\u0076\";l0e+=\"\\u0061\\x73\";w00=\"\\x67\\x65\\x74\\u0059\";w00+=\"\\u0041\\u0078\\u0069\\x73\\x42\\u0079\\x46\\x69\\x65\\u006c\\x64\";D3Y=\"\\u0043\\x68\\u0061\\u0072\";D3Y+=\"\\u0074\";D3Y+=\"\\x45\\x6e\\x67\";D3Y+=\"\\x69\\u006e\\u0065\";Q_5=\"\\x62\";Q_5+=\"\\u0061\";Q_5+=\"\\x63\\u006b\";Q_5+=\"\\x4f\\x75\\u0074\\x59\";M_a=\"\\u0076\\u0061\\x6c\\x75\";M_a+=\"\\u0065\\u0046\\x72\\x6f\\x6d\\u0050\\u0069\";M_a+=\"\\x78\";M_a+=\"\\u0065\\u006c\";E4A=\"\\u0061\\u0064\\u006a\";E4A+=\"\\u0075\\u0073\";E4A+=\"\\u0074\\x49\\u0066\\u004e\\x65\\u0063\\x65\\u0073\\x73\\x61\\u0072\\u0079\";C$f=\"\\x70\\x61\\u006e\\u0065\\x6c\";C$f+=\"\\x4e\\u0061\\u006d\\u0065\";X5C=this['\\u0070\\x61\\u006e\\u0065\\u006c\\x73'][this['\\u0061\\u0063\\u0074\\u0069\\u0076\\x65\\u0044\\u0072\\u0061\\x77\\u0069\\u006e\\x67'][C$f]];r_L=this[E4A](X5C,this['\\x63\\x72\\u006f\\u0073\\u0073\\u0068\\x61\\u0069\\u0072\\x54\\u0069\\x63\\u006b'],this['\\u0061\\x63\\x74\\u0069\\x76\\u0065\\u0044\\u0072\\x61\\u0077\\u0069\\u006e\\u0067'][M_a](this[Q_5](h7S[D3Y]['\\x63\\u0072\\u006f\\x73\\u0073\\x68\\u0061\\x69\\u0072\\x59']),X5C,this[w00](X5C,this['\\u0061\\u0063\\u0074\\x69\\u0076\\x65\\u0044\\u0072\\x61\\x77\\u0069\\u006e\\u0067']['\\u0066\\x69\\x65\\u006c\\u0064'])));h7S[l0e](this['\\u0063\\x68\\x61\\u0072\\u0074'][U3Y],this);this['\\u0061\\x63\\x74\\u0069\\u0076\\x65\\x44\\u0072\\u0061\\u0077\\u0069\\x6e\\x67'][p5F](this['\\u0063\\x68\\x61\\u0072\\u0074']['\\x74\\u0065\\u006d\\u0070\\u0043\\u0061\\u006e\\x76\\x61\\u0073']['\\u0063\\x6f\\x6e\\u0074\\x65\\u0078\\x74'],this['\\u0063\\x72\\x6f\\u0073\\u0073\\u0068\\u0061\\x69\\u0072\\x54\\u0069\\x63\\x6b'],r_L);}q2z=2046304524;n6e=56101392;n39=2;for(var l65=+\"1\";z7w.m1(l65.toString(),l65.toString().length,64402) !== q2z;l65++){f$b=\"\\x61\\u0063\\u0074\\u0069\\u0076\\u0065\\x44\\x72\\u0061\\u0077\\x69\\x6e\";f$b+=\"\\u0067\";o0B=\"\\u006d\\x65\";o0B+=\"\\u0061\\u0073\\u0075\\u0072\\x65\";if(this['\\x61\\u0063\\u0074\\u0069\\u0076\\u0065\\x44\\x72\\u0061\\u0077\\x69\\x6e\\u0067'][o0B]){this['\\x61\\u0063\\u0074\\u0069\\u0076\\u0065\\x44\\x72\\u0061\\u0077\\x69\\x6e\\u0067'][f$b]();}n39+=2;}if(z7w.P6(n39.toString(),n39.toString().length,10012) !== n6e){y1u=\"\\u006d\\x65\\u0061\";y1u+=\"\\u0073\";y1u+=\"\\u0075\\u0072\\x65\";if(this['\\x61\\u0063\\u0074\\u0069\\u0076\\u0065\\x44\\x72\\u0061\\u0077\\x69\\x6e\\u0067'][y1u]){this['\\x61\\u0063\\u0074\\u0069\\u0076\\u0065\\x44\\x72\\u0061\\u0077\\x69\\x6e\\u0067']['\\x61\\u0063\\u0074\\u0069\\u0076\\u0065\\x44\\x72\\u0061\\u0077\\x69\\x6e\\u0067']();}}if(this[y1f]['\\u006d\\x65\\u0061\\u0073\\u0075\\u0072\\x65']){this['\\x61\\u0063\\u0074\\u0069\\u0076\\u0065\\x44\\x72\\u0061\\u0077\\x69\\x6e\\u0067']['\\x6d\\u0065\\x61\\x73\\u0075\\u0072\\x65']();}}}else if(h7S['\\u0043\\u0068\\u0061\\u0072\\x74\\x45\\x6e\\x67\\u0069\\u006e\\u0065'][l$M]){Z2i=\"\\u0072\\x65\\u0073\\u0069\\x7a\\u0065\\x50\\x61\\u006e\\u0065\\u006c\";Z2i+=\"\\u0073\";this[Z2i]();}if(this['\\x69\\x6e\\u0073\\u0069\\u0064\\x65\\u0043\\u0068\\u0061\\x72\\x74']){H_5=\"\\u0063\";H_5+=\"\\u0078\";this['\\u0064\\x69\\u0073\\x70\\x61\\u0074\\x63\\x68']('\\u006d\\x6f\\x76\\x65',{stx:this,panel:this['\\u0063\\x75\\u0072\\u0072\\u0065\\x6e\\u0074\\x50\\x61\\u006e\\u0065\\u006c'],x:this[H_5],y:this['\\x63\\x79'],grab:!!0});if(!this['\\x74\\x61\\x70\\x46\\x6f\\u0072\\u0048\\u0069\\u0067\\x68\\x6c\\x69\\x67\\x68\\u0074\\u0069\\x6e\\u0067'] || !this['\\u0074\\u006f\\x75\\u0063\\u0068\\u0069\\u006e\\u0067'] || this['\\u0061\\x6e\\u0079\\u0048\\u0069\\x67\\u0068\\u006c\\x69\\x67\\u0068\\u0074\\x65\\u0064']){this['\\x66\\x69\\u006e\\u0064\\u0048\\u0069\\x67\\u0068\\x6c\\u0069\\x67\\x68\\x74\\u0073']();}}return D7t(this);}};z7w.y6g();h7S.ChartEngine.prototype.swipeStart=function(q0k){var T4j;if(this.swipe && this.swipe.interval){clearInterval(this.swipe.interval);}this.swipe.velocity=0;this.swipe.amplitude=0;this.swipe.frame=q0k.scroll;this.swipe.micropixels=this.micropixels;this.swipe.timestamp=Date.now();this.swipe.chart=q0k;this.swipe.end=!1;this.swipe.timeConstant=+\"325\";this.swipe.cb=null;T4j=this;requestAnimationFrame(function(){T4j.swipeSample();});};h7S.ChartEngine.prototype.swipeSample=function(){var S6e,U18,e41,E7I,Z_M,G3k,Q27,o5f,p$6;S6e=this.swipe;if(S6e.end){return;}U18=this;z7w.G4m(4);Q27=z7w.e7l(\"20\",0);e41=Date.now();E7I=e41 - S6e.timestamp;if(E7I < Q27){requestAnimationFrame(function(){U18.swipeSample();});return;}o5f=h7S.touchDevice?+\"0.4\":0.8;S6e.timestamp=e41;Z_M=(S6e.chart.scroll - S6e.frame) * this.layout.candleWidth + this.micropixels - S6e.micropixels;S6e.frame=S6e.chart.scroll;S6e.micropixels=this.micropixels;z7w.b8R(112);G3k=z7w.F9v(1,1000,E7I,Z_M);p$6=o5f * G3k + 0.2 * S6e.velocity;if(Math.abs(p$6) > Math.abs(S6e.velocity)){S6e.velocity=p$6;}if(Math.abs(Z_M) < 6){S6e.velocity=0;}requestAnimationFrame(function(){z7w.j1L();U18.swipeSample();});};h7S.ChartEngine.prototype.swipeRelease=function(){var e9U,Q9c;e9U=this.swipe;if(e9U.velocity > 3000){e9U.velocity=3000;}if(e9U.velocity < -3000){e9U.velocity=-3000;}if(e9U.velocity > \"10\" << 0 || e9U.velocity < -+\"10\"){z7w.G4m(113);var p8B=z7w.F9v(15,5,15,4);e9U.amplitude=\"0.8\" * p8B * e9U.velocity;e9U.scroll=e9U.chart.scroll;e9U.target=e9U.amplitude;e9U.timestamp=Date.now();Q9c=this;if(this.disableBackingStoreDuringTouch){this.disableBackingStore();}requestAnimationFrame(function(){Q9c.autoscroll();});}};h7S.ChartEngine.prototype.allowDragControls=function(){var t8j;t8j={down:(function(s2K){return function(P6w){s2K.modalBegin();s2K.chart.draggingControls={bottom:s2K.chart.chartControls.style.bottom};};})(this),move:(function(x4R){return function(P$x){var a9C,i3V,G6t,Z81;var {draggingControls:d3s, chartControls:Q9G, home:U9W}=x4R.chart;if(d3s){a9C=\"p\";a9C+=\"x\";var {style:l3i, offsetHeight:j8F}=Q9G;i3V=x4R.height - j8F;G6t=0;Z81=h7S.stripPX(d3s.bottom) - P$x.displacementY;Z81=Math.min(Math.max(Z81,G6t),i3V);z7w.G4m(0);l3i.bottom=z7w.F9v(Z81,a9C);U9W.style.bottom=l3i.bottom;}};})(this),up:(function(y$3){return function(N4U){y$3.chart.draggingControls=null;y$3.modalEnd();};})(this)};if(this.chart.chartControls){h7S.safeDrag(this.chart.chartControls,t8j);}if(this.chart.home){h7S.safeDrag(this.chart.home,t8j);}};h7S.ChartEngine.prototype.dragPlotOrAxis=function(p9o,K7C){var a$x,Z1i,C4l,n2R,a$9,J8O,U$Z,g8E,r7O,g1Y,f1q,x1L,s61,w24,G81,A9l,R2h,W0A,E1j,x5e,g8Q,K$R,S_0,D$w,y6c,e4X,D69,w_u,k1p,c2Q,r3H,D9r,R$s,R_B,a4H,R_5,W7J,d5B,f3m,K4q,O7z,C0L,g8a,I$1,E1$,S9D,T3Z,C21,i12,a_7,d2X,Y8G,f5A,T_M,P$z,z1r,n5I,L6w,t4X,X7l,x4s,z45,i7N,a7f,s3$,i2n;a$x=\"n\";a$x+=\"o\";a$x+=\"n\";a$x+=\"e\";Z1i=this;if(!N4n.call(this) && !this.grabbingScreen){return;}C4l=null;n2R=this.whichPanel(K7C);a$9=this.highlightedDraggable;J8O=0;if(!n2R){return;}if(a$9.undraggable && a$9.undraggable(this)){return;}if(this.xAxisAsFooter && n2R == Object.values(this.panels).pop()){J8O=this.xaxisHeight;if(C4l){C4l+=J8O;}}U$Z=Math.min(20,(n2R.height - J8O) / 3);z7w.G4m(1);g8E=Math.min(z7w.F9v(\"10\",64),n2R.width / 3);r7O=this.whichYAxis(n2R,p9o,K7C);z7w.b8R(4);g1Y=this.whichYAxis(n2R,z7w.e7l(p9o,g8E),K7C);z7w.b8R(0);f1q=this.whichYAxis(n2R,z7w.e7l(p9o,g8E),K7C);z7w.G4m(4);x1L=this.whichPanel(z7w.e7l(K7C,U$Z));z7w.b8R(14);s61=this.whichPanel(z7w.F9v(K7C,J8O,U$Z));w24=!({});G81=!!0;A9l=![];if(h7S.Renderer){w24=a$9 instanceof h7S.Renderer;}if(h7S.Studies){G81=a$9 instanceof h7S.Studies.StudyDescriptor;}A9l=a$9 instanceof h7S.ChartEngine.YAxis;R2h=function(A1T){var K5o,o3O;if(!A9l){K5o=\"l\";K5o+=\"e\";K5o+=\"f\";K5o+=\"t\";o3O=\"ri\";o3O+=\"g\";o3O+=\"ht\";if(A1T == o3O){z7w.b8R(114);var t_y=z7w.F9v(7,29,18,12);return n2R.right - n2R.width / t_y;}if(A1T == K5o){z7w.G4m(61);var N_r=z7w.F9v(20,12,17,19);return n2R.left + n2R.width / N_r;}}z7w.b8R(111);var B1L=z7w.F9v(7,0,11,3,19);return (n2R.left + n2R.right) / B1L;};if(!A9l && !r7O){W0A=\"le\";W0A+=\"ft\";if(p9o < R2h(W0A)){g1Y=this.whichYAxis(n2R,n2R.left - 1,K7C);}else if(p9o > R2h(\"right\")){f1q=this.whichYAxis(n2R,n2R.right + 1,K7C);}}E1j=[];if(a$9.getDependents){E1j=a$9.getDependents(this,!![]);}x5e=a$9.panel;g8Q=a$9.getYAxis(this);if(w24){x5e=a$9.params.panel;}else if(A9l){x5e=this.grabStartPanel.name;}K$R=this.panels[x5e];for(S_0 in this.panels){if(this.panels[S_0].soloing){D$w=!!\"1\";}}y6c=g8Q.isShared(this);e4X=!r7O && !A9l && !D$w && (K$R !== n2R && K$R != x1L && K$R != s61 || !this.checkForEmptyPanel(K$R,!![],[a$9].concat(E1j)));D69=x5e == n2R.name && g8Q !== r7O && g8Q !== f1q && g8Q !== g1Y || y6c;z7w.y6g();if(e4X && (!x1L || n2R !== x1L)){c2Q=\"drop\";c2Q+=\"zone\";n2R.subholder.classList.add(c2Q);n2R.subholder.classList.add(\"top\");s61=n2R;}else if(e4X && (!s61 || n2R !== s61)){n2R.subholder.classList.add(\"dropzone\");n2R.subholder.classList.add(\"bottom\");}else if(n2R !== K$R){if(!A9l && !n2R.noDrag){r3H=\"d\";r3H+=\"ropzo\";r3H+=\"n\";r3H+=\"e\";n2R.subholder.classList.add(r3H);n2R.subholder.classList.add(\"all\");w_u=n2R.name;}}else if((!n2R.yaxisRHS.length || n2R.yaxisRHS.length == +\"1\" && n2R.yaxisRHS[0] == g8Q && g8Q.position == a$x) && !r7O && !f1q && p9o > R2h(\"right\")){n2R.subholder.classList.add(\"dropzone\");n2R.subholder.classList.add(\"right\");k1p=\"right\";}else if((!n2R.yaxisLHS.length || n2R.yaxisLHS.length == 1 && n2R.yaxisLHS[0] == g8Q && g8Q.position == \"none\") && !r7O && !g1Y && p9o < R2h(\"left\")){n2R.subholder.classList.add(\"dropzone\");n2R.subholder.classList.add(\"left\");k1p=\"left\";}else if(D69){if(A9l && p9o > n2R.left && p9o < n2R.right){z7w.G4m(11);var p08=z7w.e7l(0,12,13);D9r=n2R.yaxisLHS[n2R.yaxisLHS.length - p08];R$s=n2R.yaxisRHS[0];R_B=R2h();if(p9o < R_B && D9r != g8Q){g1Y=D9r;}else if(p9o > R_B && R$s != g8Q){f1q=R$s;}}if(!A9l || r7O !== g8Q){a4H=!A9l && y6c;if(f1q && (f1q !== g8Q || a4H) && (!r7O || r7O !== f1q)){f1q.dropzone=\"left\";k1p=f1q.position || this.chart.panel.yAxis.position || \"right\";}else if(g1Y && (g1Y !== g8Q || a4H) && (!r7O || r7O !== g1Y)){R_5=\"r\";R_5+=\"i\";R_5+=\"g\";R_5+=\"ht\";W7J=\"ri\";W7J+=\"gh\";W7J+=\"t\";g1Y.dropzone=W7J;k1p=g1Y.position || this.chart.panel.yAxis.position || R_5;}else if(r7O){if(!f1q && (r7O !== g8Q || a4H)){d5B=\"ri\";d5B+=\"ght\";r7O.dropzone=d5B;}else if(!g1Y && (r7O !== g8Q || a4H)){r7O.dropzone=\"left\";}else if(r7O !== g8Q){r7O.dropzone=\"all\";}if(r7O.dropzone){k1p=r7O.position || this.chart.panel.yAxis.position || \"right\";}}}}if(this.grabbingScreen || !n2R.subholder.classList.contains(\"dropzone\") && !k1p){this.draw();return;}K4q=-1;if(!w_u && !k1p && e4X){w_u=G81?a$9.inputs.id:a$9.params.name || h7S.uniqueID();for(var z05 in this.panels){K4q++;if(this.panels[z05] == s61)break;}if(!s61){K4q++;}if(this.panels[x5e].yAxis.name == w_u){x5e=this.electNewPanelOwner(x5e);}O7z=G81?a$9.inputs.display:null;if(x5e){this.createPanel(O7z || w_u,w_u,C4l,this.chart.name,new h7S.ChartEngine.YAxis({name:w_u}));}else {x5e=w_u;}if(G81){a$9.panel=x5e;}else {a$9.params.panel=x5e;}}if(w_u){if(G81){C0L=\"S\";C0L+=\"tudies.replaceStud\";C0L+=\"y\";if(!a$9.parameters){a$9.parameters={};}a$9.parameters.panelName=w_u;g8a=1949691472;I$1=552263753;E1$=2;for(var h0p=+\"1\";z7w.m1(h0p.toString(),h0p.toString().length,17492) !== g8a;h0p++){this.highlightedDraggable=h7S.getFn(\"\")(this,a$9.inputs.id,a$9.type,a$9.inputs,a$9.outputs,a$9.parameters,1,a$9.study);E1$+=2;}if(z7w.P6(E1$.toString(),E1$.toString().length,37091) !== I$1){this.highlightedDraggable=h7S.getFn(\"\")(this,a$9.inputs.id,a$9.type,a$9.inputs,a$9.outputs,a$9.parameters,\"9\" ^ 0,a$9.study);}this.highlightedDraggable=h7S.getFn(C0L)(this,a$9.inputs.id,a$9.type,a$9.inputs,a$9.outputs,a$9.parameters,null,a$9.study);}else if(w24){for(var S6W in a$9.seriesParams){S9D=a$9.seriesParams[S6W];T3Z=null;if(a$9.params.yAxis){if(a$9.params.yAxis !== this.chart.panel.yAxis){T3Z=a$9.params.yAxis;T3Z.name=a$9.params.name;}}this.modifySeries(S9D.id,{panel:w_u,yAxis:T3Z});}}if(K4q > -1){C21={};z7w.G4m(34);i12=z7w.e7l(\"0\",0);for(S_0 in this.panels){if(K4q == i12++){C21[w_u]=this.panels[w_u];}if(S_0 == w_u)continue;C21[S_0]=this.panels[S_0];}if(!C21[w_u]){C21[w_u]=this.panels[w_u];}this.panels=C21;}this.checkForEmptyPanel(x5e);for(var s9Q=0;s9Q < E1j.length;s9Q++){if(E1j[s9Q].params){this.checkForEmptyPanel(E1j[s9Q].params.name);}else {this.checkForEmptyPanel(E1j[s9Q].name);}}this.adjustPanelPositions();}else if(k1p){a_7=function(p8V,F2F,P$T,p1A){var k1J,J5O,v$5,w9T;k1J=\"ren\";z7w.j1L();k1J+=\"de\";k1J+=\"r\";k1J+=\"er\";if(P$T == \"study\"){v$5=\"Stud\";v$5+=\"ies.replaceStudy\";if(!F2F.parameters){F2F.parameters={};}if(p1A){F2F.parameters.yaxisDisplayValue=p1A.position;}else {delete F2F.parameters.yaxisDisplayValue;}J5O=h7S.getFn(v$5)(p8V,F2F.inputs.id,F2F.type,F2F.inputs,F2F.outputs,F2F.parameters,F2F.panel,F2F.study);}if(P$T == k1J){for(var u77 in F2F.seriesParams){w9T=F2F.seriesParams[u77];J5O=p8V.modifySeries(w9T.id,{panel:w_u,yAxis:p1A});}}return J5O;};d2X=1581753624;Y8G=-88105961;f5A=2;for(var p0P=1;z7w.P6(p0P.toString(),p0P.toString().length,34586) !== d2X;p0P++){T_M=r7O || r7O.dropzone !== \"\";z7w.G4m(3);f5A+=z7w.e7l(\"2\",1);}if(z7w.P6(f5A.toString(),f5A.toString().length,18698) !== Y8G){P$z=\"a\";P$z+=\"l\";P$z+=\"l\";T_M=r7O && r7O.dropzone == P$z;}if(!T_M){if(A9l){a$9.position=k1p;if(this.layout.studies){z1r=this.layout.studies[a$9.name];if(z1r){if(!z1r.parameters){z1r.parameters={};}z1r.parameters.yaxisDisplayValue=k1p;}}}else if(G81){this.highlightedDraggable=a_7(this,a$9,\"study\",{position:k1p});}else if(w24){a_7(this,a$9,\"renderer\",new h7S.ChartEngine.YAxis({name:a$9.params.name || h7S.uniqueID(),position:k1p}));}g8Q=this.highlightedDraggable.getYAxis(this);}if(!y6c || !T_M || A9l){n5I=g8Q;if(T_M && g8Q == this.chart.panel.yAxis){n5I=r7O;}for(f3m=0;f3m < n2R.yaxisLHS.length;f3m++){if(n2R.yaxisLHS[f3m] == n5I){n2R.yaxisLHS.splice(f3m,1);break;}}for(f3m=+\"0\";f3m < n2R.yaxisRHS.length;f3m++){if(n2R.yaxisRHS[f3m] == n5I){n2R.yaxisRHS.splice(f3m,1);break;}}}if(T_M){if(this.getYAxisByName(n2R,g8Q.name) == n2R.yAxis){this.electNewPanelOwner(n2R,r7O);}if(A9l){t4X=-478779664;X7l=-1840355152;x4s=2;for(var A$G=1;z7w.P6(A$G.toString(),A$G.toString().length,+\"75507\") !== t4X;A$G++){i7N=g8Q;a7f=r7O;x4s+=2;}if(z7w.P6(x4s.toString(),x4s.toString().length,25373) !== X7l){i7N=g8Q;a7f=r7O;}i7N=g8Q;a7f=r7O;if(g8Q == this.chart.panel.yAxis){i7N=r7O;a7f=g8Q;}for(z45 in i7N.studies){a_7(this,this.layout.studies[i7N.studies[z45]],\"study\",a7f === this.chart.panel.yAxis?null:{position:a7f.name});}for(z45 in i7N.renderers){a_7(this,this.chart.seriesRenderers[i7N.renderers[z45]],\"renderer\",a7f);}this.highlightedDraggable=a7f;}else if(G81){this.highlightedDraggable=a_7(this,a$9,\"study\",{position:r7O.name});}else if(w24){a_7(this,a$9,\"renderer\",r7O);}}else {if(g8Q.position == \"none\"){g8Q.width=h7S.ChartEngine.YAxis.prototype.width;}g8Q.position=k1p;L6w=k1p == \"left\"?n2R.yaxisLHS:n2R.yaxisRHS;for(f3m=\"0\" << 0;f3m < L6w.length;f3m++){if(L6w[f3m] !== g8Q){if(L6w[f3m].dropzone == \"left\"){L6w.splice(f3m,0,g8Q);}else if(L6w[f3m].dropzone == \"right\"){z7w.b8R(0);L6w.splice(z7w.F9v(f3m,1),z7w.F9v(\"0\",0,z7w.G4m(63)),g8Q);}else continue;}break;}if(f3m == L6w.length){L6w.push(g8Q);}}}for(var N52 in this.panels){s3$=this.panels[N52];i2n=s3$.yaxisLHS.concat(s3$.yaxisRHS);for(f3m=0;f3m < i2n.length;f3m++){i2n[f3m].height=s3$.yAxis.height;if(!i2n[f3m].lockScale){this.calculateYAxisMargins(i2n[f3m]);}}}this.displayDragOK();function N4n(){var F9w,x$6,g9l,V4W,M5T;function b5P(s1S){z7w.j1L();return function(T$y){z7w.j1L();if(s1S.subholder.classList.contains(T$y)){s1S.subholder.classList.remove(T$y);F9w=!![];}};}z7w.j1L();F9w=!1;for(var f32 in Z1i.panels){x$6=\"bo\";x$6+=\"tt\";x$6+=\"om\";g9l=\"le\";g9l+=\"ft\";V4W=\"dro\";V4W+=\"pzo\";V4W+=\"ne\";[V4W,\"all\",g9l,\"right\",\"top\",x$6].forEach(b5P(Z1i.panels[f32]));for(M5T=0;M5T < Z1i.panels[f32].yaxisLHS.length;M5T++){if(Z1i.panels[f32].yaxisLHS[M5T].dropzone){F9w=!!\"1\";}Z1i.panels[f32].yaxisLHS[M5T].dropzone=null;}for(M5T=\"0\" >> 32;M5T < Z1i.panels[f32].yaxisRHS.length;M5T++){if(Z1i.panels[f32].yaxisRHS[M5T].dropzone){F9w=!0;}Z1i.panels[f32].yaxisRHS[M5T].dropzone=null;}}return F9w;}this.draw();this.calculateYAxisPositions();this.draw();this.findHighlights(null,!![]);this.savePanels();};L9I=!({});h7S.ChartEngine.prototype.findHighlights=h7S.ChartEngine.prototype.findHighlights || (function(I7a,V08){if(!L9I){console.error(\"movement feature requires activating interaction feature.\");}L9I=!!\"1\";});};t_=b5Y=>{var e5Q,d10;e5Q=\"un\";e5Q+=\"define\";e5Q+=\"d\";d10=typeof _CIQ !== e5Q?_CIQ:b5Y.CIQ;d10.NameValueStore=d10.NameValueStore || (function(){});d10.NameValueStore.prototype.toJSONIfNecessary=function(M0R){var R9y;if(M0R.constructor == String){return M0R;}k_Cdw.j1L();try{R9y=JSON.stringify(M0R);return R9y;}catch(w37){k_Cdw.G4m(0);console.log(k_Cdw.e7l(\"Cannot convert to JSON: \",M0R));return null;}};d10.NameValueStore.prototype.fromJSONIfNecessary=function(R5j){var K6G;k_Cdw.y6g();try{K6G=JSON.parse(R5j);return K6G;}catch(H4B){return R5j;}};d10.NameValueStore.prototype.get=function(L8r,i87){var R_c;R_c=d10.localStorage.getItem(L8r);i87(null,this.fromJSONIfNecessary(R_c));};d10.NameValueStore.prototype.set=function(h50,x95,O1i){d10.localStorageSetItem(h50,this.toJSONIfNecessary(x95));if(O1i){O1i(null);}};d10.NameValueStore.prototype.remove=function(v2_,j3n){d10.localStorage.removeItem(v2_);if(j3n){j3n(null);}};};l2=C_t=>{var Y4F;Y4F=typeof _CIQ !== \"undefined\"?_CIQ:C_t.CIQ;if(!Y4F.ChartEngine){Y4F.ChartEngine=function(){};}k1u.fetchInitialData=function(H7C,z4Q,I85,i_9,m0x){};k1u.fetchUpdateData=function(o1s,P_o,l0i,w0f){};k1u.fetchPaginationData=function(q31,w2H,I$6,C8Y,Z0b){};k1u.subscribe=function(s$Y){};k1u.unsubscribe=function(Y4i){};Y4F.QuoteFeed=Y4F.QuoteFeed || (function(){});Y4F.QuoteFeed.prototype.fetch=function(O1f,r5B){var K8G;k_Cdw.y6g();if(!this.v2QuoteFeed){K8G=\"You must implement CIQ.QuoteFeed.[yourfeednam\";K8G+=\"e].prototype.fetch()\";console.log(K8G);}};Y4F.QuoteFeed.prototype.announceError=function(s$6,t6o){if(s$6.suppressErrors || t6o.suppressAlert){return;}if(s$6.startDate){}else if(s$6.endDate){}else if(t6o.error){Y4F.alert(\"Error fetching quote:\" + t6o.error);}else {}};Y4F.QuoteFeed.prototype.multiFetch=function(U3h,d0w){if(U3h.length === 0){d0w([]);}k_Cdw.j1L();return U3h[0].stx.driver.multiFetch(U3h,d0w);};Y4F.QuoteFeed.Subscriptions=function(){k_Cdw.y6g();this.subscriptions=[];};Y4F.inheritsFrom(Y4F.QuoteFeed.Subscriptions,Y4F.QuoteFeed);Y4F.QuoteFeed.Subscriptions.prototype.checkSubscriptions=function(X4y){var d0D,r_v,v1I,L1s,Y1e,r9d,e$l,L9h,m2k,h1f;v1I=X4y.getSymbols({\"breakout-equations\":!!({})});L1s=this;v1I=v1I.filter(function(F3P){k_Cdw.j1L();var F5$;F5$=X4y.quoteDriver.getQuoteFeed(F3P);return F5$ && F5$.engine == L1s;});for(var B_N=\"0\" << 0;B_N < this.subscriptions.length;B_N++){this.subscriptions[B_N].match=!\"1\";}for(var H4C=+\"0\";H4C < v1I.length;H4C++){Y1e=\"w\";Y1e+=\"ee\";Y1e+=\"k\";r9d=\"m\";r9d+=\"on\";r9d+=\"t\";r9d+=\"h\";r_v=v1I[H4C];e$l=r_v.interval;if((e$l == r9d || e$l == Y1e) && !X4y.dontRoll){e$l=\"day\";}r_v.interval=e$l;r_v.period=1;r_v.match=!1;if(!isNaN(r_v.interval)){L9h=\"mi\";L9h+=\"nut\";L9h+=\"e\";r_v.period=r_v.interval;r_v.interval=r_v.timeUnit;if(!r_v.interval){r_v.interval=L9h;}}delete r_v.periodicity;delete r_v.timeUnit;delete r_v.setSpan;for(B_N=\"0\" >> 64;B_N < this.subscriptions.length;B_N++){d0D=this.subscriptions[B_N];if(d0D.symbol == r_v.symbol && d0D.period == r_v.period && d0D.interval == r_v.interval){r_v.match=!!({});d0D.match=!!\"1\";break;}else if(d0D.symbol != r_v.symbol){m2k=\"s\";m2k+=\"ym\";m2k+=\"b\";m2k+=\"ol\";h1f=\"pe\";h1f+=\"ri\";h1f+=\"od\";if(r_v.reason != h1f){r_v.reason=m2k;}d0D.reason=\"symbol\";}else {r_v.reason=\"period\";d0D.reason=\"period\";}}}this.subscriptions=this.subscriptions.filter(function(v2V){if(!v2V.match){if(!v2V.stx){v2V.stx=X4y;}L1s.unsubscribe(v2V);}k_Cdw.y6g();return v2V.match;});v1I.forEach(function(z5n){if(!z5n.match){if(!z5n.stx){z5n.stx=X4y;}if(!z5n.reason){z5n.reason=\"initialize\";}if(z5n.symbol !== X4y.chart.symbol){z5n.series=!0;}L1s.subscribe(z5n);L1s.subscriptions.push(z5n);}});};Y4F.QuoteFeed.Subscriptions.prototype.fetch=function(l43,a7E){var X4J;X4J=this;this.fetchFromSource(l43,function(T9U){if(!T9U.error){X4J.checkSubscriptions(l43.stx);}a7E(T9U);});};Y4F.QuoteFeed.Subscriptions.prototype.subscribe=function(f$v){k_Cdw.j1L();console.log(\"subscribe\",f$v);};function k1u(){}Y4F.QuoteFeed.Subscriptions.prototype.unsubscribe=function(p$D){k_Cdw.y6g();console.log(\"unsubscribe\",p$D);};Y4F.QuoteFeed.Subscriptions.prototype.fetchFromSource=function(V3z,D0s){k_Cdw.j1L();console.log(\"Please provide implementation of fetchFromSource\");};Y4F.QuoteFeed.prototype.requiresImmediateRefresh=function(l5c){k_Cdw.j1L();return !!0;};Y4F.ChartEngine.prototype.attachQuoteFeed=function(E$g,L2H,t93){var A1N,Z$_;if(!L2H){L2H={};}if(typeof E$g.fetchInitialData === \"function\" || typeof E$g.fetchUpdateData === \"function\" || typeof E$g.fetchPaginationData === \"function\"){A1N=\"functio\";A1N+=\"n\";if(typeof E$g.fetchPaginationData !== \"function\" && typeof E$g.fetchUpdateData !== \"function\"){L2H.noLoadMore=!\"\";}E$g.v2QuoteFeed=!!\"1\";[\"multiFetch\",\"announceError\",\"requiresImmediateRefresh\"].forEach(function(g6s){k_Cdw.y6g();if(!E$g[g6s] && E$g[g6s] !== !({})){E$g[g6s]=Y4F.QuoteFeed.prototype[g6s];}});if(typeof E$g.subscribe === A1N){E$g.checkSubscriptions=Y4F.QuoteFeed.Subscriptions.prototype.checkSubscriptions;E$g.subscriptions=[];}}if(!L2H.maximumTicks){L2H.maximumTicks=E$g.maxTicks?E$g.maxTicks:20000;}if(!L2H.bufferSize || L2H.bufferSize < 0){L2H.bufferSize=0;}L2H.bufferSize=Math.round(L2H.bufferSize);E$g.intervalTimer=null;if(this.quoteDriver){if(!t93 && this.quoteDriver.hasUnfilteredQuoteFeed){this.detachQuoteFeed();}else {Z$_=this.quoteDriver.hasUnfilteredQuoteFeed && this.quoteDriver.quoteFeeds.pop();this.quoteDriver.quoteFeeds.push({engine:E$g,behavior:L2H,filter:t93});if(Z$_){this.quoteDriver.quoteFeeds.push(Z$_);}this.quoteDriver.updateChartLoop(null,L2H,E$g);}}if(!this.quoteDriver){this.quoteDriver=new Y4F.ChartEngine.Driver(this,E$g,L2H,t93);}if(!t93){this.quoteDriver.hasUnfilteredQuoteFeed=!!1;}};Y4F.ChartEngine.prototype.detachQuoteFeed=function(D$J){var Q4D;Q4D=this.quoteDriver;if(!Q4D){return;}for(var A0H=Q4D.quoteFeeds.length - 1;A0H >= 0;A0H--){if(!D$J || Q4D.quoteFeeds[A0H].engine == D$J){Q4D.die(Q4D.quoteFeeds[A0H]);Q4D.quoteFeeds.splice(A0H,1);}}if(!Q4D.quoteFeeds.length){Q4D=this.quoteDriver=null;}else if(D$J == Q4D.quoteFeed){Q4D.quoteFeed=Q4D.quoteFeeds[0].quoteFeed;Q4D.behavior=Q4D.quoteFeeds[+\"0\"].behavior;}};Y4F.ChartEngine.Driver=function(c1g,X2s,A2A,a4i){this.stx=c1g;if(!A2A){A2A={};}this.quoteFeeds=[{engine:X2s,behavior:A2A,filter:a4i}];this.id=Y4F.uniqueID(!\"\");this.behavior=A2A;this.quoteFeed=X2s;this.loadingNewChart=![];this.updatingChart=!!0;if(!a4i){this.hasUnfilteredQuoteFeed=!0;}this.updateChartLoop();};Y4F.ChartEngine.Driver.prototype.die=function(W$C){var b9A;for(var i_z=\"0\" | 0;i_z < this.quoteFeeds.length;i_z++){if(!W$C || this.quoteFeeds[i_z] == W$C){b9A=this.quoteFeeds[i_z];clearInterval(b9A.intervalTimer);b9A.intervalTimer=-1;}}};Y4F.ChartEngine.Driver.prototype.getQuoteFeed=function(J9C){var p5j;k_Cdw.j1L();if(!J9C.symbolObject){J9C.symbolObject={symbol:J9C.symbol};}for(var T7Q=0;T7Q < this.quoteFeeds.length;T7Q++){p5j=this.quoteFeeds[T7Q];if(p5j.behavior.generator != J9C.symbolObject.generator)continue;if(!p5j.filter || p5j.filter(J9C)){return p5j;}}return null;};Y4F.ChartEngine.Driver.prototype.multiFetch=function(K2N,K2V){var w2G,t9r,X4I;if(K2N.length === 0){K2V([]);}function D2f(W30,u9T,p5Q){return function(V6d){var R5m;u9T.results.push({dataCallback:V6d,params:W30});u9T.counter++;if(u9T.counter >= u9T.finished){R5m=u9T.results;u9T.results=[];p5Q(R5m);}};}k_Cdw.y6g();w2G={counter:0,finished:K2N.length,results:[]};for(var Q4a=+\"0\";Q4a < K2N.length;Q4a++){t9r=K2N[Q4a];if(t9r.stx.isEquationChart(t9r.symbol)){Y4F.fetchEquationChart(t9r,D2f(t9r,w2G,K2V));}else {X4I=this.getQuoteFeed(t9r);if(X4I){Y4F.ChartEngine.Driver.fetchData(Y4F.QuoteFeed.SERIES,X4I.engine,t9r,D2f(t9r,w2G,K2V));}}}};Y4F.ChartEngine.Driver.prototype.updateSubscriptions=function(){for(var J18=0;J18 < this.quoteFeeds.length;J18++){if(this.quoteFeeds[J18].checkSubscriptions){this.quoteFeeds[J18].checkSubscriptions(this.stx);}}};Y4F.ChartEngine.Driver.prototype.loadDependents=function(n0B,G6_,T3n,r_1){var A28,A$k,A$u,s3K,k75,x09,j0w,m_D,c3w,W8C,j2L,z6Z,Q7t,R8Y,O0H,z2C,Z4Y,g9H,K_L,s6B,P5q,G8X,z_4,q4z,b3I;A28=this;if(!r_1){A$k=0;A$u=[];s3K=[];k75=function(M7u){if(G6_ && ++A$k >= A28.quoteFeeds.length){G6_(null);}};x09=function(f4V){if(++A$k < A$u.length){return;}if(!s3K.length){k75(f4V);}s3K.forEach(function(o_t){k_Cdw.j1L();A28.loadDependents(n0B,k75,T3n,o_t.behavior);});};A28.quoteFeeds.forEach(function(h0I){k_Cdw.j1L();if(h0I.behavior.generator){s3K.push(h0I);}else {A$u.push(h0I);}});A$u.forEach(function(E0D){k_Cdw.y6g();A28.loadDependents(n0B,x09,T3n,E0D.behavior);});return;}m_D={};c3w=n0B.stx;W8C=n0B.chart;j2L=W8C.series;function v3d(q0O){return function(n7w){var J94,J$A,p$P,T5C,y7r,L5U,z4o,U12,K3f,y5s;k_Cdw.j1L();J94=null;for(var J4F=0;J4F < n7w.length;J4F++){J$A=n7w[J4F];p$P=J$A.dataCallback.error;if(!p$P && p$P !== 0){T5C=J$A.params.symbolObject;y7r=J$A.dataCallback;L5U=y7r.quotes;z4o=y7r.moreAvailable;U12=y7r.upToDate;K3f=[];if(c3w.getSeries){K3f=c3w.getSeries({symbolObject:T5C});}y5s=!\"1\";for(var B71=0;B71 < K3f.length;B71++){Q7t=K3f[B71];if(!q0O){if(!n0B.future){Q7t.moreAvailable=z4o === !({})?![]:z4o || L5U.length > (J$A.params.endDate?\"1\" | 1:0);}else {Q7t.upToDate=U12 === !!({})?!!1:U12 || L5U.length <= (J$A.params.startDate?1:0);if(c3w.isHistoricalModeSet && L5U.length < 2){Q7t.mostRecentForwardAttempt=new Date();}}Q7t.loading=![];}y5s=Q7t.parameters.fillGaps || y5s;}L5U=A28.cleanup(c3w,Q7t,L5U,T3n,n0B,y5s);c3w.updateChartData(L5U,W8C,{secondarySeries:T5C.symbol,noCreateDataSet:!![],noCleanupDates:!![],allowReplaceOHL:!!\"1\"});if(L5U && L5U.length && (!J94 || J94 > L5U[0].DT)){J94=L5U[0].DT;}}}if(n7w.length){c3w.createDataSet(null,null,{appending:n0B.originalState.update || n0B.future,appendToDate:J94});if(!n0B.nodraw){c3w.draw();}if(T3n == Y4F.QuoteFeed.INITIAL){A28.resetRefreshInterval(r_1.refreshInterval,r_1);}}if(G6_){G6_(null);}};}z6Z=c3w.masterData;O0H=[];z2C={};Z4Y=T3n == Y4F.QuoteFeed.UPDATE;k_Cdw.j1L();g9H=T3n == Y4F.QuoteFeed.PAGINATION;K_L=Y4F.shallowClone(n0B);for(j0w in j2L){Q7t=j2L[j0w];s6B=Q7t.parameters;if(!Z4Y){if(!n0B.future && Q7t.moreAvailable === !({}))continue;if(n0B.future && Q7t.upToDate === !!\"1\")continue;}if(Q7t.loading)continue;if(s6B.loadData === !({}))continue;if(Z4Y || g9H){if(!Q7t.endPoints || !Object.keys(Q7t.endPoints).length)continue;}if(s6B.data && !s6B.data.useDefaultQuoteFeed)continue;R8Y=s6B.symbolObject;if(!R8Y.symbol)continue;if(R8Y.generator != r_1.generator)continue;K_L.symbolObject=R8Y;K_L.symbol=R8Y.symbol;P5q=this.getQuoteFeed(K_L);if(r_1 != (P5q && P5q.behavior))continue;G8X=!!({});if(!Z4Y){Q7t.loading=!!({});}for(var Q0D=0;Q0D < O0H.length;Q0D++){if(Y4F.symbolEqual(O0H[Q0D],R8Y)){G8X=!1;}}if(G8X){O0H.push(R8Y);z2C[R8Y.symbol]=Q7t.endPoints;}}z_4=[];for(var D0R=0;D0R < O0H.length;D0R++){R8Y=O0H[D0R];q4z=Y4F.shallowClone(n0B.originalState);q4z.symbol=R8Y.symbol;q4z.symbolObject=R8Y;if(q4z.update || q4z.future){if(!q4z.endDate){q4z.endDate=n0B.endDate;}q4z.startDate=z2C[R8Y.symbol].end;}else {if(!q4z.startDate){q4z.startDate=n0B.startDate;}q4z.endDate=g9H && !n0B.future?z2C[R8Y.symbol].begin:n0B.endDate;q4z.ticks=n0B.ticks;}z_4.push(q4z);}if(!z_4.length && Z4Y){b3I={appending:n0B.appending || n0B.originalState.update};if(b3I.appending){b3I.appendToDate=n0B.startDate;}c3w.createDataSet(null,null,b3I);if(!n0B.nodraw){c3w.draw();}if(G6_){G6_(null);}return;}this.multiFetch(z_4,v3d(Z4Y));};Y4F.ChartEngine.Driver.prototype.cleanup=function(v0T,u2F,f2w,P$9,n20,F3C){var x$G,E5d,f8S,H87,G8_,a_Z,O3_;v0T.doCleanupDates(f2w,v0T.layout.interval);k_Cdw.j1L();if(!n20.missingBarsCreated && f2w && f2w.length && v0T.cleanupGaps && F3C !== !1){f8S=n20.chart;if(!u2F){E5d=f8S.defaultPlotField;}else {f8S=u2F;E5d=u2F.parameters.symbol || u2F.id;}if(P$9 == Y4F.QuoteFeed.PAGINATION && !n20.loadMoreReplace){if(f8S.endPoints.begin && f8S.endPoints.begin > f2w[f2w.length - 1].DT){H87=\"p\";H87+=\"o\";H87+=\"p\";G8_=v0T.getFirstLastDataRecord(v0T.masterData,E5d,![]);if(u2F){G8_=G8_[E5d];}f2w.push(G8_);x$G=H87;}}else if(P$9 == Y4F.QuoteFeed.UPDATE){if(f8S.endPoints.end && f8S.endPoints.end < f2w[0].DT){a_Z=\"s\";a_Z+=\"hi\";a_Z+=\"f\";a_Z+=\"t\";O3_=v0T.getFirstLastDataRecord(v0T.masterData,E5d,!!({}));if(u2F){O3_=O3_[E5d];}f2w.unshift(O3_);x$G=a_Z;}}f2w=v0T.doCleanupGaps(f2w,n20.chart,{cleanupGaps:F3C,noCleanupDates:!\"\"});if(x$G){f2w[x$G]();}}return f2w;};Y4F.ChartEngine.Driver.prototype.updateChart=function(g5A){var H8k,C$M,g5Q,X6p,R2K,r_U,O4J,C45,s4m;if(this.updatingChart){return;}if(this.loadingNewChart){return;}H8k=Object.keys(this.stx.charts).length;C$M=0;g5Q=this.stx;function J9e(S99,p4C,p7O,U4t){if(p4C.behavior.prefetchAction){p4C.behavior.prefetchAction(\"updateChart\");}k_Cdw.y6g();return function(b9n){var n$9,J1e,Y3E;C$M++;n$9=p4C.chart;J1e=n$9.masterData;if(p7O == n$9.symbol && X6p == g5Q.layout.interval && R2K == g5Q.layout.timeUnit && !g5Q.isHistoricalMode()){if(U4t === S99.getQuoteFeed(p4C) && !b9n.error){Y3E=b9n.quotes;Y3E=S99.cleanup(g5Q,null,Y3E,Y4F.QuoteFeed.UPDATE,p4C);g5Q.updateChartData(Y3E,n$9,{noCreateDataSet:!!({}),noCleanupDates:!!({})});n$9.attribution=b9n.attribution;}else if(U4t){U4t.engine.announceError(p4C.originalState,b9n);}}else {S99.updatingChart=!({});return;}if(C$M == H8k){S99.updatingChart=![];}if(p4C.behavior.callback){p4C.behavior.callback(p4C);}S99.loadDependents(p4C,null,Y4F.QuoteFeed.UPDATE,p4C.behavior);};}X6p=g5Q.layout.interval;R2K=g5Q.layout.timeUnit;for(var g4z in g5Q.charts){r_U=g5Q.charts[g4z];if(!r_U.symbol)continue;O4J=this.makeParams(r_U.symbol,r_U.symbolObject,r_U);C45=this.getQuoteFeed(O4J);if(r_U.masterData && r_U.masterData.length){O4J.startDate=r_U.endPoints.end;}O4J.update=!!1;O4J.originalState=Y4F.shallowClone(O4J);if(g5A && g5A != O4J.behavior){this.loadDependents(O4J,null,Y4F.QuoteFeed.UPDATE,g5A);continue;}this.updatingChart=!!({});s4m=J9e(this,O4J,r_U.symbol,C45);if(g5Q.isEquationChart(O4J.symbol)){Y4F.fetchEquationChart(O4J,s4m);}else if(C45){Y4F.ChartEngine.Driver.fetchData(Y4F.QuoteFeed.UPDATE,C45.engine,O4J,s4m);}}};Y4F.ChartEngine.Driver.prototype.updateChartLoop=function(z0F,I8N,y6w){var R5I,w7W;if(!I8N){I8N=this.behavior;}if(!y6w){this.quoteFeeds.forEach(function(O4G){if(O4G.behavior === I8N){y6w=O4G;}});if(!y6w){y6w=this.quoteFeed;}}if(y6w.intervalTimer === -1){return;}clearInterval(y6w.intervalTimer);y6w.intervalTimer=null;R5I=function(v9T,j1F){k_Cdw.j1L();return function(){if(j1F.noUpdate){return;}k_Cdw.j1L();v9T.updateChart(j1F);};};for(var M6$=0;M6$ < this.quoteFeeds.length;M6$++){w7W=this.quoteFeeds[M6$].behavior;if(I8N == w7W && !w7W.noUpdate){if(!z0F && z0F !== 0){z0F=w7W.refreshInterval;}if(z0F){y6w.intervalTimer=setInterval(R5I(this,w7W),z0F * 1000);}}}};Y4F.ChartEngine.Driver.prototype.resetRefreshInterval=function(S_f,K4w){(K4w || this.behavior).refreshInterval=S_f;this.updateChartLoop(null,K4w);};Y4F.ChartEngine.Driver.prototype.pause=function(I4D){this.paused={symbol:I4D,interval:this.behavior.refreshInterval};k_Cdw.y6g();this.resetRefreshInterval(0);};Y4F.ChartEngine.Driver.prototype.resume=function(){var {interval:K1H, symbol:t3N}=this.paused;if(Y4F.symbolEqual(t3N,this.stx.chart.symbol)){return;}this.resetRefreshInterval(K1H);this.paused=null;};Y4F.ChartEngine.Driver.prototype.loadAll=function(F$i,T7k){var Z6a,d54;k_Cdw.j1L();Z6a=this;function c9W(){k_Cdw.y6g();return function(p4F){var r9L;if(p4F){T7k(p4F);}else if(Z6a.stx.currentlyImporting || !F$i.moreAvailable && F$i.upToDate){T7k(null);}else if(++d54 > 20){r9L=\"moreAvailable and upToDate not\";r9L+=\" i\";r9L+=\"mplemented correctly in quotefeed\";console.warn(r9L);T7k();}else {F$i.loadingMore=!!\"\";Z6a.checkLoadMore(F$i,!!1,!![],c9W(),!!({}));}};}d54=0;c9W()();};Y4F.ChartEngine.Driver.prototype.checkLoadMore=function(O2S,u8b,r4R,j7L,v4w){var P6f=k_Cdw;var a3M,Z1a,r7W,s4y,S4J,U6m,D1m,d5r,M5u,S5g,m7E,k8s,u_h,a19,J4c,y4t,m5j,d8d,c_q,A1b,v43,G_4;a3M=this.stx;Z1a=this;if(O2S.loadingMore || this.loadingNewChart){O2S.initialScroll=O2S.scroll;if(j7L){j7L(null);}return;}r7W=a3M.isHistoricalMode();if(!r7W){a3M.isHistoricalModeSet=!1;}function U6b(w4E){P6f.j1L();if(Z1a.paused){return ![];}return !w4E.endPoints.end || O2S.scroll - O2S.maxTicks + 1 < S4J.bufferSize || a3M.tickFromDate(w4E.endPoints.end,O2S,null,!\"\") - D1m.length + O2S.scroll - O2S.maxTicks + (\"2\" ^ 0) < S4J.bufferSize;}s4y=this.makeParams(O2S.symbol,O2S.symbolObject,O2S);function a35(U8J){if(Z1a.paused){return !({});}return !U8J.endPoints.begin || D1m.length - O2S.scroll < S4J.bufferSize || D1m.length - O2S.scroll - a3M.tickFromDate(U8J.endPoints.begin,O2S) < S4J.bufferSize;}if(a3M.currentlyImporting){if(j7L){j7L(null);}return;}S4J=s4y.behavior;D1m=O2S.dataSet;function o10(P3k,J3D){if(S4J.prefetchAction){S4J.prefetchAction(\"checkLoadMore\");}return function(j0l){var m1I,k0b,w0V,c$j,H8V,S3M,u8w,w0I,r9j;m1I=P3k.stx;P6f.j1L();k0b=J3D.chart;if(J3D.symbol == k0b.symbol && m5j == m1I.layout.interval && d8d == m1I.layout.timeUnit){if(!J3D.loadMore){J3D.chart.loadingMore=![];}if(U6m === P3k.getQuoteFeed(J3D) && !j0l.error){if(!j0l.quotes){j0l.quotes=[];}w0V=j0l.quotes;c$j=k0b.masterData;w0V=P3k.cleanup(m1I,null,w0V,Y4F.QuoteFeed.PAGINATION,J3D);if(w0V.length && k0b.masterData && k0b.masterData.length){if(J3D.future){H8V=w0V[0];if(H8V.DT && H8V.DT == k0b.masterData[k0b.masterData.length - 1].DT){c$j.pop();}}else {P6f.G4m(114);var w2r=P6f.e7l(9,14,4,18);S3M=w0V[w0V.length - w2r];if(S3M.DT && +S3M.DT == +k0b.masterData[\"0\" - 0].DT){w0V.pop();}}}if(!J3D.future){if(j0l.moreAvailable){k0b.moreAvailable=!0;}else if(j0l.moreAvailable === ![] || !w0V.length){k0b.moreAvailable=!\"1\";}else {k0b.moreAvailable=!!\"1\";}}else {k0b.maximumForwardPagination=null;if(j0l.upToDate){k0b.upToDate=!![];}else if(j0l.upToDate === ![] || w0V.length > 1){k0b.upToDate=!({});}else if(!w0V.length || w0V.length === 1 && +J3D.startDate === +j0l.quotes[0].DT){if(J3D.fetchMaximumBars){k0b.upToDate=!![];}else {k0b.maximumForwardPagination=!!1;}}if(m1I.isHistoricalModeSet && w0V.length < 2){k0b.mostRecentForwardAttempt=new Date();}}P3k.tickMultiplier=w0V.length?2:P3k.tickMultiplier * 2;u8w=w0V[0]?w0V[\"0\" | 0].DT:J3D.startDate;w0I=w0V[0]?w0V[w0V.length - 1].DT:J3D.endDate;if(!k0b.endPoints.begin || k0b.endPoints.begin > u8w){k0b.endPoints.begin=u8w;}if(!k0b.endPoints.end || k0b.endPoints.end < w0I){k0b.endPoints.end=w0I;}k0b.loadingMore=!!\"\";if(J3D.loadMoreReplace){m1I.setMasterData(w0V,k0b,{noCleanupDates:!!({})});}else if(J3D.future){m1I.updateChartData(w0V,k0b,{noCreateDataSet:!!({}),noCleanupDates:!!\"1\"});}else {Y4F.addMemberToMasterdata({stx:m1I,chart:k0b,data:w0V,fields:[+\"9680\" <= 2424?(2131,6080) === 715.93?4.15e+3:\"J\":\"*\"],noCleanupDates:!0});}if(J3D.future){r9j={appending:!!\"1\",appendToDate:w0V[\"0\" >> 0] && w0V[0].DT};}m1I.createDataSet(undefined,undefined,r9j);if(!v4w){m1I.draw();}if(S4J.callback){S4J.callback(J3D);}P3k.loadDependents(J3D,j7L,Y4F.QuoteFeed.PAGINATION);}else {P3k.quoteFeed.announceError(J3D.originalState,j0l);J3D.chart.loadingMore=![];if(j7L){j7L(j0l.error);}}}else {return;}};}P6f.b8R(115);var L8Q=P6f.e7l(167,670,1,10);P6f.G4m(11);var H2M=P6f.F9v(1,15,19);M5u=L8Q * (S4J.forwardPaginationRetryInterval || H2M);S5g=![];m7E=![];if(O2S.dataSet.length){for(var p92 in O2S.series){k8s=O2S.series[p92];if(k8s.loading)continue;if(k8s.parameters.loadData === ![])continue;d5r=!k8s.mostRecentForwardAttempt || k8s.mostRecentForwardAttempt.getTime() + M5u < Date.now();if(k8s.moreAvailable !== ![] && a35(k8s)){S5g=!![];}if(d5r && !k8s.upToDate && U6b(k8s)){m7E=!!({});}}}d5r=!O2S.mostRecentForwardAttempt || O2S.mostRecentForwardAttempt.getTime() + M5u < Date.now();u_h=(a35(O2S) || u8b) && O2S.moreAvailable !== !1;a19=(U6b(O2S) || u8b) && !O2S.upToDate && d5r;J4c=u_h || S5g;y4t=(a3M.isHistoricalModeSet || !O2S.upToDate) && !J4c && (a19 || m7E);m5j=a3M.layout.interval;d8d=a3M.layout.timeUnit;c_q=!!\"\";A1b=S4J.findHeadOfData || O2S.masterData && O2S.masterData.length;if(!S4J.noLoadMore && A1b){if(y4t || !a3M.maxDataSetSize || O2S.dataSet.length < a3M.maxDataSetSize){if(J4c || y4t){O2S.initialScroll=O2S.scroll;O2S.loadingMore=!!\"1\";s4y=this.makeParams(O2S.symbol,O2S.symbolObject,O2S);s4y.pagination=!!1;s4y.future=y4t;if(O2S.masterData && O2S.masterData.length){if(y4t){s4y.startDate=O2S.endPoints.end;}else {s4y.endDate=O2S.endPoints.begin;}if(y4t && !s4y.startDate){v43=a3M.getFirstLastDataRecord(O2S.masterData,\"DT\",!![]);if(v43){s4y.startDate=v43.DT;}}else if(J4c && !s4y.endDate){v43=a3M.getFirstLastDataRecord(O2S.masterData,\"DT\");if(v43){s4y.endDate=v43.DT;}}}else {s4y.endDate=new Date();}s4y.originalState=Y4F.shallowClone(s4y);s4y.nodraw=v4w;if(!u_h && (S5g || !a19 && m7E)){this.loadingMore=!\"\";this.loadDependents(s4y,R5q,Y4F.QuoteFeed.PAGINATION);if(j7L){j7L(null);}return;}if(O2S.maximumForwardPagination || a3M.fetchMaximumBars[a3M.layout.aggregationType]){s4y.fetchMaximumBars=!!({});if(!a3M.maxMasterDataSize || S4J.maximumTicks < a3M.maxMasterDataSize){s4y.ticks=S4J.maximumTicks;}else {s4y.ticks=a3M.maxMasterDataSize;}}G_4=o10(this,s4y);if(a3M.isEquationChart(s4y.symbol)){Y4F.fetchEquationChart(s4y,G_4);}else {if(y4t){s4y.appending=!!1;}U6m=Z1a.getQuoteFeed(s4y);if(U6m){Y4F.ChartEngine.Driver.fetchData(Y4F.QuoteFeed.PAGINATION,U6m.engine,s4y,G_4);}}c_q=!![];}}}if(!c_q && j7L){j7L(null);}function R5q(F_y){O2S.loadingMore=!!0;if(j7L){j7L(F_y);}}};Y4F.ChartEngine.Driver.prototype.extendHistoricalData=function({from:d4$},U52 = ()=>{}){k_Cdw.y6g();var N0W,v$w;var {stx:Y3r}=this;var {chart:D68, layout:E5N}=Y3r;function Y7t(J7a,y8O){k_Cdw.j1L();return function({quotes:Q$h, moreAvailable:p7l, error:e2U}){if(y8O.symbol !== D68.symbol || x2N !== E5N.interval || R5e !== E5N.timeUnit){return;}D68.loadingMore=!!0;if(e2U){return U52(e2U);}Q$h=J7a.cleanup(Y3r,null,Q$h,Y4F.QuoteFeed.PAGINATION,y8O);if(typeof p7l === \"boolean\"){D68.moreAvailable=p7l;}else {D68.moreAvailable=!!Q$h.length;}D68.endPoints.begin=d4$;Y4F.addMemberToMasterdata({stx:Y3r,chart:D68,data:Q$h,fields:[+\"5500\" < 738.06?!!1:(6907,699.63) !== (1520,421.46)?\"*\":(\"M\",0x25c1)],noCleanupDates:!!\"1\"});Y3r.createDataSet();Y3r.draw();};}var {masterData:R2k, dataSet:X_T}=D68;var {interval:x2N, timeUnit:R5e}=E5N;N0W=this.makeParams(D68.symbol,D68.symbolObject,D68);v$w=this.getQuoteFeed(N0W);if(D68.loadingMore || this.loadingNewChart || Y3r.currentlyImporting || !R2k.length || !v$w || Y3r.maxDataSetSize && X_T.length > Y3r.maxDataSetSize){return U52(null);}D68.loadingMore=!!\"1\";N0W.originalState=Object.assign({},N0W);N0W.startDate=d4$;N0W.endDate=R2k[0].DT;Y4F.ChartEngine.Driver.fetchData(Y4F.QuoteFeed.PAGINATION,v$w.engine,N0W,Y7t(this,N0W));};Y4F.ChartEngine.Driver.prototype.barsToFetch=function(Q4H){var q3F,r6v,r5K;if(!Y4F.isValidNumber(this.tickMultiplier)){this.tickMultiplier=2;}q3F=this.stx.layout.interval;r6v=Q4H.stx.layout.periodicity;k_Cdw.y6g();if((q3F == \"month\" || q3F == \"week\") && !this.stx.dontRoll){r6v*=q3F == \"week\"?7:30;}r5K=Q4H.stx.chart.maxTicks * r6v;return r5K * this.tickMultiplier;};Y4F.ChartEngine.Driver.determineStartDate=function(h8v,A2f,m8a){return this.determineStartOrEndDate(h8v,A2f,m8a,!!({}));};Y4F.ChartEngine.Driver.determineStartOrEndDate=function(T63,S9S,i3$,v4I){var x9x;if(v4I){x9x=T63.startDate || S9S.previous(i3$);}else {x9x=T63.future?S9S.next(i3$):new Date();}return x9x;};Y4F.ChartEngine.Driver.prototype.makeParams=function(h_v,V_k,h_d){var R74,x3I,P4_,O1l,m7q,W61,x2x,x4$,k0w,S0t;R74=\"w\";R74+=\"e\";R74+=\"e\";R74+=\"k\";x3I=this.stx;k_Cdw.y6g();P4_=x3I.layout.interval;O1l=this.barsToFetch({stx:x3I});if((P4_ == \"month\" || P4_ == R74) && !x3I.dontRoll){m7q=\"d\";m7q+=\"a\";m7q+=\"y\";P4_=m7q;}W61=this.getQuoteFeed({interval:P4_,symbol:h_v,symbolObject:V_k});x2x=W61 && W61.behavior;x4$=Y4F.shallowClone(x2x) || ({});x4$.behavior=x2x;k0w=![];S0t=[];if(h_d.market && h_d.market.getSessionNames){S0t=h_d.market.getSessionNames();}if(x3I.extendedHours){if(x3I.extendedHours.filter){k0w=!![];}else {k0w=x3I.layout.extended;S0t=S0t.filter(function(h_a){return h_a.enabled || x3I.layout.marketSessions[h_a.name];});}}else {S0t=S0t.filter(function(x81){return x81.enabled;});}for(var F$r=0;F$r < S0t.length;F$r++){S0t[F$r]=S0t[F$r].name;}Y4F.extend(x4$,{stx:x3I,symbol:h_v,symbolObject:V_k,chart:h_d,interval:P4_,extended:k0w,period:+\"1\",ticks:O1l,additionalSessions:S0t,quoteDriverID:this.id},!!({}));if(!x4$.symbolObject){x4$.symbolObject={symbol:h_v};}if(!isNaN(x4$.interval)){x4$.period=parseInt(x4$.interval,10);x4$.interval=x3I.layout.timeUnit;if(!x4$.interval){x4$.interval=\"minute\";}}return x4$;};Y4F.ChartEngine.Driver.prototype.newChart=function(j74,D70){var R9x,f4A,s_n,y3y,o8U,V28,f$O,x7y,P$l;R9x=this.stx;f4A=j74.symbol;s_n=R9x.layout.interval;y3y=R9x.layout.timeUnit;function Q8B(p91,e2Z){var x0i;x0i=\"newCh\";x0i+=\"a\";x0i+=\"rt\";if(x7y.prefetchAction){x7y.prefetchAction(x0i);}return function(v0h){var a30,o4G,L10,h_j;a30=e2Z.chart;k_Cdw.y6g();o4G=v0h.quotes;L10=!({});if(f4A == a30.symbol && s_n == R9x.layout.interval && y3y == R9x.layout.timeUnit){p91.loadingNewChart=!!\"\";if(f$O === p91.getQuoteFeed(e2Z) && !v0h.error){o4G=p91.cleanup(R9x,null,o4G,Y4F.QuoteFeed.INITIAL,e2Z);R9x.setMasterData(o4G,a30,{noCleanupDates:!!({})});a30.endPoints={};a30.endPoints.begin=o4G[0]?o4G[0].DT:e2Z.startDate;a30.endPoints.end=o4G[0]?o4G[o4G.length - (\"1\" | 0)].DT:e2Z.endDate;if(!o4G){a30.moreAvailable=!({});a30.upToDate=!!({});}else {a30.moreAvailable=v0h.moreAvailable === !({})?!({}):!\"\";a30.upToDate=v0h.upToDate;}a30.attribution=v0h.attribution;if(j74.initializeChart){R9x.initializeChart();}R9x.createDataSet();L10=!!({});}else {f$O.engine.announceError(e2Z.originalState,v0h);}}else {if(D70){D70(\"orphaned\");}return;}for(var a0q in a30.series){a30.series[a0q].endPoints={};a30.series[a0q].moreAvailable=null;a30.series[a0q].upToDate=null;}h_j=a30.masterData;if(h_j && h_j.length){e2Z.startDate=h_j[0].DT;e2Z.endDate=h_j[h_j.length - 1].DT;}if(x7y.callback){x7y.callback(e2Z);}p91.loadDependents(e2Z,function(){if(L10 && !e2Z.nodraw){p91.stx.home();}if(D70){D70(v0h.error);}p91.stx.dispatch(\"newChart\",{stx:p91.stx,symbol:p91.stx.chart.symbol,symbolObject:p91.stx.chart.symbolObject,moreAvailable:p91.stx.chart.moreAvailable,upToDate:p91.stx.chart.upToDate,quoteDriver:p91});p91.resetRefreshInterval(x7y.refreshInterval,x7y);},Y4F.QuoteFeed.INITIAL);};}o8U=j74.chart;o8U.moreAvailable=null;o8U.upToDate=null;o8U.loadingMore=![];o8U.attribution=null;V28=this.makeParams(f4A,j74.symbolObject,o8U);Y4F.extend(V28,j74,!!\"1\");f$O=this.getQuoteFeed(V28);x7y=V28.behavior;if(R9x.fetchMaximumBars[R9x.layout.aggregationType] || j74.fetchMaximumBars){if(!R9x.maxMasterDataSize || x7y.maximumTicks < R9x.maxMasterDataSize){V28.ticks=x7y.maximumTicks;}else {V28.ticks=R9x.maxMasterDataSize;}V28.fetchMaximumBars=!!({});}this.loadingNewChart=!![];this.updatingChart=!1;V28.originalState=Y4F.shallowClone(V28);P$l=Q8B(this,V28);if(this.stx.isEquationChart(V28.symbol)){Y4F.fetchEquationChart(V28,P$l);}else if(f$O){Y4F.ChartEngine.Driver.fetchData(Y4F.QuoteFeed.INITIAL,f$O.engine,V28,P$l);}};Y4F.QuoteFeed.INITIAL=1;Y4F.QuoteFeed.UPDATE=2;Y4F.QuoteFeed.PAGINATION=3;Y4F.QuoteFeed.SERIES=4;Y4F.ChartEngine.Driver.fetchData=function(J73,K8k,p9U,y9I){var u3w;if(!p9U.symbol){return y9I({quotes:[]});}if(K8k.v2QuoteFeed){u3w=\"fu\";u3w+=\"nction\";if(typeof K8k.subscribe !== u3w){Y4F.ChartEngine.Driver.fetchDataInContext(J73,K8k,p9U,y9I);}else {Y4F.ChartEngine.Driver.fetchDataInContext(J73,K8k,p9U,(function(T_s){if(!T_s.error){this.checkSubscriptions(p9U.stx);}y9I(T_s);}).bind(K8k));}}else {p9U.stx.convertToDataZone(p9U.startDate);p9U.stx.convertToDataZone(p9U.endDate);K8k.fetch(p9U,y9I);}};Y4F.ChartEngine.Driver.fetchDataInContext=function(F_l,g3i,f4o,g4l){var D7V=k_Cdw;var E_i,M0B,o$7,P2i,D_F,n9o,e8M,X5a,r6Z,M9z,g8m,r3X,u7h,F2Y,R6Q;D_F=f4o.stx;if(!D_F.chart.market.newIterator){console.error(\"quoteFeed feature requires first activating market feature.\");return;}if(F_l === Y4F.QuoteFeed.SERIES){f4o.series=!!({});F_l=Y4F.QuoteFeed.INITIAL;n9o=1852736649;e8M=-1389578317;X5a=2;for(var B8d=1;D7V.m1(B8d.toString(),B8d.toString().length,+\"1213\") !== n9o;B8d++){if((f4o.endDate || ~f4o.startDate) && f4o.future){F_l=Y4F.QuoteFeed.PAGINATION;}else if(f4o.startDate || ~f4o.endDate){F_l=Y4F.QuoteFeed.UPDATE;}X5a+=2;}if(D7V.m1(X5a.toString(),X5a.toString().length,39940) !== e8M){if(f4o.endDate && !f4o.startDate || f4o.future){F_l=Y4F.QuoteFeed.PAGINATION;}else if(f4o.startDate && !f4o.endDate){F_l=Y4F.QuoteFeed.UPDATE;}}}r6Z=Math.min(f4o.ticks,f4o.maximumTicks);if(g3i.maxTicks){r6Z=Math.min(r6Z,g3i.maxTicks);}M9z=f4o.symbolObject.masterSymbol || f4o.symbol;switch(F_l){case Y4F.QuoteFeed.UPDATE:if(D_F.isHistoricalModeSet){D_F.quoteDriver.updatingChart=![];return;}if(f4o.startDate){g8m=f4o.startDate;}else {r3X=-+\"1043905859\";u7h=-1163943311;F2Y=2;for(var U4l=1;D7V.P6(U4l.toString(),U4l.toString().length,77888) !== r3X;U4l++){g8m=new Date();g8m.setHours(+\"0\",0,0,0);F2Y+=2;}if(D7V.m1(F2Y.toString(),F2Y.toString().length,+\"2419\") !== u7h){g8m=new Date();g8m.setHours(7,7,5,3);}}if(typeof g3i.fetchUpdateData === \"function\"){g3i.fetchUpdateData(M9z,D_F.convertToDataZone(g8m),f4o,g4l);}break;case Y4F.QuoteFeed.INITIAL:P2i=f4o.endDate || new Date();E_i={begin:P2i,interval:f4o.interval,periodicity:f4o.interval == \"tick\"?D_F.chart.xAxis.futureTicksInterval:f4o.period,outZone:D_F.dataZone};M0B=D_F.chart.market.newIterator(E_i);o$7=Y4F.ChartEngine.Driver.determineStartDate(f4o,M0B,r6Z);if(f4o.endDate){P2i=f4o.endDate;}if(typeof g3i.fetchInitialData === \"function\"){g3i.fetchInitialData(M9z,o$7,D_F.convertToDataZone(P2i),f4o,g4l);}break;case Y4F.QuoteFeed.PAGINATION:E_i={begin:f4o.endDate || f4o.startDate,interval:f4o.interval,periodicity:f4o.interval == \"tick\"?D_F.chart.xAxis.futureTicksInterval:f4o.period,outZone:D_F.dataZone};M0B=D_F.chart.market.newIterator(E_i);R6Q=Y4F.ChartEngine.Driver.determineStartOrEndDate(f4o,M0B,r6Z,!f4o.future);o$7=f4o.startDate || R6Q;P2i=f4o.endDate || R6Q;if(!f4o.startDate){f4o.stx.convertToDataZone(P2i);}else {f4o.stx.convertToDataZone(o$7);}if(typeof g3i.fetchPaginationData === \"function\"){if(D_F.maxMasterDataSize && D_F.maxMasterDataSize <= D_F.masterData.length){return;}g3i.fetchPaginationData(M9z,o$7,P2i,f4o,function(m3L){D7V.j1L();if(P2i >= Date.now()){D_F.isHistoricalModeSet=![];}if(g4l){g4l(m3L);}});}break;default:console.error(\"Illegal fetchData constant\");}};};a3=h6X=>{var U55,J9u;U55=\"undef\";U55+=\"ined\";J9u=typeof _CIQ !== U55?_CIQ:h6X.CIQ;J9u.ChartEngine.prototype.addSeries=function(m4m,b1v,O7N){var b2D,D2d,u_H,U0Y,D9a,I_L,m4O,T6T,b3o,h8a,q7I,X7Z,i9L,f_h,E$Y,x2X,Y3V,h6e;function N7Q(e90){return function(R3N){var z9N,B0k,d9L;z9N=\"symbolChang\";z9N+=\"e\";if(!R3N.error){B0k=R3N.quotes;d9L=b1v.fillGaps;if(!h8a.cleanupGaps){d9L=![];}B0k=h8a.doCleanupGaps(B0k,h8a.chart,{cleanupGaps:d9L});h8a.updateChartData(B0k,h8a.chart,{secondarySeries:u_H,noCreateDataSet:!!({}),noCleanupDates:!!({}),allowReplaceOHL:!![]});U0Y.loading=!({});U0Y.moreAvailable=R3N.moreAvailable;U0Y.upToDate=R3N.upToDate;x$F(h8a,U0Y);}if(b1v.action !== null && !m4O.length){h8a.dispatch(q7I?\"symbolImport\":z9N,{stx:h8a,symbol:e90.symbol,symbolObject:e90.symbolObject,action:b1v.action,id:U0Y.id,parameters:b1v});}k_Cdw.j1L();if(O7N){O7N.call(h8a,R3N.error,U0Y);}};}b2D=this.runPrepend(\"addSeries\",arguments);if(b2D){return b2D;}D2d=m4m?m4m:null;u_H=m4m;if(!m4m){m4m=J9u.uniqueID();}if(b1v && b1v.panel === !![]){b1v.panel=m4m;}function x$F(S6v,j4k){var G2w,C7D,u_L,R4u;k_Cdw.j1L();G2w=b1v.renderer || \"Lines\";C7D=b1v.name || m4m;if(b1v.yAxis && !(b1v.yAxis instanceof J9u.ChartEngine.YAxis) && !q7I){b1v.yAxis.name=C7D;}if(!b1v.renderer && !b1v.name && !b1v.color && !b1v.chartType){return;}u_L=S6v.getSeriesRenderer(C7D);if(!u_L){R4u={name:C7D,overChart:b1v.overChart !== !\"1\",useChartLegend:!0};if(b1v.chartType){u_L=J9u.Renderer.produce(b1v.chartType,J9u.extend({highlightable:b1v.highlightable,dependentOf:b1v.dependentOf,panel:b1v.panel,yAxis:b1v.yAxis,baseline:b1v.baseline},R4u));}else {J9u.ensureDefaults(b1v,R4u);u_L=new J9u.Renderer[G2w]({params:b1v});}if(!u_L){return;}S6v.setSeriesRenderer(u_L);}u_L.attachSeries(m4m,b1v);if(b1v.loadData !== ![]){u_L.ready();}S6v.layout.symbols=S6v.getSymbols({\"include-parameters\":!!\"1\",\"exclude-studies\":!![]});}U0Y={parameters:b1v?J9u.clone(b1v):{},yValueCache:[],display:D2d,id:m4m,loading:b1v?b1v.loadData !== !!\"\":!!({})};U0Y.parameters.yAxis=b1v && b1v.yAxis;b1v=U0Y.parameters;if(b1v.symbol){u_H=b1v.symbol;}if(b1v.isComparison){b1v.shareYAxis=!!({});}if(b1v.yAxis && !(b1v.yAxis instanceof J9u.ChartEngine.YAxis)){b1v.yAxis=new J9u.ChartEngine.YAxis(b1v.yAxis);}J9u.ensureDefaults(b1v,{chartName:this.chart.name,symbolObject:{symbol:u_H},panel:this.chart.panel.name,fillGaps:![],action:\"add-series\"});if((\"display\" in b1v)){U0Y.display=b1v.display;}D9a=this.charts[b1v.chartName];I_L=b1v.symbolObject;u_H=b1v.symbol=I_L.symbol;if(!U0Y.display){U0Y.display=u_H || b1v.field;}U0Y.endPoints={};if(!b1v.gapDisplayStyle && b1v.gapDisplayStyle !== !!0){b1v.gapDisplayStyle=b1v.gaps;}if(b1v.isComparison){if(b1v.gapDisplayStyle === undefined){b1v.gapDisplayStyle=\"transparent\";}}m4O=this.getSeries({symbolObject:I_L,chart:D9a,includeMaster:!!({})});T6T=b1v.panel;if(!this.panels[T6T]){b3o=b1v.yAxis || new J9u.ChartEngine.YAxis();b3o.name=m4m;this.createPanel(m4m,T6T,null,null,b3o);if(!this.preferences.dragging || !this.preferences.dragging.series){b1v.highlightable=!!\"\";}}else {if(!b1v.yAxis && !b1v.shareYAxis){b1v.yAxis=new J9u.ChartEngine.YAxis({name:m4m,position:\"none\"});}}D9a.series[m4m]=U0Y;h8a=this;q7I=this.currentlyImporting;if(b1v.isComparison && D9a.forcePercentComparison && b1v.panel == D9a.panel.name && (!b1v.yAxis || b1v.yAxis == D9a.yAxis)){this.setChartScale(\"percent\");}X7Z=D9a.masterData;if(!X7Z){X7Z=D9a.masterData=this.masterData=[];}i9L=X7Z.length;if(b1v.data && !b1v.data.useDefaultQuoteFeed){f_h={symbol:u_H,symbolObject:I_L,action:b1v.action};N7Q(f_h)({quotes:b1v.data});}else if(m4O.length){U0Y.endPoints=m4O[\"0\" | 0].endPoints;U0Y.loading=m4O[0].loading;x$F(this,U0Y);if(O7N){setTimeout(function(){k_Cdw.y6g();O7N.call(h8a,null,U0Y);},0);}}else if(this.quoteDriver && b1v.loadData !== !({})){E$Y=this.quoteDriver;x2X=E$Y.makeParams(u_H,I_L,D9a);if(i9L){x2X.startDate=X7Z[+\"0\"].DT;x2X.endDate=this.isHistoricalMode()?X7Z[X7Z.length - 1].DT:new Date();}if(x2X.stx.isEquationChart(x2X.symbol)){J9u.fetchEquationChart(x2X,N7Q(x2X));}else {Y3V=E$Y.getQuoteFeed(x2X);if(Y3V){J9u.ChartEngine.Driver.fetchData(4,Y3V.engine,x2X,N7Q(x2X));}}}else {h6e=\"symbolC\";h6e+=\"han\";h6e+=\"ge\";x$F(this,U0Y);if(b1v.action !== null && !m4O.length){h8a.dispatch(q7I?\"symbolImport\":h6e,{stx:h8a,symbol:u_H,symbolObject:I_L,action:b1v.action,id:U0Y.id,parameters:b1v});}if(O7N){O7N.call(this,null,U0Y);}}this.runAppend(\"addSeries\",arguments);return U0Y;};J9u.ChartEngine.prototype.getSeries=function(V1u){var z3l,F1w,G9B,I_g,e0S,S0G,o46,V86;z3l=V1u.chart?V1u.chart:this.chart;F1w=z3l.series;G9B=V1u.symbolObject;if(!G9B){G9B={symbol:V1u.symbol};}I_g=[];for(var S_E in F1w){e0S=F1w[S_E];if(J9u.symbolEqual(G9B,e0S.parameters.symbolObject)){I_g.push(e0S);}}k_Cdw.j1L();if(V1u.includeMaster){if(J9u.symbolEqual(G9B,z3l.symbolObject)){I_g.push({});}}S0G=-1463979520;o46=-1181819042;V86=2;for(var G6R=\"1\" >> 64;k_Cdw.P6(G6R.toString(),G6R.toString().length,22809) !== S0G;G6R++){return I_g;}if(k_Cdw.P6(V86.toString(),V86.toString().length,1004) !== o46){return I_g;}};J9u.ChartEngine.prototype.modifySeries=function(Y4w,l3D,Q$H){var n0N,Y$k,x0I,I_V,m48,h7v,S$3,z4R,w8O,O11,g$5,r0N,c_2,g57,v0s,q$Z,H5P;n0N=\"modifyS\";n0N+=\"eries\";Y$k=\"modifySe\";Y$k+=\"r\";Y$k+=\"ie\";Y$k+=\"s\";if(this.runPrepend(Y$k,arguments)){return;}if(!l3D){return;}if(typeof Y4w === \"string\"){m48=l3D.chartName?this.charts[l3D.chartName]:this.chart;I_V=Y4w;x0I=m48.series[I_V];}else {x0I=Y4w;I_V=x0I.id;m48=this.charts[x0I.parameters.chartName];}if(!x0I){return;}J9u.extend(x0I.parameters,l3D,!0);this.getRendererFromSeries(I_V).modifyRenderer(l3D);h7v=x0I.parameters;for(var t$D in m48.seriesRenderers){z4R=m48.seriesRenderers[t$D];w8O=z4R.params;O11=z4R.seriesParams;for(var J8j=\"0\" << 32;J8j < O11.length;++J8j){g$5=O11[J8j];r0N=this.panels[g$5.panel];c_2=r0N && r0N.yAxis.name;if(g$5.id === x0I.id){g57=\"per\";g57+=\"ce\";g57+=\"nt\";if(h7v.panel === !0){h7v.panel=h7v.dependentOf || h7v.name;}w8O.panel=h7v.panel;if(l3D.yAxis){if(!(l3D.yAxis instanceof J9u.ChartEngine.YAxis)){l3D.yAxis=new J9u.ChartEngine.YAxis(l3D.yAxis);}w8O.yAxis=l3D.yAxis;}if(h7v.panel != g$5.panel && w8O.name == c_2){this.electNewPanelOwner(g$5.panel);}else {v0s=this.getYAxisByName(h7v.panel,w8O.name);if(v0s && h7v.yAxis && v0s.name !== h7v.yAxis.name){v0s.name=this.electNewYAxisOwner(v0s);}}if(!h7v.field){h7v.field=null;}z4R.attachSeries(I_V,J9u.ensureDefaults(h7v,g$5));if(!h7v.field){h7v.field=h7v.subField;}delete h7v.subField;if(h7v.isComparison && m48.forcePercentComparison && h7v.panel == m48.panel.name && (!x0I.parameters.yAxis || h7v.yAxis.name == m48.yAxis.name)){this.setChartScale(g57);}S$3=z4R;break;}}}J9u.getFn(\"Drawing.updateSource\")(this,x0I.parameters.symbol || I_V,null,x0I.parameters.panel);this.runAppend(n0N,arguments);if(Q$H !== !!\"1\"){q$Z=S$3.getDependents(this);for(var s7P=0;s7P < q$Z.length;s7P++){this.modifySeries(q$Z[s7P].params.name,{panel:S$3.params.panel,yAxis:x0I.parameters.yAxis},!!({}));}H5P=m48.seriesRenderers[S$3.params.dependentOf];if(H5P){if(H5P.params.yAxis != x0I.parameters.yAxis || H5P.params.panel != S$3.params.panel){this.modifySeries(S$3.params.dependentOf,{panel:S$3.params.panel,yAxis:x0I.parameters.yAxis},!![]);}}}this.draw();return x0I;};J9u.ChartEngine.prototype.deleteSeries=function(d9N,R0N,D3l){var E4i,A5h,J1Z,g_d,A1w,X08,G04,i8A;E4i=\"obj\";E4i+=\"ect\";if(this.runPrepend(\"deleteSeries\",arguments)){return;}D3l=D3l?D3l:{};A5h=D3l.action?D3l.action:\"remove-series\";if(typeof d9N === E4i){J1Z=d9N.id;R0N=R0N || this.charts[d9N.parameters.chartName];}else {J1Z=d9N;R0N=R0N || this.chart;}g_d=R0N.series[J1Z];if(!g_d){return;}A1w=g_d.parameters.loadData;X08=g_d.parameters.symbolObject;delete R0N.series[J1Z];k_Cdw.j1L();this.layout.symbols=this.getSymbols({\"include-parameters\":!![],\"exclude-studies\":!![]});G04=this.getSeries({symbolObject:X08,includeMaster:!!({})});if(A1w !== !\"1\" && !G04.length){this.cleanMasterData(X08,R0N);}i8A=this.panels[g_d.parameters.panel];if(i8A){this.checkForEmptyPanel(i8A);}this.createDataSet();if(!G04.length){this.dispatch(this.currentlyImporting?\"symbolImport\":\"symbolChange\",{stx:this,symbol:X08.symbol,symbolObject:X08,id:J1Z,action:A5h});}if(this.quoteDriver){this.quoteDriver.updateSubscriptions();}this.runAppend(\"deleteSeries\",arguments);};J9u.ChartEngine.prototype.removeSeries=function(s0C,I5c){var h8w,N6I,Q0p,H6c,v7C,y7I,W2s,B3j,H57;h8w=\"ob\";h8w+=\"j\";h8w+=\"ec\";h8w+=\"t\";N6I=\"rem\";N6I+=\"oveSeries\";if(this.runPrepend(N6I,arguments)){return;}H6c=!1;if(typeof s0C === h8w){Q0p=s0C.id;I5c=I5c || this.charts[s0C.parameters.chartName];}else {Q0p=s0C;I5c=I5c || this.chart;}for(var B7D in I5c.seriesRenderers){v7C=I5c.seriesRenderers[B7D];y7I=this.panels[v7C.params.panel];W2s=y7I && y7I.yAxis.name;for(var S9m=v7C.seriesParams.length - 1;S9m >= +\"0\";S9m--){B3j=v7C.seriesParams[S9m];if(B3j.id === Q0p){v7C.removeSeries(Q0p);if(v7C.seriesParams.length < 1){this.removeSeriesRenderer(v7C);if(v7C.params.name == W2s){this.electNewPanelOwner(v7C.params.panel);}else {if(!this.checkForEmptyPanel(v7C.params.panel)){H57=this.getYAxisByName(y7I,v7C.params.name);if(H57){H57.name=H57.studies[0] || H57.renderers[+\"1\"];}}}}H6c=!![];}}}if(!H6c){this.deleteSeries(Q0p,I5c);}this.resetDynamicYAxis();this.draw();this.resizeChart();k_Cdw.j1L();this.runAppend(\"removeSeries\",arguments);};J9u.Comparison=J9u.Comparison || (function(){});J9u.Comparison.initialPrice=100;J9u.Comparison.getInitialPrice=function(Z_Y){var Z1B,f8Q,z3Q;if(Z_Y.initialComparisonPrice){return Z_Y.initialComparisonPrice;}Z_Y.initialComparisonPrice=100;Z1B=J9u.Comparison.initialPrice;if(typeof Z1B == \"number\"){Z_Y.initialComparisonPrice=Z1B;}if(typeof Z1B == \"string\"){if(Z_Y.series[Z1B] || Z1B === \"\"){f8Q=\"Close\";if(Z_Y.defaultPlotField){if(!Z_Y.highLowBars){f8Q=Z_Y.defaultPlotField;}}for(var t7T=Z_Y.dataSet.length - Z_Y.scroll - \"1\" * 1;t7T < Z_Y.dataSet.length;t7T++){z3Q=Z_Y.dataSet[t7T];if(z3Q){if(z3Q[Z1B] && z3Q[Z1B][f8Q]){Z_Y.initialComparisonPrice=z3Q[Z1B][f8Q];break;}else if(Z1B === \"\" && z3Q[f8Q]){Z_Y.initialComparisonPrice=z3Q[f8Q];break;}}}}}return Z_Y.initialComparisonPrice;};J9u.Comparison.priceToPercent=function(y6b,q3P,O_2,S$p,d91){var b2f=k_Cdw;var b8t,U7_;b8t=\"o\";b2f.j1L();b8t+=\"bje\";b8t+=\"c\";b8t+=\"t\";U7_=y6b.comparisonBaseline;if(U7_ && (d91 in U7_)){U7_=U7_[d91];}if(U7_ && typeof U7_ === b8t){U7_=U7_[q3P.defaultPlotField || \"Close\"];}U7_=U7_ || O_2;b2f.b8R(0);var H$2=b2f.F9v(8,92);b2f.G4m(4);var J3$=b2f.e7l(20000,10000);b2f.b8R(0);var K8n=b2f.F9v(1667,8333);return Math.round((O_2 - U7_) / U7_ * H$2 * J3$) / K8n;};J9u.Comparison.percentToPrice=function(D7Q,k5n,t3Z,z2P,g2J){k_Cdw.j1L();var M9y,k9E;M9y=\"ob\";M9y+=\"j\";M9y+=\"e\";M9y+=\"ct\";k9E=D7Q.comparisonBaseline;if(k9E && (g2J in k9E)){k9E=k9E[g2J];}if(k9E && typeof k9E === M9y){k9E=k9E[k5n.defaultPlotField || \"Close\"];}k9E=k9E || 1;k_Cdw.G4m(116);return k_Cdw.e7l(100,1,k9E,t3Z);};J9u.Comparison.priceToRelative=function(T$t,r6y,F$J,O2a,M_L){var H6y,L_C;H6y=T$t.comparisonBaseline;L_C=J9u.Comparison.getInitialPrice(r6y);if(H6y && (M_L in H6y)){H6y=H6y[M_L];}if(H6y && typeof H6y === \"object\"){H6y=H6y[r6y.defaultPlotField || \"Close\"];}k_Cdw.G4m(117);return k_Cdw.e7l(H6y || F$J,L_C,F$J);};J9u.Comparison.relativeToPrice=function(D5P,x9U,b38,X4S,N2i){var h7r,H5X,J7D;h7r=\"C\";h7r+=\"lose\";H5X=D5P.comparisonBaseline;J7D=J9u.Comparison.getInitialPrice(x9U);if(H5X && (N2i in H5X)){H5X=H5X[N2i];}if(H5X && typeof H5X === \"object\"){H5X=H5X[x9U.defaultPlotField || h7r];}k_Cdw.b8R(117);return k_Cdw.e7l(J7D,H5X || 1,b38);};J9u.Comparison.createComparisonSegmentInner=function(z8S,u2b){var f0P=k_Cdw;var e67,j$5,O1g,h1R,h6m,D8I,V7x,Q8g,r8p,h9f,a34,y1_,Q0E,j$0,A2W,E2A,O9$,x7T,E8_,u5n,L4U,x$s,O$w,l$r,r6C,n1Z;e67=\"O\";e67+=\"p\";e67+=\"en\";j$5=[];for(O1g in u2b.series){D8I=u2b.series[O1g].parameters;if(!D8I.yAxis && D8I.shareYAxis || D8I.yAxis === u2b.yAxis){j$5.push(D8I.symbol);}}f0P.j1L();V7x=[\"Close\",e67,\"High\",\"Low\",\"iqPrevClose\"];Q8g=z8S.chart.highLowBars;if(u2b.defaultPlotField && !Q8g){V7x.unshift(u2b.defaultPlotField);}r8p=V7x[0];h9f=z8S.layout.studies;for(var y2F in h9f){a34=h9f[y2F];h1R=z8S.panels[a34.panel];h6m=a34.getYAxis(z8S);if(!h1R || h1R.yAxis != h6m)continue;for(O1g in a34.outputMap){V7x.push(O1g);}for(var Y5s=0;Y5s <= 2;Y5s++){V7x.push(a34.name + \"_hist\" + (Y5s?Y5s:\"\"));}if(a34.referenceOutput){V7x.push(a34.referenceOutput + ((7260,1510) > (3140,6927)?(8329,4680) < (6250,1530)?(\"g\",!({})):(0x1f1a,188.43):\" \") + a34.name);}}for(var E_C in z8S.plugins){y1_=z8S.plugins[E_C];if(!y1_.transformOutputs)continue;for(O1g in y1_.transformOutputs){V7x.push(O1g);}}u2b.initialComparisonPrice=null;u2b.dataSegment=[];Q0E=null;f0P.b8R(0);var N_d=f0P.F9v(0,1);j$0=u2b.dataSet.length - u2b.scroll - N_d;if(z8S.startComparisonsAtFirstVisibleBar){j$0+=1;}f0P.b8R(118);var y5L=f0P.e7l(0,12,2,6);A2W=u2b.maxTicks + y5L;for(var B1P=0;B1P <= A2W;B1P++){if(B1P == A2W){B1P=-1;}f0P.b8R(0);E2A=f0P.F9v(j$0,B1P);if(E2A < u2b.dataSet.length && E2A >= 0){O9$=u2b.dataSet[E2A];x7T=O9$[r8p];if(!Q0E){if(x7T === 0 || x7T === null){if(B1P < 0)break;else continue;}Q0E=J9u.clone(O9$);}if(!O9$.transform){O9$.transform={cache:{},DT:O9$.DT,Date:O9$.Date};}if(!(Q0E && Q0E[r8p]) && x7T){Q0E=J9u.clone(O9$);}z8S.comparisonBaseline=Q0E;for(E8_=0;E8_ < V7x.length;E8_++){O1g=V7x[E8_];u5n=O9$[O1g];if(u5n || u5n === 0){O9$.transform[O1g]=u2b.transformFunc(z8S,u2b,u5n);}}for(E8_=0;E8_ < j$5.length;E8_++){O1g=j$5[E8_];L4U=u2b.series[O1g];if(B1P == -1 && L4U && L4U.parameters.isComparison){delete O9$.transform[O1g];continue;}x$s=O9$[O1g];if(!x$s)continue;for(var v6P=0;v6P < V7x.length;v6P++){O$w=x$s[V7x[v6P]];if(O$w || O$w === 0){l$r=Q0E[O1g] && Q0E[O1g][V7x[0]];if(!l$r && l$r !== \"0\" * 1){if(!Q0E[O1g]){Q0E[O1g]={};}Q0E[O1g][V7x[v6P]]=l$r=O$w * Q0E[r8p] / O9$[r8p];}if(l$r !== \"0\" - 0){r6C=Q0E[r8p] || 1;f0P.b8R(119);n1Z=f0P.F9v(r6C,O$w,l$r);if(!O9$.transform[O1g]){O9$.transform[O1g]={};}O9$.transform[O1g][V7x[v6P]]=u2b.transformFunc(z8S,u2b,n1Z);}}}}u2b.dataSegment.push(O9$);}else if(E2A < 0){u2b.dataSegment.push(null);}if(B1P < 0)break;}};J9u.Comparison.priceFormat=function(O3l,V9R,r5i){var J26=k_Cdw;var O20,S48;if(r5i === null || typeof r5i == \"undefined\" || isNaN(r5i)){return \"\";}O20=V9R.yAxis.priceTick;S48=O3l.internationalizer;if(S48){if(O20 >= 5){J26.G4m(9);r5i=S48.percent.format(J26.F9v(r5i,100));}else if(O20 >= 0.5){J26.b8R(9);r5i=S48.percent1.format(J26.F9v(r5i,100));}else if(O20 >= 0.05){J26.b8R(9);r5i=S48.percent2.format(J26.F9v(r5i,100));}else if(O20 >= 0.005){J26.b8R(9);r5i=S48.percent3.format(J26.e7l(r5i,100));}else {J26.G4m(9);r5i=S48.percent4.format(J26.e7l(r5i,100));}}else {if(O20 >= 5){r5i=r5i.toFixed(0) + \"%\";}else if(O20 >= 0.5){J26.b8R(11);var V97=J26.F9v(4,5,2);J26.G4m(120);var s9T=J26.e7l(1,7107,42660,127980);J26.b8R(4);var p57=J26.e7l(11,10);J26.G4m(0);var s_W=J26.F9v(373,2986);J26.G4m(51);var F_L=J26.e7l(7756,29098,4,19);J26.b8R(0);var B2Y=J26.F9v(525,8925);J26.b8R(0);var J8o=J26.e7l(400,4);J26.b8R(121);var s_$=J26.F9v(71,1,233,20,3025);r5i=r5i.toFixed(V97) + ((s9T,\"259.23\" * p57) != s_W?\"%\":(F_L,B2Y) != (441.34,755.05)?(615.79,484.11) !== +\"250\"?(J8o,\"e\"):!({}):(!!\"1\",s_$));}else if(O20 >= \"0.05\" - 0){J26.b8R(122);var F2U=J26.e7l(15,9,2,35);J26.G4m(123);var H_t=J26.F9v(85158,8600,10,18);J26.b8R(124);var B03=J26.F9v(12,97527,4,1,1165143);J26.b8R(125);var S6$=J26.e7l(7,18,2241,2230);J26.G4m(61);var c7q=J26.F9v(20650,16525,18,13);J26.b8R(126);var y2O=J26.e7l(231420,9,1301,8,20);J26.b8R(125);var Y00=J26.F9v(4,15,4988,293);r5i=r5i.toFixed(F2U) + ((H_t,463.13) >= (B03,S6$)?c7q:(y2O,\"394.63\" - 0) >= Y00?+\"4.52e+3\":\"%\");}else if(O20 >= 0.005){r5i=r5i.toFixed(+\"3\") + \"%\";}else {J26.b8R(0);var j0r=J26.F9v(1,3);J26.b8R(23);var I$W=J26.e7l(1,14,355,4269);J26.b8R(61);var k3B=J26.e7l(2487,8,13,13);J26.G4m(60);var R7j=J26.F9v(42408,6062,8,11,13);J26.b8R(121);var z0L=J26.F9v(31,10,2260,9,2234);J26.b8R(68);var Q7Q=J26.F9v(4122,6,8206,2);J26.b8R(31);var a7F=J26.F9v(8881,8890,8890);J26.b8R(107);var t2p=J26.e7l(1,31973,11,36528);r5i=r5i.toFixed(j0r) + ((769.18,I$W) == (k3B,R7j)?(+\"7.33e+3\",\"P\"):z0L == (+\"3989\",Q7Q)?(a7F,t2p):\"%\");}}if(parseFloat(r5i) === 0 && r5i.charAt(0) == (3866 < \"426.68\" - 0?(2260,9990) === (+\"7220\",2190)?!!\"\":\"V\":\"-\")){r5i=r5i.substring(1);}return r5i;};J9u.ChartEngine.prototype.setComparison=function(N1e,x1c,Q2k){var K9u,H9e,N3H,I02;K9u=\"str\";K9u+=\"i\";K9u+=\"ng\";if(!x1c){x1c=this.chart;}if(typeof x1c == K9u){x1c=this.charts[x1c];}if(Q2k || Q2k === \"\"){J9u.Comparison.initialPrice=Q2k;}if(N1e === !!({})){if(x1c.isComparison){return;}N1e=\"percent\";}this.resetDynamicYAxis();H9e=x1c.panel.yAxis;N3H=H9e.priceFormatter == J9u.Comparison.priceFormat;switch(N1e){case \"relative\":this.setTransform(x1c,J9u.Comparison.priceToRelative,J9u.Comparison.relativeToPrice);if(N3H){H9e.priceFormatter=H9e.originalPriceFormatter?H9e.originalPriceFormatter.func:null;H9e.originalPriceFormatter=null;}H9e.whichSet=\"dataSegment\";x1c.isComparison=!![];break;case \"percent\":I02=\"dataSegmen\";I02+=\"t\";this.setTransform(x1c,J9u.Comparison.priceToPercent,J9u.Comparison.percentToPrice);if(!N3H){H9e.originalPriceFormatter={func:H9e.priceFormatter};H9e.priceFormatter=J9u.Comparison.priceFormat;}H9e.whichSet=I02;x1c.isComparison=!0;break;default:this.unsetTransform(x1c);if(N3H){H9e.priceFormatter=H9e.originalPriceFormatter?H9e.originalPriceFormatter.func:null;H9e.originalPriceFormatter=null;}H9e.whichSet=\"dataSet\";x1c.isComparison=!\"1\";break;}};J9u.ChartEngine.prototype.setChartScale=function(E1V){var X7E,s3Y,d_1;X7E=this.chart;s3Y={percent:!!({}),relative:!!\"1\"};if(!E1V){E1V=\"linear\";}if(s3Y[E1V]){this.setComparison(E1V,X7E,J9u.Comparison.initialPrice);}else if(s3Y[this.layout.chartScale]){this.setComparison(![],X7E);}d_1=this.layout.chartScale !== E1V;this.layout.chartScale=E1V;if(X7E.canvas){this.draw();}if(d_1){this.changeOccurred(\"layout\");}};};Y3=p0k=>{var W1_,P$3;W1_=typeof _CIQ !== \"undefined\"?_CIQ:p0k.CIQ;function q5z(){var p4T,G1y,C1c,c7a;p4T=\"js\";p4T+=\"/thirdp\";k_Cdw.j1L();p4T+=\"arty/\";if(W1_.Share.html2canvasLocation){return W1_.Share.html2canvasLocation;}G1y=document.getElementsByTagName(\"script\");for(var y_5=+\"0\";y_5 < G1y.length;y_5++){C1c=\"share\";C1c+=\".j\";C1c+=\"s\";c7a=G1y[y_5];if(c7a.src && c7a.src.indexOf(C1c) > -1){return c7a.src.replace(/standard\\/share\\.js/,\"\") + \"thirdparty/\";}}return p4T;}W1_.Share=W1_.Share || (function(){});function O52(P1$,P9v,W$H){var y2s,b0r,C0o,U4z,Y_7,z3c,E9R,r8E,E7A;if(!P9v){P9v={};}y2s=[];b0r=\"ciq-no-share\";C0o=P1$.container.ownerDocument.querySelector(\"body\");if(P9v.hide && P9v.hide instanceof Array){U4z=P9v.hide.join(\", \");Y_7=C0o.querySelectorAll(U4z);for(var a2F=0;a2F < Y_7.length;a2F++){Y_7[a2F].classList.add(b0r);}}C0o.classList.add(\"sharing\");P1$.draw();z3c=P1$.chart.container.getElementsByTagName(\"svg\");E9R=[];r8E=0;for(;r8E < z3c.length;r8E++){E7A=z3c[r8E];E9R.push(E7A.innerHTML);d0t(E7A);}P$3(P1$.chart.container,{allowTaint:!1,logging:![],width:P9v.width || null,height:P9v.height || null,backgroundColor:P9v.background || null,useCORS:!0}).then(function(S_G){var S9e;S9e=\"shar\";S9e+=\"i\";S9e+=\"ng\";if(W$H){W$H(null,P9v.data?S_G.toDataURL(\"image/png\"):S_G);}for(r8E=0;r8E < z3c.length;r8E++){z3c[r8E].innerHTML=E9R[r8E];}C0o.classList.remove(S9e);}).catch(function(f1S){var n1I;n1I=\"s\";n1I+=\"har\";n1I+=\"ing\";if(W$H){W$H(f1S);}k_Cdw.j1L();for(r8E=0;r8E < z3c.length;r8E++){z3c[r8E].innerHTML=E9R[r8E];}C0o.classList.remove(n1I);});}W1_.Share.fullChart2PNG=function(v0f,I9a,T5$){if(!v0f || !v0f.chart){return;}if(typeof html2canvas === \"undefined\"){return X9l(function(){k_Cdw.j1L();return O52(v0f,I9a,T5$);});}P$3=html2canvas;O52(v0f,I9a,T5$);};W1_.Share.createImage=function(k0Y,D1v,X5o){var P8A,v7g,c$$,N9G,K7k,q9Z,v7f,m87,c_V;P8A=\"im\";P8A+=\"g\";v7g=[].slice.call(arguments);X5o=v7g.pop();if(D1v === null || typeof D1v != \"object\"){D1v={widthPX:v7g[1],heightPX:v7g[2],imageType:v7g[3]};}c$$=D1v.widthPX;N9G=D1v.heightPX;K7k=D1v.imageType;q9Z=k0Y.chart.canvas.height;v7f=k0Y.chart.canvas.width;if(k0Y.chart.canvas.style.height){q9Z=W1_.stripPX(k0Y.chart.canvas.style.height);v7f=W1_.stripPX(k0Y.chart.canvas.style.width);}if(c$$ && N9G){q9Z=N9G;v7f=c$$;}else if(N9G){v7f=k0Y.chart.canvas.width * (q9Z / k0Y.chart.canvas.height);}else if(c$$){v7f=c$$;q9Z=k0Y.chart.canvas.height * (c$$ / k0Y.chart.canvas.width);}m87=K7k?\"image/\" + K7k:\"image/png\";c_V=document.createElement(P8A);c_V.onload=function(){W1_.Share.fullChart2PNG(k0Y,{image:this,width:v7f,height:q9Z,hide:D1v.hide},function(v5s,u1f){if(v5s){k_Cdw.b8R(0);console.warn(k_Cdw.e7l(\"Error producing canvas snapshot: \",v5s));}else {try{X5o(u1f.toDataURL(m87));}catch(B4z){var S_u;S_u=\"Sa\";S_u+=\"fari devices do not handle CORS enabled images. Using the charts' canvas\";S_u+=\" as \";S_u+=\"a fallback.\";console.warn(S_u);X5o(c_V.src);}}});};c_V.src=k0Y.chart.canvas.toDataURL(m87);};W1_.Share.uploadImage=function(Z6b,t_j,A0M,O2o){var E1U;if(!A0M){A0M={};}A0M.image=Z6b;E1U=W1_.postAjax(t_j,JSON.stringify(A0M),function(P2o,z09){if(P2o != 200){O2o(P2o,null);return;}O2o(null,z09);});if(!E1U){O2o(0,null);}};W1_.Share.shareChart=function(x4j,f7C,l_k){W1_.Share.createImage(x4j,{},function(i7T){var S0W=k_Cdw;var r5N,K9x,u9Y,Q2x,g56,K8H;r5N=W1_.uniqueID();K9x=\"https://\";K9x+=\"share.chartiq.c\";K9x+=\"om\";S0W.G4m(14);u9Y=S0W.e7l(K9x,r5N,\"/upload/\");if(f7C){if(f7C.host){K9x=f7C.host;}if(f7C.path){u9Y=K9x + f7C.path + \"/\" + r5N;}}Q2x=x4j.getStartDateOffset();S0W.j1L();g56={layout:x4j.exportLayout(),drawings:x4j.exportDrawings(),xOffset:Q2x,startDate:x4j.chart.dataSegment[Q2x].Date,endDate:x4j.chart.dataSegment[x4j.chart.dataSegment.length - 1].Date,id:r5N,symbol:x4j.chart.symbol};K8H={id:r5N,image:i7T,config:g56};W1_.Share.uploadImage(i7T,u9Y,K8H,function(l1P,Y52){S0W.y6g();if(l1P !== null){W1_.alert(\"error sharing chart: \",l1P);}else {S0W.G4m(0);l_k(S0W.e7l(K9x,Y52));}});});};function d0t(V3D){var Z1E,a25,m5E,p7r,u70;Z1E=\"tex\";Z1E+=\"t-a\";Z1E+=\"ncho\";Z1E+=\"r\";a25=\"fill-opa\";a25+=\"city\";m5E=\"dom\";m5E+=\"inant-bas\";m5E+=\"el\";m5E+=\"ine\";if(!V3D.style){return;}p7r=getComputedStyle(V3D);u70=[\"alignment-baseline\",m5E,\"fill\",a25,\"font-family\",\"font-size\",\"font-variant\",\"font-weight\",\"text-align\",Z1E];u70.forEach(function(q6a){if(!V3D.style[q6a] && p7r[q6a]){V3D.style[q6a]=p7r[q6a];}});for(var n5h in V3D.children){d0t(V3D.children[n5h]);}}function X9l(z7b){k_Cdw.j1L();var t1S;t1S=\"un\";t1S+=\"def\";t1S+=\"ined\";if(typeof html2canvas === t1S){if(typeof requirejs !== \"undefined\"){try{return requirejs([\"html2canvas.min.js\"],function(U60){P$3=U60;return z7b();});}catch(h_Y){var X9o;X9o=\"Require loading has failed, attempting to load\";X9o+=\" html2canvas manually.\";console.warn(X9o);}}W1_.loadScript(q5z() + \"html2canvas.min.js\",function(){P$3=html2canvas;k_Cdw.j1L();return z7b();});}else {P$3=html2canvas;return z7b();}}};x4=R8f=>{var e6L;e6L=typeof _CIQ !== \"undefined\"?_CIQ:R8f.CIQ;e6L.ChartEngine.prototype.setRange=function(W0_,K85){var k0K,N3T,H6I,g8P,p$Y,q_2,p2s,G$8,Y14,d_r,G1k,X$V,X4B,I11,O5$,e76,s8$,j2k,K0g,p8x,I8A,G3f,B3h,X2q,R27,n0l,V07,F1X,X3o,o$0,N3j,t4K,S1k;k0K=\"s\";k0K+=\"tr\";k0K+=\"in\";k0K+=\"g\";if(e6L.isEmpty(W0_)){W0_={dtLeft:arguments[0],dtRight:arguments[1],padding:arguments[2],chart:arguments[3]};K85=arguments[4];}if(this.staticRange){W0_.goIntoPast=W0_.goIntoFuture=!![];}if(!W0_.chart){W0_.chart=this.chart;}function d_g(O6I,G3b,O$J,F6_,Q8t,q6W){var R55=k_Cdw;var d3J,U_B,O9s;d3J=0;R55.G4m(4);U_B=R55.F9v(O6I,G3b);if(e6L.ChartEngine.isDailyInterval(O$J)){O9s=\"w\";O9s+=\"e\";O9s+=\"e\";O9s+=\"k\";if(O$J == \"month\"){d3J=U_B / e6L.MONTH / F6_;}else if(O$J == O9s){d3J=U_B / e6L.WEEK / F6_;}else {d3J=U_B / e6L.DAY / F6_;}}else {if(!isNaN(O$J)){if(Q8t == \"millisecond\"){R55.G4m(127);d3J=R55.e7l(U_B,F6_,O$J);}else if(Q8t == \"second\"){d3J=U_B / e6L.SECOND / (F6_ * O$J);}else {d3J=U_B / e6L.MINUTE / (F6_ * O$J);}}}return Math.round(d3J);}function Q1h(c98){k_Cdw.j1L();if(c98 && G$8 === 0){H6I.scroll=G3f;p2s.setCandleWidth(B3h);p2s.layout.interval=X2q;p2s.layout.periodicity=R27;p2s.layout.timeUnit=n0l;if(K85){K85(c98);}return;}G$8++;if(G$8 > 10){console.log(\"CIQ.ChartEngine.setRange(): Too many loads (10) from server. Stopping. Check periodicity logic.\");p5K();return;}p5K();}if(typeof W0_.padding == \"undefined\"){W0_.padding=0;}N3T=!\"1\";function p5K(D8a){var l0d=k_Cdw;var s5a,q41,P0c,C$0,u30,B4B,v76,V5J,P6L,K9R,G$E,X7T,i9e,j4h,v4q,T2a,l63,U1T;s5a=\"d\";s5a+=\"a\";s5a+=\"y\";if(typeof D8a == \"undefined\"){D8a=null;}q41=0;P0c=+\"0\";C$0=new Date();u30=W0_.base;B4B=W0_.periodicity;v76=p2s.layout;if(W0_.goIntoFuture && (!H6I.masterData.length || g8P > H6I.masterData[H6I.masterData.length - 1].DT)){V5J=H6I.masterData.length?H6I.masterData.pop():{DT:g8P};P6L=p2s.doCleanupGaps([V5J,{DT:p$Y}],H6I,{cleanupGaps:\"gap\",noCleanupDates:!![]});p2s.setMasterData(H6I.masterData.concat(P6L),H6I,{noCleanupDates:!!({})});p2s.createDataSet(null,null,{appending:!!1});}K9R=H6I.dataSet;G$E=K9R.length;if(!K9R || G$E === +\"0\"){if(K85){K85(D8a);}return;}if(u30 === \"day\" && B4B && B4B.interval === s5a){i9e=W0_.multiplier;q41=G$E < i9e?0:G$E - i9e;l0d.G4m(4);P0c=l0d.e7l(G$E,1);}else if(u30 === \"today\" && K9R[G$E - 1].DT.getDate() < C$0.getDate()){j4h=new Date(K9R[G$E - 1].DT.getTime());v4q=j4h.getTime();X7T=0;for(var Q1Z=G$E - 1;Q1Z >= 0;Q1Z--){if(K9R[Q1Z] && K9R[Q1Z].DT.getDate() != j4h.getDate()){j4h=new Date(+K9R[Q1Z + 1].DT);l0d.G4m(26);X7T=l0d.F9v(1,\"1\",Q1Z);break;}}q41=X7T;l0d.b8R(128);P0c=l0d.e7l(G$E,\"1\");}else {if(W0_.base != \"all\" && (g8P.getTime() >= K9R[\"0\" * 1].DT.getTime() || W0_.goIntoPast)){q41=p2s.tickFromDate(g8P,H6I,null,!!({}));}else {q41=0;}if(W0_.base != \"all\" && (p$Y.getTime() <= K9R[G$E - 1].DT.getTime() || W0_.goIntoFuture)){P0c=p2s.tickFromDate(p$Y,H6I);if(P0c > G$E - +\"1\"){P0c--;}}else {l0d.G4m(103);P0c=l0d.F9v(\"1\",0,G$E);}}l0d.G4m(11);T2a=l0d.e7l(P0c,q41,1);if(T2a < 1){if(K85){K85(D8a);}return;}l63=W0_.padding || 0;if(P0c < G$E - 1){l63=+\"0\";}U1T=(H6I.width - l63) / T2a;p2s.setCandleWidth(U1T,H6I);l0d.G4m(129);H6I.scroll=l0d.e7l(P0c,T2a,1,G$E);p2s.micropixels=1;for(var o$u in p2s.panels){p2s.calculateYAxisMargins(p2s.panels[o$u].yAxis);}if(!W0_.dontSaveRangeToLayout){delete W0_.chart;delete v76.setSpan;v76.range=W0_;}else {delete v76.range;}p2s.draw();p2s.changeOccurred(\"layout\");if(!N3T){p2s.dispatch(\"periodicity\",{stx:p2s,differentData:V07,prevPeriodicity:{interval:X2q,periodicity:R27,timeUnit:n0l}});}if(K85){K85(D8a);}}H6I=W0_.chart;g8P=typeof W0_.dtLeft === \"string\"?new Date(W0_.dtLeft):W0_.dtLeft;p$Y=new Date();if(W0_.dtRight){p$Y=typeof W0_.dtRight === k0K?new Date(W0_.dtRight):W0_.dtRight;}if(!g8P){q_2=this.standardMarketIterator(p$Y,null,H6I);g8P=q_2.previous(H6I.maxTicks);if(!W0_.periodicity){N3T=!\"\";}}H6I.inflectionPoint=g8P;this.layout.range={dtLeft:g8P,dtRight:p$Y};p2s=this;k_Cdw.j1L();G$8=0;if(this.quoteDriver){if(N3T){Y14=this.layout.interval;G1k=this.layout.timeUnit;d_r=this.layout.periodicity;}else if(W0_.periodicity){X$V=e6L.cleanPeriodicity(W0_.periodicity.period,W0_.periodicity.interval,W0_.periodicity.timeUnit);Y14=X$V.interval;G1k=X$V.timeUnit;d_r=X$V.period;}else {X4B=p$Y.getTime() - g8P.getTime();if(!this.autoPickCandleWidth.turnOn){I11=this.staticRangePeriodicityMap;O5$=null;for(var p0O=0;p0O < I11.length;p0O++){e76=I11[p0O];if(X4B / e76.rangeInMS < 1.001){O5$=e76;break;}}Y14=O5$.interval;d_r=O5$.periodicity;G1k=O5$.timeUnit;}else {s8$=0;if(this.autoPickCandleWidth.candleWidth){s8$=this.autoPickCandleWidth.candleWidth;}else {s8$=this.chart.barsHaveWidth?+\"5\":2;}j2k=H6I.width / s8$;K0g=this.dynamicRangePeriodicityMap;Y14=K0g[0].interval;d_r=1;for(var z0X=0;z0X < K0g.length;z0X++){I8A=X4B / K0g[z0X].rangeInMS;if(I8A < j2k){if(K0g[z0X - 1]){Y14=K0g[z0X - 1].interval;G1k=K0g[z0X - 1].timeUnit;k_Cdw.G4m(9);d_r=Math.ceil(k_Cdw.e7l(p8x,j2k));}else {Y14=K0g[z0X].interval;G1k=K0g[z0X].timeUnit;d_r=1;}break;}p8x=I8A;}}}G3f=this.chart.scroll;B3h=this.layout.candleWidth;X2q=this.layout.interval;R27=this.layout.periodicity;n0l=this.layout.timeUnit;this.chart.scroll=this.chart.maxTicks=d_g(p$Y.getTime(),g8P.getTime(),Y14,d_r,G1k,this.dontRoll);this.layout.candleWidth=this.chart.width / this.chart.maxTicks;V07=this.needDifferentData({period:d_r,interval:Y14,timeUnit:G1k});if(Object.keys(this.chart.endPoints).length && (this.chart.endPoints.begin > g8P || this.chart.endPoints.end < p$Y)){V07=!!\"1\";}if(!this.chart.masterData || !this.chart.masterData.length || V07 || W0_.forceLoad){F1X=\"we\";F1X+=\"ek\";this.layout.interval=Y14;this.layout.periodicity=d_r;this.layout.timeUnit=G1k;if(!this.layout.timeUnit){X3o=\"secon\";X3o+=\"d\";o$0=\"s\";o$0+=\"econ\";o$0+=\"d\";if(e6L.ChartEngine.isDailyInterval(this.layout.interval)){this.layout.timeUnit=null;}else if(this.layout.interval == o$0){this.layout.timeUnit=X3o;}else if(this.layout.interval != \"tick\"){this.layout.timeUnit=\"minute\";}}N3j={symbol:H6I.symbol,symbolObject:H6I.symbolObject,chart:H6I,nodraw:!!\"1\"};if(this.layout.interval == \"tick\"){N3j.startDate=g8P;N3j.endDate=p$Y;}if(!this.displayInitialized){N3j.initializeChart=!!\"1\";}t4K={symbol:H6I.symbol,symbolObject:H6I.symbolObject,interval:this.layout.interval};if((t4K.interval == \"month\" || t4K.interval == F1X) && !this.dontRoll){t4K.interval=\"day\";}S1k=Math.max(this.quoteDriver.getQuoteFeed(t4K).behavior.bufferSize + 50,200);q_2=this.standardMarketIterator(g8P,null,H6I);N3j.startDate=new Date(q_2.previous(S1k).getTime());q_2=this.standardMarketIterator(p$Y,null,H6I);N3j.endDate=new Date(q_2.next(S1k).getTime());if(N3j.endDate < Date.now()){this.isHistoricalModeSet=!!\"1\";}this.clearCurrentMarketData(this.chart);clearTimeout(this.streamParameters.timeout);this.quoteDriver.newChart(N3j,Q1h);}else {if(this.layout.interval != Y14 || this.layout.periodicity != d_r || this.layout.timeUnit != G1k || !this.chart.dataSegment || !this.chart.dataSegment[0] || this.chart.dataSegment[0].DT != H6I.inflectionPoint){this.layout.interval=Y14;this.layout.periodicity=d_r;this.layout.timeUnit=G1k;this.createDataSet();}Q1h();}}else {p5K();}};e6L.ChartEngine.prototype.setSpan=function(e4z,U1w){var C3Y=k_Cdw;var u6$,e87,i8U,H1N,f8J,M1_,B14,l4N,o7Z,w9L,p89,q8u,j4V,i$U,r5Y,I1B,w6S,W$o,l1s,i8y,Y_L,o0f,J3d,S6M,z1Z,E88,G$7;u6$=\"t\";u6$+=\"oday\";e87=\"d\";e87+=\"a\";e87+=\"y\";i8U=\"y\";i8U+=\"ea\";i8U+=\"r\";H1N=\"mo\";H1N+=\"nt\";H1N+=\"h\";f8J=\"ye\";f8J+=\"ar\";M1_=\"a\";function z2a(J33){J33.setHours(0);C3Y.y6g();J33.setMinutes(0);J33.setSeconds(0);J33.setMilliseconds(0);return J33;}M1_+=\"ll\";B14=arguments[0];l4N=arguments[1];o7Z=arguments[2];w9L=arguments[3];if(typeof e4z == \"object\"){B14=e4z.period?e4z.period:e4z.multiplier?e4z.multiplier:1;l4N=e4z.interval?e4z.interval:e4z.base?e4z.base:e4z.span?e4z.span:e4z.period;o7Z=e4z.padding;w9L=e4z.chart;}else {e4z={period:B14,interval:l4N,padding:o7Z,chart:w9L};U1w=arguments[5];}if(!w9L){w9L=this.chart;}p89=w9L.market;l4N=l4N.toLowerCase();if(l4N == M1_){e4z.dontSaveRangeToLayout=!![];this.displayAll(e4z,U1w);return;}function e4i(m$n,H9D){var s8h;if(!l1s){return m$n;}s8h=7;if(H9D){m$n.setHours(m$n.getHours() + s8h);}else {m$n.setHours(m$n.getHours() - s8h);if(!p89.isMarketDate(m$n)){m$n.setDate(m$n.getDate() - +\"2\");}}return m$n;}j4V=l4N;i$U=1;if(l4N == \"today\"){r5Y=\"d\";r5Y+=\"ay\";j4V=r5Y;}else if(l4N == f8J){j4V=\"month\";i$U=12;}I1B=e6L.shallowClone(e4z);w6S={begin:p89.marketZoneNow(),interval:j4V,period:i$U};W$o=w6S.begin;l1s=e6L.Market.Symbology.isForexSymbol(w9L.symbol);if(l4N === \"ytd\"){W$o=z2a(W$o);W$o.setMonth(0);W$o.setDate(1);}else if(l4N === H1N){i8y=+\"332389983\";Y_L=-1984560823;o0f=2;for(var d_T=1;C3Y.P6(d_T.toString(),d_T.toString().length,19812) !== i8y;d_T++){W$o=z2a(new Date());W$o.setMonth(W$o.getMonth() - B14);o0f+=2;}if(C3Y.P6(o0f.toString(),o0f.toString().length,38345) !== Y_L){W$o=z2a(new Date());W$o.setMonth(W$o.getMonth() * B14);}}else if(l4N === i8U){W$o=z2a(new Date());W$o.setFullYear(W$o.getFullYear() - B14);}else if(l4N === \"week\"){W$o=z2a(new Date());W$o.setDate(W$o.getDate() - B14 * 7);}else if(l4N === e87 && B14 == \"1\" - 0 && p89.isMarketDay()){J3d=W$o.getHours();S6M=W$o.getMinutes();z1Z=W$o.getSeconds();E88=W$o.getMilliseconds();q8u=p89.newIterator(w6S);W$o=q8u.previous();W$o.setHours(J3d,S6M,z1Z,E88);W$o=p89._convertFromMarketTZ(W$o);}else if(l4N === u6$){w6S.begin=e4i(W$o,!![]);q8u=p89.newIterator(w6S);if(p89.isOpen() || p89.getPreviousOpen().getDate() == W$o.getDate()){q8u.next();}W$o=q8u.previous();e4i(W$o);I1B.goIntoFuture=!!\"1\";I1B.dtRight=new Date(+W$o);I1B.dtRight.setDate(W$o.getDate() + \"1\" * 1);I1B.dtRight=p89._convertFromMarketTZ(I1B.dtRight);if(!l1s){W$o.setHours(q8u.market.zopen_hour);W$o.setMinutes(q8u.market.zopen_minute);W$o.setSeconds(0);}W$o=p89._convertFromMarketTZ(W$o);}else {if(l4N == \"day\"){w6S.begin=e4i(W$o,!!({}));}q8u=p89.newIterator(w6S);if(B14 == 1){B14++;}C3Y.G4m(128);W$o=q8u.previous(C3Y.e7l(B14,\"1\"));if(l4N == \"day\"){W$o=p89._convertFromMarketTZ(e4i(W$o));}}I1B.dtLeft=W$o;if(I1B.maintainPeriodicity){I1B.periodicity={};I1B.periodicity.interval=this.layout.interval;I1B.periodicity.period=this.layout.periodicity;}w9L.spanLock=![];I1B.dontSaveRangeToLayout=!![];G$7=this;this.setRange(I1B,function(F$M){G$7.layout.setSpan=e4z;C3Y.y6g();G$7.changeOccurred(\"layout\");if(l4N == \"today\"){w9L.spanLock=!!\"1\";}if(U1w){U1w(F$M);}});};e6L.ChartEngine.prototype.getSpanCandleWidth=function(r3W){var w7C=k_Cdw;var G37,t7v,w2A,R2W,W5g,p1g,n2t,y1F,A3s,P5G;G37=\"w\";G37+=\"e\";G37+=\"ek\";t7v=\"d\";t7v+=\"a\";t7v+=\"y\";w2A=\"m\";w2A+=\"on\";w2A+=\"t\";w2A+=\"h\";R2W=\"y\";R2W+=\"e\";R2W+=\"a\";w7C.y6g();R2W+=\"r\";if(!r3W || !r3W.base || !r3W.multiplier){return;}W5g=parseFloat(r3W.multiplier);p1g=r3W.base;n2t=new Date();y1F=new Date();if(p1g == R2W){y1F.setFullYear(y1F.getFullYear() - W5g);}else if(p1g == w2A){y1F.setMonth(y1F.getMonth() - W5g);}else if(p1g == t7v){y1F.setDate(y1F.getDate() - W5g);}else if(p1g == G37){y1F.setDate(y1F.getDate() - (\"7\" - 0) * W5g);}else if(p1g == \"YTD\"){y1F.setMonth(0);y1F.setDate(1);}w7C.G4m(60);var B1g=w7C.F9v(8750,988,10,3,16);w7C.b8R(123);var U1W=w7C.F9v(358,80,5,18);w7C.G4m(130);var o5$=w7C.F9v(2,1140,571,58);A3s=(n2t.getTime() - y1F.getTime()) / B1g / U1W / o5$ / +\"24\";w7C.b8R(117);A3s=w7C.e7l(7,A3s,5);P5G=this.chart.width / A3s;return P5G;};e6L.ChartEngine.prototype.displayAll=function(S7V,A65){var b0g,q7u,V$t;var {chart:t6X, layout:F9d}=this;function z9Y(){var G3H;if(!t6X.masterData || !t6X.masterData.length){return;}G3H=e6L.clone(S7V);G3H.dtLeft=t6X.endPoints.begin;G3H.dtRight=t6X.endPoints.end;G3H.periodicity={};G3H.periodicity.interval=F9d.interval;G3H.periodicity.period=F9d.periodicity;G3H.periodicity.timeUnit=F9d.timeUnit;b0g.setRange(G3H,function(I4o){var t3e,X1b,L41;b0g.layout.setSpan={base:S7V.base,multiplier:S7V.multiplier};b0g.changeOccurred(\"layout\");for(var n7N in b0g.panels){b0g.calculateYAxisMargins(b0g.panels[n7N].yAxis);}t3e=1989599070;X1b=-2020946290;L41=2;for(var i8s=1;k_Cdw.P6(i8s.toString(),i8s.toString().length,56326) !== t3e;i8s++){b0g.draw();L41+=2;}if(k_Cdw.m1(L41.toString(),L41.toString().length,78922) !== X1b){b0g.draw();}b0g.draw();if(A65){A65(I4o);}});}if(S7V && S7V.chart){t6X=S7V.chart;}function O45(J6X){if(!J6X){b0g.quoteDriver.loadAll(t6X,z9Y);}}b0g=this;if(!this.quoteDriver){z9Y();return;}q7u=S7V.maintainPeriodicity?{period:F9d.periodicity,interval:F9d.interval,timeUnit:F9d.timeUnit}:{period:+\"1\",interval:\"month\",timeUnit:null};q7u=S7V.periodicity?S7V.periodicity:q7u;q7u=e6L.cleanPeriodicity(q7u.period,q7u.interval,q7u.timeUnit);V$t=this.needDifferentData(q7u);this.layout.periodicity=q7u.period;this.layout.interval=q7u.interval;this.layout.timeUnit=q7u.timeUnit;if(S7V.forceLoad || V$t){this.clearCurrentMarketData(this.chart);this.quoteDriver.newChart({nodraw:!!({}),symbol:this.chart.symbol,symbolObject:this.chart.symbolObject,chart:this.chart,initializeChart:!![],fetchMaximumBars:!!1},O45);}else {if(t6X.moreAvailable || !t6X.upToDate){O45();}else {this.createDataSet();z9Y();}}};};z9=c5i=>{var n6s,d_w;n6s=\"un\";n6s+=\"defined\";d_w=typeof _CIQ !== n6s?_CIQ:c5i.CIQ;d_w.ChartEngine.prototype.importLayout=function(Q98,I2$){var H0P=k_Cdw;var Q8l,e_n,B0L,o28,R9X,z7d,R_6,M0Q,T7i,A0_,f8k,E1D,w6U,O57,N33,K2f,g8B,k0$,d1$,V5l,H2y,F0k,b8Y,a5B,T9O,A2w,K7T,P8V,p$S,O5F,w_o,h$F,W4T,C1A,U4q,V93,T7X,v06;if(!Q98){if(I2$.cb){I2$.cb();}return;}Q8l=this;e_n=[];if(typeof I2$ !== \"object\"){I2$={managePeriodicity:arguments[\"1\" * 1],preserveTicksAndCandleWidth:arguments[2]};}B0L=this.layout;o28=d_w.shallowClone(B0L);R9X=I2$.managePeriodicity;z7d=I2$.cb;R_6=I2$.seriesCB;M0Q=I2$.noDataLoad;T7i=I2$.preserveTicksAndCandleWidth;A0_=null;if(this.exportDrawings){A0_=this.exportDrawings();this.abortDrawings();}function d70(V_m){var c5J,s4P,g2i,c_W;if(A0_){Q8l.importDrawings(A0_);}Q8l.currentlyImporting=![];if(V_m){return;}g2i=[];for(var K4Z in Q8l.chart.series){c_W=\"stu\";c_W+=\"dy\";if(!Q8l.removeSeries)break;s4P=Q8l.chart.series[K4Z];if(s4P.parameters.bucket == c_W){c5J=!![];Q8l.removeSeries(s4P);g2i.push(s4P);}}for(var d43=0;d43 < g2i.length;d43++){s4P=g2i[d43];Q8l.addSeries(s4P.id,s4P.parameters,q$T);}if(!c5J){Q8l.draw();}Q8l.updateListeners(\"layout\");function q$T(){H0P.j1L();Q8l.createDataSet();G0n(Q8l.panels);Q8l.calculateYAxisPositions();Q8l.draw();}Q8l.changeOccurred(\"layout\");}this.currentlyImporting=!!1;for(var b1D in B0L.studies){f8k=B0L.studies[b1D];d_w.getFn(\"Studies.removeStudy\")(this,f8k);}this.overlays={};E1D=d_w.shallowClone(this.panels);this.panels={};w6U=d_w.clone(Q98);B0L.periodicity=o28.periodicity;B0L.interval=o28.interval;B0L.timeUnit=o28.timeUnit;B0L.setSpan=o28.setSpan;B0L.range=o28.range;if(T7i){B0L.candleWidth=o28.candleWidth;}else {if(!B0L.candleWidth){B0L.candleWidth=8;}}this.setCandleWidth(B0L.candleWidth);if(B0L.flipped){this.flipChart(B0L.flipped);}O57=w6U.panels;function o5O(){Q8l.calculateYAxisPositions();G0n(Q8l.panels);H0P.j1L();if(R_6){R_6();}}k0$=function(h3l,I6C){H0P.j1L();return h3l.index < I6C.index?-1:1;};for(N33 in O57){d1$=\"i\";d1$+=\"nd\";d1$+=\"ex\";if(!((d1$ in O57[N33]))){k0$=null;}K2f=O57[N33];K2f.name=N33;e_n.push(K2f);}B0L.panels={};V5l=null;if(e_n.length > 0){if(k0$){e_n.sort(k0$);}for(var b3f=\"0\" << 96;b3f < e_n.length;++b3f){K2f=e_n[b3f];g8B=K2f.yAxis?new d_w.ChartEngine.YAxis(K2f.yAxis):null;this.stackPanel(K2f.display,K2f.name,K2f.percent,K2f.chartName,g8B);if(K2f.soloing){V5l=this.panels[K2f.name];}}}if(d_w.isEmpty(O57)){H2y=\"ch\";H2y+=\"art\";F0k=\"c\";F0k+=\"har\";F0k+=\"t\";this.stackPanel(\"chart\",F0k,1,H2y);}this.resizeCanvas();for(var W5F in E1D){b8Y=E1D[W5F];a5B=this.panels[W5F];if(a5B){this.container.removeChild(a5B.holder);if(b8Y.handle){this.container.removeChild(b8Y.handle);}T9O={holder:!!({}),subholder:!![],display:!![],icons:!!\"1\"};for(var a0f in T9O){a5B[a0f]=b8Y[a0f];}this.configurePanelControls(a5B);if(b8Y.chart.panel == b8Y){b8Y.chart.panel=a5B;}}else {this.privateDeletePanel(b8Y);}}this.chart.panel=this.panels.chart;G0n(this.panels);d_w.extend(B0L,d_w.clone(w6U));A2w=d_w.clone(B0L.studies);delete B0L.studies;for(var V38 in A2w){K7T=A2w[V38];P8V=d_w.getFn(\"Studies.addStudy\")(this,K7T.type,K7T.inputs,K7T.outputs,K7T.parameters,K7T.panel);P8V.disabled=K7T.disabled;if(K7T.signalData){P8V.signalData=K7T.signalData;p$S=this.panels[P8V.panel];if(this.checkForEmptyPanel(p$S,!!({}),P8V)){p$S.hidden=!!({});p$S.percent=0;}}}if(this.extendedHours){this.extendedHours.prepare(B0L.extended,B0L.marketSessions);}if(typeof B0L.chartType == \"undefined\"){B0L.chartType=\"line\";}this.setMainSeriesRenderer();if(V5l){this.panelSolo(V5l);}this.adjustPanelPositions();G0n(this.panels);this.storePanels();if(!M0Q){if(w6U.symbols && w6U.symbols.length){O5F=1465580324;w_o=-465789511;h$F=2;for(var w01=\"1\" >> 64;H0P.P6(w01.toString(),w01.toString().length,+\"83931\") !== O5F;w01++){W4T={chart:this.chart};h$F+=2;}if(H0P.m1(h$F.toString(),h$F.toString().length,1513) !== w_o){W4T={chart:this.chart};}if(!T7i && R9X && w6U.range && Object.keys(w6U.range).length){W4T.range=w6U.range;}else if(!T7i && R9X && w6U.setSpan && Object.keys(w6U.setSpan).length){W4T.span=w6U.setSpan;}else if(R9X && w6U.interval){W4T.periodicity={interval:w6U.interval,period:w6U.periodicity,timeUnit:w6U.timeUnit};}else {W4T.periodicity={interval:o28.interval,period:o28.periodicity,timeUnit:o28.timeUnit};}C1A=w6U.symbols[\"0\" << 0].symbolObject || w6U.symbols[0].symbol;this.loadChart(C1A,W4T,function(r_k){var j9p,e2F;if(!r_k){for(var S5n,V91=1;V91 < w6U.symbols.length;++V91){if(!Q8l.addSeries)break;S5n=w6U.symbols[V91];if(!S5n.parameters){S5n.parameters={};}j9p=d_w.clone(S5n.parameters);if(this.panels[j9p.panel]){Q8l.addSeries(S5n.id,j9p,o5O);}else {e2F=\"\\\" could not be imported due to a missing corresp\";e2F+=\"onding panel \\\"\";console.warn('Warning: Series \"' + S5n.id + e2F + j9p.panel + ((8460,2570) == \"3523\" * 1?(849.39,\"9.50e+3\" | 4):'\"'));}}if(w6U.chartScale){Q8l.setChartScale(w6U.chartScale);}}d70(r_k);if(z7d){z7d.apply(null,arguments);}});return;}if(R9X){if(!T7i && this.setRange){U4q=w6U.range;if(U4q && Object.keys(U4q).length && this.chart.symbol){this.setRange(U4q,function(){d70();if(z7d){z7d();}});return;}else if(w6U.setSpan && Object.keys(w6U.setSpan).length && this.chart.symbol){this.setSpan(w6U.setSpan,function(){d70();if(z7d){z7d();}});return;}}V93=w6U.interval;T7X=w6U.periodicity;v06=w6U.timeUnit;if(isNaN(T7X)){T7X=+\"1\";}if(!V93){V93=\"day\";}this.setPeriodicity({period:T7X,interval:V93,timeUnit:v06},function(){H0P.j1L();d70();if(z7d){z7d();}});return;}}if(R9X){B0L.periodicity=w6U.periodicity;B0L.interval=w6U.interval;B0L.timeUnit=w6U.timeUnit;B0L.setSpan=w6U.setSpan;}this.createDataSet();if(!T7i){this.home();}d70();if(z7d){z7d();}function G0n(r96){var p1V,X24;for(var f4G=0;f4G < e_n.length;f4G++){p1V=\"y\";p1V+=\"axisLH\";p1V+=\"S\";X24=e_n[f4G];X4i(X24,p1V);X4i(X24,\"yaxisRHS\");}Q8l.chart.yAxis=Q8l.chart.panel.yAxis;function b$j(N5r){return !!N5r;}function X4i(Q0o,C8J){var G3O,r70,p64,F3X;if(!Q0o[C8J] || !Q0o[C8J].length){return;}G3O=r96[Q0o.name];if(!G3O){return;}r70=G3O[C8J];p64=new Array(r70.length);H0P.j1L();for(var q80=0;q80 < r70.length;q80++){F3X=Q0o[C8J].indexOf(r70[q80].name);if(F3X > -1){p64[F3X]=r70[q80];}else {p64.push(r70[q80]);}}if(p64.length){G3O[C8J]=p64.filter(b$j);}}}};d_w.ChartEngine.prototype.exportLayout=function(z9m){var W4h,U_N,R1N,P3a,F7u,l$5;W4h={};for(var a1r in this.layout){if(a1r != \"studies\" && a1r != \"panels\" && a1r != \"drawing\"){W4h[a1r]=d_w.clone(this.layout[a1r]);}else if(a1r == \"studies\"){W4h.studies={};}else if(a1r == \"panels\"){W4h.panels={};}}U_N=+\"0\";function J6v(x6T){var g7f;g7f=[];k_Cdw.j1L();for(var k1I=0;k1I < x6T.length;k1I++){g7f.push(x6T[k1I].name);}return g7f;}for(var x8M in this.panels){R1N=this.panels[x8M];if(R1N.exportable === ![])continue;P3a=W4h.panels[x8M]={};P3a.percent=R1N.percent;P3a.display=R1N.display;P3a.chartName=R1N.chart.name;P3a.soloing=R1N.soloing;P3a.index=U_N++;P3a.yAxis={name:R1N.yAxis.name,position:R1N.yAxis.position};if(R1N.yaxisLHS){P3a.yaxisLHS=J6v(R1N.yaxisLHS);}if(R1N.yaxisRHS){P3a.yaxisRHS=J6v(R1N.yaxisRHS);}}for(var N_7 in this.layout.studies){F7u=W4h.studies[N_7]={};l$5=this.layout.studies[N_7];F7u.type=l$5.type;F7u.inputs=d_w.clone(l$5.inputs);F7u.outputs=d_w.clone(l$5.outputs);F7u.panel=l$5.panel;F7u.parameters=d_w.clone(l$5.parameters);F7u.disabled=l$5.disabled;if(l$5.signalData){if(l$5.signalData.cloneForExport){F7u.signalData=l$5.signalData.cloneForExport();}else {F7u.signalData=d_w.clone(l$5.signalData);}}}if(z9m){W4h.symbols=this.getSymbols({\"include-parameters\":!!({}),\"exclude-studies\":!0,\"exclude-generated\":!!({})});if(W4h.symbols.length && W4h.symbols[0].symbolObject && W4h.symbols[0].symbolObject.static){delete W4h.symbols[0].symbolObject.static;}}else {delete W4h.symbols;}return W4h;};d_w.ChartEngine.prototype.importPreferences=function(a83){k_Cdw.y6g();var q4k;q4k=\"p\";q4k+=\"r\";q4k+=\"eferences\";d_w.extend(this.preferences,a83);if(a83.timeZone){this.setTimeZone(this.dataZone,a83.timeZone);}if(a83.language && d_w.I18N){d_w.I18N.localize(this,a83.language);}this.changeOccurred(q4k);};d_w.ChartEngine.prototype.exportPreferences=function(){k_Cdw.j1L();return this.preferences;};};g7=D8u=>{var Q_p=k_Cdw;var Q37,L73,N3q,G8q,m9T,l4S,r$O,y8i,b2L,c_v,n6c,h5p,A6L,V9k,T$R,e3N,p6h,m$S,K0N,e53,f7_;Q37=\"m\";Q37+=\"a\";L73=\"#\";L73+=\"b\";L73+=\"82c\";L73+=\"0c\";N3q=\"0 to\";N3q+=\" max\";G8q=\"Vo\";G8q+=\"lume Chart\";m9T=\"m\";m9T+=\"a\";l4S=\"#FF0\";l4S+=\"000\";r$O=\"f\";r$O+=\"ie\";r$O+=\"ld\";y8i=\"Expone\";y8i+=\"nt\";y8i+=\"ial\";b2L=\"Ex\";b2L+=\"po\";b2L+=\"n\";b2L+=\"ential\";c_v=\"W\";c_v+=\"eig\";c_v+=\"ht\";c_v+=\"ed\";n6c=\"W\";n6c+=\"eig\";n6c+=\"hted\";h5p=\"VID\";h5p+=\"YA\";A6L=\"V\";A6L+=\"I\";A6L+=\"DY\";Q_p.j1L();A6L+=\"A\";V9k=\"wel\";V9k+=\"les wilder\";T$R=\"triang\";T$R+=\"ular\";e3N=\"exp\";e3N+=\"onential\";p6h=\"si\";p6h+=\"mple\";m$S=\"a\";m$S+=\"u\";m$S+=\"to\";K0N=\"u\";K0N+=\"n\";K0N+=\"defin\";K0N+=\"ed\";e53=typeof _CIQ !== K0N?_CIQ:D8u.CIQ;f7_=typeof _timezoneJS !== \"undefined\"?_timezoneJS:D8u.timezoneJS;if(e53.ChartEngine){e53.ChartEngine.prototype.rightClickOverlay=function(m4K,C3h){var k4l;if(this.runPrepend(\"rightClickOverlay\",arguments)){return;}k4l=this.overlays[m4K];if(k4l.editFunction){k4l.editFunction(C3h);}else {this.removeOverlay(m4K);}this.runAppend(\"rightClickOverlay\",arguments);};e53.ChartEngine.prototype.addOverlay=function(r2J){if(this.runPrepend(\"addOverlay\",arguments)){return;}Q_p.y6g();this.overlays[r2J.name]=r2J;this.runAppend(\"addOverlay\",arguments);};e53.ChartEngine.prototype.removeOverlay=function(F3f){var j9c,u$K,z8p,J2K,J9T;if(this.runPrepend(\"removeOverlay\",arguments)){return;}j9c=this.overlays[F3f];Q_p.j1L();if(j9c){for(var j5b in this.overlays){u$K=\"Fi\";u$K+=\"eld\";z8p=this.overlays[j5b];J2K=[u$K];if(e53.Studies){J2K=e53.Studies.getFieldInputs(z8p);}for(var g1z=+\"0\";g1z < J2K.length;g1z++){if(j9c.outputMap[z8p.inputs[J2K[g1z]]]){this.removeOverlay(z8p.name);}}}this.cleanupRemovedStudy(j9c);J9T=this.panels[j9c.panel];delete this.overlays[F3f];this.checkForEmptyPanel(j9c.panel);}if(!this.currentlyImporting){this.displaySticky();this.createDataSet();this.changeOccurred(\"layout\");}this.resetDynamicYAxis();this.runAppend(\"removeOverlay\",arguments);};e53.ChartEngine.prototype.cleanupRemovedStudy=function(p30){if(!p30){return;}if(p30.study.removeFN){p30.study.removeFN(this,p30);}for(var H52 in this.plugins){if(H52.indexOf((+\"7273\" === 3740?(\"6.17e+3\" * 1,\"c\"):\"{\") + p30.id + \"}\") > -1){delete this.plugins[H52];}}if(p30.removeSignals){p30.removeSignals();}if(this.layout.studies){delete this.layout.studies[p30.name];}this.chart.state.studies.sorted=null;delete this.overlays[p30.name];var {sd:v03}=this.repositioningAnchorSelector || ({});if(v03 && v03 === p30){this.repositioningAnchorSelector=null;var {anchorHandles:N1J}=this.controls;if(N1J && N1J[p30.uniqueId]){N1J[p30.uniqueId].highlighted=![];e53.Studies.displayAnchorHandleAndLine(this,p30,this.chart.dataSegment);}}if(e53.Studies){e53.Studies.removeStudySymbols(p30,this);}if(this.quoteDriver){this.quoteDriver.updateSubscriptions();}};}e53.Studies=e53.Studies || (function(){});e53.Studies.DEFAULT_INPUTS={Period:14};e53.Studies.DEFAULT_OUTPUTS={Result:m$S};e53.Studies.impliedVolatilityAvailable=!\"1\";e53.Studies.sortForProcessing=R04=>{var J3Y,N_o;J3Y=[];N_o=R04.layout.studies;Q_p.j1L();function C1O(G0v,o4c){G0v.forEach(B9g=>{var n_7;if(o4c.indexOf(B9g) == -1){n_7=B9g.getDependents(R04);if(n_7.length){C1O(n_7,o4c);}o4c.unshift(B9g);}});}if(N_o){C1O(Object.values(N_o),J3Y);}return J3Y;};e53.Studies.StudyDescriptor=function(r0a,H_L,h5X,c$p,J8X,X76){var Y08,l$t,E$p;Y08=\"undef\";Y08+=\"in\";Y08+=\"ed\";this.name=r0a;this.disabled=!!\"\";this.type=H_L;this.panel=h5X;this.inputs=c$p;this.outputs=J8X;this.parameters=X76;this.outputMap={};this.min=null;this.max=null;this.startFrom=0;this.subField=\"Close\";l$t=e53.Studies.studyLibrary[H_L];if(!l$t){E$p=\"c\";E$p+=\"h\";E$p+=\"art\";l$t={};if(h5X == \"chart\" || !h5X && X76 && X76.chartName == E$p){this.overlay=!\"\";}}if(typeof l$t.inputs == \"undefined\"){l$t.inputs=e53.clone(e53.Studies.DEFAULT_INPUTS);}if(typeof l$t.outputs == Y08){l$t.outputs=e53.clone(e53.Studies.DEFAULT_OUTPUTS);}this.study=l$t;this.libraryEntry=l$t;};e53.Studies.StudyDescriptor.prototype.toggleDisabledState=function(Z8_){var {disabled:B9C, study:C6K, signalData:s3p}=this;this.disabled=B9C=!B9C;if(!B9C){this.startFrom=0;this.error=null;if(C6K && C6K.calculateFN){C6K.calculateFN(Z8_,this);}if(this.flagSignals){this.flagSignals();}Z8_.draw();}if(s3p){s3p[B9C?\"hide\":\"show\"]();}};e53.Studies.StudyDescriptor.prototype.getYAxis=function(U$b){var J0Q,I_5,d7E;J0Q=this.yAxis;if(this.parameters){I_5=this.parameters.yaxisDisplayValue;}if(!J0Q){d7E=U$b.panels[this.panel];if(d7E){J0Q=U$b.getYAxisByName(d7E,I_5) || U$b.getYAxisByName(d7E,this.name) || d7E.yAxis;}}if(!J0Q){J0Q=U$b.getYAxisByName(U$b.chart.panel,I_5) || U$b.chart.panel.yAxis;}Q_p.y6g();return J0Q;};e53.Studies.StudyDescriptor.prototype.getContext=function(a_P){Q_p.y6g();return a_P.chart.context;};e53.Studies.StudyDescriptor.prototype.getDependents=function(d9Y,L8i){var z8J,v1C,V3M;z8J=[];for(var q_F in d9Y.layout.studies){v1C=d9Y.layout.studies[q_F];if(v1C == this)continue;V3M=e53.Studies.getFieldInputs(v1C);for(var p5z=0;p5z < V3M.length;p5z++){if(v1C.inputs[V3M[p5z]].includes(this.name)){if(L8i && v1C.parameters && v1C.parameters.panelName)continue;z8J.push(v1C);z8J=z8J.concat(v1C.getDependents(d9Y,L8i));break;}}}return z8J;};e53.Studies.StudyDescriptor.prototype.undraggable=function(c0y){var C_9;if(this.signalData){return !!\"1\";}C_9=this.study.attributes;Q_p.j1L();if(C_9){if(C_9.panelName && C_9.panelName.hidden){return !![];}if(C_9.yaxisDisplayValue && C_9.yaxisDisplayValue.hidden){return !!1;}}return ![];};e53.Studies.StudyDescriptor.prototype.appendFutureTicks=function(T9L,k5H){Q_p.y6g();var G9O,I_W,y6o,q0Y;G9O=T9L.chart.scrubbed;if(!G9O.length){return;}I_W=T9L.standardMarketIterator(G9O[G9O.length - (\"1\" >> 32)].DT);for(y6o=k5H.length - 1;y6o >= 0;y6o--){q0Y=k5H[y6o];for(var z3s in q0Y){if(q0Y[z3s] || q0Y[z3s] === 0){Q_p.b8R(3);y6o=-Q_p.F9v(\"1\",1);break;}}if(y6o == -1)break;k5H.pop();}for(y6o=+\"0\";y6o < k5H.length;y6o++){q0Y=k5H[y6o];if(!q0Y.DT){q0Y.DT=I_W.next();}if(!q0Y.displayDate){T9L.setDisplayDate(q0Y);}q0Y.futureTick=!!\"1\";G9O.push(q0Y);}};e53.Studies.generateID=function(m$T,B$L,r32,W6e,x2W){var Q3v,Z4q,d_i,p9w,Z9n,K7Q,T0C;Q3v=e53.Studies.studyLibrary[B$L];Q_p.b8R(14);Z4q=Q_p.F9v(\"\\u200c\",\"\\u200c\",x2W || B$L);d_i=Z4q;if(Q3v){if(Q3v.customRemoval){return d_i;}}if(!e53.isEmpty(r32)){p9w=!0;for(var P3J in r32){if([\"id\",\"display\",\"Shading\",\"Anchor Selector\"].includes(P3J)){continue;}Z9n=r32[P3J];if(Z9n == \"field\")continue;Z9n=Z9n.toString();if(e53.Studies.prettify[Z9n] !== undefined){Z9n=e53.Studies.prettify[Z9n];}if(p9w){K7Q=\" \";K7Q+=\"(\";p9w=!({});d_i+=K7Q;}else {if(Z9n){d_i+=587.81 >= 2160?7.50e+1:\",\";}}d_i+=Z9n;}if(!p9w){d_i+=(4220,100.8) >= (4487,6390)?(\"X\",!!({})):2430 > (\"3970\" | 2,2364)?\")\":(\"964.81\" - 0,617) !== (3594,6690)?(+\"0x3ad\",0x1e58):467.81;}}if(W6e && W6e.indexOf(d_i) === +\"0\"){return W6e;}if(m$T.layout.studies && m$T.layout.studies[d_i]){for(var S28=+\"2\";S28 < 50;S28++){Q_p.G4m(14);T0C=Q_p.e7l(d_i,S28,\"-\");if(!m$T.layout.studies[T0C]){d_i=T0C;break;}}}return d_i;};e53.Studies.DialogHelper=function(r23){var S84,S8S,r4z,O7T,b2z,a$B,o_m,K1Q,L_Z,z72,d0H,c46,G1b,N$h,f_B,A5B,H7F,I5S,J4D,e1A,y$M,W_L,G9C,T5n,j6i,E32,m4z,L0O,i$H,d3O,r1h,m4j,Y5W,Z4C,c_H,F46,L0C,S4Q,v3h,v$F,g_f;S84=this.stx=r23.stx;S8S=this.sd=r23.sd;this.name=S8S?S8S.type:r23.name;this.signal=+\"1\";this.inputs=[];this.outputs=[];this.parameters=[];r4z=this.libraryEntry=S8S?S8S.study:e53.Studies.studyLibrary[r23.name];if(typeof r4z.inputs == \"undefined\"){r4z.inputs=e53.clone(e53.Studies.DEFAULT_INPUTS);}if(typeof r4z.outputs == \"undefined\"){r4z.outputs=e53.clone(e53.Studies.DEFAULT_OUTPUTS);}function j3S(O5T){var Z30,m5J,A4_,V$g;Z30=\"sel\";Z30+=\"ect\";m5J={};A4_=O5T.defaults;Q_p.y6g();V$g={name:O5T.name,heading:S84.translateIf(O5T.label),defaultValue:A4_[0],value:O5T.value,options:m5J,type:Z30};for(var k$8=0;k$8 < A4_.length;k$8++){m5J[A4_[k$8]]=S84.translateIf(A4_[k$8]);}if(O5T.color !== undefined){V$g.defaultColor=S84.defaultColor;V$g.color=O5T.color;}return V$g;}O7T=S8S && S84.panels[S8S.panel]?S84.panels[S8S.panel]:S84.chart.panel;b2z=O7T.chart;this.title=S84.translateIf(r4z.name);this.attributes=e53.clone(r4z.attributes);if(!this.attributes){this.attributes={};}function O4T(m06,J2U){var d3h;d3h=this;if(!d3h.attributes[m06]){d3h.attributes[m06]={};}if(J2U){d3h.attributes[m06].hidden=!!({});}}for(var H7d in this.attributes){a$B=this.attributes[H7d];for(var d06 in a$B){if(typeof a$B[d06] == \"function\"){a$B[d06]=a$B[d06].call(S8S);}}}o_m=[];K1Q=S84.layout.studies;L_Z=[];Q_p.y6g();function b$w(u5W){var S0Y;S0Y={name:u5W.name,heading:S84.translateIf(u5W.label),defaultValue:u5W.defaults,value:u5W.value,type:\"checkbox\"};return S0Y;}if(S8S){L_Z=Array.prototype.concat(S8S,S8S.getDependents(S84));}for(var B$D in K1Q){if(K1Q[B$D].signalData)continue;if(L_Z.indexOf(K1Q[B$D]) > -1)continue;for(var k6T in K1Q[B$D].outputMap){o_m.push(k6T);}}for(var T5f in r4z.inputs){z72={};this.inputs.push(z72);z72.name=T5f;z72.heading=S84.translateIf(T5f);d0H=r4z.inputs[T5f];if(S8S && S8S.inputs && typeof S8S.inputs[T5f] != \"undefined\" && S8S.inputs[T5f] !== null){z72.value=S8S.inputs[T5f];}else {z72.value=r4z.inputs[T5f];}z72.defaultInput=r4z.inputs[T5f];if(!this.attributes[T5f]){this.attributes[T5f]=e53.Studies.inputAttributeDefaultGenerator(z72.defaultInput);}if(d0H.constructor == Number){z72.type=\"number\";}else if(d0H.constructor == String){c46=e53.Studies.movingAverageHelper(S84,z72.defaultInput);if(c46){z72.type=\"select\";z72.defaultInput=c46;G1b=e53.Studies.movingAverageHelper(S84,z72.value);if(!G1b){G1b=z72.value;}z72.value=G1b;z72.options=e53.Studies.movingAverageHelper(S84,\"options\");}else if(d0H == \"field\"){N$h=\"f\";N$h+=\"i\";N$h+=\"eld\";f_B=\"h\";f_B+=\"lcc/4\";A5B=\"L\";A5B+=\"ow\";z72.type=\"select\";z72.options={};H7F=[\"Open\",\"High\",A5B,\"Close\",\"Adj_Close\",\"hl/2\",\"hlc/3\",f_B,\"ohlc/4\",b2z.defaultPlotField].concat(o_m);for(var W7k=0;W7k < H7F.length;W7k++){I5S=H7F[W7k];z72.options[I5S]=S84.translateIf(I5S);}if(z72.value == N$h){z72.value=\"Close\";}if(z72.defaultInput == \"field\"){J4D=\"C\";J4D+=\"lose\";z72.defaultInput=J4D;}}else {e1A=\"h\";e1A+=\"h:\";e1A+=\"mm:ss\";y$M=\"yy\";y$M+=\"yy\";y$M+=\"-m\";y$M+=\"m-dd\";z72.type=\"text\";if(this.attributes[T5f].placeholder == y$M){z72.type=\"date\";}else if(this.attributes[T5f].placeholder == e1A){z72.type=\"time\";}}}else if(d0H.constructor == Boolean){W_L=\"tr\";W_L+=\"u\";W_L+=\"e\";z72.type=\"checkbox\";if(z72.value === !0 || z72.value == W_L || z72.value == \"on\"){z72.value=!!({});}}else if(d0H.constructor == Array){G9C=\"s\";G9C+=\"el\";G9C+=\"ec\";G9C+=\"t\";z72.type=G9C;z72.options={};for(var W_N=0;W_N < d0H.length;W_N++){z72.options[d0H[W_N]]=S84.translateIf(d0H[W_N]);}if(z72.value.constructor == Array){z72.value=z72.value[0];}if(this.attributes[T5f].defaultSelected){z72.defaultInput=this.attributes[T5f].defaultSelected;}else {z72.defaultInput=d0H[0];}}}this.dateTimeInputs=[];for(var R03=0;R03 < this.inputs.length;R03++){T5n=this.inputs[R03];if(T5n.type == \"date\"){j6i=\" D\";j6i+=\"a\";j6i+=\"t\";j6i+=\"e\";Q_p.G4m(1);E32=T5n.name.substring(Q_p.e7l(\"0\",0),T5n.name.indexOf(j6i));for(var M2Z=0;M2Z < this.inputs.length;M2Z++){m4z=this.inputs[M2Z];if(m4z.type == \"time\"){if(m4z.name == E32 + \" Time\"){this.dateTimeInputs.push(E32);break;}}}}}this.adjustInputTimesForDisplayZone();for(T5f in r4z.outputs){L0O={name:T5f,heading:S84.translateIf(T5f)};L0O.color=L0O.defaultOutput=r4z.outputs[T5f];if(S8S && S8S.outputs && S8S.outputs[T5f]){L0O.color=S8S.outputs[T5f];}if(L0O.color == \"auto\"){L0O.color=S84.defaultColor;}this.outputs.push(L0O);}function s1K(o0K){Q_p.y6g();var d6l;if(Z4C == \"alias\"){d6l=1;for(var E08 in S84.panels){if(E08 == o0K){return K8v(E08,d6l);}d6l++;}}function K8v(t8M,o8C){Q_p.y6g();return \"Panel \" + o8C.toString();}return o0K;}i$H=S8S?S8S.parameters:null;if(r4z.parameters){d3O=r4z.parameters.init;if(d3O){if(d3O.studyOverZonesEnabled !== undefined){r1h={name:\"studyOverZones\",heading:S84.translateIf(\"Show Zones\"),defaultValue:d3O.studyOverZonesEnabled,value:d3O.studyOverZonesEnabled};if(i$H && (i$H.studyOverZonesEnabled || i$H.studyOverZonesEnabled === !\"1\")){r1h.value=i$H.studyOverZonesEnabled;}r1h.type=\"checkbox\";this.parameters.push(r1h);}if(d3O.studyOverBoughtValue !== undefined){m4j=\"s\";m4j+=\"t\";m4j+=\"udyOverBoug\";m4j+=\"ht\";r1h={name:m4j,heading:S84.translateIf(\"OverBought\"),defaultValue:d3O.studyOverBoughtValue,value:d3O.studyOverBoughtValue,defaultColor:d3O.studyOverBoughtColor,color:d3O.studyOverBoughtColor};if(i$H && i$H.studyOverBoughtValue){r1h.value=i$H.studyOverBoughtValue;}if(i$H && i$H.studyOverBoughtColor){r1h.color=i$H.studyOverBoughtColor;}if(r1h.color == \"auto\"){r1h.color=S84.defaultColor;}r1h.type=\"text\";this.parameters.push(r1h);}if(d3O.studyOverSoldValue !== undefined){Y5W=\"OverS\";Y5W+=\"o\";Y5W+=\"ld\";r1h={name:\"studyOverSold\",heading:S84.translateIf(Y5W),defaultValue:d3O.studyOverSoldValue,value:d3O.studyOverSoldValue,defaultColor:d3O.studyOverSoldColor,color:d3O.studyOverSoldColor};if(i$H && i$H.studyOverSoldValue){r1h.value=i$H.studyOverSoldValue;}if(i$H && i$H.studyOverSoldColor){r1h.color=i$H.studyOverSoldColor;}if(r1h.color == \"auto\"){r1h.color=S84.defaultColor;}r1h.type=\"text\";this.parameters.push(r1h);}if(!this.attributes.studyOverBoughtValue){this.attributes.studyOverBoughtValue={};}if(!this.attributes.studyOverSoldValue){this.attributes.studyOverSoldValue={};}}}Z4C=this.panelSelect=r23.panelSelect;c_H=this.axisSelect=r23.axisSelect;if(r23.addWhenDone){c_H=Z4C=!1;}if(c_H || Z4C){F46=\"yaxisDis\";F46+=\"playValue\";L0C=\"underlayEnabl\";L0C+=\"e\";L0C+=\"d\";if(!S8S){S8S=e53.Studies.addStudy(S84,r23.name,null,null,{calculateOnly:!!({})});e53.Studies.removeStudy(S84,S8S);}if(Z4C){S4Q=\"P\";S4Q+=\"an\";S4Q+=\"e\";S4Q+=\"l\";this.parameters.push(j3S({label:S4Q,name:\"panelName\",defaults:(function(){var e_c;e_c=[];e_c.push(\"Auto\");for(var c6L in S84.panels){if(c6L != S8S.panel || !i$H || !i$H.panelName)if(!S84.panels[c6L].noDrag){e_c.push(s1K(c6L));}}if(!S84.checkForEmptyPanel(S8S.panel,!!({}),S8S)){e_c.push(\"New panel\");}return e_c;})(),value:i$H && i$H.panelName?s1K(i$H.panelName):\"Auto\"}),b$w({label:\"Show as Underlay\",name:\"underlay\",defaults:!({}),value:S8S.underlay || S8S.parameters && S8S.parameters.underlayEnabled}));}v3h=S84.getYAxisByName(O7T,S8S.name);if(c_H){v$F=\"I\";v$F+=\"nve\";v$F+=\"rt Y-Axi\";v$F+=\"s\";g_f=\"Y-\";g_f+=\"Axis\";this.parameters.push(j3S({label:g_f,name:\"yaxisDisplay\",defaults:(function(){var d4p,o55,Z06,b0S;d4p=\"non\";d4p+=\"e\";o55=\"l\";Q_p.j1L();o55+=\"e\";o55+=\"ft\";Z06=O7T.yaxisLHS.concat(O7T.yaxisRHS);b0S=[];b0S.push(\"default\",\"right\",o55,d4p,\"shared\");for(var X8w=0;X8w < Z06.length;X8w++){if(Z06[X8w] != v3h){b0S.push(Z06[X8w].name);}}return b0S;})(),value:i$H && i$H.yaxisDisplayValue || v3h && v3h.position || (!v3h?\"shared\":\"default\"),color:v3h && v3h.textStyle?v3h.textStyle:\"auto\"}),b$w({label:v$F,name:\"flipped\",defaults:!1,value:i$H && i$H.flippedEnabled !== undefined?i$H.flippedEnabled:v3h?v3h.flipped:![]}));}O4T.call(this,\"flippedEnabled\",!v3h && S8S.panel != S8S.name);O4T.call(this,L0C,r4z.underlay);O4T.call(this,\"panelName\",r4z.seriesFN === null);O4T.call(this,F46,r4z.seriesFN === null || r4z.yAxis && r4z.yAxis.noDraw);}};e53.Studies.DialogHelper.prototype.updateStudy=function(i7P){var D5h,R7N,z$e,C2B;D5h={};R7N=this.sd;function u06(E7T){var N16,l_c,u$n,w0a,V9n;function V3h(f5q){var S7o;S7o=f5q.match(/.{0,50} (\\d)/);Q_p.y6g();return S7o && S7o[1];}Q_p.j1L();N16=-607695613;l_c=1982850919;u$n=2;for(var w_R=1;Q_p.P6(w_R.toString(),w_R.toString().length,98600) !== N16;w_R++){w0a=this;u$n+=2;}if(Q_p.P6(u$n.toString(),u$n.toString().length,48457) !== l_c){w0a=this;}w0a=this;if(w0a.panelSelect == \"alias\"){V9n=V3h(E7T);if(V9n){for(var c2i in w0a.stx.panels){if(!--V9n){return c2i;}}}}return E7T;}z$e=this.libraryEntry;if(!z$e){z$e={};}if(!R7N){R7N=z$e;}D5h.inputs=e53.clone(R7N.inputs);D5h.outputs=e53.clone(R7N.outputs);D5h.parameters=e53.clone(R7N.parameters);this.adjustInputTimesForDisplayZone(i7P);Q_p.y6g();if(i7P.parameters && i7P.parameters.panelName){i7P.parameters.panelName=u06.call(this,i7P.parameters.panelName);}e53.extend(D5h,i7P);if(!D5h.parameters){D5h.parameters={};}if(D5h.inputs && D5h.inputs.id){R7N=e53.Studies.replaceStudy(this.stx,D5h.inputs.id,this.name,D5h.inputs,D5h.outputs,D5h.parameters,null,R7N.study);}else {R7N=e53.Studies.addStudy(this.stx,this.name,D5h.inputs,D5h.outputs,D5h.parameters,null,R7N.study);}C2B=new e53.Studies.DialogHelper({stx:this.stx,sd:R7N,axisSelect:this.axisSelect,panelSelect:this.panelSelect});for(var D2i in C2B){if(D2i != \"signal\"){this[D2i]=C2B[D2i];}}this.signal*=-1;};e53.Studies.DialogHelper.prototype.adjustInputTimesForDisplayZone=function(l0L){var y52,K$2,B6u,O3P,p$8,p3p,l9Y,y_e,N_e,J9H,e84,m7j;if(this.stx.displayZone){for(var t1h=+\"0\";t1h < this.dateTimeInputs.length;t1h++){y52=this.dateTimeInputs[t1h];p3p=\"\";if(l0L && l0L.inputs){l9Y=\" D\";l9Y+=\"a\";l9Y+=\"t\";l9Y+=\"e\";Q_p.G4m(0);B6u=l0L.inputs[Q_p.e7l(y52,l9Y)];Q_p.b8R(0);O3P=l0L.inputs[Q_p.e7l(y52,\" Time\")];if(B6u){p3p=B6u;}if(O3P){p3p+=O3P;}}for(K$2=0;K$2 < this.inputs.length;K$2++){y_e=\" \";y_e+=\"D\";y_e+=\"at\";y_e+=\"e\";p$8=this.inputs[K$2];if(!B6u && B6u !== \"\" && p$8.name == y52 + y_e){p3p=p$8.value + p3p;}else if(!O3P && O3P !== \"\" && p$8.name == y52 + \" Time\"){p3p+=p$8.value;}}p3p=p3p.replace(/\\D/g,\"\");if(p3p.length < 12){return;}N_e=e53.strToDateTime(p3p);if(!isNaN(N_e.valueOf())){if(l0L){e84=\" D\";e84+=\"ate\";if(!l0L.inputs){l0L.inputs={};}J9H=e53.convertTimeZone(N_e,this.stx.displayZone);Q_p.G4m(0);l0L.inputs[Q_p.F9v(y52,e84)]=e53.yyyymmdd(J9H);Q_p.G4m(0);l0L.inputs[Q_p.F9v(y52,\" Time\")]=e53.hhmmss(J9H);}else {J9H=e53.convertTimeZone(N_e,null,this.stx.displayZone);for(K$2=0;K$2 < this.inputs.length;K$2++){m7j=\" D\";m7j+=\"a\";m7j+=\"t\";m7j+=\"e\";p$8=this.inputs[K$2];if(p$8.name == y52 + m7j){p$8.value=e53.yyyymmdd(J9H);}if(p$8.name == y52 + \" Time\"){p$8.value=e53.hhmmss(J9H);}}}}}}};e53.Studies.prepareStudy=function(L1p,m8c,s8G){Q_p.y6g();var I2C;I2C=\"und\";I2C+=\"efi\";I2C+=\"ned\";if(typeof m8c.calculateFN == I2C){m8c.useRawValues=!0;}if(e53.isEmpty(s8G.outputMap)){for(var P3n in s8G.outputs){if(m8c.useRawValues){s8G.outputMap[P3n]=P3n;}else {Q_p.b8R(18);var f1x=Q_p.e7l(6,7840,7050);Q_p.b8R(17);var n5f=Q_p.e7l(576,6,0);Q_p.b8R(81);var g3W=Q_p.e7l(117,11,11,13,16763);Q_p.G4m(4);var P95=Q_p.F9v(19535,15628);Q_p.G4m(60);var q9f=Q_p.F9v(20994,7002,4,12,18);Q_p.b8R(4);var r6i=Q_p.e7l(2376,18);Q_p.b8R(36);var X8G=Q_p.e7l(6,3264,296);Q_p.b8R(60);var i$K=Q_p.F9v(117281,6884,18,20,5);s8G.outputMap[P3n + (f1x == (n5f,g3W)?(\"l\",419.53):P95 < q9f?r6i != X8G?\" \":(i$K,!\"1\"):636.43) + s8G.name]=P3n;}}}};e53.Studies.rejiggerDerivedStudies=function(q5F,J7Q,t2c){var j7G,k3t,t97,m$R,x$c,F5a,d3b,p4w,K4p;j7G=J7Q.name;k3t=J7Q.panel;t97=J7Q.getDependents(q5F);for(var U0G=0;U0G < t97.length;U0G++){m$R=t97[U0G];x$c=e53.clone(m$R.inputs);F5a=x$c.id;if(!F5a)continue;d3b=![];p4w=e53.Studies.getFieldInputs(m$R);for(var K8L=\"0\" - 0;K8L < p4w.length;K8L++){x$c[p4w[K8L]]=x$c[p4w[K8L]].replace(j7G,t2c);}K4p=e53.Studies.replaceStudy(q5F,F5a,m$R.type,x$c,m$R.outputs,e53.extend(m$R.parameters,{rejiggering:!0}),null,m$R.study);delete K4p.parameters.rejiggering;}};e53.Studies.removeStudySymbols=function(K8N,K_z){Q_p.j1L();if(K8N.series){for(var T0Z in K8N.series){K_z.deleteSeries(K8N.series[T0Z],null,{action:\"remove-study\"});}}};e53.Studies.replaceStudy=function(p$4,H0l,B9z,q5a,Z09,V0R,f4B,N_X){var j1a,x6U,b8g,D4t;if(!V0R){V0R={};}if(H0l){V0R.replaceID=H0l;}H0l=V0R.replaceID;j1a=p$4.layout.studies[H0l];e53.Studies.removeStudySymbols(j1a,p$4);if(j1a.attribution){p$4.removeFromHolder(j1a.attribution.marker);}if(p$4.quoteDriver){p$4.quoteDriver.updateSubscriptions();}if(q5a){if(q5a.id == q5a.display){delete q5a.display;}delete q5a.id;}x6U=e53.Studies.addStudy(p$4,B9z,q5a,Z09,V0R,f4B,N_X);x6U.highlight=j1a.highlight;x6U.uniqueId=j1a.uniqueId;if(j1a.signalData){x6U.signalData=j1a.signalData;if(x6U.signalData.updateConditions){x6U.signalData.updateConditions(H0l,x6U.inputs.id);}}Q_p.j1L();D4t={};for(b8g in p$4.layout.studies){if(b8g == H0l){D4t[x6U.name]=x6U;}else {D4t[b8g]=p$4.layout.studies[b8g];}}p$4.layout.studies=D4t;D4t={};for(b8g in p$4.overlays){if(b8g == H0l){if(x6U.overlay || x6U.underlay){D4t[x6U.name]=x6U;}}else {D4t[b8g]=p$4.overlays[b8g];}}p$4.overlays=D4t;if(!p$4.overlays[x6U.name] && (x6U.overlay || x6U.underlay)){p$4.addOverlay(x6U);}p$4.checkForEmptyPanel(j1a.panel);if(!V0R.rejiggering){p$4.initializeDisplay(p$4.chart);e53.Studies.rejiggerDerivedStudies(p$4,j1a,x6U.inputs.id,x6U.panel);}e53.transferObject(j1a,x6U);p$4.layout.studies[x6U.name]=j1a;p$4.overlays[x6U.name]=j1a;p$4.chart.state.studies.sorted=null;if(!V0R.rejiggering){p$4.changeOccurred(\"layout\");if(!j1a.currentlyImporting && !V0R.calculateOnly && j1a.chart.dataSet){p$4.createDataSet(null,j1a.chart);}p$4.draw();}return j1a;};e53.Studies.addStudy=function(j3h,j5h,G4R,q9Q,n5a,Q1N,h$s){var Y7R,I$M,u61,z$P,L8c,W17,s40,L3X,o8_,m2u,U3C,T$K,h2J,Q9Z,I5V;Y7R=h$s?h$s:e53.Studies.studyLibrary[j5h];if(!n5a){n5a={};}if(Y7R){if(Y7R.inputs){I$M=e53.clone(Y7R.inputs);for(var t_R in I$M){if(I$M[t_R] instanceof Array){if(Y7R.attributes && Y7R.attributes[t_R] && Y7R.attributes[t_R].defaultSelected){I$M[t_R]=Y7R.attributes[t_R].defaultSelected;}else {Q_p.b8R(63);I$M[t_R]=I$M[t_R][Q_p.F9v(\"0\",0)];}}}G4R=e53.extend(I$M,G4R);}if(Y7R.outputs){q9Q=e53.extend(e53.clone(Y7R.outputs),q9Q);}u61=Y7R.parameters;if(u61 && u61.init){n5a=e53.extend(e53.clone(u61.init),n5a);}if(u61 && !n5a.display){z$P=-885502145;L8c=1097311533;W17=2;for(var G0Y=1;Q_p.m1(G0Y.toString(),G0Y.toString().length,41627) !== z$P;G0Y++){n5a.display=u61.display;Q_p.b8R(4);W17+=Q_p.e7l(\"2\",0);}if(Q_p.P6(W17.toString(),W17.toString().length,28277) !== L8c){n5a.display=u61.display;}}}if(!G4R){G4R=e53.clone(e53.Studies.DEFAULT_INPUTS);}if(!q9Q){q9Q=e53.clone(e53.Studies.DEFAULT_OUTPUTS);}if(!n5a.chartName){n5a.chartName=\"chart\";}if(n5a.panelName == \"Auto\" || n5a.panelName == \"Default panel\"){n5a.panelName=\"\";}if(G4R.Period < 1){Q_p.G4m(34);G4R.Period=Q_p.F9v(\"1\",0);}s40=null;if(!j3h.layout.studies){j3h.layout.studies={};}if(Y7R && Y7R.initializeFN){s40=Y7R.initializeFN(j3h,j5h,G4R,q9Q,n5a,Q1N,h$s);}else {s40=e53.Studies.initializeFN(j3h,j5h,G4R,q9Q,n5a,Q1N,h$s);}if(!s40){Q_p.b8R(0);console.log(Q_p.F9v(\"CIQ.Studies.addStudy: initializeFN() returned null for \",j5h));return;}else if(s40 === \"abort\"){return;}Q_p.y6g();h$s=s40.study;s40.chart=j3h.charts[n5a.chartName];s40.type=j5h;s40.permanent=h$s.permanent;s40.customLegend=h$s.customLegend;s40.uniqueId=e53.uniqueID();e53.Studies.prepareStudy(j3h,h$s,s40);L3X=j3h.chart.state.studies;if(!L3X){L3X=j3h.chart.state.studies={};}L3X.sorted=null;if(!n5a.replaceID){j3h.layout.studies[s40.inputs.id]=s40;if(s40.overlay || s40.underlay){j3h.addOverlay(s40);}if(!j3h.currentlyImporting && !n5a.calculateOnly && s40.chart.dataSet){j3h.createDataSet(null,s40.chart);}}else {o8_=!![];delete n5a.replaceID;}if(j3h.quoteDriver){j3h.quoteDriver.updateSubscriptions();}if(n5a.calculateOnly){j3h.changeOccurred(\"layout\");return s40;}m2u=j3h.panels[s40.panel];U3C=!\"1\";T$K=!(s40.overlay || s40.underlay);if(T$K && h$s.horizontalCrosshairFieldFN){m2u.horizontalCrosshairField=h$s.horizontalCrosshairFieldFN(j3h,s40);}if(j3h.editCallback){U3C=!![];}else if(T$K){if(j3h.callbackListeners.studyPanelEdit && j3h.callbackListeners.studyPanelEdit.length){U3C=!\"\";}}else {if(j3h.callbackListeners.studyOverlayEdit && j3h.callbackListeners.studyOverlayEdit.length){U3C=!!1;}}if(U3C){n5a.editMode=!!({});h2J=!\"1\";for(var Q_1 in s40.inputs){if(Q_1 == \"id\")continue;if(Q_1 == \"display\")continue;h2J=!![];break;}if(!h2J){for(var R0A in s40.outputs){h2J=!![];break;}}if(h2J){if(typeof s40.study.edit != \"undefined\"){if(s40.study.edit){Q9Z=(function(w5d,B$R,c9q,J7L,p4V){return function(){Q_p.j1L();e53.clearCanvas(w5d.chart.tempCanvas,w5d);B$R.study.edit(B$R,{stx:w5d,inputs:c9q,outputs:J7L,parameters:p4V});};})(j3h,s40,G4R,q9Q,n5a);j3h.setPanelEdit(m2u,Q9Z);s40.editFunction=Q9Z;}}else if(!T$K){Q9Z=(function(K0x,s38,P5V,Y6D,U6L){return function(X6N){Q_p.y6g();var I2H;I2H=\"s\";I2H+=\"tudyOverlayEdit\";e53.clearCanvas(K0x.chart.tempCanvas,K0x);K0x.dispatch(I2H,{stx:K0x,sd:s38,inputs:P5V,outputs:Y6D,parameters:U6L,forceEdit:X6N});};})(j3h,s40,G4R,q9Q,n5a);s40.editFunction=Q9Z;}else {if(j3h.editCallback){Q9Z=(function(N0f,J1J,b0$,o1k,P4Q){Q_p.y6g();return function(){var L$c;Q_p.y6g();L$c=N0f.editCallback(N0f,J1J);e53.clearCanvas(N0f.chart.tempCanvas,N0f);e53.Studies.studyDialog(N0f,j5h,L$c,{inputs:b0$,outputs:o1k,parameters:P4Q});};})(j3h,s40,G4R,q9Q,n5a);if(m2u.name != \"chart\"){j3h.setPanelEdit(m2u,Q9Z);}}else {I5V=\"c\";I5V+=\"hart\";Q9Z=(function(H2H,i5Y,a5s,k1P,a6E){Q_p.j1L();return function(){e53.clearCanvas(H2H.chart.tempCanvas,H2H);Q_p.y6g();H2H.dispatch(\"studyPanelEdit\",{stx:H2H,sd:i5Y,inputs:a5s,outputs:k1P,parameters:a6E});};})(j3h,s40,G4R,q9Q,n5a);if(m2u.name != I5V){j3h.setPanelEdit(m2u,Q9Z);s40.editFunction=Q9Z;}}}}}j3h.changeOccurred(\"layout\");if(!o8_){j3h.draw();}return s40;};e53.Studies.removeStudy=function(L$$,w4n){var A5X,h8G,E9z,A2O;Q_p.y6g();A5X=L$$.panels[w4n.panel];h8G=A5X && A5X.yAxis.name;if(w4n.overlay || w4n.underlay){L$$.removeOverlay(w4n.name);}E9z=L$$.panels[w4n.panel];if(w4n.attribution){L$$.removeFromHolder(w4n.attribution.marker);}L$$.cleanupRemovedStudy(w4n);if(E9z && !L$$.checkForEmptyPanel(E9z)){if(h8G == w4n.name){L$$.electNewPanelOwner(E9z);}A2O=L$$.getYAxisByName(w4n.panel,w4n.name);if(A2O){A2O.name=A2O.studies[1] || A2O.renderers[0];}}L$$.draw();L$$.resizeChart();};e53.Studies.getPanelFromFieldName=function(d3$,Y_6){var v8k,d02,M3y,L1i,S81,D5q,k3X,k4X;v8k=1508778999;d02=342854718;M3y=2;for(var u3X=+\"1\";Q_p.m1(u3X.toString(),u3X.toString().length,88579) !== v8k;u3X++){L1i=e53.Studies.getFieldInputs(Y_6);if(+L1i.length){return 1;}M3y+=2;}if(Q_p.P6(M3y.toString(),M3y.toString().length,\"27891\" ^ 0) !== d02){L1i=e53.Studies.getFieldInputs(Y_6);if(!L1i.length){return null;}}S81=d3$.layout.studies;if(!S81){return null;}D5q={};for(var b19 in S81){for(var l4Q in S81[b19].outputMap){D5q[l4Q]=S81[b19].panel;}}Q_p.y6g();for(var U14=0;U14 < L1i.length;U14++){k3X=Y_6.inputs[L1i[U14]];if(k3X){k4X=D5q[k3X];if(k4X){return k4X;}}}return null;};e53.Studies.createLibraryHash=function(){Q_p.j1L();return Object.keys(e53.Studies.studyLibrary).join((910.53,85) !== (9236,9860)?3060 == 286.01?\"6.63e+3\" * 1:+\"4950\" <= (2490,4937)?(905.05,0x25bc):\"|\":(528.47,5.48e+3));};e53.Studies.displayStudies=function(T3g,u67,M$M){var b__,B9r,c_x,o8b,G5w,m17,D3e,o75,I6j,x8h,X5l,p9u,g2S,V9u;if(M$M){u67.studyLibraryHash=e53.Studies.createLibraryHash();}b__=T3g.layout.studies;if(!b__){return;}B9r={};B9r[u67.name]=!![];for(var d9V in b__){c_x=b__[d9V];o8b=c_x.study;if(!o8b)continue;if(c_x.disabled || c_x.signalData && !c_x.signalData.reveal)continue;G5w=c_x.underlay || c_x.parameters && c_x.parameters.underlayEnabled;if(M$M && !G5w || !M$M && G5w)continue;m17=e53.clone(o8b.renderer);if(m17 && !(m17 instanceof Array)){m17=[m17];}D3e=T3g.panels[c_x.panel];if(D3e){if(D3e.chart != u67)continue;if(D3e.hidden)continue;if(!B9r[D3e.name]){o75=c_x.permanent || !T3g.manageTouchAndMouse;if(D3e.closeX){if(o75){D3e.closeX.style.display=\"none\";}}else if(D3e.close){if(o75){D3e.close.style.display=\"none\";}}if(D3e.edit){if(o75){D3e.edit.style.display=\"none\";}}B9r[D3e.name]=o75;}}else {if(T3g.currentlyImporting){delete b__[d9V];}continue;}I6j=c_x.chart.dataSegment;if(c_x.panel == c_x.parameters.chartName && (!c_x.parameters || !c_x.parameters.panelName)){x8h=e53.Studies.getPanelFromFieldName(T3g,c_x);if(x8h && c_x.panel != x8h){c_x.panel=x8h;}}if(typeof o8b.seriesFN == \"undefined\"){if(m17){if(!c_x.overlay){e53.Studies.createYAxis(T3g,c_x,I6j,D3e);}for(var I8U=0;I8U < m17.length;I8U++){X5l=m17[I8U];for(var A86 in c_x.outputMap){if(c_x.outputMap[A86] == X5l.field){X5l.field=A86;}}if(!X5l.field)continue;X5l.panel=c_x.panel;p9u=X5l.binding;if(p9u){for(var O5l in p9u){g2S=e53.Studies.determineColor(c_x.outputs[p9u[O5l]]);if(g2S && g2S != \"auto\"){X5l[O5l]=g2S;}}}X5l.yAxis=null;V9u=e53.Renderer.produce(X5l.type,X5l);V9u.stx=T3g;V9u.attachSeries(null,X5l).draw();}}else {e53.Studies.displaySeriesAsLine(T3g,c_x,I6j);}if(D3e){e53.Studies.displayError(T3g,c_x);}}else {if(o8b.seriesFN){if(D3e){o8b.seriesFN(T3g,c_x,I6j);e53.Studies.displayError(T3g,c_x);}}}}};e53.Studies.displayError=function(T_o,u6m,w2h){var e99,i$W,P1C;e99=\"ce\";e99+=\"n\";e99+=\"t\";e99+=\"er\";Q_p.y6g();if(!u6m.error){return;}i$W=w2h && w2h.panel?w2h.panel:u6m.panel;P1C=u6m.error === !0?T_o.translateIf(\"Not enough data to compute \") + T_o.translateIf(u6m.study.name):T_o.translateIf(u6m.error);if(w2h && (w2h.h !== e99 || w2h.v !== \"bottom\")){T_o.watermark(i$W,w2h);return;}T_o.displayErrorAsWatermark(i$W,P1C);};e53.Studies.calculateMinMaxForDataPoint=function(B2Z,k$1,r3F){var K83,y1U,H6_;K83=Number.MAX_VALUE;Q_p.b8R(131);var D7G=Q_p.e7l(7,219,13,11);Q_p.j1L();y1U=Number.MAX_VALUE * D7G;for(var o2z=+\"0\";o2z < r3F.length;o2z++){H6_=r3F[o2z][k$1];if(H6_ === null || typeof H6_ == \"undefined\")continue;if(isNaN(H6_))continue;K83=Math.min(H6_,K83);y1U=Math.max(H6_,y1U);}return {min:K83,max:y1U};};e53.Studies.getYAxisParameters=function(r2b,p7F){var V0b,U1U,f24,z9v,f$a,Z_l,A_K,l3t;V0b={};Q_p.y6g();U1U=r2b.layout.studies && r2b.layout.studies[p7F.name];if(U1U){f24=U1U.study;if(f24.yaxis || f24.yAxisFN){V0b.noDraw=!![];}else {z9v=-705562405;f$a=1549366915;Z_l=+\"2\";for(var Y2w=1;Q_p.m1(Y2w.toString(),Y2w.toString().length,85539) !== z9v;Y2w++){if(f24.parameters && f24.parameters.excludeYAxis){V0b.noDraw=!\"\";}V0b.ground=f24.yAxis && f24.yAxis.ground;Z_l+=+\"2\";}if(Q_p.m1(Z_l.toString(),Z_l.toString().length,84279) !== f$a){if(f24.parameters || f24.parameters.excludeYAxis){V0b.noDraw=!\"1\";}V0b.ground=f24.yAxis || f24.yAxis.ground;}if(p7F){A_K=\"b\";A_K+=\"yp\";A_K+=\"as\";A_K+=\"s\";if(f24.range != A_K){if(f24.range == \"0 to 100\"){V0b.range=[0,100];}else if(f24.range == \"-1 to 1\"){V0b.range=[-1,1];}else {l3t=\"0 \";l3t+=\"to max\";if(f24.range == l3t){V0b.range=[0,Math.max(0,p7F.high)];}else if(f24.centerline || f24.centerline === 0){V0b.range=[Math.min(f24.centerline,p7F.low),Math.max(f24.centerline,p7F.high)];}}}if(V0b.range){p7F.low=V0b.range[0];p7F.high=V0b.range[+\"1\"];}if(U1U.min){p7F.min=U1U.min;}if(U1U.max){p7F.max=U1U.max;}if(U1U.parameters && U1U.parameters.studyOverZonesEnabled){V0b.noDraw=!0;}}}}return V0b;};e53.Studies.doPostDrawYAxis=function(I9G,n8U){var H72,L8A,e1m,k8E,j_8;Q_p.j1L();for(var e2e in I9G.layout.studies){H72=I9G.layout.studies[e2e];L8A=I9G.panels[H72.panel];if(!L8A || L8A.hidden)continue;e1m=H72.getYAxis(I9G);if(e1m != n8U)continue;k8E=H72.study;if(n8U.name == H72.name){if(k8E.yaxis){k8E.yaxis(I9G,H72);}if(k8E.yAxisFN){k8E.yAxisFN(I9G,H72);}}e53.Studies.drawZones(I9G,H72);if(!H72.error){j_8=k8E.centerline;if(j_8 || j_8 === 0 || j_8 !== null && n8U.highValue - 0.000000000001 > (\"0\" ^ 0) && n8U.lowValue + 0.000000000001 < +\"0\"){e53.Studies.drawHorizontal(I9G,H72,null,j_8 || +\"0\",n8U);}}}};e53.Studies.displaySeriesAsLine=function(x7s,Y5g,Q_B){var s5n;if(!Q_B.length){return;}Q_p.y6g();s5n=x7s.panels[Y5g.panel];if(!s5n || s5n.hidden){return;}for(var m8Z in Y5g.outputMap){e53.Studies.displayIndividualSeriesAsLine(x7s,Y5g,s5n,m8Z,Q_B);}};e53.Studies.displaySeriesAsHistogram=function(L_G,T0e,t1r){var P4k,f64,d4S,A2_,J4B,f5w,v4v,y$o,P7X,X52,A13;Q_p.y6g();if(!t1r.length){return;}P4k=L_G.panels[T0e.panel];if(!P4k){return;}if(P4k.hidden){return;}f64=[];for(var W24 in T0e.outputMap){d4S=T0e.outputs[T0e.outputMap[W24]];if(!d4S)continue;Q_p.b8R(4);A2_=Q_p.F9v(\"0.3\",0);if(typeof d4S == \"object\"){A2_=d4S.opacity;d4S=d4S.color;}J4B={field:W24,fill_color_up:d4S,border_color_up:d4S,fill_color_down:d4S,border_color_down:d4S};if(T0e.underlay){J4B.opacity_up=J4B.opacity_down=A2_ || 0.3;}f64.push(J4B);}f5w=T0e.getYAxis(L_G);v4v=T0e.inputs;y$o=v4v.WidthFactor;if(T0e.study && T0e.study.parameters){P7X=\"un\";P7X+=\"de\";P7X+=\"fine\";P7X+=\"d\";X52=T0e.study.parameters;if(typeof X52.widthFactor !== P7X){y$o=X52.widthFactor;}}A13={name:T0e.name,type:v4v.HistogramType?v4v.HistogramType:\"overlaid\",panel:T0e.panel,yAxis:f5w,widthFactor:y$o || 0.5,bindToYAxis:!!\"1\",highlight:T0e.highlight};L_G.drawHistogram(A13,f64);};e53.Studies.displayIndividualSeriesAsLine=function(A7Z,J7O,X8Q,M2x,c$w){var C7h,M5o,I$v,M5P,m8R,k$d,J7f,H2p,i7U,A35,L$w,o8a,F1r,q1w,J1d,L4o,H2a,x2G,U7D;if(!X8Q.height){X8Q.height=X8Q.bottom - X8Q.top;}C7h=J7O.getContext(A7Z);M5o=J7O.outputs[J7O.outputMap[M2x]];if(!M5o){return;}C7h.save();if(typeof M5o === \"string\"){M5o={color:M5o,width:1};}C7h.lineWidth=M5o.width || 1;I$v=M5o.color;if(I$v == \"auto\"){I$v=A7Z.defaultColor;}C7h.strokeStyle=I$v;M5P=M5o.pattern;C7h.setLineDash(e53.borderPatternToArray(C7h.lineWidth,M5P));C7h.lineDashOffset=0;m8R=+\"0\";k$d=J7O.study;J7f=J7O.getYAxis(A7Z);m8R=A7Z.decimalPlacesFromPriceTick(J7f.priceTick,J7f.idealTickSizePixels);Q_p.y6g();H2p=1372509403;i7U=-+\"100761208\";A35=2;for(var C5G=1;Q_p.P6(C5G.toString(),C5G.toString().length,77629) !== H2p;C5G++){if(J7O.overlay && J7O.underlay){m8R=1;}if(J7f.decimalPlaces && J7f.decimalPlaces !== 6){m8R=J7f.decimalPlaces;}L$w=1;if(J7O.parameters){L$w=J7O.parameters.label;}o8a=k$d.parameters;if(+o8a){o8a={};}A35+=2;}if(Q_p.m1(A35.toString(),A35.toString().length,55338) !== i7U){if(J7O.overlay || J7O.underlay){m8R=null;}if(J7f.decimalPlaces || J7f.decimalPlaces === +\"0\"){m8R=J7f.decimalPlaces;}L$w=null;if(J7O.parameters){L$w=J7O.parameters.label;}o8a=k$d.parameters;if(!o8a){o8a={};}}F1r=o8a.plotType == \"step\";if(J7O.series){for(var H9r in J7O.series){q1w=\"s\";q1w+=\"t\";q1w+=\"e\";q1w+=\"p\";J1d=J7O.series[H9r].parameters.type;if(J1d){Q_p.b8R(82);F1r=Q_p.e7l(J1d,q1w);}}}if(o8a.noLabels){L$w=!({});}if(!J7O.noSlopes && J7O.noSlopes !== ![]){J7O.noSlopes=o8a.noSlopes;}if(!J7O.extendToEnd && J7O.extendToEnd !== !({})){J7O.extendToEnd=o8a.extendToEnd;}L4o=L$w || A7Z.preferences.labels && L$w !== !!\"\";H2a=J7O.gaplines;if(H2a === !!\"\"){H2a=\"transparent\";}x2G=J7O.inputs.Symbol;U7D=H2a?A7Z.getGapColorFunction(x2G,M2x,M5o,H2a):null;A7Z.plotDataSegmentAsLine(M2x,X8Q,{yAxis:J7f,skipTransform:A7Z.panels[J7O.panel].name != J7O.chart.name,label:L4o,labelDecimalPlaces:m8R,noSlopes:J7O.noSlopes,step:F1r,alignStepToSide:J7O.alignStepToSide,extendToEndOfLastBar:J7O.extendToEndOfLastBar,width:J7O.lineWidth,extendToEndOfDataSet:J7O.extendToEnd,gapDisplayStyle:H2a,highlight:J7O.highlight},U7D);if(k$d.appendDisplaySeriesAsLine){k$d.appendDisplaySeriesAsLine(A7Z,J7O,c$w,M2x,X8Q);}C7h.restore();};e53.Studies.drawHorizontal=function(j2w,g8S,I_K,x56,F$N,T2$){var b6O,z3J,o0A;Q_p.y6g();b6O=j2w.panels[g8S.panel];z3J=j2w.getBackgroundCanvas().context;if(!b6O){return;}if(!T2$){T2$=F$N.textStyle;}o0A=j2w.pixelFromPrice(x56,b6O,F$N);if(o0A > F$N.top && o0A < F$N.bottom){j2w.plotLine(b6O.left,b6O.right,o0A,o0A,T2$,\"segment\",z3J,![],{opacity:T2$ && T2$.opacity?T2$.opacity:0.5});}};e53.Studies.displayHistogramWithSeries=function(k2s,p4z,r_0){var q4L,d3l;q4L=k2s.panels[p4z.panel];Q_p.b8R(4);d3l=Q_p.F9v(\"0.5\",0);if(p4z.underlay){d3l=0.3;}e53.Studies.createHistogram(k2s,p4z,r_0,!({}),d3l);e53.Studies.displaySeriesAsLine(k2s,p4z,r_0);};e53.Studies.drawZones=function(J4w,t0J,K3z){var w0o,T15,o1T,P71,N2v,s1z,L$Z,r0n,z0E,G7e,a0V,n8g,G2O,m08,B9t,G4d,Z_9,e44,i7K,d55,x0e,q91,U$P,u1q,P$Z,x7I,Q_Z,S_g,Q5M,O2H,o1O,M9H;w0o=\"stx\";w0o+=\"_grid_borde\";w0o+=\"r\";T15=\"l\";T15+=\"eft\";o1T=\"au\";o1T+=\"to\";if(!t0J.parameters || !t0J.parameters.studyOverZonesEnabled){return;}P71=parseFloat(t0J.parameters.studyOverSoldValue);N2v=parseFloat(t0J.parameters.studyOverBoughtValue);s1z=t0J.parameters.studyOverSoldColor;L$Z=t0J.parameters.studyOverBoughtColor;r0n=t0J.zoneOutput;if(!r0n){r0n=\"Result\";}z0E=e53.Studies.determineColor(t0J.outputs[r0n]);if(!z0E || z0E == o1T || e53.isTransparent(z0E)){z0E=J4w.defaultColor;}if(!s1z){s1z=z0E;}if(!s1z || s1z == \"auto\" || e53.isTransparent(s1z)){s1z=J4w.defaultColor;}if(!L$Z){L$Z=z0E;}if(!L$Z || L$Z == \"auto\" || e53.isTransparent(L$Z)){L$Z=J4w.defaultColor;}G7e=J4w.panels[t0J.panel];a0V=t0J.getYAxis(J4w);n8g=a0V.displayBorder;if(J4w.axisBorders === !!\"\"){n8g=!\"1\";}if(J4w.axisBorders === !0){n8g=!!\"1\";}if(a0V.width === 0){n8g=!({});}G2O=J4w.getYAxisCurrentPosition(a0V,G7e);Q_p.G4m(82);m08=Q_p.F9v(G2O,T15);B9t=a0V.justifyRight;if(!B9t && B9t !== ![]){if(J4w.chart.yAxis.justifyRight || J4w.chart.yAxis.justifyRight === !!0){B9t=J4w.chart.yAxis.justifyRight;}else {B9t=m08;}}G4d=Math.round(a0V.left + (m08?a0V.width:0)) + 0.5;Z_9=n8g?3:0;e44=J4w.getBackgroundCanvas().context;i7K=e44.fillStyle;e44.globalAlpha=0.2;J4w.startClip(G7e.name,!![]);e44.beginPath();Q_p.b8R(132);var R4e=Q_p.F9v(8,1,11,12,31);d55=Math.round(J4w.pixelFromPrice(N2v,G7e,a0V)) - \"0.5\" * R4e;e44.strokeStyle=L$Z;e44.moveTo(G7e.left,d55);e44.lineTo(G7e.right,d55);e44.stroke();e44.closePath();e44.beginPath();x0e=Math.round(J4w.pixelFromPrice(P71,G7e,a0V)) + 0.5;e44.strokeStyle=s1z;e44.moveTo(G7e.left,x0e);e44.lineTo(G7e.right,x0e);e44.stroke();e44.closePath();q91=new e53.Plotter();q91.newSeries(\"border\",\"stroke\",J4w.canvasStyle(w0o));if(n8g){U$P=\"b\";U$P+=\"order\";u1q=m08?G4d - Z_9:G4d - 0.5;P$Z=m08?G4d + 0.5:G4d + Z_9;q91.moveTo(\"border\",u1q,d55);q91.lineTo(\"border\",P$Z,d55);q91.moveTo(\"border\",u1q,x0e);q91.lineTo(U$P,P$Z,x0e);}e44.fillStyle=i7K;x7I={skipTransform:J4w.panels[t0J.panel].name != t0J.chart.name,panelName:t0J.panel,band:r0n + ((5220,+\"9100\") > (354.3,8610)?(739.13,664) >= (8878,2.9)?\" \":!!0:\"R\") + t0J.name,yAxis:a0V,opacity:+\"0.3\"};if(!t0J.highlight && J4w.highlightedDraggable){x7I.opacity*=0.3;}e53.preparePeakValleyFill(J4w,e53.extend(x7I,{threshold:N2v,direction:a0V.flipped?-(\"1\" << 32):1,color:L$Z}));e53.preparePeakValleyFill(J4w,e53.extend(x7I,{threshold:P71,direction:a0V.flipped?+\"1\":-1,color:s1z}));e44.globalAlpha=1;if(!t0J.study || !t0J.study.yaxis){if(n8g){Q_Z=\"bo\";Q_Z+=\"r\";Q_Z+=\"der\";S_g=Math.round(a0V.bottom) + 0.5;q91.moveTo(\"border\",G4d,a0V.top);q91.lineTo(\"border\",G4d,S_g);q91.draw(e44,Q_Z);}if(a0V.width !== \"0\" << 64){Q5M=\"stx\";Q5M+=\"_\";Q5M+=\"yax\";Q5M+=\"is\";O2H=\"s\";O2H+=\"t\";O2H+=\"x_y\";O2H+=\"axis\";J4w.canvasFont(O2H,e44);J4w.canvasColor(Q5M,e44);e44.textAlign=B9t?\"right\":\"left\";o1O=J4w.getCanvasFontSize(\"stx_yaxis\") / +\"2\";if(m08){Q_p.b8R(13);var I9n=Q_p.F9v(14,11);M9H=a0V.left + I9n;if(B9t){Q_p.b8R(132);var y9l=Q_p.e7l(15,1,6,5,28);M9H=a0V.left + a0V.width - Z_9 - y9l;}}else {Q_p.b8R(33);var C5m=Q_p.F9v(12,14,167);M9H=a0V.left + Z_9 + \"3\" * C5m;if(B9t){M9H=a0V.left + a0V.width;}}if(d55 > a0V.top + o1O){e44.fillStyle=L$Z;e44.fillText(N2v,M9H,d55);}if(x0e < a0V.bottom - o1O){e44.fillStyle=s1z;e44.fillText(P71,M9H,x0e);}e44.fillStyle=i7K;}}J4w.endClip();e44.globalAlpha=1;if(a0V.name == t0J.name){a0V.yAxisPlotter=new e53.Plotter();}};e53.Studies.createHistogram=function(E8Z,c9d,k$G,U9r,F6S){var G1H,t9U,B3f,C4j,h7m,U6u,S1X,b0b,v7r,v1$,m_l,N8n,r0C,W0o,U3B,E5j,C4x,t3w,u1d,C2V,r7h;G1H=\"_\";G1H+=\"h\";G1H+=\"is\";G1H+=\"t\";t9U=E8Z.panels[c9d.panel];B3f=c9d.getContext(E8Z);C4j=c9d.getYAxis(E8Z);E8Z.startClip(t9U.name);Q_p.b8R(13);var J6Q=Q_p.F9v(17,15);h7m=E8Z.layout.candleWidth - J6Q;if(h7m < +\"2\"){h7m=1;}U6u=E8Z.pixelFromPrice(0,t9U,C4j);if(C4j.min > 0){U6u=E8Z.pixelFromPrice(C4j.min,t9U,C4j);}if(U9r){U6u=Math.floor(t9U.top + t9U.height / (\"2\" ^ 0));}S1X=c9d.name + G1H;E8Z.canvasColor(\"stx_histogram\");b0b=B3f.fillStyle;if(F6S || F6S === 0){B3f.globalAlpha=F6S;}if(!c9d.highlight && E8Z.highlightedDraggable){B3f.globalAlpha*=+\"0.3\";}v7r=null;v1$=null;m_l=c9d.outputs;for(var b$T=0;b$T < k$G.length;b$T++){N8n=\"Decreasin\";N8n+=\"g Ba\";N8n+=\"r\";r0C=k$G[b$T];if(!r0C)continue;if(r0C.candleWidth){h7m=Math.floor(Math.max(\"1\" << 0,r0C.candleWidth - 2));}W0o=Math.floor(E8Z.pixelFromBar(b$T,t9U.chart) - h7m / +\"2\");U3B=Math.floor(h7m);if(v7r === null){Q_p.b8R(13);var T23=Q_p.e7l(16,15);E5j=E8Z.tickFromPixel(W0o,t9U.chart) - T23;if(E5j < 0){v7r=v1$;}else {v7r=E8Z.pixelFromPrice(E8Z.chart.dataSet[E5j][S1X],t9U,C4j) - U6u;}}else {v7r=v1$;}v1$=E8Z.pixelFromPrice(r0C[S1X],t9U,C4j) - U6u;C4x=e53.Studies.determineColor(m_l[N8n]);t3w=e53.Studies.determineColor(m_l[\"Increasing Bar\"]);u1d=e53.Studies.determineColor(m_l[\"Positive Bar\"]);C2V=e53.Studies.determineColor(m_l[\"Negative Bar\"]);r7h=C4j.flipped;B3f.fillStyle=b0b;if(C4x && (r7h?v1$ < v7r:v1$ > v7r)){B3f.fillStyle=C4x;}else if(t3w && (r7h?v1$ > v7r:v1$ < v7r)){B3f.fillStyle=t3w;}else if(u1d && (r7h?v1$ > 0:v1$ < \"0\" * 1)){B3f.fillStyle=u1d;}else if(C2V && (r7h?v1$ < 0:v1$ > +\"0\")){B3f.fillStyle=C2V;}B3f.fillRect(W0o,U6u,U3B,Math.floor(v1$));}B3f.globalAlpha=1;E8Z.endClip();};e53.Studies.prettify={Close:1036 !== (520.85,6288)?(755,845.58) != 148.85?\"C\":(528,7182) !== (3887,\"400.54\" - 0)?+\"0x1ef3\":\"k\":!!0,Open:7168 == 2017?(!\"1\",4.14e+3):9161 > 8560?\"O\":(6.76e+3,\"H\"),High:741.14 > 9210?1.38:(3545,3223) != 7580?(843,347.91) >= 9305?107.97:\"H\":559.06,Low:\"L\",simple:\"ma\",exponential:\"ema\",triangular:\"tma\",VIDYA:\"vdma\",weighted:\"wma\",\"welles wilder\":\"smma\",true:4279 < +\"6975\"?(517.94,\"803.17\" - 0) !== (928.15,46.86)?\"y\":(![],\"e\"):(![],![]),false:(7196,7419) >= 1212?6170 == 730?(0x19fb,843.80):\"n\":!1};e53.Studies.prettyRE=/^.{0,50}\\((.{0,50})\\).{0,50}$/;e53.Studies.prettyDisplay=function(d9i){var t54,v5x;t54=e53.Studies.prettyRE.exec(d9i);if(!t54){return d9i;}v5x=t54[1];if(v5x){for(var z04 in e53.Studies.prettify){v5x=v5x.replace(z04,e53.Studies.prettify[z04]);}d9i=d9i.replace(t54[1],v5x);}return d9i;};e53.Studies.getFieldInputs=function(v9b){Q_p.y6g();var G0L,d5W;G0L=[];d5W=v9b.study.inputs;for(var d3L in d5W){if(d5W[d3L] == \"field\"){G0L.push(d3L);}}return G0L;};e53.Studies.initializeFN=function(B74,x9e,G5m,t3W,S_v,O8G,G8C){var U3p,A0i,c5L,J96,R_8,p9p,g1C,V33,H7y,H0B,t23,g1r,n8O,F77,s5x,r2O,r_M,m02,R78,F1T,N_W,P7w,Z1o,Z7r;U3p=\"Bo\";U3p+=\"t\";U3p+=\"to\";U3p+=\"m\";if(!G5m){G5m={};}if(!S_v){S_v={};}if(!G5m.id){G5m.id=e53.Studies.generateID(B74,x9e,G5m,S_v.replaceID,S_v.display);}if(!G5m.display){G5m.display=G5m.id;}A0i=new e53.Studies.StudyDescriptor(G5m.id,x9e,G5m.id,G5m,t3W,S_v);if(G5m.Period){A0i.days=Math.max(1,parseInt(A0i.inputs.Period,10));}if(G8C){if(!G8C.inputs){G8C.inputs=A0i.study.inputs;}if(!G8C.outputs){G8C.outputs=A0i.study.outputs;}A0i.study=G8C;}else {G8C=A0i.study;}if(G8C.display){G5m.display=G8C.display;}if(typeof S_v.panelName == \"string\"){O8G=S_v.panelName;}if(O8G == G5m.id || O8G && !B74.panelExists(O8G)){A0i.underlay=A0i.overlay=!1;}if(O8G == \"Own panel\" || O8G == \"New panel\"){O8G=null;}c5L=A0i.overlay || G5m.Overlay || A0i.overlay !== !1 && G8C.overlay;J96=A0i.underlay || G5m.Underlay || A0i.underlay !== !1 && G8C.underlay;if(c5L && S_v.underlayEnabled){J96=!![];}if(J96){A0i.underlay=!!({});}if(!J96 && B74.chart.panel && O8G == B74.chart.panel.name){c5L=!![];}if(c5L){A0i.overlay=!![];}R_8=B74.preferences.dragging;if(R_8 === !!1 || R_8 && R_8.study){A0i.overlay=!!\"1\";}if(O8G){S_v.panelName=O8G;}else if(!c5L && !J96){O8G=G5m.id;}if(S_v.calculateOnly){if(c5L || J96){if(B74.panels[S_v.panelName]){A0i.panel=S_v.panelName;}else {A0i.panel=e53.Studies.getPanelFromFieldName(B74,A0i) || S_v.chartName;}}return A0i;}p9p={};g1C=B74.layout.studies[S_v.replaceID];if(g1C){p9p={outputMap:e53.clone(g1C.outputMap),panel:g1C.panel};}A0i.panel=\"\";if(O8G){V33=\"de\";V33+=\"fa\";V33+=\"ult\";H7y=\"sh\";H7y+=\"ar\";H7y+=\"e\";H7y+=\"d\";H0B=\"n\";H0B+=\"o\";H0B+=\"n\";H0B+=\"e\";t23=e53.Studies.smartMovePanel(B74,A0i.inputs,O8G,S_v.replaceID,S_v.panelName == \"New panel\");if(t23){A0i.panel=t23.name;}if(S_v.yaxisDisplayValue && ![\"left\",\"right\",H0B,H7y,V33].includes(S_v.yaxisDisplayValue) && !B74.getYAxisByName(t23,S_v.yaxisDisplayValue)){S_v.yaxisDisplayValue=\"default\";}}else if(c5L || J96){A0i.panel=e53.Studies.getPanelFromFieldName(B74,A0i) || S_v.chartName;}if(!A0i.panel){g1r=G8C.panelHeight || null;n8O=S_v.yAxis || G8C.yAxis || ({});n8O.name=A0i.inputs.id;A0i.panel=A0i.inputs.id;B74.createPanel(A0i.inputs.display,A0i.panel,g1r,S_v.chartName,new e53.ChartEngine.YAxis(n8O));}if(A0i.parameters && A0i.parameters.panelName){A0i.parameters.panelName=A0i.panel;}Q_p.j1L();F77=B74.panels[A0i.panel];s5x=G8C?e53.clone(G8C.yAxis):null;r2O=S_v.yAxis || s5x;if((r2O || ({})).ground){Q_p.G4m(4);r2O[\"initialMargin\" + (r2O.flipped?\"Top\":U3p)]=Q_p.e7l(\"0\",0);}r_M=e53.Studies.smartCreateYAxis(B74,F77,A0i.inputs.id,S_v.yaxisDisplayValue,r2O);if(r_M){m02=\"defau\";m02+=\"lt\";if(r_M.name == S_v.replaceID){r_M.name=A0i.inputs.id;}if(!S_v.replaceID && r_M.name === A0i.name){B74.calculateYAxisMargins(r_M);}r_M.allowSharing=!S_v.yAxis && !G8C.yAxis;r_M.width=r_M.position == \"none\"?0:e53.ChartEngine.YAxis.prototype.width;if(S_v.yaxisDisplayValue == \"shared\" || S_v.yaxisDisplayValue == m02){delete S_v.yaxisDisplayValue;}else {if(s5x){e53.ensureDefaults(r_M,s5x);}if(r_M.name == A0i.name){if(!(s5x || ({})).textStyle && !S_v.yaxisDisplayColor || S_v.yaxisDisplayColor == \"auto\"){delete r_M.textStyle;}else if(S_v.yaxisDisplayColor){r_M.textStyle=e53.colorToHex(S_v.yaxisDisplayColor);}if((s5x || ({})).justifyRight === undefined){r_M.justifyRight=null;}if(S_v.flippedEnabled !== undefined){r_M.flipped=S_v.flippedEnabled;}}}if(r_M != F77.yAxis){r_M.displayGridLines=!\"1\";}else if(r_M != B74.chart.yAxis){R78=-787486553;Q_p.G4m(1);F1T=-Q_p.F9v(\"1907453207\",0);N_W=2;for(var o_H=+\"1\";Q_p.m1(o_H.toString(),o_H.toString().length,+\"23261\") !== R78;o_H++){r_M.displayGridLines=B74.displayGridLinesInStudies;N_W+=2;}if(Q_p.P6(N_W.toString(),N_W.toString().length,22825) !== F1T){r_M.displayGridLines=B74.displayGridLinesInStudies;}}}B74.calculateYAxisPositions();if(g1C){P7w=\"vecto\";P7w+=\"r\";Z1o=!!\"\";for(var a4K in B74.drawingObjects){Z7r=B74.drawingObjects[a4K];if(p9p.outputMap && p9p.outputMap.hasOwnProperty(Z7r.field)){Z7r.field=Z7r.field.replace(S_v.replaceID,A0i.inputs.id);if(A0i.parameters && A0i.parameters.panelName){Z7r.panelName=A0i.parameters.panelName;}else {Z7r.panelName=A0i.panel;}Z1o=!!\"1\";}else if(p9p.panel && p9p.panel == Z7r.panelName){Z7r.panelName=Z7r.panelName.replace(S_v.replaceID,A0i.inputs.id);Z1o=!!({});}}if(Z1o){B74.changeOccurred(P7w);}}return A0i;};e53.Studies.smartMovePanel=function(U7c,X86,m7W,I__,s0E){var E4t,k_e,j5Q,H3h;k_e=X86.id;if(I__){E4t=U7c.layout.studies[I__];}if(E4t){j5Q=U7c.panels[E4t.panel];if(j5Q){if(j5Q.yAxis.name == I__){if((s0E || m7W != I__ && m7W != k_e) && !U7c.checkForEmptyPanel(j5Q.name,!!\"1\",E4t)){U7c.electNewPanelOwner(j5Q);H3h=E4t.getYAxis(U7c);if(H3h.name == I__){U7c.electNewYAxisOwner(H3h);}}else if(m7W == I__ || !U7c.panels[m7W]){if(k_e != j5Q.name){U7c.modifyPanel(j5Q,{name:k_e,display:X86.display});}m7W=k_e;}}}}return U7c.panels[m7W];};e53.Studies.smartCreateYAxis=function(Y_c,X03,i3Y,y0m,d5g){var a8K,X$$,O__,a3_,q4q,M8e,Z2B;a8K=\"sh\";a8K+=\"are\";a8K+=\"d\";X$$=\"ri\";X$$+=\"ght\";O__=d5g || ({});a3_=Y_c.getYAxisByName(X03,i3Y);if(!y0m && d5g){y0m=d5g.position;}if([\"left\",X$$,\"none\"].indexOf(y0m) > -1 || y0m === undefined && d5g){if(!a3_ || a3_.isShared(Y_c)){e53.extend(O__,{name:i3Y,position:y0m});if(!a3_ && !Y_c.currentlyImporting && X03 != X03.chart.panel && !X03.yAxis.studies.length && !X03.yAxis.renderers.length){a3_=X03.yAxis;e53.extend(a3_,O__);}else {q4q=a3_ == X03.yAxis;if(a3_){a3_.name=Y_c.electNewYAxisOwner(a3_);}M8e=a3_ || X03.yAxis;if(M8e.lockScale){e53.extend(O__,{zoom:M8e.zoom,scroll:M8e.scroll,lockScale:!!({})});}a3_=Y_c.addYAxis(X03,new e53.ChartEngine.YAxis(O__));if(q4q){X03.yAxis=a3_;}}}else {if(d5g){e53.extend(a3_,d5g);}a3_.position=y0m;a3_.name=i3Y;}return a3_;}Q_p.j1L();if(y0m && y0m !== \"default\" && y0m !== a8K && y0m !== X03.yAxis.name){Z2B=Y_c.getYAxisByName(X03,y0m);if(Z2B && a3_ == X03.yAxis && !a3_.isShared(Y_c)){X03.yAxis=Z2B;}if(a3_ && a3_.isShared(Y_c)){a3_.name=Y_c.electNewYAxisOwner(a3_);}else {if(a3_ !== X03.yAxis){Y_c.deleteYAxisIfUnused(X03,a3_);}}return Z2B;}if(y0m == \"shared\" || y0m == X03.yAxis.name || X03.yAxis.allowSharing && (!a3_ || a3_.allowSharing)){if(a3_){if(a3_ !== X03.yAxis && a3_.isShared(Y_c)){a3_.name=Y_c.electNewYAxisOwner(a3_);}else {delete a3_.position;Y_c.deleteYAxisIfUnused(X03,a3_);}}Y_c.resizeChart();return X03.yAxis;}e53.extend(O__,{name:i3Y});if(a3_){a3_.name=Y_c.electNewYAxisOwner(a3_);}if(!a3_ || a3_.name){a3_=Y_c.addYAxis(X03,new e53.ChartEngine.YAxis(O__));}else {e53.extend(a3_,O__);delete a3_.position;}return a3_;};e53.Studies.calculateVolume=function(m7h,H4V){var v0$,H3w,Z2R,n9c,W98;v0$=\"vo\";Q_p.j1L();v0$+=\"l\";v0$+=\" un\";v0$+=\"dr\";if(H4V.type == v0$){H3w=\"lay\";H3w+=\"o\";H3w+=\"ut\";if(!m7h || !m7h.chart.dataSet){return;}Z2R=m7h.layout;n9c=H4V.parameters.removeStudy;W98=Z2R.volumeUnderlay;Z2R.volumeUnderlay=!n9c;if(W98 != Z2R.volumeUnderlay){m7h.changeOccurred(H3w);}if(n9c){e53.Studies.removeStudy(m7h,H4V);}}H4V.outputMap={};H4V.outputMap.Volume=\"\";};e53.Studies.MA=function(w70,t_T,Z4v,l8$,s1O,h1k,a6C,E8C){var C9j,m8f;C9j=\"m\";C9j+=\"a\";m8f=new e53.Studies.StudyDescriptor(s1O + \" \" + a6C.name,C9j,a6C.panel);m8f.chart=a6C.chart;m8f.days=parseInt(t_T,10);Q_p.y6g();m8f.startFrom=a6C.startFrom;if(E8C){m8f.subField=E8C;}m8f.inputs={};if(w70){m8f.inputs.Type=w70;}if(Z4v){m8f.inputs.Field=Z4v;}if(l8$){m8f.inputs.Offset=parseInt(l8$,+\"10\");}e53.Studies.calculateMovingAverage(h1k,m8f);};e53.Studies.movingAverage={conversions:{ma:p6h,sma:\"simple\",ema:e3N,tma:T$R,vdma:\"vidya\",wma:\"weighted\",smma:V9k},translations:{simple:\"Simple\",exponential:\"Exponential\",triangular:\"Triangular\",vidya:A6L,weighted:\"Weighted\",\"welles wilder\":\"Welles Wilder\"},typeMap:{ema:\"Exponential\",exponential:\"Exponential\",tma:\"Triangular\",triangular:\"Triangular\",vdma:\"VIDYA\",vidya:h5p,wma:n6c,weighted:c_v,smma:b2L,\"welles wilder\":y8i}};e53.Studies.movingAverageHelper=function(z0D,U0F){var v3P;if(U0F == \"options\"){v3P={};for(var j3Z in e53.Studies.movingAverage.translations){v3P[j3Z]=z0D.translateIf(e53.Studies.movingAverage.translations[j3Z]);}return v3P;}return e53.Studies.movingAverage.conversions[U0F];};e53.Studies.createVolumeChart=function(s6Q,M0K,l67){var k9p,j6a,U81,b2J,q89,E62,v5A,r5l,T6U,v_7,V$E,f1T,x0o,f1F,i8_,Y3G;k9p=\"co\";k9p+=\"lor\";j6a=\"_\";j6a+=\"down\";U81=\"st\";U81+=\"x\";U81+=\"_vo\";U81+=\"lume\";b2J=M0K.panel;q89=M0K.inputs;E62=M0K.underlay;v5A=M0K.overlay;r5l=E62 || v5A;T6U=e53.Studies.determineColor(M0K.outputs[\"Up Volume\"]);v_7=e53.Studies.determineColor(M0K.outputs[\"Down Volume\"]);V$E=E62?\"stx_volume_underlay\":U81;Q_p.b8R(0);s6Q.setStyle(Q_p.e7l(V$E,\"_up\"),\"color\",T6U);Q_p.G4m(0);s6Q.setStyle(Q_p.F9v(V$E,j6a),k9p,v_7);f1T=[{field:M0K.volumeField || \"Volume\",fill_color_up:s6Q.canvasStyle(V$E + \"_up\").color,border_color_up:s6Q.canvasStyle(V$E + \"_up\").borderLeftColor,opacity_up:s6Q.canvasStyle(V$E + \"_up\").opacity,fill_color_down:s6Q.canvasStyle(V$E + \"_down\").color,border_color_down:s6Q.canvasStyle(V$E + \"_down\").borderLeftColor,opacity_down:s6Q.canvasStyle(V$E + \"_down\").opacity,color_function:M0K.colorFunction}];x0o=f1T[0];if(!E62 && x0o.border_color_down === \"rgb(184, 44, 12)\"){f1F=\"#\";f1F+=\"000\";f1F+=\"000\";x0o.border_color_down=\"#000000\";x0o.border_color_up=f1F;}i8_=M0K.getYAxis(s6Q);Y3G={name:\"Volume\",panel:b2J,yAxis:i8_,widthFactor:1,bindToYAxis:!\"\",highlight:M0K.highlight};Q_p.j1L();e53.extend(Y3G,M0K.study.parameters);e53.extend(Y3G,M0K.parameters);if(s6Q.colorByCandleDirection && !M0K.colorFunction){x0o.color_function=function(p6D){var o38,h7j;o38=p6D.Open;h7j=p6D.Close;return {fill_color:o38 > h7j?x0o.fill_color_down:x0o.fill_color_up,border_color:o38 > h7j?x0o.border_color_down:x0o.border_color_up,opacity:o38 > h7j?x0o.opacity_down:x0o.opacity_up};};}s6Q.drawHistogram(Y3G,f1T);};e53.Studies.calculateStandardDeviation=function(N17,h7Y){var f8b,z7N,H7a,o6V,R7u,d45,k0I,G7X,W5D,g5R,Z5M,X6Y,Y0t,N$0,E$0;f8b=\"Moving \";f8b+=\"Av\";f8b+=\"era\";f8b+=\"ge Type\";z7N=h7Y.chart.scrubbed;if(z7N.length < h7Y.days + +\"1\"){h7Y.error=!!({});return;}H7a=h7Y.inputs.Field;if(!H7a || H7a == \"field\"){H7a=\"Close\";}o6V=h7Y.inputs[f8b];if(!o6V){o6V=h7Y.inputs.Type;}e53.Studies.MA(o6V,h7Y.days,H7a,h7Y.inputs.Offset,\"_MA\",N17,h7Y);R7u=0;Q_p.G4m(3);d45=Q_p.e7l(\"0\",1);Q_p.b8R(42);k0I=Q_p.F9v(\"0\",96);G7X=Number(h7Y.inputs[\"Standard Deviations\"]);if(G7X < 0){G7X=+\"2\";}W5D=h7Y.name;for(var g8g in h7Y.outputs){Q_p.b8R(14);W5D=Q_p.F9v(g8g,W5D,\" \");}for((g5R=h7Y.startFrom - +\"1\",X6Y=0);g5R >= 0 && X6Y < h7Y.days;(g5R--,X6Y++)){Z5M=z7N[g5R][H7a];if(Z5M && typeof Z5M == \"object\"){Z5M=Z5M[h7Y.subField];}if(isNaN(Z5M)){Z5M=0;}R7u+=Math.pow(Z5M,2);d45+=Z5M;}for(g5R=h7Y.startFrom;g5R < z7N.length;g5R++){Y0t=\"_M\";Y0t+=\"A \";N$0=z7N[g5R];Z5M=N$0[H7a];if(Z5M && typeof Z5M == \"object\"){Z5M=Z5M[h7Y.subField];}if(!Z5M && Z5M !== 0){Z5M=0;}R7u+=Math.pow(Z5M,2);d45+=Z5M;if(g5R < h7Y.days - 1)continue;if(g5R >= h7Y.days){E$0=z7N[g5R - h7Y.days][H7a];if(E$0 && typeof E$0 == \"object\"){E$0=E$0[h7Y.subField];}if(isNaN(E$0)){E$0=0;}R7u-=Math.pow(E$0,2);d45-=E$0;}k0I=N$0[Y0t + h7Y.name];if(k0I || k0I === 0){Q_p.G4m(4);var t0r=Q_p.F9v(28,26);Q_p.b8R(133);var I1_=Q_p.F9v(2,12,3,15,178);N$0[W5D]=Math.sqrt((R7u + h7Y.days * Math.pow(k0I,t0r) - I1_ * k0I * d45) / h7Y.days) * G7X;}}};e53.Studies.calculateMovingAverage=function(Z6s,i4U){var U2V,T8f,j8B,Y8v,B7C,X8z,y1W,a2h,B0J,O0U,p1i,R5A,s9G,u66,O7$,F$T,W08,X6O,Z1z,N5n,f6P,P4q,N8W;U2V=\"fie\";U2V+=\"ld\";T8f=\"s\";T8f+=\"i\";T8f+=\"mple\";j8B=\"s\";j8B+=\"i\";j8B+=\"mple\";Y8v=\"s\";Y8v+=\"ma\";if(!i4U.chart.scrubbed){return;}B7C=i4U.inputs.Type;if(B7C == \"ma\" || B7C == Y8v || !B7C){B7C=j8B;}X8z=e53.Studies.movingAverage.typeMap;if((B7C in X8z)){y1W=\"calculat\";y1W+=\"eMovingAver\";y1W+=\"age\";return e53.Studies[y1W + X8z[B7C]](Z6s,i4U);}else if(B7C !== T8f){return;}a2h=i4U.chart.scrubbed;Q_p.G4m(3);B0J=Q_p.F9v(\"0\",1);O0U=[];p1i=i4U.name;for(var U_u in i4U.outputs){Q_p.G4m(14);p1i=Q_p.F9v(U_u,p1i,\" \");}R5A=i4U.inputs.Field;if(!R5A || R5A == U2V){R5A=\"Close\";}s9G=parseInt(i4U.inputs.Offset,10);if(isNaN(s9G)){Q_p.b8R(63);s9G=Q_p.e7l(\"0\",0);}W08=i4U.startFrom;X6O=s9G;for(u66=i4U.startFrom - 1;u66 >= 0;u66--){O7$=a2h[u66][R5A];if(O7$ && typeof O7$ == \"object\"){O7$=O7$[i4U.subField];}if(!O7$ && O7$ !== 0)continue;if(X6O > (\"0\" ^ 0)){X6O--;W08=u66;continue;}if(O0U.length == i4U.days - 1)break;B0J+=O7$;O0U.unshift(O7$);}if(O0U.length < i4U.days - +\"1\"){O0U=[];W08=+\"0\";}Z1z=[];for(u66=W08;u66 < a2h.length;u66++){N5n=a2h[u66];O7$=N5n[R5A];if(O7$ && typeof O7$ == \"object\"){O7$=O7$[i4U.subField];}f6P=u66 + s9G >= +\"0\" && u66 + s9G < a2h.length;P4q=f6P?a2h[u66 + s9G]:null;if(!O7$ && O7$ !== +\"0\"){if(P4q){P4q[p1i]=null;}else if(u66 + s9G >= a2h.length){F$T={};F$T[p1i]=null;Z1z.push(F$T);}continue;}B0J+=O7$;O0U.push(O7$);if(O0U.length > i4U.days){B0J-=O0U.shift();}N8W=O0U.length == i4U.days?B0J / i4U.days:null;if(P4q){P4q[p1i]=N8W;}else if(u66 + s9G >= a2h.length){F$T={};F$T[p1i]=N8W;Z1z.push(F$T);}}i4U.appendFutureTicks(Z6s,Z1z);};e53.Studies.calculateMovingAverageExponential=function(C9u,V4p){var Z42,y9Y,B3g,e60,T_j,e4T,e0G,I6g,f6Y,w47,z0i,F4h,m9r,K3N,O6z,W8i,p_S,S3D,F0S,C83,S_1;Z42=\"s\";Z42+=\"mm\";Z42+=\"a\";y9Y=V4p.inputs.Type;B3g=V4p.chart.scrubbed;e60=0;T_j=0;Q_p.G4m(63);e4T=Q_p.F9v(\"0\",0);Q_p.G4m(51);var i$k=Q_p.F9v(17,0,68,8);Q_p.G4m(17);var f1b=Q_p.F9v(16,20,35);e0G=i$k / (V4p.days + f1b);if(y9Y === \"welles wilder\" || y9Y === Z42){Q_p.b8R(11);var I6s=Q_p.F9v(8,17,10);e0G=I6s / V4p.days;}I6g=null;f6Y=V4p.name;for(var c_N in V4p.outputs){Q_p.b8R(14);f6Y=Q_p.e7l(c_N,f6Y,\" \");}w47=V4p.inputs.Field;if(!w47 || w47 == \"field\"){w47=\"Close\";}z0i=parseInt(V4p.inputs.Offset,10);if(isNaN(z0i)){Q_p.b8R(42);z0i=Q_p.F9v(\"0\",64);}K3N=V4p.startFrom;O6z=z0i;for(F4h=V4p.startFrom - 1;F4h >= 0;F4h--){m9r=B3g[F4h][f6Y];if(!m9r && m9r !== 0)continue;if(I6g === null){I6g=m9r;}e4T=V4p.days;if(O6z <= 0)break;O6z--;K3N=F4h;}if(I6g === null){I6g=K3N=0;}W8i=[];for(F4h=K3N;F4h < B3g.length;F4h++){p_S=B3g[F4h];m9r=p_S[w47];if(m9r && typeof m9r == \"object\"){m9r=m9r[V4p.subField];}S3D=F4h + z0i >= 0 && F4h + z0i < B3g.length;F0S=S3D?B3g[F4h + z0i]:null;if(!m9r && m9r !== 0){C83=null;}else {if(e4T == V4p.days - 1){e60+=m9r;T_j=e60 / V4p.days;C83=T_j;}else if(e4T < V4p.days - 1){e60+=m9r;Q_p.G4m(134);T_j=Q_p.e7l(1,e60,e4T);C83=null;}else if(e4T === 0){e60+=m9r;T_j=e60;C83=null;}else if(I6g || I6g === 0){Q_p.G4m(20);T_j=Q_p.e7l(m9r,e0G,I6g,I6g);C83=T_j;}I6g=T_j;e4T++;}if(F0S){F0S[f6Y]=C83;}else if(F4h + z0i >= B3g.length){S_1={};S_1[f6Y]=C83;W8i.push(S_1);}}V4p.appendFutureTicks(C9u,W8i);};e53.Studies.calculateMovingAverageVIDYA=function(b05,B2F){var f0i,j7p,v9s,C7E,y$A,D$h,b_5,U8X,i6x,a4k,j27,s_D,h41,X7k,g6E,D15,Y5b,N3z,B4X,e65,Q6G,e4p;f0i=\"_\";f0i+=\"S\";f0i+=\"T\";f0i+=\"D \";j7p=B2F.inputs.Type;v9s=B2F.chart.scrubbed;Q_p.G4m(135);var o2r=Q_p.e7l(4,18,7,172,17);C7E=(\"2\" >> 0) / (B2F.days + o2r);y$A=null;D$h=B2F.name;for(var n6u in B2F.outputs){Q_p.b8R(14);D$h=Q_p.e7l(n6u,D$h,\"3230\" << 64 >= (2410,+\"3494\")?(\"F\",!1):(2520,\"155.29\" * 1) === 347.08?!![]:\" \");}b_5=B2F.inputs.Field;if(!b_5 || b_5 == \"field\"){b_5=\"Close\";}B2F.std=new e53.Studies.StudyDescriptor(B2F.name,\"sdev\",B2F.panel);B2F.std.chart=B2F.chart;B2F.std.days=5;B2F.std.startFrom=B2F.startFrom;B2F.std.inputs={Field:b_5,\"Standard Deviations\":1,Type:\"ma\"};B2F.std.outputs={_STD:null};e53.Studies.calculateStandardDeviation(b05,B2F.std);e53.Studies.MA(\"ma\",20,f0i + B2F.name,0,\"_MASTD\",b05,B2F);U8X=parseInt(B2F.inputs.Offset,10);if(isNaN(U8X)){U8X=0;}s_D=B2F.startFrom;h41=U8X;for(i6x=B2F.startFrom - 1;i6x >= 0;i6x--){a4k=v9s[i6x][D$h];if(!a4k && a4k !== 0)continue;if(y$A === null){y$A=a4k;}if(h41 <= +\"0\")break;h41--;s_D=i6x;}if(y$A === null){y$A=s_D=0;}X7k=[];for(i6x=s_D;i6x < v9s.length;i6x++){g6E=\"_STD\";g6E+=\" \";D15=\"_\";D15+=\"MASTD\";D15+=\" \";Y5b=\"o\";Y5b+=\"bj\";Y5b+=\"ec\";Y5b+=\"t\";N3z=v9s[i6x];a4k=N3z[b_5];if(a4k && typeof a4k == Y5b){a4k=a4k[B2F.subField];}B4X=i6x + U8X >= \"0\" * 1 && i6x + U8X < v9s.length;e65=B4X?v9s[i6x + U8X]:null;if(!a4k && a4k !== 0){if(e65){e65[D$h]=null;}else if(i6x + U8X >= v9s.length){j27={};j27[D$h]=null;X7k.push(j27);}continue;}if(!N3z[\"_MASTD \" + B2F.name] && N3z[D15 + B2F.name] !== 0)continue;Q6G=N3z[g6E + B2F.name] / N3z[\"_MASTD \" + B2F.name];Q_p.G4m(136);e4p=Q_p.e7l(1,C7E,C7E,a4k,Q6G,y$A,Q6G);y$A=e4p;if(i6x < B2F.days){e4p=null;}if(e65){e65[D$h]=e4p;}else if(i6x + U8X >= v9s.length){j27={};j27[D$h]=e4p;X7k.push(j27);}}B2F.appendFutureTicks(b05,X7k);};e53.Studies.calculateMovingAverageTriangular=function(J8b,V4e){var s5N,r9c,k5Z,Q7Z,D$M,z8M,Q6r,z7J,G6e,Z46,N0v,L45;s5N=\"T\";s5N+=\"R\";s5N+=\"I2\";r9c=\"TR\";r9c+=\"I\";r9c+=\"1 \";Q_p.j1L();k5Z=V4e.chart.scrubbed;Q7Z=V4e.inputs.Field;if(!Q7Z || Q7Z == \"field\"){Q7Z=\"Close\";}D$M=Math.ceil(V4e.days / (\"2\" * 1));e53.Studies.MA(\"simple\",D$M,Q7Z,+\"0\",\"TRI1\",J8b,V4e);if(V4e.days % 2 === \"0\" >> 32){D$M++;}e53.Studies.MA(\"simple\",D$M,r9c + V4e.name,0,s5N,J8b,V4e);z8M=V4e.name;for(var Y9h in V4e.outputs){Q_p.b8R(14);z8M=Q_p.e7l(Y9h,z8M,(1780,246.49) <= (\"575.6\" * 1,8900)?(706,6217) < (686,668.88)?480.84:\" \":(441.09,0x211f));}Q6r=parseInt(V4e.inputs.Offset,10);if(isNaN(Q6r)){Q6r=0;}z7J=Q6r;for(var T9k=V4e.startFrom - 1;T9k >= 0;T9k--){G6e=k5Z[T9k][z8M];if(!G6e && G6e !== 0)continue;if(z7J > 0){z7J--;continue;}break;}Z46=[];for(T9k++;T9k < k5Z.length;T9k++){if(T9k + Q6r >= 0){if(T9k + Q6r < k5Z.length){Q_p.b8R(0);k5Z[Q_p.F9v(T9k,Q6r)][z8M]=k5Z[T9k][\"TRI2 \" + V4e.name];}else {N0v=\"T\";N0v+=\"RI\";N0v+=\"2 \";L45={};L45[z8M]=k5Z[T9k][N0v + V4e.name];Z46.push(L45);}}}V4e.appendFutureTicks(J8b,Z46);};e53.Studies.calculateMovingAverageWeighted=function(U2B,C9G){var K0d,n7c,x3n,g3j,b0_,J92,M06,J5j,n3L,I5z,I9b,u0w,s4X,D8E,r1X,H0h,Z1_,B6i,h_o;K0d=\"Cl\";K0d+=\"o\";K0d+=\"s\";K0d+=\"e\";n7c=C9G.chart.scrubbed;x3n=0;g3j=0;b0_=C9G.inputs.Field;if(!b0_ || b0_ == \"field\"){b0_=K0d;}Q_p.b8R(137);var T_R=Q_p.e7l(3,5,1);J92=C9G.days * (C9G.days + +\"1\") / T_R;M06=C9G.name;for(var A_t in C9G.outputs){Q_p.G4m(14);M06=Q_p.F9v(A_t,M06,6850 >= 125.46?\" \":(!1,\"p\"));}J5j=parseInt(C9G.inputs.Offset,+\"10\");if(isNaN(J5j)){J5j=0;}Q_p.j1L();u0w=[];s4X=C9G.startFrom;D8E=J5j;for(n3L=C9G.startFrom - 1;n3L >= 0;n3L--){I5z=n7c[n3L][b0_];if(I5z && typeof I5z == \"object\"){I5z=I5z[C9G.subField];}if(!I5z && I5z !== 0)continue;if(D8E > +\"0\"){D8E--;s4X=n3L;continue;}if(u0w.length == C9G.days - (\"1\" - 0))break;u0w.unshift(I5z);}if(u0w.length < C9G.days - 1){u0w=[];s4X=0;}for(n3L=\"0\" ^ 0;n3L < u0w.length;n3L++){Q_p.G4m(17);var z5o=Q_p.e7l(0,18,17);x3n+=(n3L + z5o) * u0w[n3L];g3j+=u0w[n3L];}r1X=[];for(n3L=s4X;n3L < n7c.length;n3L++){H0h=n7c[n3L];I5z=H0h[b0_];if(I5z && typeof I5z == \"object\"){I5z=I5z[C9G.subField];}Z1_=n3L + J5j >= 0 && n3L + J5j < n7c.length;B6i=Z1_?n7c[n3L + J5j]:null;if(!I5z && I5z !== 0){if(B6i){B6i[M06]=null;}else if(n3L + J5j >= n7c.length){I9b={};I9b[M06]=null;r1X.push(I9b);}continue;}u0w.push(I5z);if(u0w.length > C9G.days){x3n-=g3j;g3j-=u0w.shift();}x3n+=u0w.length * I5z;g3j+=I5z;h_o=n3L < C9G.days - 1?null:x3n / J92;if(B6i){B6i[M06]=h_o;}else if(n3L + J5j >= n7c.length){I9b={};I9b[M06]=h_o;r1X.push(I9b);}}C9G.appendFutureTicks(U2B,r1X);};e53.Studies.calculateMultMA=function(s4U,M$4){var E_b,J77,S0x,R4m,M1I,l8M,u_U,T3u;E_b=\"MA\";E_b+=\" \";J77=\"s\";J77+=\"imp\";J77+=\"l\";J77+=\"e\";S0x=\"C\";S0x+=\"lo\";S0x+=\"se\";R4m=M$4.chart.scrubbed;M1I=[Number.MAX_VALUE];Object.keys(M$4.inputs).filter(Y3f=>{Q_p.b8R(13);var a6i=Q_p.e7l(15,16);return Y3f.indexOf(\"Period\") > a6i;}).forEach((k$h,U_e)=>{Q_p.G4m(0);M1I[Q_p.F9v(U_e,1)]=M$4.inputs[k$h];});if(R4m.length < Math.min(...M1I) + 1){M$4.error=!!\"1\";return;}l8M=M$4.inputs.Field;Q_p.y6g();if(!l8M || l8M == \"field\"){l8M=S0x;}u_U=M$4.inputs[\"Moving Average Type\"];if(!u_U){u_U=J77;}T3u=M$4.inputs.Offset || 0;for(var b61=1;b61 < M1I.length;b61++){e53.Studies.MA(u_U,M1I[b61],l8M,T3u,E_b + b61,s4U,M$4);}};e53.Studies.calculateStudyATR=function(A8a,r2p){var f$X,y42,V2O,V6Q,T9d,h4x,e8w,g4d,V4s,F$6,s3X,J_d,Q78;f$X=r2p.chart.scrubbed;y42=r2p.days;if(f$X.length < y42 + 1){r2p.error=!!\"1\";return;}Q_p.G4m(1);V2O=-Q_p.e7l(\"975052846\",32);V6Q=-+\"928175448\";T9d=2;for(var c3o=1;Q_p.P6(c3o.toString(),c3o.toString().length,31335) !== V2O;c3o++){h4x=0;e8w=r2p.name;T9d+=2;}if(Q_p.m1(T9d.toString(),T9d.toString().length,93319) !== V6Q){h4x=+\"5\";e8w=r2p.name;}for(var P_w=Math.max(r2p.startFrom,\"1\" - 0);P_w < f$X.length;P_w++){g4d=\"A\";g4d+=\"T\";g4d+=\"R\";g4d+=\" \";V4s=\"A\";V4s+=\"TR\";V4s+=\" \";F$6=\"Su\";F$6+=\"m True\";F$6+=\" Range \";s3X=f$X[P_w];Q_p.b8R(4);J_d=f$X[Q_p.e7l(P_w,1)];Q78=s3X.trueRange;if(J_d[\"Sum True Range \" + e8w]){Q_p.b8R(0);h4x=J_d[Q_p.e7l(F$6,e8w)];}h4x+=Q78;if(P_w > y42){Q_p.G4m(4);h4x-=f$X[Q_p.e7l(P_w,y42)][Q_p.e7l(\"True Range \",e8w,Q_p.G4m(0))];}Q_p.b8R(0);s3X[Q_p.e7l(\"True Range \",e8w)]=Q78;Q_p.b8R(0);s3X[Q_p.e7l(\"Sum True Range \",e8w)]=h4x;if(P_w == y42){Q_p.G4m(0);s3X[Q_p.F9v(\"ATR \",e8w)]=Q_p.F9v(h4x,y42,Q_p.b8R(9));}else if(P_w > y42){Q_p.G4m(18);var q0c=Q_p.F9v(6,14,7);Q_p.b8R(0);s3X[Q_p.F9v(V4s,e8w)]=(J_d[g4d + e8w] * (y42 - q0c) + Q78) / y42;}}};e53.Studies.displayPSAR2=function(O4U,a6X,F4p){var B7P,n5S,q5t,j5C,D97,C2w,c$T,p97,u0R,V5p,p2M,p1p,B3u;B7P=O4U.panels[a6X.panel];n5S=a6X.getYAxis(O4U);q5t=n5S == O4U.chart.panel.yAxis;O4U.startClip(B7P.name);j5C=a6X.getContext(O4U);D97=a6X.inputs[\"Plot Type\"] == \"squarewave\";for(var u0N in a6X.outputs){C2w=u0N + \" \" + a6X.name;j5C.beginPath();c$T=O4U.layout.candleWidth;p97=Math.max(+\"3\",Math.floor(O4U.chart.tmpWidth / 2));for(var s8E=0;s8E < F4p.length;s8E++){u0R=F4p[s8E];if(!u0R || !u0R[C2w] && u0R[C2w] !== 0)continue;if(u0R.candleWidth){c$T=u0R.candleWidth;}if(q5t && u0R.transform){u0R=u0R.transform;}V5p=O4U.pixelFromBar(s8E,B7P.chart);if(D97){Q_p.G4m(9);V5p-=Q_p.F9v(c$T,2);}p2M=O4U.pixelFromTransformedValue(u0R[a6X.referenceOutput?a6X.referenceOutput + (1813 < (1270,9586)?4610 == 914?(732.92,!1):\" \":0x750) + a6X.name:C2w],B7P,n5S);if(s8E === 0 || !F4p[s8E - +\"1\"] || !F4p[s8E - 1][C2w] && F4p[s8E - 1][C2w] !== 0){j5C.moveTo(V5p,p2M);}if(D97){j5C.lineTo(V5p,p2M);Q_p.b8R(0);j5C.lineTo(Q_p.F9v(V5p,c$T),p2M);if(F4p[s8E + \"1\" * 1]){Q_p.G4m(0);p1p=F4p[Q_p.e7l(s8E,1)];if(q5t && p1p.transform){p1p=p1p.transform;}if(!p1p[C2w] && p1p[C2w] !== 0){Q_p.G4m(0);j5C.lineTo(Q_p.e7l(V5p,c$T),O4U.pixelFromTransformedValue(p1p[a6X.referenceOutput?a6X.referenceOutput + (6060 >= 393?\" \":614.07 != 4359?(911.65,756.86) <= (9292,6897)?0x11de:\"942.48\" * 1:(821.11,\"0x246c\" ^ 0)) + a6X.name:C2w],O4U.panels[a6X.panel],n5S));}}}else {Q_p.b8R(48);j5C.moveTo(Q_p.e7l(p97,2,V5p),p2M);Q_p.b8R(138);j5C.lineTo(Q_p.F9v(p97,0,V5p,\"2\"),p2M);}}j5C.lineWidth=1;if(a6X.highlight){j5C.lineWidth=3;}B3u=e53.Studies.determineColor(a6X.outputs[u0N]);if(B3u == \"auto\"){B3u=O4U.defaultColor;}j5C.strokeStyle=B3u;if(!a6X.highlight && O4U.highlightedDraggable){j5C.globalAlpha*=0.3;}j5C.stroke();j5C.closePath();j5C.lineWidth=1;}O4U.endClip();};e53.Studies.inputAttributeDefaultGenerator=function(Z2S){Q_p.j1L();if(!Z2S && Z2S !== 0){return {};}if(Z2S.constructor == Number){if(Math.floor(Z2S) == Z2S){if(Z2S > 0){return {min:1,step:+\"1\"};}return {step:1};}if(Z2S > 0){return {min:0,step:0.01};}return {step:0.01};}return {};};e53.Studies.getMarketOffset=function({stx:H3U, localQuoteDate:w8V, shiftToDateBoundary:r9G}){var m_I,O6u,T3$,V7k,k2w;if(arguments.length > +\"1\"){H3U=arguments[0];w8V=arguments[1];m_I=arguments[2];}var {symbol:R21}=H3U.chart;O6u=e53.getFn(\"Market.Symbology.isForexMetal\")(R21);if(m_I === undefined){m_I=e53.getFn(\"Market.Symbology.isForexSymbol\")(R21);}if(!H3U.chart.market){T3$=null;}else {T3$=m_I?\"America/New_York\":H3U.chart.market.market_tz;}Q_p.G4m(123);var t3V=Q_p.e7l(14760014,1140000,13,14);V7k=new Date(w8V.getTime() + w8V.getTimezoneOffset() * t3V);if(!T3$ || T3$.indexOf(\"UTC\") == -1){V7k=e53.convertTimeZone(V7k,\"UTC\",T3$);}k2w=new Date(V7k.getFullYear(),V7k.getMonth(),V7k.getDate(),V7k.getHours(),V7k.getMinutes(),V7k.getSeconds(),V7k.getMilliseconds()).getTime() - w8V.getTime();if(r9G && m_I){Q_p.b8R(139);k2w+=Q_p.F9v(O6u?6:7,\"60\",60,4,1000);}return k2w;};e53.Studies.getStudyList=function(o2$){var B2a,b3C;B2a={};Q_p.y6g();b3C={};e53.extend(b3C,o2$);for(var u0T in e53.Studies.studyLibrary){if(!b3C[u0T]){B2a[e53.Studies.studyLibrary[u0T].name]=u0T;}}return B2a;};e53.Studies.determineColor=function(e$z){Q_p.y6g();if(!e$z){return null;}else if(typeof e$z === \"object\"){return e$z.color;}return e$z;};e53.Studies.calculateGenericEnvelope=function(d_V,w0m,o5_,k9n,b4d,j_S){var Q_f,i3L,E9u,t0O,Z5k,R8Q,g72,H5U,R_h,n_8,N0t;if(!o5_){o5_=0;}if(!j_S){j_S=0;}if(!k9n || k9n == \"field\"){k9n=\"Close\";}if(!b4d){b4d=k9n;}Q_f=w0m.chart.scrubbed;if(!Q_f){return;}i3L=w0m.inputs.Field;if(!i3L || i3L === \"field\"){i3L=\"Close\";}for(var d92=w0m.startFrom;d92 < Q_f.length;d92++){E9u=\"%\";E9u+=\"b\";E9u+=\" \";t0O=\" \";t0O+=\"Bot\";t0O+=\"t\";t0O+=\"om \";Z5k=\"o\";Z5k+=\"bjec\";Z5k+=\"t\";R8Q=\"o\";R8Q+=\"bje\";R8Q+=\"c\";R8Q+=\"t\";g72=Q_f[d92];if(!g72)continue;if(!g72[k9n])continue;H5U=g72[i3L];if(H5U && typeof H5U == R8Q){H5U=H5U.Close;}R_h=g72[k9n];if(R_h && typeof R_h == \"object\"){R_h=R_h[w0m.subField];}n_8=g72[b4d];if(n_8 && typeof n_8 == Z5k){n_8=n_8[w0m.subField];}Q_p.G4m(36);N0t=Q_p.F9v(n_8,j_S,o5_);Q_p.b8R(0);g72[w0m.type + \" Top \" + w0m.name]=Q_p.F9v(R_h,N0t);Q_p.G4m(4);g72[w0m.type + t0O + w0m.name]=Q_p.e7l(R_h,N0t);g72[w0m.type + \" Median \" + w0m.name]=R_h;g72[\"Bandwidth \" + w0m.name]=R_h?+\"200\" * N0t / R_h:0;Q_p.G4m(140);g72[E9u + w0m.name]=Q_p.e7l(\"1\",\"50\",R_h,N0t,H5U);}};e53.Studies.displayChannel=function(O2Z,D5U,F_f){var T1q,R4Y,g$p,v81,S6G;T1q=\"Ch\";T1q+=\"ann\";Q_p.y6g();T1q+=\"el \";T1q+=\"Fill\";if(D5U.inputs[T1q]){R4Y={panelName:D5U.panel};for(var G$$ in D5U.outputs){g$p=\"C\";g$p+=\"h\";g$p+=\"anne\";g$p+=\"l\";v81=G$$.split(\" \").pop();if(v81 == \"Top\" || v81 == \"High\"){R4Y.topBand=G$$ + \" \" + D5U.name;}else if(v81 == \"Bottom\" || v81 == \"Low\"){R4Y.bottomBand=G$$ + \" \" + D5U.name;}else if(v81 == \"Median\" || v81 == g$p){R4Y.color=e53.Studies.determineColor(D5U.outputs[G$$]);}}if(D5U.parameters && D5U.parameters.opacity){R4Y.opacity=D5U.parameters.opacity;}else {R4Y.opacity=0.2;}S6G=O2Z.panels[D5U.panel];R4Y.skipTransform=S6G.name != D5U.chart.name;R4Y.yAxis=D5U.getYAxis(O2Z);if(!D5U.highlight && O2Z.highlightedDraggable){R4Y.opacity*=0.3;}e53.prepareChannelFill(O2Z,R4Y);}e53.Studies.displaySeriesAsLine(O2Z,D5U,F_f);};e53.Studies.initAnchorHandle=function(f5X,i6B){var {handle:S5F}=i6B;Q_p.y6g();if(S5F){return;}if(!f5X.controls.anchorHandles){f5X.controls.anchorHandles={};}var {anchorHandles:Q3h, chartControls:D0k}=f5X.controls;if(Q3h[i6B.uniqueId]){({handle:S5F}=Q3h[i6B.uniqueId]);}else {S5F=document.createElement(\"div\");S5F.classList.add(\"stx_anchor_handle\");S5F.setAttribute(i6B.uniqueId,\"\");Q3h[i6B.uniqueId]={handle:S5F,sd:i6B};if(D0k){D0k.parentElement.appendChild(S5F);}}i6B.anchorHandle=S5F;};e53.Studies.removeAnchorHandle=function(E$q,Y8x){var {handle:F34}=(E$q.controls.anchorHandles || ({}))[Y8x.uniqueId] || ({});Q_p.y6g();if(F34){delete E$q.controls.anchorHandles[Y8x.uniqueId];F34.remove();}};e53.Studies.repositionAnchor=function(V3B,j8U){var s8j,m6P,i23,e_h,N3N,d8l,S0k;var {currentAnchorTime:I6v, uniqueId:J6M}=j8U;var {hoverTick:u5o}=V3B.repositioningAnchorSelector || ({});var {dataSet:U1b, market:l4X}=V3B.chart;Q_p.y6g();if(!V3B.controls.anchorHandles){V3B.controls.anchorHandles={};}var {anchorHandles:B_M}=V3B.controls;s8j={};if(u5o || u5o === 0){if(u5o >= U1b.length){return;}m6P=!j8U.inputs.hasOwnProperty(\"Anchor Date\");i23=U1b[u5o].DT;e_h=e53.Studies.getMarketOffset({stx:V3B,localQuoteDate:i23,shiftToDateBoundary:!![]});if(I6v && m6P && new Date(i23.getTime() + e_h).getDate() !== new Date(I6v.getTime() + e_h).getDate()){return;}if(l4X.market_def && l4X.market_def.market_tz){i23=new f7_.Date(i23,l4X.market_def.market_tz);}N3N=!m6P && e53.dateToStr(i23,\"YYYY-MM-dd\");d8l=e53.dateToStr(i23,\"HH:mm:ss\");s8j={\"Anchor Time\":d8l};if(N3N){s8j[\"Anchor Date\"]=N3N;}}S0k=e53.Studies.replaceStudy(V3B,j8U.inputs.id,j8U.type,Object.assign(j8U.inputs,s8j),j8U.outputs,j8U.parameters,j8U.panel);if(B_M[J6M]){B_M[J6M].sd=S0k;}V3B.draw();};e53.Studies.cancelRepositionAnchor=function(F4t){var {sd:D0q, tapToAdd:l8V}=F4t.repositioningAnchorSelector || ({});if(!D0q){return;}Q_p.j1L();if(l8V){e53.Studies.removeStudy(F4t,D0q);}F4t.repositioningAnchorSelector=null;var {anchorHandles:m1u}=F4t.controls;if(m1u && m1u[D0q.uniqueId]){m1u[D0q.uniqueId].highlighted=!({});e53.Studies.displayAnchorHandleAndLine(F4t,D0q,F4t.chart.dataSegment);}F4t.draw();};e53.Studies.displayAnchorHandleAndLine=function(b40,I4q,Q82){var h3q,g5g,X$_,T9R,a3C,I5$,I1Z,m9M,v1w,N3X,r_3,W9j,C69,L4L,V$i,B9_,Y4h,r66,b$K,J1v;h3q=\"stx_\";h3q+=\"anchor_h\";h3q+=\"andle\";if(I4q.signalData && !I4q.signalData.reveal){return;}g5g=(b40.repositioningAnchorSelector || ({})).sd === I4q;var {hoverTick:w8m}=g5g && b40.repositioningAnchorSelector;var {chart:q3k, panels:e7N, cy:l1j}=b40;var {market:v4k = {}, symbol:F_H}=q3k;X$_=e7N[I4q.panel];var {top:M0N, right:t25, left:O$H, height:P0f, subholder:Y_A}=X$_;var {bottom:N_a}=X$_.yAxis;Q_p.G4m(42);var {inputs:f9C, anchorHandle:O9C, currentAnchorTime:L$K, lineWidth:E0a = k_Cdw.F9v(\"1\",32)}=I4q;var {backgroundColor:T2x, borderLeftColor:j0j}=b40.canvasStyle(h3q);T9R=!f9C[\"Anchor Date\"];a3C=e53.getFn(\"Market.Symbology.isForexSymbol\")(F_H);I5$=(w8m || w8m === 0) && (b40.chart.dataSet[w8m] || ({})).DT;I1Z=e53.Studies.getMarketOffset({stx:b40,localQuoteDate:Q82[Q82.length - 1].DT,shiftToDateBoundary:!!({})});m9M=L$K && I5$ && T9R && new Date(I5$.getTime() + I1Z).getDate() !== new Date(L$K.getTime() + I1Z).getDate();var {floatDate:e72, anchorHandles:z76 = {}}=b40.controls;v1w=z76[I4q.uniqueId] || ({});var {highlighted:p3u}=v1w;var [H3z,C4m]=v4k.getNormalOpen().split(3120 > 4860?(579.75,9680) != \"635.27\" * 1?(334.65,9060) === (730.98,218.69)?!\"1\":(\"g\",0x1b01):0x956:\":\").map(j6n=>{return parseInt(j6n);});N3X=q$t=>{var V1M;V1M=q$t?b40.tickFromDate(q$t,null,null,!!({})):w8m;return [b40.pixelFromTick(V1M,q3k),V1M];};r_3={y0:M0N,y1:N_a,type:\"line\",confineToPanel:X$_};var [e9M]=N3X();if(e9M){e9M-=0.5;b40.plotLine(Object.assign(r_3,{x0:e9M,x1:e9M,color:m9M?j0j:T2x,pattern:[6,6],lineWidth:\"1\" ^ 0,opacity:m9M?0.5:1}));e53.efficientDOMUpdate(e72.style,\"visibility\",\"\");b40.updateChartAccessories();}if(O9C){W9j=T9R?new Date(Q82[Q82.length - +\"1\"].DT):e53.strToDate(f9C[\"Anchor Date\"]);if(v4k.market_def && v4k.market_def.market_tz){W9j=new f7_.Date(W9j,v4k.market_def.market_tz);}if(!T9R){var [O4x,X5M,A6Z]=(f9C[\"Anchor Date\"] || \"\").split((2110,182.81) >= (93.28,473.42)?854.91:822 === (+\"5820\",+\"5561\")?(0x1052,![]):466 <= (\"930\" >> 64,7456)?\"-\":(0x148f,0x26a9));if(!A6Z){[,O4x,X5M,A6Z]=O4x.match(/([0-9]{4})([0-9]{2})([0-9]{2})/);}Q_p.b8R(4);W9j.setFullYear(O4x,Q_p.F9v(X5M,1),A6Z);}var [j1P,F$X,D8m = 0]=(f9C[\"Anchor Time\"] || \"\").split((\"2180\" | 4) == (274.7,+\"8808\")?\"Z\":5040 > (3770,8271)?(\"210.98\" - 0,9607) >= 724.97?(0x20f9,\"u\"):(\"o\",\"i\"):\":\");if(!F$X && F$X !== 0){[,j1P,F$X,D8m]=j1P.match(/([0-9]{2})([0-9]{2})([0-9]{2})/);}W9j.setHours(j1P,F$X,D8m);C69=a3C && (W9j.getHours() > H3z || W9j.getHours() === H3z && W9j.getMinutes() >= C4m);if(C69){W9j.setDate(W9j.getDate() - 1);}var [K28,o5l]=N3X(W9j);L4L=new Date(W9j);L4L.setHours(...v4k.getNormalClose().split(\":\"));if(C69){L4L.setDate(L4L.getDate() + 1);}var [C8R]=L4L && N3X(L4L) || [];if(T9R && (K28 > t25 || C8R > t25)){V$i=new Date(W9j);if(v4k){do {V$i.setDate(V$i.getDate() - 1);}while(!v4k.isMarketDate(V$i));}var [B$7,d6L]=N3X(V$i);if(B$7 > O$H){W9j=V$i;K28=B$7;o5l=d6L;}}K28-=0.5;b40.plotLine(Object.assign(r_3,{x0:K28,x1:K28,color:T2x,pattern:\"solid\",lineWidth:E0a,opacity:p3u || I4q.highlight?1:0.5}));v1w.currentPixel=K28;if(p3u){B9_=\"ew-re\";B9_+=\"siz\";B9_+=\"e\";Y4h=\"p\";Y4h+=\"x\";O9C.style.display=\"\";Q_p.G4m(141);var S5z=Q_p.e7l(12,8,13,619,51);Q_p.G4m(142);var v9t=Q_p.e7l(6,19,2,1,9);O9C.style.height=Math.max(Math.min(\"25\" >> S5z,P0f / (\"4\" | 0)),v9t) + \"px\";r66=O9C.getBoundingClientRect();b$K=Math.max(Math.min(l1j - r66.height / 2,N_a - +\"3\" - r66.height),M0N + +\"3\");Q_p.G4m(0);O9C.style.top=Q_p.e7l(b$K,Y4h);Q_p.b8R(130);var a5R=Q_p.e7l(3,0,3,1);O9C.style.left=(w8m || w8m === \"0\" - 0?e9M:K28) - r66.width / a5R + \"px\";Y_A.style.cursor=B9_;}else {J1v=\"n\";J1v+=\"o\";J1v+=\"n\";J1v+=\"e\";O9C.style.display=J1v;Y_A.style.cursor=\"auto\";}I4q.currentAnchorTime=W9j;I4q.currentAnchorTick=o5l;}};e53.Studies.studyScriptLibrary={};e53.Studies.studyLibrary=e53.Studies.studyLibrary || ({});e53.extend(e53.Studies.studyLibrary,{ma:{name:\"Moving Average\",overlay:!\"\",calculateFN:e53.Studies.calculateMovingAverage,inputs:{Period:50,Field:r$O,Type:\"ma\",Offset:\"0\" * 1},outputs:{MA:l4S}},\"STD Dev\":{name:\"Standard Deviation\",calculateFN:e53.Studies.calculateStandardDeviation,inputs:{Period:14,Field:\"field\",\"Standard Deviations\":2,\"Moving Average Type\":m9T},attributes:{\"Standard Deviations\":{min:0.1,step:0.1}}},\"True Range\":{name:\"True Range\",calculateFN:e53.Studies.calculateStudyATR,inputs:{},outputs:{\"True Range\":\"auto\"}},volume:{name:G8q,range:N3q,yAxis:{ground:!\"\"},seriesFN:e53.Studies.createVolumeChart,calculateFN:e53.Studies.calculateVolume,inputs:{},outputs:{\"Up Volume\":\"#8cc176\",\"Down Volume\":L73}},MACross:{name:\"Moving Average Cross\",overlay:!![],calculateFN:e53.Studies.calculateMultMA,inputs:{\"MA 1 Period\":20,\"MA 2 Period\":50,\"MA 3 Period\":200,Field:\"field\",\"Moving Average Type\":Q37,Offset:0},outputs:{\"MA 1\":\"#e9088c\",\"MA 2\":\"#00afed\",\"MA 3\":\"#f4932f\"}}});};F4=K7P=>{var R4N,Q_U;R4N=\"un\";R4N+=\"defined\";Q_U=typeof _CIQ !== R4N?_CIQ:K7P.CIQ;if(!Q_U.ChartEngine.Driver){console.error(\"symbolLookupBase feature requires first activating quoteFeed feature.\");}else {Q_U.ChartEngine.Driver.Lookup=function(b8G){};Q_U.ChartEngine.Driver.Lookup.prototype.acceptText=function(M5z,U_z,D6U,I3r){if(!this.cb){return;}};}};S9=c3W=>{var R6H;R6H=typeof _CIQ !== \"undefined\"?_CIQ:c3W.CIQ;R6H.ThemeHelper=R6H.ThemeHelper || (function(A4I){var y9i,x3N,A_U,T2L,h67,q9_,l9J,u6h;y9i=\"stx_\";y9i+=\"line_chart\";x3N=\"stx_candle_u\";x3N+=\"p\";k_Cdw.y6g();A_U=\"st\";A_U+=\"x_candle\";A_U+=\"_d\";A_U+=\"own\";T2L=\"C\";T2L+=\"andle\";T2L+=\"/B\";T2L+=\"ar\";h67=\"stx_c\";h67+=\"andle_shadow_e\";h67+=\"ven\";q9_=\"stx_candl\";q9_+=\"e_sha\";q9_+=\"dow_down\";this.params=A4I;l9J=A4I.stx;u6h=\"#F\";u6h+=\"F\";u6h+=\"FFFF\";if(l9J.chart.container){u6h=getComputedStyle(l9J.chart.container).backgroundColor;if(R6H.isTransparent(u6h)){u6h=l9J.containerColor;}}this.settings.chart.Background.color=R6H.hexToRgba(u6h);this.settings.chart[\"Grid Lines\"].color=R6H.hexToRgba(l9J.canvasStyle(\"stx_grid\").color);this.settings.chart[\"Grid Dividers\"].color=R6H.hexToRgba(l9J.canvasStyle(\"stx_grid_dark\").color);this.settings.chart[\"Axis Text\"].color=R6H.hexToRgba(l9J.canvasStyle(\"stx_xaxis\").color);this.settings.chartTypes[\"Candle/Bar\"].up.color=R6H.hexToRgba(l9J.canvasStyle(\"stx_candle_up\").color);this.settings.chartTypes[\"Candle/Bar\"].down.color=R6H.hexToRgba(l9J.canvasStyle(\"stx_candle_down\").color);this.settings.chartTypes[\"Candle/Bar\"].up.wick=R6H.hexToRgba(l9J.canvasStyle(\"stx_candle_shadow_up\").color);this.settings.chartTypes[\"Candle/Bar\"].down.wick=R6H.hexToRgba(l9J.canvasStyle(q9_).color);this.settings.chartTypes[\"Candle/Bar\"].even.wick=R6H.hexToRgba(l9J.canvasStyle(h67).color);this.settings.chartTypes[T2L].up.border=R6H.hexToRgba(l9J.canvasStyle(\"stx_candle_up\").borderLeftColor);this.settings.chartTypes[\"Candle/Bar\"].down.border=R6H.hexToRgba(l9J.canvasStyle(A_U).borderLeftColor);if(R6H.isTransparent(l9J.canvasStyle(x3N).borderLeftColor)){this.settings.chartTypes[\"Candle/Bar\"].up.border=null;}if(R6H.isTransparent(l9J.canvasStyle(\"stx_candle_down\").borderLeftColor)){this.settings.chartTypes[\"Candle/Bar\"].down.border=null;}this.settings.chartTypes.Line.color=R6H.hexToRgba(l9J.canvasStyle(y9i).color);this.settings.chartTypes.Mountain.color=R6H.hexToRgba(l9J.canvasStyle(\"stx_mountain_chart\").backgroundColor);this.settings.chartTypes.Mountain.basecolor=R6H.hexToRgba(l9J.canvasStyle(\"stx_mountain_chart\").color);});R6H.ThemeHelper.prototype.settings={chart:{Background:{color:null},\"Grid Lines\":{color:null},\"Grid Dividers\":{color:null},\"Axis Text\":{color:null}},chartTypes:{\"Candle/Bar\":{up:{color:null,wick:null,border:null},down:{color:null,wick:null,border:null},even:{color:null,wick:null,border:null}},Line:{color:null},Mountain:{color:null,basecolor:null}}};R6H.ThemeHelper.prototype.update=function(F_Z){var G8k,o$H,A6y,p9c,Q2q,G5Z,p49,w31,n4P,j0W,R_f,N49,R4K;G8k=\"borderTopColo\";G8k+=\"r\";o$H=\"c\";o$H+=\"ol\";o$H+=\"or\";A6y=\"stx\";A6y+=\"_candle\";A6y+=\"_\";A6y+=\"down\";p9c=\"st\";p9c+=\"x_sha\";p9c+=\"dow_even\";Q2q=\"colo\";Q2q+=\"r\";G5Z=\"colo\";G5Z+=\"r\";p49=\"Can\";p49+=\"d\";p49+=\"le/Ba\";p49+=\"r\";w31=\"stx_xaxi\";w31+=\"s\";n4P=\"stx\";n4P+=\"_grid_dar\";n4P+=\"k\";j0W=\"G\";j0W+=\"rid Lines\";R_f=\"c\";R_f+=\"o\";function m_A(V5v,A73,v_O){k_Cdw.y6g();var x8y;x8y=N49[V5v];for(var B$c in x8y){F_Z.setStyle(B$c,A73,v_O);}}R_f+=\"lor\";if(!F_Z){F_Z=this.params.stx;}N49={stx_candle_up:{stx_candle_up:!!({}),stx_bar_up:!![],stx_hollow_candle_up:!\"\",stx_line_up:!!\"1\",stx_baseline_up:!0},stx_candle_down:{stx_candle_down:!0,stx_bar_down:!![],stx_hollow_candle_down:!\"\",stx_line_down:!![],stx_baseline_down:!!({})},stx_candle_even:{stx_hollow_candle_even:!!({}),stx_bar_even:!!1},stx_shadow_up:{stx_candle_shadow_up:!!({})},stx_shadow_down:{stx_candle_shadow_down:!0},stx_shadow_even:{stx_candle_shadow_even:!!1},stx_line_chart:{stx_bar_chart:!!1,stx_line_chart:!!({})},stx_grid:{stx_grid:!0},stx_grid_dark:{stx_grid_dark:!!\"1\"},stx_xaxis:{stx_xaxis_dark:!![],stx_xaxis:!\"\",stx_yaxis:!!1,stx_yaxis_dark:!![],stx_grid_border:!0},stx_mountain_chart:{stx_mountain_chart:!!1},stx_market_session:{stx_market_session:!!({})}};F_Z.chart.container.style.backgroundColor=this.settings.chart.Background.color;F_Z.defaultColor=\"\";m_A(\"stx_grid\",R_f,this.settings.chart[j0W].color);m_A(n4P,\"color\",this.settings.chart[\"Grid Dividers\"].color);m_A(w31,\"color\",this.settings.chart[\"Axis Text\"].color);R4K=this.settings.chartTypes[p49];if(!R4K.even){R4K.even={color:null,wick:R6H.hexToRgba(F_Z.canvasStyle(\"stx_candle_shadow_even\").color),border:null};}m_A(\"stx_candle_up\",G5Z,R4K.up.color);m_A(\"stx_candle_down\",\"color\",R4K.down.color);m_A(\"stx_candle_even\",\"color\",R4K.even.color);m_A(\"stx_shadow_up\",Q2q,R4K.up.wick);m_A(\"stx_shadow_down\",\"color\",R4K.down.wick);m_A(p9c,\"color\",R4K.even.wick);F_Z.setStyle(\"stx_candle_up\",\"borderLeftColor\",R4K.up.border);F_Z.setStyle(A6y,\"borderLeftColor\",R4K.down.border);m_A(\"stx_line_chart\",o$H,this.settings.chartTypes.Line.color);F_Z.setStyle(\"stx_mountain_chart\",G8k,R6H.hexToRgba(this.settings.chartTypes.Mountain.color,1));F_Z.setStyle(\"stx_mountain_chart\",\"backgroundColor\",R6H.hexToRgba(this.settings.chartTypes.Mountain.color,0.5));F_Z.setStyle(\"stx_mountain_chart\",\"color\",R6H.hexToRgba(this.settings.chartTypes.Mountain.basecolor,0.01));F_Z.draw();};R6H.ChartEngine.prototype.setThemeSettings=function(p5H){var J37,Y5a;this.styles={};this.chart.container.style.backgroundColor=\"\";this.defaultColor=\"\";if(p5H){J37=new R6H.ThemeHelper({stx:this});J37.settings=p5H;J37.update();}this.updateListeners(\"theme\");this.changeOccurred(\"theme\");k_Cdw.j1L();if(this.displayInitialized){Y5a=\"t\";Y5a+=\"he\";Y5a+=\"m\";Y5a+=\"e\";this.headsUpHR();this.clearPixelCache();this.updateListeners(Y5a);this.draw();}};};r3=e2x=>{var o2t=k_Cdw;var D0$,g1e,t8A,s0v,L8d,z$w,R6o,o7$,l9d,U1G,G3C,U7L,V6B,x4I,Q2V,F1f,q43,E_h,r76,N2L,d9_,Z$j,w8J,D26,r2z,J$e,u18,u2N,g4f,b$0,S5U,e6T,c$8,F$R,W2K,q_u,z77,h7n,e9W,p7n,L0Z,i$T,J6i,L2R,u$_,v5d,Q7P,F_B,O5x,o6x,k3E,D0n,u14,q5Q,R16,C9l,M6e,P1T,f69,A6d,e5m,H$8,G0x,v93,O37,H91,A90,C8D,v8K,t83,G2P,D8Y,Z9e,I4B,r11,O6N,U$8,p5M,f4a,t7y,k_p,i56,l6V,E$X,K2Z,x4D,J5g,x$4,x47,Q62,D9F,E9Q,Y8n,t3k,U8v,w50,A9o,E2u,V8r,B22,r2G,h$Q,j3O,J3J,n8v,y5R,p3$,e6R,f2$,A2a,i08,E2H,Y6T,N53,T68,s_I,d1R,z5a,n8a,e$0,B3i,S7U,j_F,s7h,k0h,z4T,o9W,v_3,f9Y,s3i,m$B,w4J,Q02,x1Q,i_h,s1w,g$j,p51,l4u,I31,T9C,h1c,I1S,s_B,G5U,I3V,k65,l2x,k46,Y41,c_F,Y6Y,w6l,t0o,X6v,c0F,z5z,F1Q,b90,I17,p_q,K4F,m9s,X0k,S$y,R3E,s0F,Z4L,L8O,A6N,E1c,z7l,q6f,t7M,g4g,o$r,I1P,U03,m$G,z2q,Q4T,v64,f8t,n3e,F8T,T6Z,a0t;D0$=\"S\";D0$+=\"u\";D0$+=\"n>=22\";g1e=\"Sun\";g1e+=\">=2\";t8A=\"A\";t8A+=\"p\";t8A+=\"r\";s0v=\"Sun>\";s0v+=\"=9\";L8d=\"A\";L8d+=\"u\";L8d+=\"g\";z$w=\"M\";z$w+=\"a\";z$w+=\"y\";R6o=\"on\";R6o+=\"l\";R6o+=\"y\";o7$=\"S\";o7$+=\"un\";o7$+=\">=\";o7$+=\"8\";l9d=\"m\";l9d+=\"a\";l9d+=\"x\";U1G=\"M\";U1G+=\"a\";U1G+=\"r\";G3C=\"N\";G3C+=\"o\";G3C+=\"v\";U7L=\"lastS\";U7L+=\"un\";V6B=\"m\";V6B+=\"a\";V6B+=\"x\";x4I=\"m\";x4I+=\"a\";x4I+=\"x\";Q2V=\"M\";Q2V+=\"ar\";F1f=\"m\";F1f+=\"a\";F1f+=\"x\";q43=\"No\";q43+=\"v\";E_h=\"Ma\";E_h+=\"r\";r76=\"m\";r76+=\"a\";r76+=\"x\";N2L=\"la\";N2L+=\"s\";N2L+=\"tS\";N2L+=\"un\";d9_=\"las\";d9_+=\"tSun\";Z$j=\"m\";Z$j+=\"a\";Z$j+=\"x\";w8J=\"S\";w8J+=\"u\";w8J+=\"n>=\";w8J+=\"1\";D26=\"lastS\";D26+=\"u\";D26+=\"n\";r2z=\"m\";r2z+=\"a\";r2z+=\"x\";J$e=\"Sun>=\";J$e+=\"8\";u18=\"D\";u18+=\"ec\";u2N=\"o\";u2N+=\"nl\";u2N+=\"y\";g4f=\"J\";g4f+=\"a\";g4f+=\"n\";b$0=\"Su\";b$0+=\"n\";b$0+=\">=\";b$0+=\"1\";S5U=\"A\";S5U+=\"p\";S5U+=\"r\";e6T=\"ma\";e6T+=\"x\";c$8=\"S\";c$8+=\"un>=1\";F$R=\"O\";F$R+=\"ct\";W2K=\"S\";W2K+=\"un>\";W2K+=\"=1\";q_u=\"m\";q_u+=\"a\";q_u+=\"x\";z77=\"S\";z77+=\"un\";z77+=\">=\";z77+=\"1\";h7n=\"m\";h7n+=\"a\";h7n+=\"x\";e9W=\"las\";e9W+=\"tFr\";e9W+=\"i\";p7n=\"Oc\";p7n+=\"t\";L0Z=\"ma\";L0Z+=\"x\";i$T=\"las\";i$T+=\"tFri\";J6i=\"Ma\";J6i+=\"r\";L2R=\"ma\";L2R+=\"x\";u$_=\"o\";u$_+=\"n\";u$_+=\"l\";u$_+=\"y\";v5d=\"Sa\";v5d+=\"t>\";v5d+=\"=2\";v5d+=\"4\";Q7P=\"O\";Q7P+=\"c\";Q7P+=\"t\";F_B=\"las\";F_B+=\"tSun\";O5x=\"ma\";O5x+=\"x\";o6x=\"ma\";o6x+=\"x\";k3E=\"O\";k3E+=\"c\";k3E+=\"t\";D0n=\"m\";D0n+=\"a\";D0n+=\"x\";u14=\"la\";u14+=\"st\";u14+=\"T\";u14+=\"hu\";q5Q=\"O\";q5Q+=\"c\";q5Q+=\"t\";R16=\"Ma\";R16+=\"r\";C9l=\"m\";C9l+=\"a\";C9l+=\"x\";M6e=\"2\";M6e+=\"0\";P1T=\"Se\";P1T+=\"p\";f69=\"o\";f69+=\"n\";f69+=\"ly\";A6d=\"M\";A6d+=\"a\";A6d+=\"r\";e5m=\"lastS\";e5m+=\"un\";H$8=\"M\";H$8+=\"ar\";G0x=\"m\";G0x+=\"a\";G0x+=\"x\";v93=\"las\";v93+=\"tSun\";O37=\"lastS\";O37+=\"un\";H91=\"m\";H91+=\"ax\";A90=\"o\";A90+=\"n\";A90+=\"l\";A90+=\"y\";C8D=\"F\";C8D+=\"e\";C8D+=\"b\";v8K=\"on\";v8K+=\"l\";v8K+=\"y\";t83=\"A\";t83+=\"p\";t83+=\"r\";G2P=\"1\";G2P+=\"4\";D8Y=\"o\";D8Y+=\"n\";D8Y+=\"l\";D8Y+=\"y\";Z9e=\"1\";Z9e+=\"0\";I4B=\"3\";I4B+=\"0\";r11=\"A\";r11+=\"p\";r11+=\"r\";O6N=\"M\";O6N+=\"a\";O6N+=\"r\";U$8=\"1\";U$8+=\"1\";p5M=\"3\";p5M+=\"1\";f4a=\"1\";f4a+=\"9\";t7y=\"o\";t7y+=\"nly\";k_p=\"o\";k_p+=\"nly\";i56=\"M\";i56+=\"a\";i56+=\"y\";l6V=\"o\";l6V+=\"n\";l6V+=\"l\";l6V+=\"y\";E$X=\"M\";E$X+=\"a\";E$X+=\"y\";K2Z=\"on\";K2Z+=\"ly\";x4D=\"Asia/\";x4D+=\"R\";x4D+=\"i\";x4D+=\"yadh\";J5g=\"Europe/\";J5g+=\"Buc\";J5g+=\"harest\";x$4=\"-\";x$4+=\"0\";x$4+=\"4\";x47=\"-\";x47+=\"0\";x47+=\"2\";Q62=\"-04/\";Q62+=\"-0\";Q62+=\"3\";D9F=\"Pa\";D9F+=\"r\";D9F+=\"a\";E9Q=\"-\";E9Q+=\"04/-03\";Y8n=\"C\";Y8n+=\"hile\";t3k=\"AS\";t3k+=\"T\";U8v=\"E\";U8v+=\"%\";U8v+=\"s\";U8v+=\"T\";w50=\"Ha\";w50+=\"i\";w50+=\"ti\";A9o=\"C\";A9o+=\"u\";A9o+=\"b\";A9o+=\"a\";E2u=\"C\";E2u+=\"%sT\";V8r=\"C\";V8r+=\"%\";V8r+=\"s\";V8r+=\"T\";B22=\"A%\";B22+=\"sT\";r2G=\"N\";r2G+=\"%\";r2G+=\"sT\";h$Q=\"Ca\";h$Q+=\"nada\";j3O=\"U\";j3O+=\"S\";J3J=\"+\";J3J+=\"0\";J3J+=\"3\";n8v=\"E\";n8v+=\"U\";y5R=\"C\";y5R+=\"E%\";y5R+=\"sT\";p3$=\"+\";p3$+=\"1\";p3$+=\"1\";e6R=\"+\";e6R+=\"0\";e6R+=\"9\";f2$=\"+\";f2$+=\"0\";f2$+=\"5\";A2a=\"+\";A2a+=\"0\";A2a+=\"3\";i08=\"+\";i08+=\"0\";i08+=\"4\";E2H=\"+\";E2H+=\"03\";Y6T=\"E\";Y6T+=\"U\";N53=\"E\";N53+=\"U\";T68=\"C\";T68+=\"E%s\";T68+=\"T\";s_I=\"E\";s_I+=\"U\";d1R=\"A\";d1R+=\"%s\";d1R+=\"T\";z5a=\"Thu\";z5a+=\"le\";n8a=\"C\";n8a+=\"E\";n8a+=\"%sT\";e$0=\"E\";e$0+=\"U\";B3i=\"E\";B3i+=\"E%\";B3i+=\"s\";B3i+=\"T\";S7U=\"C\";S7U+=\"E\";S7U+=\"%\";S7U+=\"sT\";j_F=\"C\";j_F+=\"-Eur\";s7h=\"WE%s\";s7h+=\"T\";k0h=\"IS\";k0h+=\"T/GMT\";z4T=\"+13\";z4T+=\"/+14\";o9W=\"W\";o9W+=\"S\";v_3=\"S\";v_3+=\"S\";v_3+=\"T\";f9Y=\"N\";f9Y+=\"Z\";f9Y+=\"%\";f9Y+=\"sT\";s3i=\"C\";s3i+=\"h\";s3i+=\"ST\";m$B=\"Fij\";m$B+=\"i\";w4J=\"AE\";w4J+=\"%sT\";Q02=\"A\";Q02+=\"N\";x1Q=\"A\";x1Q+=\"V\";i_h=\"A\";i_h+=\"E\";i_h+=\"%sT\";s1w=\"A\";s1w+=\"T\";g$j=\"A\";g$j+=\"S\";p51=\"A\";p51+=\"E%sT\";l4u=\"AW\";l4u+=\"%s\";l4u+=\"T\";I31=\"AC%\";I31+=\"sT\";T9C=\"+\";T9C+=\"0\";T9C+=\"4\";h1c=\"+\";h1c+=\"0\";h1c+=\"7\";I1S=\"E\";I1S+=\"E\";I1S+=\"%\";I1S+=\"sT\";s_B=\"Mon\";s_B+=\"g\";s_B+=\"ol\";G5U=\"KS\";G5U+=\"T\";I3V=\"KS\";I3V+=\"T\";k65=\"A\";k65+=\"L\";k65+=\"M\";k65+=\"T\";l2x=\"J\";l2x+=\"%\";l2x+=\"sT\";k46=\"+0330/+\";k46+=\"0\";k46+=\"430\";Y41=\"I\";Y41+=\"S\";Y41+=\"T\";c_F=\"E\";c_F+=\"E\";c_F+=\"%s\";c_F+=\"T\";Y6Y=\"+06\";Y6Y+=\"30\";w6l=\"+\";w6l+=\"0\";w6l+=\"4/+05\";t0o=\"T\";t0o+=\"r\";t0o+=\"oll\";X6v=\"%\";X6v+=\"s\";c0F=\"M\";c0F+=\"orocco\";z5z=\"EA\";z5z+=\"T\";F1Q=\"-\";F1Q+=\"0\";F1Q+=\"1\";b90=\"Pac\";b90+=\"if\";b90+=\"ic/Tongatapu\";I17=\"Pac\";I17+=\"ific/Auc\";I17+=\"k\";I17+=\"land\";p_q=\"Asia/Ka\";p_q+=\"mch\";p_q+=\"a\";p_q+=\"tka\";K4F=\"Pacifi\";K4F+=\"c/Guam\";m9s=\"Aust\";m9s+=\"ralia/\";m9s+=\"D\";m9s+=\"arwin\";X0k=\"A\";X0k+=\"sia\";X0k+=\"/\";X0k+=\"Seoul\";S$y=\"Asia\";S$y+=\"/Pyongy\";S$y+=\"a\";S$y+=\"ng\";R3E=\"A\";R3E+=\"sia/\";R3E+=\"Novosibi\";R3E+=\"rsk\";s0F=\"As\";s0F+=\"ia/Novokuznets\";s0F+=\"k\";Z4L=\"A\";Z4L+=\"sia/Yan\";Z4L+=\"gon\";L8O=\"As\";L8O+=\"ia/Almaty\";A6N=\"Asia\";A6N+=\"/Baku\";E1c=\"Europ\";E1c+=\"e\";E1c+=\"/Saraje\";E1c+=\"vo\";o2t.j1L();z7l=\"Europe/Ams\";z7l+=\"terd\";z7l+=\"am\";q6f=\"A\";q6f+=\"fri\";q6f+=\"ca/Casablan\";q6f+=\"ca\";t7M=\"U\";t7M+=\"TC\";g4g=\"America/Pun\";g4g+=\"ta_Ar\";g4g+=\"enas\";o$r=\"America\";o$r+=\"/Argentina/Buenos_Aires\";I1P=\"America/Pana\";I1P+=\"ma\";U03=\"Amer\";U03+=\"ic\";U03+=\"a\";U03+=\"/St_Johns\";m$G=\"America/Santia\";m$G+=\"go\";z2q=\"America\";z2q+=\"/Asunc\";z2q+=\"ion\";Q4T=\"Ame\";Q4T+=\"ri\";Q4T+=\"ca/C\";Q4T+=\"hicago\";v64=\"A\";v64+=\"merica/\";v64+=\"P\";v64+=\"hoenix\";f8t=\"Americ\";f8t+=\"a/Juneau\";n3e=\"Pacif\";n3e+=\"ic/Honolu\";n3e+=\"lu\";F8T=\"u\";F8T+=\"n\";F8T+=\"de\";F8T+=\"fined\";T6Z=typeof _CIQ !== \"undefined\"?_CIQ:e2x.CIQ;a0t=typeof _timezoneJS !== F8T?_timezoneJS:e2x.timezoneJS;T6Z.timeZoneMap={\"(UTC-11:00) American Samoa, Midway Island\":\"Pacific/Pago_Pago\",\"(UTC-10:00) Hawaii\":n3e,\"(UTC-09:00) Alaska\":f8t,\"(UTC-08:00) Pacific Time (US and Canada), Tijuana\":\"America/Los_Angeles\",\"(UTC-07:00) Arizona\":v64,\"(UTC-07:00) Chihuahua, Mazatlan\":\"America/Chihuahua\",\"(UTC-07:00) Mountain Time (US and Canada)\":\"America/Denver\",\"(UTC-06:00) Central America\":\"America/Costa_Rica\",\"(UTC-06:00) Central Time (US and Canada)\":Q4T,\"(UTC-06:00) Guadalajara, Mexico City, Monterrey\":\"America/Mexico_City\",\"(UTC-06:00) Saskatchewan\":\"America/Regina\",\"(UTC-05:00) Bogota, Lima, Quito, Rio Branco\":\"America/Bogota\",\"(UTC-05:00) Eastern Time (US and Canada)\":\"America/New_York\",\"(UTC-05:00) Havana\":\"America/Havana\",\"(UTC-05:00) Port-au-Prince\":\"America/Port-au-Prince\",\"(UTC-04:00) Asuncion\":z2q,\"(UTC-04:00) Santiago\":m$G,\"(UTC-04:00) Caracas\":\"America/Caracas\",\"(UTC-04:00) Atlantic Time (Canada)\":\"America/Halifax\",\"(UTC-04:00) Georgetown, La Paz, Manaus, San Juan\":\"America/Puerto_Rico\",\"(UTC-03:30) Newfoundland and Labrador\":U03,\"(UTC-03:00) Cancun, Jamaica, Panama\":I1P,\"(UTC-03:00) Buenos Aires\":o$r,\"(UTC-03:00) Punta Arenas\":g4g,\"(UTC-03:00) Montevideo\":\"America/Montevideo\",\"(UTC-03:00) Sao Paulo\":\"America/Sao_Paulo\",\"(UTC-02:00) Mid-Atlantic\":\"Atlantic/South_Georgia\",\"(UTC-01:00) Azores\":\"Atlantic/Azores\",\"(UTC-01:00) Cape Verde Islands\":\"Atlantic/Cape_Verde\",\"(UTC) Greenwich Mean Time, Reykjavik\":t7M,\"(UTC) Dublin\":\"Europe/Dublin\",\"(UTC) Lisbon, London\":\"Europe/London\",\"(UTC+01:00) Algiers, Tunis\":\"Africa/Tunis\",\"(UTC+01:00) Casablanca\":q6f,\"(UTC+01:00) Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna\":z7l,\"(UTC+01:00) Belgrade, Bratislava, Budapest, Ljubljana, Prague\":\"Europe/Belgrade\",\"(UTC+01:00) Brussels, Copenhagen, Madrid, Paris\":\"Europe/Brussels\",\"(UTC+01:00) Sarajevo, Skopje, Warsaw, Zagreb\":E1c,\"(UTC+02:00) Kaliningrad\":\"Europe/Kaliningrad\",\"(UTC+02:00) Athens, Bucharest\":\"Europe/Bucharest\",\"(UTC+02:00) Cairo\":\"Africa/Cairo\",\"(UTC+02:00) Harare, Johannesburg\":\"Africa/Johannesburg\",\"(UTC+02:00) Helsinki, Kiev, Riga, Sofia, Tallinn, Vilnius\":\"Europe/Helsinki\",\"(UTC+02:00) Cyprus\":\"Asia/Nicosia\",\"(UTC+02:00) Beirut\":\"Asia/Beirut\",\"(UTC+02:00) Damascus\":\"Asia/Damascus\",\"(UTC+02:00) Jerusalem\":\"Asia/Jerusalem\",\"(UTC+02:00) Amman\":\"Asia/Amman\",\"(UTC+03:00) Istanbul\":\"Europe/Istanbul\",\"(UTC+03:00) Baghdad, Kuwait, Qatar, Riyadh\":\"Asia/Riyadh\",\"(UTC+03:00) Minsk, Moscow, Kirov, Simferopol\":\"Europe/Moscow\",\"(UTC+03:00) Volgograd\":\"Europe/Volgograd\",\"(UTC+03:00) Nairobi\":\"Africa/Nairobi\",\"(UTC+03:30) Tehran\":\"Asia/Tehran\",\"(UTC+04:00) Baku\":A6N,\"(UTC+04:00) Dubai, Muscat\":\"Asia/Dubai\",\"(UTC+04:00) Astrakhan, Samara, Saratov, Ulyanovsk\":\"Europe/Samara\",\"(UTC+04:30) Kabul\":\"Asia/Kabul\",\"(UTC+05:00) Karachi, Tashkent\":\"Asia/Karachi\",\"(UTC+05:00) Yekaterinburg\":\"Asia/Yekaterinburg\",\"(UTC+05:30) Chennai, Kolkata, Mumbai, New Delhi\":\"Asia/Kolkata\",\"(UTC+05:45) Kathmandu\":\"Asia/Kathmandu\",\"(UTC+06:00) Almaty\":L8O,\"(UTC+06:00) Omsk\":\"Asia/Omsk\",\"(UTC+06:00) Astana, Dhaka\":\"Asia/Dhaka\",\"(UTC+06:30) Yangon\":Z4L,\"(UTC+07:00) Bangkok, Jakarta, Vietnam\":\"Asia/Bangkok\",\"(UTC+07:00) Hovd\":\"Asia/Hovd\",\"(UTC+07:00) Krasnoyarsk\":\"Asia/Krasnoyarsk\",\"(UTC+07:00) Novokuznetsk\":s0F,\"(UTC+07:00) Barnaul, Novosibirsk, Tomsk\":R3E,\"(UTC+08:00) Beijing, Chongqing, Hong Kong SAR\":\"Asia/Hong_Kong\",\"(UTC+08:00) Brunei, Kuala Lumpur, Singapore\":\"Asia/Kuala_Lumpur\",\"(UTC+08:00) Irkutsk\":\"Asia/Irkutsk\",\"(UTC+08:00) Choibalsan, Ulaanbaatar\":\"Asia/Ulaanbaatar\",\"(UTC+08:00) Manila, Taipei\":\"Asia/Taipei\",\"(UTC+08:00) Perth\":\"Australia/Perth\",\"(UTC+08:45) Eucla\":\"Australia/Eucla\",\"(UTC+09:00) Osaka, Sapporo, Tokyo\":\"Asia/Tokyo\",\"(UTC+09:00) Pyongyang\":S$y,\"(UTC+09:00) Seoul\":X0k,\"(UTC+09:00) Chita, Khandyga, Yakutsk\":\"Asia/Yakutsk\",\"(UTC+09:30) Adelaide\":\"Australia/Adelaide\",\"(UTC+09:30) Darwin\":m9s,\"(UTC+10:00) Brisbane\":\"Australia/Brisbane\",\"(UTC+10:00) Canberra, Melbourne, Sydney\":\"Australia/Sydney\",\"(UTC+10:00) Guam, Port Moresby\":K4F,\"(UTC+10:00) Ust-Nera, Vladivostok\":\"Asia/Vladivostok\",\"(UTC+11:00) Noumea, Solomon Islands\":\"Pacific/Noumea\",\"(UTC+11:00) Magadan\":\"Asia/Magadan\",\"(UTC+11:00) Sakhalin, Srednekolymsk\":\"Asia/Srednekolymsk\",\"(UTC+12:00) Anadyr, Kamchatka\":p_q,\"(UTC+12:00) Auckland, Wellington\":I17,\"(UTC+12:00) Fiji\":\"Pacific/Fiji\",\"(UTC+12:45) Chatham\":\"Pacific/Chatham\",\"(UTC+13:00) Tonga\":b90,\"(UTC+13:00) Samoa\":\"Pacific/Apia\",\"(UTC+14:00) Kiritimati\":\"Pacific/Kiritimati\"};(function(){var t4g,O7t,w9b,L60,E75,b2s,H4S,c9f,a9W,v8f,o6p,g_G,k0U,o9h,w$g,Q1i,t9X;t4g=\"Nove\";t4g+=\"mbe\";t4g+=\"r\";O7t=\"Se\";O7t+=\"ptemb\";O7t+=\"er\";w9b=\"Au\";w9b+=\"gu\";w9b+=\"st\";L60=\"A\";L60+=\"pril\";E75=\"undef\";E75+=\"i\";E75+=\"ne\";E75+=\"d\";\"use strict\";b2s=typeof window !== E75?window:null;H4S=b2s || (typeof global !== \"undefined\"?global:{});a0t.VERSION=\"0.4.11\";c9f=H4S.$ || H4S.jQuery || H4S.Zepto;a9W=H4S.fleegix;v8f=a0t.Days=[\"Sunday\",\"Monday\",\"Tuesday\",\"Wednesday\",\"Thursday\",\"Friday\",\"Saturday\"];o6p=a0t.Months=[\"January\",\"February\",\"March\",L60,\"May\",\"June\",\"July\",w9b,O7t,\"October\",t4g,\"December\"];g_G={};k0U={};o9h={};o2t.j1L();for(var h_M=0;h_M < o6p.length;h_M++){g_G[o6p[h_M].substr(0,3)]=h_M;}for(h_M=\"0\" ^ 0;h_M < v8f.length;h_M++){k0U[v8f[h_M].substr(0,3)]=h_M;}w$g=Array.prototype.indexOf || (function(q0j){var a9R,Y9e,o$q,H3A;if(this === null){throw new TypeError();}a9R=Object(this);Y9e=a9R.length >>> 0;if(Y9e === 0){o2t.G4m(42);return -o2t.F9v(\"1\",96);}o$q=0;if(arguments.length > 1){o$q=Number(arguments[1]);if(o$q != o$q){o$q=0;}else if(o$q !== +\"0\" && o$q !== Infinity && o$q !== -Infinity){o2t.b8R(143);var f2k=o2t.e7l(1154,5,21,11);o$q=(o$q > 0 || f2k) * Math.floor(Math.abs(o$q));}}if(o$q >= Y9e){return -1;}H3A=o$q >= 0?o$q:Math.max(Y9e - Math.abs(o$q),0);o2t.j1L();for(;H3A < Y9e;H3A++){if((H3A in a9R) && a9R[H3A] === q0j){return H3A;}}return -1;});Q1i=function(J8k,X1o){var m6D,b8V,Z0c;if(typeof J8k !== \"number\"){o2t.G4m(0);throw o2t.F9v(\"not a number: \",J8k);}o2t.b8R(100);m6D=o2t.F9v(J8k,1000);b8V=J8k.toString();Z0c=b8V.length;if(m6D && Z0c > X1o){o2t.b8R(4);return b8V.substr(o2t.e7l(Z0c,X1o),Z0c);}b8V=[b8V];while(Z0c < X1o){b8V.unshift((2754,8777) >= +\"4682\"?649 >= 605?\"0\":(!0,+\"2.50e+3\"):(\"m\",+\"286.17\"));Z0c++;}return b8V.join(\"\");};t9X=function(Z9v){var m6d,I$H,d7x;m6d=\"te\";m6d+=\"x\";m6d+=\"t\";I$H=\"undefine\";I$H+=\"d\";d7x=\"URL must \";d7x+=\"be\";d7x+=\" specified\";if(!Z9v){return;}if(!Z9v.url){throw new Error(d7x);}if(!((\"async\" in Z9v))){Z9v.async=!!\"1\";}if((!a9W || typeof a9W.xhr === \"undefined\") && (!c9f || typeof c9f.ajax === I$H)){throw new Error(\"Please use the Fleegix.js XHR module, jQuery ajax, Zepto ajax, or define your own transport mechanism for downloading zone files.\");}if(!Z9v.async){return a9W && a9W.xhr?a9W.xhr.doReq({url:Z9v.url,async:!({})}):c9f.ajax({url:Z9v.url,async:!({}),dataType:\"text\"}).responseText;}return a9W && a9W.xhr?a9W.xhr.send({url:Z9v.url,method:\"get\",handleSuccess:Z9v.success,handleErr:Z9v.error}):c9f.ajax({url:Z9v.url,dataType:m6d,method:\"GET\",error:Z9v.error,success:Z9v.success});};a0t.ruleCache={};a0t.Date=function(){var T$x,Y9A,E3s,B1p,M5s,u5w,o$E,k7c,w84;T$x=\"st\";T$x+=\"ri\";T$x+=\"n\";T$x+=\"g\";if(this === a0t){Y9A=\"timezoneJS.Date object m\";Y9A+=\"ust be constructed with 'new'\";throw Y9A;}E3s=Array.prototype.slice.apply(arguments);B1p=null;M5s=null;u5w=[];o$E=![];if(Object.prototype.toString.call(E3s[0]) === \"[object Array]\"){E3s=E3s[0];}if(typeof E3s[E3s.length - 1] === T$x){o$E=Date.parse(E3s[E3s.length - 1].replace(/GMT[+-]\\d+/,\"\"));if(isNaN(o$E) || o$E === null){M5s=E3s.pop();}}k7c=!!0;switch(E3s.length){case +\"0\":B1p=new Date();break;case 1:B1p=new Date(E3s[0]);if(typeof E3s[\"0\" ^ 0] == \"string\" && E3s[0].search(/[+-][0-9]{4}/) == -1 && E3s[0].search(/Z/) == -1 && E3s[0].search(/T/) == -1){k7c=!0;}break;case 2:B1p=new Date(E3s[0],E3s[1]);k7c=!\"\";break;default:for(var c6o=0;c6o < +\"7\";c6o++){u5w[c6o]=E3s[c6o] || 0;}B1p=new Date(u5w[0],u5w[1],u5w[2],u5w[3],u5w[4],u5w[5],u5w[6]);k7c=!!({});break;}if(isNaN(B1p.getTime())){w84=\"In\";w84+=\"va\";w84+=\"lid \";w84+=\"date\";throw new Error(w84);}this._useCache=!1;this._tzInfo={};this._day=0;this.year=0;this.month=0;this.date=0;o2t.G4m(34);this.hours=o2t.e7l(\"0\",0);this.minutes=0;this.seconds=+\"0\";this.milliseconds=0;this.timezone=M5s || null;if(k7c){this.setFromDateObjProxy(B1p);}else {this.setFromTimeProxy(B1p.getTime(),M5s);}};T6Z.extend(a0t.Date.prototype,{getDate:function(){o2t.j1L();return this.date;},getDay:function(){o2t.j1L();return this._day;},getFullYear:function(){o2t.j1L();return this.year;},getMonth:function(){o2t.y6g();return this.month;},getYear:function(){o2t.G4m(33);var x_W=o2t.e7l(1896,17,30332);return this.year - x_W;},getHours:function(){return this.hours;},getMilliseconds:function(){return this.milliseconds;},getMinutes:function(){o2t.j1L();return this.minutes;},getSeconds:function(){return this.seconds;},getUTCDate:function(){o2t.j1L();return this.getUTCDateProxy().getUTCDate();},getUTCDay:function(){o2t.j1L();return this.getUTCDateProxy().getUTCDay();},getUTCFullYear:function(){o2t.y6g();return this.getUTCDateProxy().getUTCFullYear();},getUTCHours:function(){return this.getUTCDateProxy().getUTCHours();},getUTCMilliseconds:function(){o2t.j1L();return this.getUTCDateProxy().getUTCMilliseconds();},getUTCMinutes:function(){return this.getUTCDateProxy().getUTCMinutes();},getUTCMonth:function(){return this.getUTCDateProxy().getUTCMonth();},getUTCSeconds:function(){o2t.y6g();return this.getUTCDateProxy().getUTCSeconds();},getTime:function(){o2t.G4m(58);var v8T=o2t.e7l(95448,360,14,19,18);o2t.b8R(32);var P6C=o2t.e7l(10,1013,5,4015);return this._timeProxy + this.getTimezoneOffset() * v8T * P6C;},getTimezone:function(){o2t.j1L();return this.timezone;},getTimezoneOffset:function(){o2t.j1L();return this.getTimezoneInfo().tzOffset;},getTimezoneAbbreviation:function(){return this.getTimezoneInfo().tzAbbr;},getTimezoneInfo:function(){o2t.y6g();var i6Z,K2o;if(this._useCache){return this._tzInfo;}if(this.timezone){K2o=\"E\";K2o+=\"tc/G\";K2o+=\"M\";K2o+=\"T\";i6Z=this.timezone === \"Etc/UTC\" || this.timezone === K2o?{tzOffset:0,tzAbbr:\"UTC\"}:a0t.timezone.getTzInfo(this._timeProxy,this.timezone);}else {i6Z={tzOffset:this.getLocalOffset(),tzAbbr:null};}this._tzInfo=i6Z;this._useCache=!![];return i6Z;},getUTCDateProxy:function(){var P1u;P1u=new Date(this._timeProxy);P1u.setUTCMinutes(P1u.getUTCMinutes() + this.getTimezoneOffset());return P1u;},setDate:function(B31){this.setAttribute(\"date\",B31);o2t.j1L();return this.getTime();},setFullYear:function(G0G,I4c,u3Q){var x3c,t$8;x3c=\"y\";x3c+=\"e\";x3c+=\"a\";x3c+=\"r\";if(u3Q !== undefined){this.setAttribute(\"date\",1);}this.setAttribute(x3c,G0G);if(I4c !== undefined){this.setAttribute(\"month\",I4c);}if(u3Q !== undefined){t$8=\"d\";t$8+=\"ate\";this.setAttribute(t$8,u3Q);}return this.getTime();},setMonth:function(s_s,x1U){this.setAttribute(\"month\",s_s);if(x1U !== undefined){this.setAttribute(\"date\",x1U);}return this.getTime();},setYear:function(w2y){w2y=Number(w2y);if(0 <= w2y && w2y <= \"99\" >> 0){w2y+=1900;}o2t.j1L();this.setUTCAttribute(\"year\",w2y);return this.getTime();},setHours:function(y8t,I_7,b94,j0G){var c9o,t6E,Z4b,I87,S0i;this.setAttribute(\"hours\",y8t);if(I_7 !== undefined){this.setAttribute(\"minutes\",I_7);}if(b94 !== undefined){c9o=\"s\";c9o+=\"e\";c9o+=\"conds\";this.setAttribute(c9o,b94);}if(j0G !== undefined){t6E=1506764741;Z4b=-1829639526;I87=+\"2\";for(var w57=1;o2t.m1(w57.toString(),w57.toString().length,15612) !== t6E;w57++){S0i=\"m\";S0i+=\"illis\";S0i+=\"econd\";S0i+=\"s\";this.setAttribute(S0i,j0G);I87+=2;}if(o2t.P6(I87.toString(),I87.toString().length,+\"66209\") !== Z4b){this.setAttribute(\"\",j0G);}}return this.getTime();},setMinutes:function(d6v,H97,g7C){var Q05;Q05=\"minut\";Q05+=\"e\";Q05+=\"s\";this.setAttribute(Q05,d6v);if(H97 !== undefined){this.setAttribute(\"seconds\",H97);}if(g7C !== undefined){this.setAttribute(\"milliseconds\",g7C);}return this.getTime();},setSeconds:function(o92,H7r){var F1_;this.setAttribute(\"seconds\",o92);if(H7r !== undefined){F1_=\"mi\";F1_+=\"lli\";F1_+=\"secon\";F1_+=\"ds\";this.setAttribute(F1_,H7r);}return this.getTime();},setMilliseconds:function(V__){this.setAttribute(\"milliseconds\",V__);return this.getTime();},setTime:function(c15){if(isNaN(c15)){throw new Error(\"Units must be a number.\");}this.setFromTimeProxy(c15,this.timezone);o2t.j1L();return this.getTime();},setUTCFullYear:function(g$Q,b1J,S2e){if(S2e !== undefined){this.setUTCAttribute(\"date\",1);}this.setUTCAttribute(\"year\",g$Q);if(b1J !== undefined){this.setUTCAttribute(\"month\",b1J);}if(S2e !== undefined){this.setUTCAttribute(\"date\",S2e);}return this.getTime();},setUTCMonth:function(G9Q,u7q){this.setUTCAttribute(\"month\",G9Q);if(u7q !== undefined){this.setUTCAttribute(\"date\",u7q);}return this.getTime();},setUTCDate:function(E8z){var z19;z19=\"d\";o2t.y6g();z19+=\"a\";z19+=\"t\";z19+=\"e\";this.setUTCAttribute(z19,E8z);return this.getTime();},setUTCHours:function(c$t,m3K,D1j,B8J){var X7w;this.setUTCAttribute(\"hours\",c$t);if(m3K !== undefined){this.setUTCAttribute(\"minutes\",m3K);}if(D1j !== undefined){X7w=\"sec\";X7w+=\"on\";X7w+=\"d\";X7w+=\"s\";this.setUTCAttribute(X7w,D1j);}if(B8J !== undefined){this.setUTCAttribute(\"milliseconds\",B8J);}return this.getTime();},setUTCMinutes:function(d4r,W$m,C1D){var a6r,E5w,W3a,I8r,k1n;a6r=\"m\";a6r+=\"inu\";a6r+=\"te\";a6r+=\"s\";o2t.j1L();this.setUTCAttribute(a6r,d4r);if(W$m !== undefined){E5w=-1671686851;W3a=-816615620;o2t.b8R(4);I8r=o2t.e7l(\"2\",0);for(var Z$C=1;o2t.P6(Z$C.toString(),Z$C.toString().length,34722) !== E5w;Z$C++){this.setUTCAttribute(\"\",W$m);I8r+=2;}if(o2t.m1(I8r.toString(),I8r.toString().length,11531) !== W3a){this.setUTCAttribute(\"seconds\",W$m);}}if(C1D !== undefined){k1n=\"mi\";k1n+=\"l\";k1n+=\"lisecond\";k1n+=\"s\";this.setUTCAttribute(k1n,C1D);}return this.getTime();},setUTCSeconds:function(L48,k8Y){var J68;J68=\"s\";J68+=\"e\";J68+=\"conds\";this.setUTCAttribute(J68,L48);if(k8Y !== undefined){this.setUTCAttribute(\"milliseconds\",k8Y);}return this.getTime();},setUTCMilliseconds:function(v5k){var p2a;p2a=\"m\";p2a+=\"il\";p2a+=\"lisecon\";p2a+=\"ds\";this.setUTCAttribute(p2a,v5k);return this.getTime();},setFromDateObjProxy:function(J0e){this.year=J0e.getFullYear();this.month=J0e.getMonth();this.date=J0e.getDate();this.hours=J0e.getHours();this.minutes=J0e.getMinutes();this.seconds=J0e.getSeconds();this.milliseconds=J0e.getMilliseconds();this._day=J0e.getDay();this._dateProxy=J0e;this._timeProxy=Date.UTC(this.year,this.month,this.date,this.hours,this.minutes,this.seconds,this.milliseconds);this._useCache=!1;},setFromTimeProxy:function(V17,U1I){var b9x,o0i;b9x=new Date(V17);o0i=U1I?a0t.timezone.getTzInfo(V17,U1I,!0).tzOffset:b9x.getTimezoneOffset();b9x.setTime(V17 + (b9x.getTimezoneOffset() - o0i) * 60000);this.setFromDateObjProxy(b9x);},setAttribute:function(j5W,k$u){var f8Y,r4S,C9H,w9K;f8Y=\"y\";f8Y+=\"e\";f8Y+=\"a\";f8Y+=\"r\";if(isNaN(k$u)){r4S=\"Uni\";r4S+=\"ts must be a number.\";throw new Error(r4S);}C9H=this._dateProxy;w9K=j5W === f8Y?\"FullYear\":j5W.substr(0,+\"1\").toUpperCase() + j5W.substr(1);C9H[\"set\" + w9K](k$u);this.setFromDateObjProxy(C9H);},setUTCAttribute:function(m69,p_W){var m4E,Y$E,M1T;m4E=\"setU\";m4E+=\"TC\";if(isNaN(p_W)){throw new Error(\"Units must be a number.\");}Y$E=m69 === \"year\"?\"FullYear\":m69.substr(+\"0\",+\"1\").toUpperCase() + m69.substr(1);M1T=this.getUTCDateProxy();M1T[m4E + Y$E](p_W);M1T.setUTCMinutes(M1T.getUTCMinutes() - this.getTimezoneOffset());this.setFromTimeProxy(M1T.getTime() + this.getTimezoneOffset() * 60000,this.timezone);},setTimezone:function(O98){var j7u;o2t.j1L();j7u=this.getTimezoneInfo().tzOffset;this.timezone=O98;this._useCache=!({});this.setUTCMinutes(this.getUTCMinutes() - this.getTimezoneInfo().tzOffset + j7u);},removeTimezone:function(){o2t.j1L();this.timezone=null;this._useCache=!1;},valueOf:function(){o2t.y6g();return this.getTime();},clone:function(){return this.timezone?new a0t.Date(this.getTime(),this.timezone):new a0t.Date(this.getTime());},toGMTString:function(){o2t.y6g();return this.toString(\"EEE, dd MMM yyyy HH:mm:ss Z\",\"Etc/GMT\");},toLocaleStringIntl:function(){},toLocaleDateString:function(){},toLocaleTimeString:function(){},toSource:function(){},toISOString:function(){var k7s;k7s=\"yyyy-MM-ddTHH\";k7s+=\":mm:ss.SSS\";return this.toString(k7s,\"Etc/UTC\") + \"Z\";},toJSON:function(){return this.toISOString();},toDateString:function(){return this.toString(\"EEE MMM dd yyyy\");},toTimeString:function(){return this.toString(\"H:mm k\");},toString:function(W_a,N5d){var a_s,m$g,f6X,F_s;if(!W_a){W_a=\"yyyy-MM-ddTHH:mm:ss.SSS\";}o2t.y6g();a_s=W_a;m$g=N5d?a0t.timezone.getTzInfo(this.getTime(),N5d):this.getTimezoneInfo();f6X=this;if(N5d){f6X=this.clone();f6X.setTimezone(N5d);}F_s=f6X.getHours();return a_s.replace(/a+/g,function(){o2t.y6g();return (514,4280) >= (845,\"7460\" | 4)?(\"Z\",8.04e+3):\"k\";}).replace(/y+/g,function(E6G){return Q1i(f6X.getFullYear(),E6G.length);}).replace(/d+/g,function(c4S){return Q1i(f6X.getDate(),c4S.length);}).replace(/m+/g,function(Z6T){o2t.j1L();return Q1i(f6X.getMinutes(),Z6T.length);}).replace(/s+/g,function(r4n){return Q1i(f6X.getSeconds(),r4n.length);}).replace(/S+/g,function(T6$){return Q1i(f6X.getMilliseconds(),T6$.length);}).replace(/h+/g,function(X3S){return Q1i(F_s % (\"12\" | 0) === 0?12:F_s % +\"12\",X3S.length);}).replace(/M+/g,function(v6N){var o6Q,y_9;o6Q=f6X.getMonth();y_9=v6N.length;if(y_9 > 3){return a0t.Months[o6Q];}else if(y_9 > 2){return a0t.Months[o6Q].substring(0,y_9);}o2t.y6g();o2t.G4m(0);return Q1i(o2t.e7l(o6Q,1),y_9);}).replace(/k+/g,function(){var x0V;if(F_s >= 12){x0V=\"P\";x0V+=\"M\";if(F_s > 12){F_s-=12;}return x0V;}return \"AM\";}).replace(/H+/g,function(q$N){o2t.y6g();return Q1i(F_s,q$N.length);}).replace(/E+/g,function(X97){o2t.y6g();return v8f[f6X.getDay()].substring(0,X97.length);}).replace(/Z+/gi,function(){return m$g.tzAbbr;});},toUTCString:function(){return this.toGMTString();},civilToJulianDayNumber:function(L2X,M5v,D_l){var d05,h8H,F5R;M5v++;if(M5v > 12){o2t.G4m(9);d05=parseInt(o2t.e7l(M5v,12),10);o2t.b8R(101);M5v=o2t.F9v(12,M5v);L2X+=d05;}if(M5v <= 2){o2t.G4m(4);L2X-=o2t.e7l(\"1\",0);M5v+=12;}o2t.b8R(9);d05=Math.floor(o2t.F9v(L2X,100));o2t.G4m(99);var X3D=o2t.e7l(4,18,6,18);o2t.b8R(144);var D1W=o2t.e7l(11,20,1984,8,9);h8H=X3D - d05 + Math.floor(d05 / D1W);o2t.G4m(29);var I6b=o2t.F9v(15,4,12,4713,843620);o2t.G4m(33);var F3F=o2t.F9v(1540,3,3096);F5R=Math.floor(+\"365.25\" * (L2X + I6b)) + Math.floor(30.6001 * (M5v + (\"1\" | 0))) + D_l + h8H - F3F;o2t.j1L();return F5R;},getLocalOffset:function(){o2t.j1L();return this._dateProxy.getTimezoneOffset();}},!![]);a0t.timezone=new (function(){var M4L,A75,V1g,Y7k,K2i,V$e,A_k,B0C,d5d,a14,p0v,T89,L$S,r3y,v9J,m6t,x78,D4c,D3$,f$d,p$a,M0n,Y$B;M4L=\"no\";M4L+=\"rthamerica\";function L$W(l0j){var G9c,E3q,y4U,F3a,B5E,V4n,T51,C4K;G9c=Y$B[l0j];if(G9c){return G9c;}E3q=l0j.split(\"/\")[0];y4U=M0n[E3q];if(y4U){return y4U;}F3a=p$a.zones[l0j];if(typeof F3a === \"string\"){return L$W(F3a);}if(!p$a.loadedZones.backward){B5E=\"bac\";B5E+=\"kward\";p$a.loadZoneFile(B5E);return L$W(l0j);}V4n=+\"1577414605\";T51=1341591828;C4K=2;for(var F0W=1;o2t.m1(F0W.toString(),F0W.toString().length,45100) !== V4n;F0W++){E$1(l0j);C4K+=2;}if(o2t.P6(C4K.toString(),C4K.toString().length,71410) !== T51){E$1(l0j);}E$1(l0j);}A75=\"antarcti\";A75+=\"ca\";V1g=\"a\";V1g+=\"s\";V1g+=\"ia\";Y7k=\"euro\";Y7k+=\"pe\";K2i=\"europ\";K2i+=\"e\";function v2N(Y2Q,X0n){var Q$K,N0P,B6x,H_U,w5v;Q$K=typeof Y2Q === \"number\"?Y2Q:new Date(+Y2Q).getTime();N0P=X0n;B6x=p$a.zones[N0P];while(typeof B6x === \"string\"){N0P=B6x;B6x=p$a.zones[N0P];}if(!B6x){if(!p$a.loadedZones.backward){p$a.loadZoneFile(\"backward\");return v2N(Y2Q,X0n);}else if(N0P && N0P !== X0n){p$a.lazyLoadZoneFiles(N0P);return v2N(Y2Q,N0P);}E$1(N0P);}if(B6x.length === 0){H_U=\"No Zone\";H_U+=\" found for '\";o2t.G4m(2);throw new Error(o2t.e7l(\"' on \",Y2Q,X0n,H_U));}for(var i$l=B6x.length - 1;i$l >= (\"0\" | 0);i$l--){w5v=B6x[i$l];if(w5v[+\"3\"] && Q$K > w5v[\"3\" | 1])break;}o2t.b8R(145);return B6x[o2t.e7l(\"1\",0,i$l)];}V$e=\"e\";V$e+=\"uro\";V$e+=\"p\";V$e+=\"e\";A_k=\"e\";function f5l(U7z,q19){var T0u,F$H,H7t;T0u=U7z[2];o2t.y6g();if(T0u.indexOf(\"%s\") > -+\"1\"){F$H=\"%\";F$H+=\"s\";if(q19){H7t=q19[7] === (+\"2890\" !== (256.68,\"4057\" - 0)?\"-\":6968 != (+\"1530\",3736)?(3570,1757) === 2419?257.77:(\"l\",5.19e+3):0x26f1)?\"\":q19[7];}else {H7t=\"S\";}return T0u.replace(F$H,H7t);}else if(T0u.indexOf(\"/\") > -1){return T0u.split(\"/\",o2t.e7l(\"2\",0,o2t.G4m(34)))[q19?q19[6]?+\"1\":\"0\" | 0:0];}return T0u;}A_k+=\"ur\";function E$1(C3e){o2t.G4m(14);throw new Error(o2t.F9v(\"Timezone '\",\"' is either incorrect, or not loaded in the timezone registry.\",C3e));}A_k+=\"op\";A_k+=\"e\";B0C=\"eu\";B0C+=\"rope\";d5d=\"eur\";d5d+=\"o\";function b$g(S5a,s9C,w2m,s0X){var S4s,d8M,X8v,Y5H,x2v,A6k,b_E,B5r,s4E,g14,L7T,Z1F,M1K,e6N,D28;S4s=typeof S5a === \"number\"?new Date(S5a):S5a;d8M=s9C[1];X8v=s9C[0];Y5H=d8M.match(/^([0-9]):([0-9][0-9])$/);if(Y5H){x2v=\"Ja\";x2v+=\"n\";A6k=\"m\";A6k+=\"a\";A6k+=\"x\";o2t.b8R(57);var s_H=o2t.e7l(0,56,3,19);o2t.G4m(31);var n3f=o2t.e7l(54,9,54);o2t.b8R(0);var g_y=o2t.F9v(1,9);o2t.b8R(34);return [-o2t.F9v(\"1000000\",64),A6k,\"-\",x2v,1,[0,0,+\"0\"],parseInt(Y5H[s_H],+\"10\") * n3f + parseInt(Y5H[+\"2\"],\"10\" | g_y),3430 <= (918,2160)?4288 >= 4070?6921 <= \"994.87\" - 0?(\"n\",977.21):314.57:(\"l\",495.48):\"-\"];}b_E=function(N4p,v$j,Y4I){var P$O;o2t.y6g();P$O=0;if(v$j === ((841,3436) !== (\"5459\" | 3,\"591\" << 0)?\"u\":!![]) || v$j === \"g\" || v$j === \"z\"){P$O=0;}else if(v$j === (2921 > (1116,6872)?184.43:\"s\")){P$O=X8v;}else if(v$j === \"w\" || !v$j){P$O=q_z(X8v,Y4I[6]);}else {o2t.b8R(0);throw new Error(o2t.e7l(\"unknown type \",v$j));}o2t.G4m(146);P$O*=o2t.F9v(0,1,\"1000\",\"60\");return new Date(N4p.getTime() + P$O);};B5r=function(C09,l7D){var W3V,F5M,t2q,R5a,F6I,Q0S,U51,c0o;W3V=C09[0];F5M=C09[1];t2q=F5M[5];if(!o9h[W3V]){o9h[W3V]={};}if(o9h[W3V][F5M]){R5a=o9h[W3V][F5M];}else {if(!isNaN(F5M[4])){R5a=new Date(Date.UTC(W3V,g_G[F5M[3]],F5M[4],t2q[0],t2q[1],t2q[2],0));}else {F6I=\"l\";F6I+=\"a\";F6I+=\"s\";F6I+=\"t\";if(F5M[4].substr(\"0\" << 0,4) === F6I){R5a=new Date(Date.UTC(W3V,g_G[F5M[\"3\" - 0]] + +\"1\",1,t2q[0] - 24,t2q[+\"1\"],t2q[2],0));Q0S=k0U[F5M[4].substr(4,3)];U51=\"<=\";}else {R5a=new Date(Date.UTC(W3V,g_G[F5M[3]],F5M[+\"4\"].substr(5),t2q[\"0\" ^ 0],t2q[1],t2q[\"2\" | 2],0));Q0S=k0U[F5M[4].substr(0,3)];U51=F5M[4].substr(3,2);}c0o=R5a.getUTCDay();if(U51 === \">=\"){R5a.setUTCDate(R5a.getUTCDate() + (Q0S - c0o + (Q0S < c0o?7:0)));}else {R5a.setUTCDate(R5a.getUTCDate() + (Q0S - c0o - (Q0S > c0o?7:0)));}}o9h[W3V][F5M]=R5a;}o2t.j1L();if(l7D){R5a=b_E(R5a,t2q[3],l7D);}return R5a;};s4E=function(s9t,I1x){var i9I;o2t.j1L();i9I=[];if(I1x){for(var e4h=\"0\" >> 64;e4h < I1x.length;e4h++){if(I1x[e4h][0] <= s9t && (I1x[e4h][+\"1\"] >= s9t || I1x[e4h][0] === s9t && I1x[e4h][1] === \"only\" || I1x[e4h][+\"1\"] === \"max\")){i9I.push([s9t,I1x[e4h]]);}}}return i9I;};g14=function(j3V,d0i,T6d){var K2n,O0g;o2t.y6g();if(!(j3V instanceof Date)){K2n=j3V[0];O0g=j3V[1];j3V=!T6d && o9h[K2n] && o9h[K2n][O0g]?o9h[K2n][O0g]:B5r(j3V,T6d);}else if(T6d){j3V=b_E(j3V,w2m?3001 === (616.8,1969)?0x14e2:\"334.46\" * 1 !== 456?\"u\":\"0x5b1\" << 96:(4931,907.79) >= 2935?\"o\":\"w\",T6d);}if(!(d0i instanceof Date)){K2n=d0i[0];O0g=d0i[1];d0i=!T6d && o9h[K2n] && o9h[K2n][O0g]?o9h[K2n][O0g]:B5r(d0i,T6d);}else if(T6d){d0i=b_E(d0i,w2m?\"u\":\"w\",T6d);}j3V=Number(j3V);d0i=Number(d0i);o2t.b8R(4);return o2t.e7l(j3V,d0i);};L7T=S4s.getUTCFullYear();M1K=a0t.ruleCache[s0X];if(!M1K){M1K=a0t.ruleCache[s0X]={};}Z1F=M1K[L7T];if(!Z1F){o2t.G4m(4);Z1F=s4E(o2t.F9v(L7T,1),p$a.rules[d8M]);Z1F=Z1F.concat(s4E(L7T,p$a.rules[d8M]));Z1F.sort(g14);M1K[L7T]=Z1F;}if(!Z1F || !Z1F.length){return null;}for(var V2a=Z1F.length - 1;V2a >= +\"0\";V2a--){if(V2a > 0){o2t.b8R(128);e6N=Z1F[o2t.F9v(V2a,\"1\")][1];}else {e6N=null;}D28=Z1F[V2a];if(!D28[2]){D28[2]=B5r(D28,e6N);}if(g14(S4s,D28,e6N) >= +\"0\"){o2t.b8R(3);return D28[o2t.e7l(\"1\",1)];}}return null;}d5d+=\"pe\";a14=\"aus\";a14+=\"tral\";a14+=\"a\";a14+=\"sia\";p0v=\"austra\";p0v+=\"lasia\";function U66(P0S){var z$W,F8k;z$W=I3R(P0S);F8k=P0S.charAt(0) === (4360 != 533?73 < (\"57.63\" - 0,\"8446\" ^ 0)?\"-\":4755 !== 915.81?(974.33,\"0x1d08\" ^ 0):(9.37e+3,30.63):8.51e+2)?-1:1;o2t.G4m(33);var A2K=o2t.e7l(73,18,1254);o2t.b8R(68);var O5i=o2t.e7l(28,10,42,1);o2t.b8R(77);o2t.y6g();var b$H=o2t.F9v(7,39,6,28);o2t.b8R(17);var l2D=o2t.e7l(994,20,14);z$W=F8k * (((z$W[+\"0\"] * A2K + z$W[+\"1\"]) * O5i + z$W[b$H]) * l2D);o2t.G4m(147);return o2t.e7l(60,1,\"1000\",z$W);}T89=\"a\";T89+=\"s\";T89+=\"i\";T89+=\"a\";L$S=\"an\";L$S+=\"tarctica\";r3y=\"eur\";r3y+=\"o\";r3y+=\"pe\";function u9f(g9J,v1X){var v05;v05=p$a.zoneFileBasePath + \"/\" + g9J;o2t.j1L();return !v1X || !v1X.async?p$a.parseZones(p$a.transport({url:v05,async:![]})):p$a.transport({async:!0,url:v05,success:function(T3r){return p$a.parseZones(T3r) && typeof v1X.callback === \"function\" && v1X.callback();},error:function(){o2t.y6g();o2t.G4m(14);throw new Error(o2t.F9v(\"Error retrieving '\",\"' zoneinfo files\",v05));}});}function q_z(A4U,N1j){o2t.b8R(4);return -Math.ceil(o2t.e7l(N1j,A4U));}function P82(s$U){var p9n,O1T,C2Y,F$k;if(!s$U[+\"3\"]){return;}p9n=parseInt(s$U[+\"3\"],10);O1T=11;C2Y=31;if(s$U[\"4\" | 0]){O1T=g_G[s$U[4].substr(+\"0\",3)];C2Y=parseInt(s$U[5],10) || 1;}F$k=s$U[6]?I3R(s$U[6]):[+\"0\",\"0\" - 0,0];return [p9n,O1T,C2Y,F$k[0],F$k[+\"1\"],F$k[2]];}v9J=\"aust\";v9J+=\"ral\";v9J+=\"asia\";m6t=\"a\";m6t+=\"fri\";m6t+=\"c\";m6t+=\"a\";x78=\"no\";o2t.j1L();x78+=\"rth\";x78+=\"a\";x78+=\"merica\";D4c=\"nor\";D4c+=\"thamerica\";D3$=\"north\";D3$+=\"america\";f$d=\"northamer\";f$d+=\"ica\";p$a=this;M0n={Etc:\"etcetera\",EST:\"northamerica\",MST:f$d,HST:D3$,EST5EDT:\"northamerica\",CST6CDT:\"northamerica\",MST7MDT:\"northamerica\",PST8PDT:D4c,America:[x78,\"southamerica\"],Pacific:\"australasia\",Atlantic:\"europe\",Africa:m6t,Indian:\"africa\",Antarctica:\"antarctica\",Asia:\"asia\",Australia:v9J,Europe:r3y,WET:\"europe\",CET:\"europe\",MET:\"europe\",EET:\"europe\"};Y$B={\"Pacific/Honolulu\":\"northamerica\",\"Atlantic/Bermuda\":\"northamerica\",\"Atlantic/Cape_Verde\":\"africa\",\"Atlantic/St_Helena\":\"africa\",\"Indian/Kerguelen\":L$S,\"Indian/Chagos\":\"asia\",\"Indian/Maldives\":T89,\"Indian/Christmas\":p0v,\"Indian/Cocos\":a14,\"America/Danmarkshavn\":d5d,\"America/Scoresbysund\":\"europe\",\"America/Godthab\":\"europe\",\"America/Thule\":B0C,\"Asia/Istanbul\":\"europe\",\"Asia/Yekaterinburg\":A_k,\"Asia/Omsk\":\"europe\",\"Asia/Novosibirsk\":\"europe\",\"Asia/Krasnoyarsk\":\"europe\",\"Asia/Irkutsk\":V$e,\"Asia/Yakutsk\":\"europe\",\"Asia/Vladivostok\":\"europe\",\"Asia/Sakhalin\":\"europe\",\"Asia/Magadan\":K2i,\"Asia/Kamchatka\":Y7k,\"Asia/Anadyr\":\"europe\",\"Africa/Ceuta\":\"europe\",GMT:\"etcetera\",\"Europe/Nicosia\":V1g};this.zoneFileBasePath=null;this.zoneFiles=[\"africa\",A75,\"asia\",\"australasia\",\"backward\",\"etcetera\",\"europe\",M4L,\"pacificnew\",\"southamerica\"];this.loadingSchemes={PRELOAD_ALL:\"preloadAll\",LAZY_LOAD:\"lazyLoad\",MANUAL_LOAD:\"manualLoad\"};this.getRegionForTimezone=L$W;this.loadingScheme=this.loadingSchemes.LAZY_LOAD;this.loadedZones={};this.zones={};this.rules={};this.init=function(C2F){var d3y,k5v;d3y={async:!\"\"};o2t.y6g();k5v=this.loadingScheme === this.loadingSchemes.PRELOAD_ALL?this.zoneFiles:this.defaultZoneFile || \"northamerica\";for(var s7W in C2F){d3y[s7W]=C2F[s7W];}return this.loadZoneFiles(k5v,d3y);};this.loadZoneFiles=function(H1X,G5n){var g7i,T_i,N_N;g7i=\"strin\";g7i+=\"g\";N_N=0;if(typeof H1X === g7i){return this.loadZoneFile(H1X,G5n);}G5n=G5n || ({});T_i=G5n.callback;G5n.callback=function(){var j5G;j5G=\"f\";j5G+=\"uncti\";j5G+=\"on\";N_N++;N_N === H1X.length && typeof T_i === j5G && T_i();};for(var p20=0;p20 < H1X.length;p20++){this.loadZoneFile(H1X[p20],G5n);}};this.loadZoneFile=function(e1P,a2o){if(typeof this.zoneFileBasePath === \"undefined\"){throw new Error(\"Please define a base path to your zone file directory -- timezoneJS.timezone.zoneFileBasePath.\");}if(this.loadedZones[e1P]){return;}this.loadedZones[e1P]=!0;return u9f(e1P,a2o);};this.loadZoneJSONData=function(h4J,A4j){var F4T;o2t.j1L();F4T=function(E8d){o2t.y6g();E8d=JSON.parse(E8d);for(var z31 in E8d.zones){p$a.zones[z31]=E8d.zones[z31];}for(var T_g in E8d.rules){p$a.rules[T_g]=E8d.rules[T_g];}};return A4j?F4T(p$a.transport({url:h4J,async:!({})})):p$a.transport({url:h4J,success:F4T});};this.loadZoneDataFromObject=function(r1E){if(!r1E){return;}for(var X5p in r1E.zones){p$a.zones[X5p]=r1E.zones[X5p];}for(var v6m in r1E.rules){p$a.rules[v6m]=r1E.rules[v6m];}};this.getAllZones=function(){var T9_;T9_=[];for(var N0L in this.zones){T9_.push(N0L);}return T9_.sort();};this.parseZones=function(i8X){var F5f,z99,B9m,J39,o8m,A0w,G$I,F00;if(!i8X){return !\"1\";}F5f=i8X.split(459.22 < 5936?\"\\n\":967);z99=[];B9m=\"\";o8m=null;A0w=null;for(var c1l=0;c1l < F5f.length;c1l++){J39=F5f[c1l];if(J39.match(/^\\s/)){o2t.G4m(14);J39=o2t.e7l(\"Zone \",J39,o8m);}J39=J39.split(7580 == 257.47?\"j\":761.5 === 9931?\"U\":\"#\")[+\"0\"];if(J39.length > 3){G$I=\"R\";G$I+=\"u\";G$I+=\"le\";F00=\"Zo\";F00+=\"n\";F00+=\"e\";z99=J39.split(/\\s+/);B9m=z99.shift();switch(B9m){case F00:o8m=z99.shift();if(!p$a.zones[o8m]){p$a.zones[o8m]=[];}if(z99.length < 3)break;z99.splice(3,z99.length,P82(z99));if(z99[3]){z99[3]=Date.UTC.apply(null,z99[3]);}z99[0]=-U66(z99[0]);p$a.zones[o8m].push(z99);break;case G$I:A0w=z99.shift();if(!p$a.rules[A0w]){p$a.rules[A0w]=[];}z99[+\"0\"]=parseInt(z99[0],10);z99[1]=parseInt(z99[1],10) || z99[1];z99[5]=I3R(z99[\"5\" << 64]);z99[6]=U66(z99[6]);p$a.rules[A0w].push(z99);break;case \"Link\":if(p$a.zones[z99[+\"1\"]]){o2t.b8R(77);var N1g=o2t.e7l(10,32,3,20);throw new Error(\"Error with Link \" + z99[N1g] + \". Cannot create link of a preexisted zone.\");}if(isNaN(z99[0])){o2t.b8R(63);p$a.zones[z99[1]]=z99[o2t.e7l(\"0\",0)];}else {p$a.zones[z99[1]]=parseInt(z99[0],10);}break;}}}return !![];};this.transport=t9X;function I3R(w5Y){var r_8,O_h;r_8=/(\\d{1,2})(?::0*(\\d{1,2}))?(?::0*(\\d{1,2}))?([wsugz])?$/;O_h=w5Y.match(r_8);O_h[1]=parseInt(O_h[1],10);O_h[2]=O_h[\"2\" ^ 0]?parseInt(O_h[2],10):0;O_h[3]=O_h[\"3\" - 0]?parseInt(O_h[3],10):0;return O_h.slice(1,5);}this.getTzInfo=function(k8J,K15,q83){var V5n,l3A,l8c,D7I;this.lazyLoadZoneFiles(K15);V5n=v2N(k8J,K15);l3A=+V5n[0];l8c=b$g(k8J,V5n,q83,K15);o2t.j1L();if(l8c){l3A=q_z(l3A,l8c[6]);}D7I=f5l(V5n,l8c);return {tzOffset:l3A,tzAbbr:D7I};};this.lazyLoadZoneFiles=function(S$b){var e7q;if(this.loadingScheme === this.loadingSchemes.LAZY_LOAD){e7q=L$W(S$b);if(!e7q){throw new Error(\"Not a valid timezone ID.\");}this.loadZoneFiles(e7q);}};})();}).call(typeof window !== \"undefined\"?window:this);a0t.timezone.loadingScheme=a0t.timezone.loadingSchemes.MANUAL_LOAD;a0t.timezone.loadZoneDataFromObject({zones:{\"Atlantic/Cape_Verde\":[[60,9797 <= (4663,\"8430\" | 78)?(2370,4690) == 1644?0x20e1:(\"6900\" ^ 0,+\"6536\") < (167.89,643.74)?(425.81,\"A\"):(0xaf2,0xe09):\"-\",F1Q,null]],\"Africa/Cairo\":[[-120,\"\",\"EE%sT\",null]],\"Africa/Nairobi\":[[-180,3137 > +\"466.34\"?\"-\":(4.70e+3,\"u\"),z5z,null]],\"Africa/Casablanca\":[[0,\"Morocco\",\"+00/+01\",1540695600000],[-60,c0F,\"+01/+00\",null]],\"Africa/Windhoek\":[[-120,\"\",X6v,null]],\"Africa/Johannesburg\":[[-+\"120\",\"\",\"SAST\",null]],\"Africa/Tunis\":[[-60,\"\",\"CE%sT\",null]],\"Antarctica/Troll\":[[0,t0o,\"%s\",null]],\"Asia/Kabul\":[[-270,(9430,7670) > (7490,+\"8996\")?(626.65,4.10e+3):\"-\",\"+0430\",null]],\"Asia/Baku\":[[-240,\"\",w6l,null]],\"Asia/Dhaka\":[[-360,\"\",\"+06/+07\",null]],\"Asia/Yangon\":[[-+\"390\",\"-\",Y6Y,null]],\"Asia/Shanghai\":[[-480,\"\",\"C%sT\",null]],\"Asia/Hong_Kong\":[[-(\"480\" << 64),\"\",\"HK%sT\",null]],\"Asia/Taipei\":[[-480,\"\",\"C%sT\",null]],\"Asia/Nicosia\":[[-120,\"EUAsia\",c_F,null]],\"Asia/Kolkata\":[[-330,5899 !== +\"407.25\"?281.78 >= 740?973.66:(+\"1310\",617.83) === (6110,4433)?!0:\"-\":(!!\"\",969.30),Y41,null]],\"Asia/Tehran\":[[-210,\"Iran\",k46,null]],\"Asia/Jerusalem\":[[-+\"120\",\"Zion\",\"I%sT\",null]],\"Asia/Tokyo\":[[-540,\"\",l2x,null]],\"Asia/Amman\":[[-120,\"Jordan\",\"EE%sT\",null]],\"Asia/Almaty\":[[-360,9670 == (53,+\"6205\")?(1452,+\"640\") <= 197.66?+\"685.94\":(0xc9b,500.38):\"-\",k65,null]],\"Asia/Seoul\":[[-540,\"\",\"K%sT\",null]],\"Asia/Pyongyang\":[[-510,(\"5880\" << 64,+\"11\") <= 2720?\"-\":3934 !== 679?\"B\":(!!\"1\",\"F\"),I3V,1525476600000],[-(\"540\" << 0),\"-\",G5U,null]],\"Asia/Beirut\":[[-120,\"Lebanon\",\"EE%sT\",null]],\"Asia/Kuala_Lumpur\":[[-(\"480\" << 0),(8350,\"4035\" - 0) < (4740,+\"463\")?626.06:\"-\",\"+08\",null]],\"Asia/Hovd\":[[-420,\"\",\"+07/+08\",null]],\"Asia/Ulaanbaatar\":[[-480,s_B,\"+08/+09\",null]],\"Asia/Kathmandu\":[[-345,8915 >= 2620?\"-\":7.66e+3,\"+0545\",null]],\"Asia/Karachi\":[[-300,\"\",\"PK%sT\",null]],\"Asia/Hebron\":[[-120,\"Palestine\",\"EE%sT\",null]],\"Asia/Riyadh\":[[-(\"180\" - 0),\"-\",\"+03\",null]],\"Asia/Damascus\":[[-120,\"Syria\",I1S,null]],\"Asia/Bangkok\":[[-420,8780 < (1240,\"5605\" << 32)?(2440,\"3000\" - 0) >= 1860?(\"C\",108.94):(!1,\"k\"):\"-\",h1c,null]],\"Asia/Dubai\":[[-240,(+\"676.64\",464.83) === 7662?(![],8.74e+3):\"-\",T9C,null]],\"Australia/Darwin\":[[-570,\"\",I31,null]],\"Australia/Perth\":[[-480,\"\",l4u,null]],\"Australia/Eucla\":[[-525,\"AW\",\"+0845/+0945\",null]],\"Australia/Brisbane\":[[-600,\"\",p51,null]],\"Australia/Adelaide\":[[-570,g$j,\"AC%sT\",null]],\"Australia/Hobart\":[[-600,s1w,i_h,null]],\"Australia/Melbourne\":[[-+\"600\",x1Q,\"AE%sT\",null]],\"Australia/Sydney\":[[-600,Q02,w4J,null]],\"Australia/Lord_Howe\":[[-630,\"LH\",\"+1030/+11\",null]],\"Pacific/Fiji\":[[-(\"720\" * 1),m$B,\"+12/+13\",null]],\"Pacific/Guam\":[[-600,\"-\",s3i,null]],\"Pacific/Kiritimati\":[[-840,849.96 <= 836.66?(4291,1760) != (824.06,869.88)?8.35e+3:(1.60e+3,0x1ff9):\"-\",\"+14\",null]],\"Pacific/Noumea\":[[-660,\"\",\"+11/+12\",null]],\"Pacific/Auckland\":[[-720,\"NZ\",f9Y,null]],\"Pacific/Chatham\":[[-+\"765\",\"Chatham\",\"+1245/+1345\",null]],\"Pacific/Pago_Pago\":[[660,\"-\",v_3,null]],\"Pacific/Apia\":[[-780,o9W,\"+13/+14\",null]],\"Pacific/Tongatapu\":[[-780,\"\",z4T,null]],\"Etc/UTC\":[[0,(\"442\" ^ 0) > 1742?+\"9719\" > (2900,6090)?2.64e+3:(\"g\",!!\"1\"):\"-\",\"UTC\",null]],UTC:\"Etc/UTC\",\"Europe/London\":[[0,\"EU\",\"GMT/BST\",null]],\"Europe/Dublin\":[[0,\"Eire\",k0h,null]],WET:[[+\"0\",\"EU\",s7h,null]],CET:[[-60,j_F,S7U,null]],MET:[[-60,\"C-Eur\",\"ME%sT\",null]],EET:[[-120,\"EU\",B3i,null]],\"Europe/Brussels\":[[-60,\"EU\",\"CE%sT\",null]],\"Europe/Copenhagen\":[[-60,e$0,n8a,null]],\"America/Thule\":[[240,z5a,d1R,null]],\"Europe/Helsinki\":[[-120,\"EU\",\"EE%sT\",null]],\"Europe/Paris\":[[-60,s_I,\"CE%sT\",null]],\"Europe/Berlin\":[[-60,\"EU\",T68,null]],\"Europe/Amsterdam\":[[-60,\"EU\",\"CE%sT\",null]],\"Atlantic/Azores\":[[60,N53,\"-01/+00\",null]],\"Europe/Bucharest\":[[-120,Y6T,\"EE%sT\",null]],\"Europe/Kaliningrad\":[[-(\"120\" - 0),3150 < (209.05,+\"8250\")?\"-\":(7324,153.59) == (9541,4700)?(6.40e+3,6.44e+3):+\"3356\" >= 558.29?(!!1,+\"7.31e+3\"):(+\"917.08\",\"v\"),\"EET\",null]],\"Europe/Moscow\":[[-180,207 >= (+\"4450\",8464)?0x5db:319 != 3661?\"-\":672.25 < (1100,8380)?(0x72f,197.91):(!!({}),\"k\"),\"MSK\",null]],\"Europe/Volgograd\":[[-180,9100 !== (+\"498.9\",739.45)?\"-\":7.67e+3,E2H,1540692000000],[-240,\"-\",i08,1609034400000],[-180,\"-\",A2a,null]],\"Europe/Samara\":[[-240,+\"7310\" == (9860,3180)?(6.09e+3,!\"1\"):(5310,4381) > (528.08,6910)?(2.09e+3,0x1d19):(\"514.23\" * 1,229.38) !== 771.42?\"-\":(\"g\",\"6.30e+3\" >> 32),\"+04\",null]],\"Asia/Yekaterinburg\":[[-300,(388.43,4693) !== +\"636.47\"?\"-\":(2370,570) !== 4044?55 !== 4120?0x175:\"U\":(0x2412,+\"773.54\"),f2$,null]],\"Asia/Omsk\":[[-(\"360\" | 40),9140 != (9590,+\"3231\")?\"-\":(\"v\",600.46),\"+06\",null]],\"Asia/Novosibirsk\":[[-420,\"6040\" - 0 == (\"683\" * 1,+\"8300\")?(8.91e+3,!!\"\"):(741.35,234) === (984.86,77)?3800 != (\"9711\" >> 0,8552)?1.90e+3:(\"747.85\" - 0,+\"0x526\"):\"-\",\"+07\",null]],\"Asia/Novokuznetsk\":[[-(\"420\" ^ 0),\"-\",\"+07\",null]],\"Asia/Krasnoyarsk\":[[-420,5016 >= 235?\"-\":(2230,+\"2064\") <= 6240?0x1900:(608.21,0x5db),\"+07\",null]],\"Asia/Irkutsk\":[[-480,\"-\",\"+08\",null]],\"Asia/Yakutsk\":[[-(\"540\" - 0),(5430,\"282.5\" * 1) != 7760?(8089,1379) !== (2368,688)?\"-\":(\"9220\" << 64,8410) === (55.93,5604)?(5.88e+3,217.04):3.88e+3:(0x16c7,0x156a),e6R,null]],\"Asia/Vladivostok\":[[-+\"600\",\"-\",\"+10\",null]],\"Asia/Magadan\":[[-660,(\"4570\" >> 64,2190) != 669.06?\"-\":\"765.2\" - 0 < (7950,+\"587\")?0x1863:(608.77,!({})),\"+11\",null]],\"Asia/Srednekolymsk\":[[-660,\"-\",p3$,null]],\"Asia/Kamchatka\":[[-720,(+\"132.61\",641) == 682.66?544.42:\"-\",\"+12\",null]],\"Europe/Belgrade\":[[-+\"60\",\"EU\",\"CE%sT\",null]],\"Europe/Sarajevo\":\"Europe/Belgrade\",\"Europe/Madrid\":[[-+\"60\",\"EU\",y5R,null]],\"Europe/Stockholm\":[[-60,\"EU\",\"CE%sT\",null]],\"Europe/Zurich\":[[-60,n8v,\"CE%sT\",null]],\"Europe/Istanbul\":[[-180,512.94 < 995.1?(860,9190) <= (1310,7927)?0x107c:+\"6530\" != (2960,531.38)?\"-\":!![]:(3.60e+3,\"n\"),J3J,null]],\"America/New_York\":[[300,\"US\",\"E%sT\",null]],\"America/Chicago\":[[360,\"US\",\"C%sT\",null]],\"America/Denver\":[[\"420\" >> 0,j3O,\"M%sT\",null]],\"America/Los_Angeles\":[[480,\"US\",\"P%sT\",null]],\"America/Juneau\":[[540,\"US\",\"AK%sT\",null]],\"Pacific/Honolulu\":[[+\"600\",\"-\",\"HST\",null]],\"America/Phoenix\":[[\"420\" - 0,(5448,4047) < 2225?872.71:\"-\",\"MST\",null]],\"America/St_Johns\":[[210,h$Q,r2G,null]],\"America/Halifax\":[[240,\"Canada\",B22,null]],\"America/Regina\":[[360,(2510,\"260.87\" * 1) < +\"7874\"?\"-\":!({}),\"CST\",null]],\"America/Mexico_City\":[[360,\"Mexico\",V8r,null]],\"America/Chihuahua\":[[420,\"Mexico\",\"M%sT\",null]],\"America/Costa_Rica\":[[360,\"\",E2u,null]],\"America/Havana\":[[+\"300\",A9o,\"C%sT\",null]],\"America/Port-au-Prince\":[[300,w50,U8v,null]],\"America/Panama\":[[300,7292 >= (6406,542.59)?\"-\":(5400,3680) <= 6621?(163.88,3274) >= 9732?(281.99,\"2.81e+2\" >> 0):(106.27,!({})):(\"g\",!1),\"EST\",null]],\"America/Puerto_Rico\":[[240,(971.85,7731) == (51.76,7478)?!1:6930 >= 5349?\"-\":0x2db,t3k,null]],\"America/Argentina/Buenos_Aires\":[[+\"180\",\"\",\"-03/-02\",null]],\"America/Sao_Paulo\":[[180,\"Brazil\",\"-03/-02\",null]],\"America/Santiago\":[[240,Y8n,E9Q,null]],\"America/Punta_Arenas\":[[180,\"1130\" - 0 <= 2473?\"-\":54 !== 434.22?(0x1027,+\"8.59e+3\"):(\"E\",76.40),\"-03\",null]],\"America/Bogota\":[[300,\"\",\"-05/-04\",null]],\"America/Asuncion\":[[240,D9F,Q62,null]],\"Atlantic/South_Georgia\":[[120,+\"369\" <= 7944?\"-\":5009 === 1376?20:(846.73,\"u\"),x47,null]],\"America/Montevideo\":[[180,\"\",\"-03/-02\",null]],\"America/Caracas\":[[240,300.01 > (229,8104)?\"T\":(873.37,\"3770\" * 1) >= 426.64?\"-\":3.33e+3,x$4,null]],\"Europe/Athens\":J5g,\"Europe/Simferopol\":\"Europe/Moscow\",\"Asia/Rangoon\":\"Asia/Yangon\",\"Atlantic/Reykjavik\":\"UTC\",\"Asia/Kuwait\":x4D,\"Asia/Muscat\":\"Asia/Riyadh\",\"Asia/Istanbul\":\"Europe/Istanbul\"},rules:{Morocco:[[2013,+\"2018\",(496.16,\"4290\" * 1) < (2499,8706)?(+\"985.29\",5490) != (5110,677)?9580 > (170.38,\"3390\" * 1)?\"-\":\"P\":(6.38e+2,588.46):0x1e2,\"Oct\",\"lastSun\",[+\"3\",0,0,null],0,7970 == \"672.82\" - 0?(2270,621.91) !== 8810?\"310\" << 0:(574,!!({})):\"-\"],[\"2014\" ^ 0,+\"2018\",\"-\",\"Mar\",\"lastSun\",[2,+\"0\",0,null],60,(8070,4233) !== (409.99,5386)?\"-\":(\"A\",\"v\")],[2018,K2Z,(918.29,892.66) >= (3190,9410)?75.23:5458 <= +\"76.94\"?!!\"1\":(481,895.97) != 811.04?\"-\":129.16,E$X,\"13\",[3,0,0,null],\"0\" >> 0,6470 > (1060,296.87)?(959,7988) <= 447.36?\"E\":\"-\":(!\"1\",0x1ae5)],[2018,\"only\",(770,159.09) != (290.59,1600)?\"-\":629 !== \"948.45\" * 1?!!0:(!\"1\",\"10.29\" * 1),\"Jun\",\"17\",[+\"2\",0,0,null],60,2500 === (9643,\"196.86\" * 1)?(5258,2864) < (381.5,570.06)?\"F\":(230.26,5297) >= 4051?(5.41e+3,401.98):\"r\":\"-\"],[2019,l6V,(525.61,7270) <= 8060?\"-\":(0x1796,0x1e8c),i56,1807 <= (\"8115\" >> 64,8237)?\"5\":\"z\",[\"3\" ^ 0,0,0,null],-60,(761.01,4370) < 2557?6.57e+3:(6420,1750) > 136.8?+\"7697\" >= 546.68?\"-\":(!![],0x1bd7):835.00],[2019,k_p,(4040,8370) !== (750.29,4570)?\"-\":(2768,3874) >= 590.41?!!\"\":\"O\",\"Jun\",7520 !== 13.87?\"9\":\"e\",[\"2\" * 1,0,0,null],0,+\"7890\" === (3470,4580)?0x60a:\"-\"],[2020,t7y,(+\"2220\",+\"128.56\") != 788.68?\"-\":4870 <= 4883?(0x2591,\"h\"):(300.14,796.09),\"Apr\",f4a,[\"3\" * 1,0,0,null],-60,\"-\"],[+\"2020\",\"only\",\"-\",\"May\",p5M,[\"2\" | 0,0,0,null],+\"0\",3220 <= (812.14,7750)?391.77 !== +\"814.31\"?\"-\":522.33:\"e\"],[2021,\"only\",\"-\",\"Apr\",U$8,[3,0,0,null],-(\"60\" >> 32),468.06 >= (2410,4619)?(9217,\"225.16\" - 0) != +\"7810\"?(792.22,602.06) < 280.8?(264.21,\"z\"):(130.33,!\"\"):(0x65e,+\"8.91e+3\"):\"-\"],[2021,\"only\",\"-\",\"May\",\"16\",[\"2\" | 2,0,\"0\" - 0,null],+\"0\",(8940,+\"855.43\") < 643.38?3.01e+2:(2600,4338) === (8310,439.27)?357.28:\"-\"],[+\"2022\",\"only\",796.55 === 5400?(\"k\",!({})):\"-\",O6N,\"27\",[+\"3\",0,+\"0\",null],-60,\"-\"],[2022,\"only\",7170 > (5662,9170)?(+\"557.87\",8.65e+2):(\"757.46\" - 0,1350) > 9875?(2.65e+3,0x18f8):\"-\",\"May\",\"8\",[2,0,0,null],0,\"-\"],[2023,\"only\",2510 === (5840,749)?(42,\"S\"):\"-\",\"Mar\",\"19\",[3,0,0,null],-60,(134.44,4465) !== 7159?\"-\":0x1af9],[2023,\"only\",\"-\",r11,I4B,[2,0,0,null],0,62 !== 1450?4610 === (8190,788.85)?(\"k\",784.54):\"-\":(+\"9.91e+3\",3.58e+3)],[2024,\"only\",\"-\",\"Mar\",Z9e,[3,0,0,null],-60,\"-\"],[2024,D8Y,\"-\",\"Apr\",G2P,[2,+\"0\",0,null],0,933.13 == 4820?(!!0,\"k\"):\"-\"],[2025,\"only\",(988.76,42.54) > (27.22,4200)?9545 > (9270,868.67)?\"t\":6.67e+3:\"-\",\"Feb\",\"23\",[3,0,0,null],-60,(9371,25) > 82.66?\"d\":(2040,626.12) !== (6060,705.49)?\"-\":+\"3910\" === 7690?(0xae5,\"j\"):(724.32,675.38)],[+\"2025\",\"only\",\"715\" << 64 < 2280?\"-\":7280 > (\"933\" >> 32,3120)?(!!({}),214.25):(0x1bef,\"p\"),t83,(1681,6380) !== 905.1?\"6\":1677 > (+\"5860\",6281)?(164.28,+\"316.58\"):8839 != (632,\"9130\" << 32)?5.48e+3:(0x2b7,4.38e+2),[2,\"0\" - 0,0,null],0,(2220,1375) != 283?\"-\":562.44 === (699,\"3750\" >> 64)?(!!\"\",![]):0x13d8],[2026,v8K,(7392,5878) < 3420?\"V\":\"-\",C8D,\"15\",[3,0,\"0\" - 0,null],-60,2400 <= (662.11,3263)?\"-\":!!0],[2026,A90,\"9044\" >> 32 <= 249?+\"525.03\":9590 != \"442.21\" - 0?\"-\":6296 !== (+\"4520\",147.26)?(6.64e+3,\"u\"):!({}),\"Mar\",\"22\",[2,0,0,null],0,\"-\"]],Troll:[[\"2005\" << 0,H91,\"-\",\"Mar\",O37,[+\"1\",+\"0\",0,\"u\"],120,\"+02\"],[2004,\"max\",(\"2122\" | 74,961.23) <= (+\"31\",6680)?\"-\":\"323\" << 32,\"Oct\",v93,[1,0,0,(415,\"3974\" | 2) == (888.11,490.33)?(0x1065,\"k\"):+\"955.95\" === (5832,386)?(4951,7350) < (765.36,5935)?!\"1\":9.61e+3:\"u\"],0,\"+00\"]],EUAsia:[[\"1981\" ^ 0,G0x,(6820,893.97) > 9096?(!\"1\",!!({})):\"-\",H$8,\"lastSun\",[1,0,0,5100 <= (3330,510.1)?(!!0,9.88e+3):6719 !== +\"4940\"?\"u\":\"f\"],60,\"S\"],[1996,\"max\",2370 <= (+\"6090\",8740)?\"-\":(222.97,545.78) !== (604.08,1028)?\"J\":(\"t\",551.70),\"Oct\",e5m,[1,0,0,\"u\"],0,\"-\"]],Iran:[[2017,2019,(992,713.92) === (276.37,8140)?216.7 == 5826?\"J\":319.66:\"-\",A6d,\"21\",[24,0,0,null],60,(\"7950\" | 0) === (602.2,7810)?(6.65e+3,![]):\"-\"],[2017,2019,\"-\",\"Sep\",\"21\",[24,0,0,null],0,\"-\"],[2020,f69,712.65 < 875.34?\"-\":153 < (980.4,446.4)?427.24:0x671,\"Mar\",\"20\",[24,0,\"0\" >> 32,null],60,\"-\"],[2020,\"only\",\"-\",\"Sep\",\"20\",[24,0,0,null],0,(194.01,41.84) <= 238.07?\"-\":1688 < (8090,682.05)?1.34e+3:5.41e+3],[2021,2023,(6350,492.36) != (412,848.01)?\"-\":0x1b22,\"Mar\",\"21\",[24,+\"0\",\"0\" * 1,null],60,6520 > (\"722\" ^ 0,4380)?\"-\":(\"L\",240.44)],[+\"2021\",+\"2023\",(4777,3542) > (+\"6873\",614.25)?\"-\":237.68,\"Sep\",\"21\",[24,0,0,null],+\"0\",\"-\"],[2024,\"only\",(78.29,915) <= (1949,+\"1940\")?\"-\":(0x1c9b,0x190),\"Mar\",\"20\",[\"24\" | 0,0,0,null],60,(+\"882\",\"1550\" * 1) > 3870?(!({}),\"S\"):\"-\"],[2024,\"only\",(4566,1196) < 7660?\"-\":367 >= (4570,7412)?(!\"1\",2.34e+3):(\"l\",!![]),P1T,M6e,[24,0,0,null],0,\"-\"],[2025,2027,(402.74,9520) != (9860,7670)?\"-\":(4951,6858) >= (8570,250.15)?(731,693.20):(739.75,\"557.51\" - 0),\"Mar\",\"21\",[+\"24\",0,0,null],60,\"-\"],[2025,2027,\"-\",\"Sep\",\"21\",[+\"24\",+\"0\",+\"0\",null],+\"0\",(947,\"6754\" - 0) >= 959.88?164.42 > (6210,9688)?7.17e+3:\"-\":(\"S\",\"6.58e+3\" << 0)]],Zion:[[\"2013\" ^ 0,C9l,\"-\",R16,\"Fri>=23\",[2,0,0,null],60,963.65 === (362.51,504.19)?126.78:\"D\"],[2013,\"max\",5910 == 8735?(\"762.62\" - 0,+\"3090\") != 297.45?(0x109c,100.93):(8.44e+3,8.80e+3):\"-\",q5Q,\"lastSun\",[2,0,0,null],0,3929 != +\"5670\"?(2397,267.82) == (887,436.61)?(267.33,5.57e+3):\"S\":5.23e+3]],Jordan:[[2014,2021,613.05 <= 6692?\"-\":(677.59,872.65) <= (+\"401.86\",644.81)?2.72e+3:0x17d0,\"Mar\",u14,[24,0,0,null],60,\"S\"],[2014,D0n,\"-\",k3E,\"lastFri\",[0,0,+\"0\",(138.88,9670) != (8164,764.95)?\"s\":(\"2470\" ^ 0,105.8) == (129.19,2400)?!1:(207.17,!![])],0,549.41 === +\"3270\"?![]:(5620,1881) > (310.28,6215)?(5.36e+3,9.15e+3):7980 <= (313,793.09)?(0x1319,\"a\"):\"-\"],[2022,o6x,(1198,9390) < 3150?363.46:\"-\",\"Feb\",\"lastThu\",[24,0,0,null],\"60\" >> 64,\"703.9\" - 0 < +\"9470\"?\"S\":(\"282.03\" * 1,4210) >= 775.72?9310 == (\"953.53\" - 0,2249)?0xed5:\"0xb04\" ^ 0:!\"1\"]],Lebanon:[[1993,O5x,\"-\",\"Mar\",\"lastSun\",[0,+\"0\",0,null],60,(2086,624.46) < (+\"7499\",683.58)?\"S\":(3056,8580) !== (\"7970\" | 0)?\"x\":0x5a2],[1999,\"max\",627.76 < (293.81,\"715.91\" * 1)?\"-\":(\"X\",0x198b),\"Oct\",F_B,[0,0,0,null],0,(939.99,4260) != (8580,\"2586\" - 0)?7495 > (645.26,29.5)?\"-\":1.10e+3:481.47]],Palestine:[[2016,+\"2018\",(\"674.93\" * 1,42) !== (104.95,840)?(\"7800\" | 16,\"171.66\" - 0) === (6772,4252)?917.29:\"-\":(1.84e+3,\"G\"),\"Mar\",\"Sat>=24\",[1,+\"0\",0,null],60,(1275,1373) > +\"1440\"?8663 < (8950,3179)?\"u\":(!({}),0x112f):\"S\"],[\"2016\" | 0,\"2018\" * 1,\"-\",Q7P,v5d,[1,0,0,null],0,7672 === \"5294\" >> 32?(\"P\",!!\"1\"):332.47 <= 8120?1640 != (7516,\"908.2\" * 1)?\"-\":(+\"390.61\",\"H\"):\"V\"],[2019,u$_,4900 > 9770?(0x904,\"z\"):\"-\",\"Mar\",\"29\",[0,+\"0\",0,null],60,7370 >= 1644?\"S\":(9191,+\"2826\") > (856.77,672)?1433 < (767.49,6979)?(5.95e+3,!({})):(0x671,+\"769\"):7.01e+3],[2019,\"only\",\"-\",\"Oct\",\"Sat>=24\",[0,+\"0\",0,null],60,(614.36,2900) != 659.83?\"-\":(\"k\",!0)],[2020,2021,\"-\",\"Mar\",\"Sat>=24\",[0,0,0,null],60,6380 <= (9654,337.57)?(\"835.44\" - 0,1248) < (9200,7190)?(+\"16\",5470) != (6810,949.04)?(!!1,8.42e+3):(\"Z\",0x14cc):(\"j\",\"0x2338\" | 40):\"S\"],[2020,\"only\",840.81 < (457.43,403.26)?6057 === \"730.18\" - 0?!!1:8036 < (479.66,5841)?(865,188.94):!!0:\"-\",\"Oct\",\"24\",[1,0,0,null],60,(778.81,3087) !== (\"9480\" | 0,+\"9300\")?\"-\":(\"7050\" - 0,874) == 9900?\"j\":405.12],[\"2021\" | 96,L2R,\"-\",\"Oct\",\"Fri>=23\",[1,+\"0\",0,null],0,+\"557.94\" === (624.9,\"5694\" - 0)?(0x2224,!({})):\"-\"],[2022,\"max\",1633 > 8130?(0x2110,0x1af0):(5190,964) <= 1810?1280 === (744,421.36)?(!!0,\"556.27\" - 0):\"-\":(+\"4.02e+3\",4.22e+3),\"Mar\",\"Sun>=25\",[+\"0\",+\"0\",\"0\" - 0,null],60,(+\"391.4\",\"2100\" - 0) == (276,8996)?\"o\":(1035,+\"5030\") > 9585?+\"0xfd9\":\"S\"]],Syria:[[2012,\"max\",\"-\",J6i,i$T,[0,0,0,null],60,\"S\"],[2009,L0Z,8916 !== (6239,944.07)?\"-\":(5860,261.67) <= (+\"1090\",744.43)?(\"h\",7.95e+3):(733.31,\"X\"),p7n,e9W,[0,\"0\" >> 32,0,null],0,(7824,2176) == 2760?(0x1a2c,!!\"\"):455 <= (6.82,+\"970.28\")?1720 === (433.69,4180)?(!1,742.93):\"-\":(+\"0xafb\",492.79)]],AS:[[2008,h7n,\"-\",\"Apr\",z77,[2,0,0,927 <= (+\"803.81\",2622)?313.33 <= (8020,\"2280\" >> 32)?\"s\":\"g\":(!!\"\",356.41)],0,\"S\"],[2008,q_u,\"-\",\"Oct\",\"Sun>=1\",[+\"2\",0,0,\"s\"],60,4850 <= (+\"3552\",6150)?(582.24,6180) != (+\"658.56\",\"827\" >> 0)?6588 > (3800,9175)?\"Q\":\"D\":0x1c26:![]]],AT:[[2001,\"max\",8629 != 43.64?\"-\":(0x12bd,0x21c9),\"Oct\",\"Sun>=1\",[2,0,0,+\"3596\" !== 857?\"s\":4.52e+3],+\"60\",\"D\"],[2008,\"max\",\"-\",\"Apr\",\"Sun>=1\",[2,0,0,(83.63,332.57) >= 4770?(+\"1.68e+2\",2.29e+3):(225,5577) === (3287,884.58)?+\"6.04e+3\":1078 < (\"6\" - 0,1215)?\"s\":(+\"0x1b11\",+\"543.90\")],0,79.34 === 5400?(69.28,733.15):(329,6422) != 7605?(249,5481) != 325.03?\"S\":!!({}):3.83e+3]],AV:[[2008,\"max\",\"-\",\"Apr\",W2K,[2,0,0,(1370,676) == (621,35.37)?(1970,4156) >= 600.53?69.92 === (9506,6000)?(\"V\",![]):(7.61e+3,!({})):(835.74,\"U\"):\"s\"],+\"0\",\"S\"],[2008,\"max\",8510 <= (+\"2230\",2603)?(1380,5940) > 318.77?(\"0xfde\" * 1,337.57):(843.68,!![]):\"-\",F$R,\"Sun>=1\",[2,0,0,\"s\"],\"60\" - 0,\"D\"]],AN:[[\"2008\" | 80,\"max\",\"-\",\"Apr\",c$8,[2,+\"0\",+\"0\",\"s\"],0,(4415,5762) < (814.18,1427)?149.04:\"S\"],[+\"2008\",\"max\",\"-\",\"Oct\",\"Sun>=1\",[2,0,\"0\" << 0,\"s\"],60,\"D\"]],LH:[[2008,e6T,(9980,+\"7365\") === 824?4.89e+3:\"-\",S5U,\"Sun>=1\",[\"2\" ^ 0,0,0,null],0,1510 !== (7663,+\"4160\")?16.06 >= (268.59,1560)?256 >= (\"9524\" ^ 0,2610)?8.73e+3:604.39:\"-\":(\"6.80e+3\" - 0,+\"6.49e+3\")],[2008,\"max\",(697.3,+\"9240\") > 1407?1230 < 7290?\"-\":(0x681,\"h\"):(0xc20,!!({})),\"Oct\",\"Sun>=1\",[2,0,+\"0\",null],30,\"-\"]],Fiji:[[2014,2018,\"-\",\"Nov\",b$0,[2,0,0,null],60,(12.93,+\"5626\") !== \"9558\" << 0?185 === 6290?(0x1466,!!({})):\"-\":(6.00e+2,3.45)],[\"2015\" * 1,+\"2021\",(1486,2720) > (8347,5596)?(6.15e+3,\"H\"):\"432.48\" - 0 < 2090?\"-\":(!![],!\"\"),g4f,\"Sun>=12\",[3,0,+\"0\",null],0,\"-\"],[2019,u2N,\"-\",\"Nov\",\"Sun>=8\",[2,0,0,null],60,1569 != 3955?64 === (579.63,\"3300\" - 0)?(6947,2700) <= 291.93?(\"m\",+\"0x24fe\"):(+\"0xb1b\",182.42):\"-\":\"s\"],[2020,\"only\",\"-\",u18,\"20\",[2,0,0,null],+\"60\",\"-\"],[2022,\"max\",\"-\",\"Nov\",J$e,[\"2\" ^ 0,+\"0\",0,null],60,(2740,975.45) >= 1500?(!!\"\",0x1980):848.5 == (6260,+\"500.36\")?(\"8026\" >> 0,3626) == (5850,1366)?0xfc1:(!!\"\",6.92e+2):\"-\"],[\"2023\" * 1,r2z,\"-\",\"Jan\",\"Sun>=12\",[3,0,0,null],0,\"-\"]],NZ:[[+\"2007\",\"max\",168 < (3860,761.76)?\"-\":(1471,\"842.89\" - 0) <= 2290?(!!1,\"0xd79\" << 64):(!!\"\",\"n\"),\"Sep\",\"lastSun\",[+\"2\",0,0,911.11 < (50.45,358.05)?(203.82,\"N\"):(+\"4.95\",1750) < 528?(1.06e+3,220.21):\"s\"],+\"60\",\"D\"],[2008,\"max\",(\"2530\" >> 64,6440) !== (690.8,65.38)?(7490,3885) >= (10.95,5610)?(622.14,!!\"\"):3211 === 8781?(\"I\",0xbd6):\"-\":85,\"Apr\",\"Sun>=1\",[2,0,0,\"2851\" >> 0 <= (9508,121)?(682.56,6170) <= 9115?(\"V\",0x20ac):6.19e+3:\"s\"],0,(1490,1590) < (\"1272\" >> 96,3741)?\"S\":2980 <= (2430,142.11)?!![]:+\"673\"]],Chatham:[[2007,\"max\",\"-\",\"Sep\",D26,[2,45,0,(+\"4379\",167.4) >= (+\"2380\",327)?!!({}):\"s\"],60,(4898,\"4200\" - 0) >= (8851,848.98)?\"-\":(2.69e+3,!!1)],[2008,\"max\",(8841,338.26) != (237.65,\"440.87\" * 1)?\"-\":(!({}),\"E\"),\"Apr\",w8J,[2,45,0,9819 == 9950?(!\"\",\"A\"):194.4 < (912.26,330)?\"s\":(![],2.78e+3)],\"0\" >> 64,(699.58,5368) == (181.35,+\"7664\")?+\"0x36a\":\"-\"]],WS:[[2012,2021,314.86 >= (3934,7353)?\"A\":\"-\",\"Apr\",\"Sun>=1\",[4,0,0,null],\"0\" | 0,\"-\"],[+\"2012\",2020,\"-\",\"Sep\",\"lastSun\",[3,+\"0\",0,null],60,\"-\"]],Eire:[[\"1981\" ^ 0,Z$j,3903 != +\"7661\"?\"-\":(875.32,3373) <= 178?(+\"0x1b17\",6.37e+3):(0x202b,!!({})),\"Mar\",d9_,[1,+\"0\",0,(322.52,393.18) < 8176?\"u\":453.38 <= 5979?(891.27,929.88) < (6368,+\"650.44\")?(1.11e+3,\"0x12b7\" - 0):(955.03,887.52):1.14e+3],0,(2978,1150) === 8782?906.96:(6890,8800) <= (549.48,5210)?145 < (9340,7040)?(848.78,!!0):![]:\"-\"],[1996,\"max\",\"-\",\"Oct\",\"lastSun\",[1,\"0\" ^ 0,+\"0\",\"u\"],-60,(\"7427\" * 1,+\"861.77\") === (\"2940\" | 20,60.09)?(3.36e+3,!![]):7687 <= 830.97?(!\"\",24.29):\"-\"]],EU:[[\"1981\" - 0,\"max\",\"-\",\"Mar\",\"lastSun\",[1,\"0\" | 0,0,\"u\"],60,(8440,410) >= 656?511:\"S\"],[\"1996\" >> 0,\"max\",6760 == +\"5150\"?0x25b0:\"-\",\"Oct\",\"lastSun\",[1,0,0,(\"1.47\" - 0,8770) != (+\"7508\",9927)?\"121.25\" - 0 > (146.97,997.07)?(1910,7330) < (678.33,5120)?(\"b\",0xaca):\"d\":\"u\":(!!\"1\",\"790.56\" * 1)],+\"0\",(618.6,58.17) <= \"8250\" - 0?\"-\":(3220,136.79) <= (484.56,6030)?(\"6620\" | 24) !== (\"9390\" * 1,403.11)?(0xf92,\"J\"):(\"G\",0x2f3):(\"a\",2.90e+2)]],\"C-Eur\":[[1981,\"max\",\"-\",\"Mar\",\"lastSun\",[2,+\"0\",0,(3210,2830) == (5390,202)?(\"R\",\"Q\"):\"s\"],60,1540 === (613,9850)?+\"0x75f\":\"S\"],[1996,\"max\",+\"766.69\" != 4560?5340 !== 7835?+\"4113\" >= (+\"965\",2540)?\"-\":5.43e+2:(+\"154\",5.39e+3):6.00e+3,\"Oct\",N2L,[2,0,0,(1274,3990) <= (\"7612\" >> 96,6120)?\"s\":(2370,371.75) < (9690,6204)?(0x1ef9,9.79e+3):465.33],0,(555.14,+\"6498\") != (1800,1910)?5130 >= (\"881.22\" - 0,2220)?(8267,83) != 964.39?\"-\":\"X\":(0x1fd6,9.95e+3):(9.11e+2,+\"913.66\")]],Thule:[[+\"2007\",r76,(7480,4576) == 7680?(1.16e+3,0x184c):\"-\",E_h,\"Sun>=8\",[2,0,0,null],60,(\"740.41\" * 1,+\"7130\") == (972,913.46)?0x916:(2300,246.87) >= (\"7110\" ^ 0,+\"5406\")?\"p\":\"D\"],[2007,\"max\",(\"2485\" << 32,130.31) >= 147?(\"G\",!\"\"):\"-\",q43,\"Sun>=1\",[2,+\"0\",\"0\" * 1,null],0,\"S\"]],US:[[2007,F1f,\"-\",\"Mar\",\"Sun>=8\",[2,0,0,null],60,(5989,772) <= 872.95?(+\"737.74\",3222) >= +\"9315\"?(0x1d25,\"k\"):(6349,\"33.72\" - 0) <= (796,4050)?\"D\":!!({}):!({})],[2007,\"max\",7310 === (9439,+\"986.81\")?(\"2.00e+3\" | 16,\"Z\"):671.15 == +\"3800\"?0x9e9:(3317,2400) >= +\"727.1\"?\"-\":(\"K\",\"a\"),\"Nov\",\"Sun>=1\",[2,0,0,null],0,(537,2951) >= (164,\"129.64\" * 1)?454.53 == (447.24,\"1610\" * 1)?9.96e+3:\"S\":+\"8.01e+3\"]],Canada:[[+\"2007\",\"max\",\"4740\" << 96 !== (2650,\"162\" - 0)?(\"6538\" ^ 0) >= (7625,+\"5081\")?\"-\":(9.00e+3,\"951.11\" - 0):!!\"1\",Q2V,\"Sun>=8\",[2,0,0,null],60,+\"1942\" != 4060?\"D\":379 == (471,983)?+\"984.12\":(\"J\",!!({}))],[+\"2007\",x4I,(\"8187\" >> 0,562) != (1870,3940)?\"-\":823.04 >= +\"8570\"?\"i\":+\"1.86e+3\",\"Nov\",\"Sun>=1\",[2,0,0,null],\"0\" * 1,\"S\"]],Mexico:[[2002,\"max\",506.22 < (+\"8935\",9249)?(9450,807.44) <= 7700?\"-\":2070 == 842.28?![]:(3.87e+3,0xa91):(5.08e+3,\"r\"),\"Apr\",\"Sun>=1\",[2,0,0,null],60,5400 > (+\"335\",\"2900\" ^ 0)?(9600,8220) === 4299?40.62:\"D\":(![],0x25f4)],[2002,V6B,753.46 <= (4570,332)?(575.59,!![]):\"-\",\"Oct\",U7L,[2,0,0,null],0,(8634,9198) <= (5600,\"121.27\" * 1)?(0xe87,\"1.83e+3\" >> 0):4083 > \"5104\" * 1?147.29:\"S\"]],Cuba:[[2012,\"max\",\"-\",G3C,\"Sun>=1\",[0,\"0\" ^ 0,0,3915 == 4570?(\"T\",579.29):(7699,+\"6028\") != 659.31?\"s\":!!\"1\"],0,(3240,5660) === 809.63?4.01e+3:\"S\"],[+\"2013\",\"max\",\"-\",U1G,\"Sun>=8\",[0,0,\"0\" ^ 0,(5441,725.24) !== (8530,9080)?\"s\":(2.10e+3,\"P\")],60,\"D\"]],Haiti:[[2017,l9d,+\"612\" > (\"9741\" | 12,593)?\"397.57\" * 1 > (1900,2610)?4.67e+3:\"-\":(951.18,+\"6.58e+3\"),\"Mar\",o7$,[2,0,0,null],+\"60\",(279.05,614.62) === 2752?(\"r\",\"Q\"):\"D\"],[2017,\"max\",(2045,1490) == 654?(+\"2144\",5330) >= (116.68,\"392.72\" - 0)?(4959,741.11) == 7770?160.60:\"k\":9.03e+2:\"-\",\"Nov\",\"Sun>=1\",[2,0,+\"0\",null],0,4690 < 545.15?(5.89e+3,+\"246.39\"):\"S\"]],Brazil:[[2016,+\"2019\",5346 != (9219,897.53)?\"-\":709.5 > 876?0x447:1116 >= 1540?!\"\":(!![],\"d\"),\"Feb\",\"Sun>=15\",[\"0\" | 0,0,0,null],\"0\" ^ 0,(878,9995) !== (\"5241\" >> 64,\"3864\" ^ 0)?7808 !== (8694,\"5210\" << 0)?\"-\":(\"D\",![]):1.68e+3],[+\"2018\",R6o,318.76 !== (8250,4761)?\"-\":455 >= 2317?(0xd60,769):(952.77,5050) !== (477.84,3910)?(!![],!!0):(!\"\",\"D\"),\"Nov\",\"Sun>=1\",[\"0\" | 0,0,0,null],+\"60\",\"-\"]],Chile:[[2016,2018,(8810,982.76) < (6493,5050)?\"-\":796.64,z$w,\"Sun>=9\",[+\"3\",0,0,\"u\"],0,(4187,\"4197\" - 0) != (560,+\"8144\")?\"-\":(59,163.69) <= 1450?!!({}):(479.89,\"T\")],[2016,2018,(1210,+\"345.73\") != +\"5782\"?7500 !== (+\"1.86\",3146)?\"-\":\"5510\" >> 64 < (\"8390\" >> 32,7910)?(626.73,!!0):(\"7.20e+3\" * 1,!!0):(!!({}),\"k\"),L8d,s0v,[4,0,0,2140 != +\"706.54\"?\"u\":8.88e+3],60,\"-\"],[2019,\"max\",\"-\",t8A,g1e,[3,0,0,(+\"814\",\"6797\" >> 64) <= (\"2605\" << 64,8720)?(4410,+\"7140\") === 44.18?475 == (636.74,\"2259\" ^ 0)?(![],234.38):0x139f:\"u\":(\"u\",!!\"1\")],0,292 > (+\"9870\",3000)?2310 < 4407?7618 <= 9778?(4.95e+3,861.48):(![],!0):(6.41e+3,!\"\"):\"-\"],[2019,\"max\",570.61 > \"235.28\" * 1?+\"7870\" !== +\"395\"?(583,4887) != (8603,775)?\"-\":5.90e+3:6.43e+3:(!![],!\"\"),\"Sep\",\"Sun>=2\",[4,0,+\"0\",(677.09,6380) !== 867.07?2760 !== 171.31?\"973\" >> 32 >= (3010,9390)?(575.58,\"D\"):\"u\":(![],4.26e+3):1.91e+3],60,\"-\"]],Para:[[2010,\"max\",(9040,33.9) == 360.31?(\"Z\",\"P\"):\"-\",\"Oct\",\"Sun>=1\",[0,0,0,null],+\"60\",\"-\"],[\"2013\" << 64,\"max\",\"460.13\" * 1 === (7110,\"486.15\" * 1)?2.85e+3:\"-\",\"Mar\",D0$,[+\"0\",+\"0\",\"0\" - 0,null],\"0\" | 0,(+\"39\",1915) === (400,\"372\" >> 64)?(4520,9810) === (+\"3670\",238.65)?(\"m\",131.30):(\"1826\" ^ 0,1000) != 5060?0x10f9:0x2cf:\"-\"]]}});};s2=s_Z=>{var W$K=k_Cdw;var J0G,z9Z,D_8;W$K.y6g();J0G=\"undef\";J0G+=\"ined\";z9Z=typeof _CIQ !== J0G?_CIQ:s_Z.CIQ;z9Z.ChartEngine.prototype.touchSingleClick=function(j91,K_Z,x7z){var J$z,D6O;J$z=this;D6O=arguments;return function(){(function(){var s51,V8S,t4z,y2q,S$V;s51=\"touchSingl\";s51+=\"eClick\";W$K.j1L();if(!this.cancelTouchSingleClick){if(this.runPrepend(\"touchSingleClick\",D6O)){return;}if(this.editingAnnotation){return;}this.clicks={s1MS:-1,e1MS:-+\"1\",s2MS:-1,e2MS:-1};if(!this.displayCrosshairs){return;}if(!this.displayInitialized){return;}if(this.openDialog !== \"\"){return;}if(K_Z < this.left || K_Z > this.right || x7z < this.top || x7z > this.bottom){return;}V8S=this.crossYActualPos;t4z=this.crossXActualPos;this.currentPanel=this.whichPanel(V8S);y2q=this.currentVectorParameters.vectorType;if(!z9Z.Drawing || !y2q || !z9Z.Drawing[y2q] || !new z9Z.Drawing[y2q]().dragToDraw){if(!this.drawingClick(this.currentPanel,t4z,V8S)){R_X(this,K_Z,x7z);}if(!this.currentVectorParameters.vectorType){S$V=this.activeMarker && this.activeMarker.click({cx:t4z,cy:V8S,panel:this.currentPanel});if(!S$V){this.dispatch(\"tap\",{stx:this,panel:this.currentPanel,x:t4z,y:V8S});}}}}this.runAppend(s51,D6O);}).apply(J$z,D6O);};};z9Z.ChartEngine.prototype.touchDoubleClick=function(y8K,A3V,C41){var N5b,B77;N5b=\"touchDoub\";N5b+=\"leCl\";N5b+=\"ick\";if(this.runPrepend(N5b,arguments)){return;}if(this.editingAnnotation){return;}if(z9Z.ChartEngine.drawingLine){return this.undo();}if(this.activeDrawing){return;}R_X(this,A3V,C41);B77=this.activeMarker && this.activeMarker.doubleClick({cx:A3V,cy:C41,panel:this.currentPanel});if(!B77){this.dispatch(\"doubleTap\",{stx:this,finger:y8K,x:A3V,y:C41});}this.runAppend(\"touchDoubleClick\",arguments);};z9Z.ChartEngine.prototype.startProxy=function(A_n){this.touchPointerType=A_n.pointerType;if(this.touchPointerType != \"touch\"){this.mouseMode=!!({});return;}this.mouseMode=![];this.touches[this.touches.length]={pointerId:A_n.pointerId,pageX:A_n.clientX,pageY:A_n.clientY,clientX:A_n.clientX,clientY:A_n.clientY};this.changedTouches=[{pointerId:A_n.pointerId,pageX:A_n.clientX,pageY:A_n.clientY,clientX:A_n.clientX,clientY:A_n.clientY}];W$K.j1L();if(this.touches.length == 1){this.gesturePointerId=A_n.pointerId;}this.touchstart(A_n);};z9Z.ChartEngine.prototype.moveProxy=function(b6j){var E4Q;E4Q=\"t\";E4Q+=\"o\";W$K.y6g();E4Q+=\"uc\";E4Q+=\"h\";if(b6j.pointerType && b6j.pointerType != E4Q){this.mouseMode=!!({});return;}this.mouseMode=!1;this.touchmove(b6j);};function R_X(W0h,q6G,z43){var F9k;if(!W0h.layout.crosshair){z9Z.ChartEngine.crosshairY=0;z9Z.ChartEngine.crosshairX=0;W0h.cx=W0h.backOutX(0);W0h.cy=W0h.backOutY(0);W0h.findHighlights(null,!!\"1\");z9Z.ChartEngine.crosshairY=z43;z9Z.ChartEngine.crosshairX=q6G;F9k=W0h.container.getBoundingClientRect();W0h.top=F9k.top;W0h.left=F9k.left;W0h.right=W0h.left + W0h.width;W0h.bottom=W0h.top + W0h.height;W0h.cx=W0h.backOutX(q6G);W0h.cy=W0h.backOutY(z43);if(W0h.currentPanel && W0h.currentPanel.chart.dataSet){W0h.crosshairTick=W0h.tickFromPixel(W0h.cx,W0h.currentPanel.chart);W0h.crosshairValue=W0h.adjustIfNecessary(W0h.currentPanel,W0h.crosshairTick,W0h.valueFromPixel(W0h.cy,W0h.currentPanel));}W0h.headsUpHR();}W0h.findHighlights(!\"\");W0h.draw();}z9Z.ChartEngine.prototype.endProxy=function(a2e){var f_Y;if(this.touchPointerType != \"touch\"){this.mouseMode=!!({});return;}this.mouseMode=!({});f_Y=this.touches.length;for(var h3w=0;h3w < this.touches.length;h3w++){if(this.touches[h3w].pointerId == a2e.pointerId){this.touches.splice(h3w,1);break;}}if(h3w == f_Y){this.touches=[];this.grabbingScreen=!!0;this.touching=!1;return;}this.changedTouches=[{pointerId:a2e.pointerId,pageX:a2e.clientX,pageY:a2e.clientY,clientX:a2e.clientX,clientY:a2e.clientY}];this.touchend(a2e);};z9Z.ChartEngine.prototype.msMouseMoveProxy=function(M2F){if(this.touches.length || !this.mouseMode){return;}W$K.j1L();this.mousemove(M2F);};z9Z.ChartEngine.prototype.msMouseDownProxy=function(z2v){if(!this.mouseMode){return;}this.mousedown(z2v);};z9Z.ChartEngine.prototype.msMouseUpProxy=function(N3B){if(!this.mouseMode){return;}this.mouseup(N3B);};z9Z.ChartEngine.prototype.iosMouseMoveProxy=function(j8T){if(this.touching){return;}this.mousemove(j8T);};z9Z.ChartEngine.prototype.iosMouseDownProxy=function(K10){var P4p,C8p,v3g;if(this.touching){this.mouseMode=!\"1\";return;}this.mouseMode=!\"\";W$K.y6g();P4p=-414638960;C8p=-2095465042;v3g=2;for(var U87=1;W$K.P6(U87.toString(),U87.toString().length,56006) !== P4p;U87++){this.mousedown(K10);v3g+=2;}if(W$K.P6(v3g.toString(),v3g.toString().length,93332) !== C8p){this.mousedown(K10);}};z9Z.ChartEngine.prototype.iosMouseUpProxy=function(u8V){if(this.touching){return;}W$K.y6g();this.mouseup(u8V);};z9Z.ChartEngine.prototype.touchmove=function(G4Y){var Z5r,R9P,j_Q,F07,o2D,i6a,Q5z,w1k,k42,F9Y,W0s,z9n,Z6d,o5D,g2F,E$F,K$Y,m8F,Y4L,v4x,s63,m$V,i34,l7z,I0y,j5M,g4C,F$Y,E3u,P5X,V2r,n$T,f71,T9F,j67,g_8,D0_,t3q,t67,h$u;Z5r=\"f\";Z5r+=\"reef\";Z5r+=\"orm\";R9P=\"n\";R9P+=\"one\";if(!this.displayInitialized){return;}if(this.openDialog !== \"\"){return;}if(z9Z.ChartEngine.ignoreTouch === !!1){return;}j_Q=[];W$K.j1L();if(!this.overYAxis || this.controls && this.controls.crossX && this.controls.crossX.style.display != R9P){if(G4Y && G4Y.preventDefault && G4Y.cancelable && this.captureTouchEvents){G4Y.preventDefault();}if(G4Y){G4Y.stopPropagation();}}F07=new Date().getTime();if(this.clicks.s2MS == -(\"1\" >> 32)){this.clicks.e1MS=F07;if(this.clicks.e1MS - this.clicks.s1MS < 25){return;}}else {this.clicks.e2MS=F07;if(this.clicks.e2MS - this.clicks.s2MS < 25){return;}}if(!G4Y.pointerType){G4Y.pointerType=this.touchPointerType;}if(z9Z.isSurface){if(this.mouseMode){return;}if(!G4Y.pointerId){G4Y.pointerId=this.gesturePointerId;}for(var c02=0;c02 < this.touches.length;c02++){if(this.touches[c02].pointerId == G4Y.pointerId){o2D=Math.abs(this.touches[c02].pageX - G4Y.clientX);i6a=Math.abs(this.touches[c02].pageY - G4Y.clientY);W$K.G4m(41);Q5z=Math.sqrt(W$K.e7l(i6a,i6a,o2D,o2D));if(!Q5z){return;}this.clicks.e1MS=new Date().getTime();if(this.clicks.e1MS - this.clicks.s1MS < 50){return;}if(this.touches[c02].pageX == G4Y.clientX && this.touches[c02].pageY == G4Y.clientY){return;}this.touches[c02].pageX=this.touches[c02].clientX=G4Y.clientX;this.touches[c02].pageY=this.touches[c02].clientY=G4Y.clientY;break;}}if(c02 === 0){this.movedPrimary=!!({});}else {this.movedSecondary=!!({});}if(c02 == this.touches.length){return;}this.changedTouches=[{pointerId:G4Y.pointerId,pageX:G4Y.clientX,pageY:G4Y.clientY,clientX:G4Y.clientX,clientY:G4Y.clientY}];j_Q=this.touches.length?this.touches:this.changedTouches;}else {j_Q=G4Y.touches;this.changedTouches=G4Y.changedTouches;}if(j_Q.length == +\"1\"){if(Math.pow(this.clicks.x - j_Q[+\"0\"].clientX,2) + Math.pow(this.clicks.y - j_Q[0].clientY,2) <= \"16\" - 0){return;}}w1k=this.crosshairXOffset;k42=this.crosshairYOffset;F9Y=this.currentVectorParameters.vectorType && this.currentVectorParameters.vectorType !== \"\";W0s=!this.layout.crosshair && !F9Y && !this.touchNoPan;if(G4Y.pointerType == \"pen\" || W0s || this.activeDrawing && this.activeDrawing.name == Z5r){w1k=k42=0;}if(this.runPrepend(\"touchmove\",arguments)){return;}if(z9Z.ChartEngine.resizingPanel){o5D=j_Q[0];z9n=o5D.clientX;Z6d=o5D.clientY;W$K.b8R(0);this.mousemoveinner(W$K.e7l(z9n,w1k),W$K.e7l(Z6d,k42));return;}if(this.moveB != -1){this.touchMoveTime=new Date();}this.moveA=this.moveB;this.moveB=j_Q[0].pageX;if(j_Q.length == +\"1\" && !this.twoFingerStart){E$F=j_Q[0];z9n=E$F.clientX;Z6d=E$F.clientY;this.pinchingScreen=0;W$K.b8R(0);this.mousemoveinner(W$K.e7l(z9n,w1k),W$K.F9v(Z6d,k42));K$Y=this.whichPanel(Z6d);m8F=this.xAxisAsFooter === !![]?this.chart.canvasHeight:this.chart.panel.bottom;this.overXAxis=Z6d <= this.top + m8F && Z6d >= m8F - this.xaxisHeight + this.top && this.insideChart;if(!K$Y){this.overYAxis=!!0;}else {this.overYAxis=(z9n >= K$Y.right || z9n <= K$Y.left) && this.insideChart;}}else if(j_Q.length == 2){if(!this.allowZoom || this.activeDrawing && !this.allowDrawingZoom){return;}if(!this.displayCrosshairs){return;}Y4L=j_Q[+\"0\"];v4x=Y4L.clientX;s63=Y4L.clientY;m$V=j_Q[1];i34=m$V.clientX;l7z=m$V.clientY;W$K.G4m(148);g2F=Math.sqrt(W$K.e7l(v4x,i34,v4x,s63,l7z,s63,i34,l7z));W$K.b8R(51);var e0k=W$K.F9v(4,6,3,6);this.pinchingCenter=(Math.min(v4x,i34) - Math.max(v4x,i34)) / e0k;I0y=Math.round(this.gestureStartDistance - g2F);if(W0s){this.pinchingScreen=5;}this.clearPixelCache();if(this.pinchingScreen < 2){if(z9Z.isSurface && (!this.movedPrimary || !this.movedSecondary)){return;}if(v4x < this.pt.x1 && i34 < this.pt.x2 || v4x > this.pt.x1 && i34 > this.pt.x2 || s63 < this.pt.y1 && l7z < this.pt.y2 || s63 > this.pt.y1 && l7z > this.pt.y2){this.pinchingScreen=0;}else {this.pinchingScreen++;if(this.pinchingScreen < 2){return;}}}this.pt={x1:v4x,x2:i34,y1:s63,y2:l7z};if(this.pinchingScreen === 0){j5M=\"p\";j5M+=\"a\";j5M+=\"n\";this.grabMode=j5M;W$K.b8R(0);this.mousemoveinner(W$K.F9v(v4x,w1k),W$K.e7l(s63,k42));this.gestureStartDistance=g2F;}else if(this.grabStartValues){g4C=Math.asin((Math.max(l7z,s63) - Math.min(l7z,s63)) / g2F);if(Math.abs(I0y) < 12 && !W0s){this.moveCount++;if(this.moveCount == 4){this.pinchingScreen=0;this.moveCount=0;return;}}else {this.moveCount=0;}if(g4C < 1 || !this.goneVertical && g4C < 1.37){if(!this.currentPanel){return;}F$Y=this.currentPanel.chart;this.goneVertical=![];g2F=this.pt.x2 - this.pt.x1;E3u=this.grabStartValues.t2 - this.grabStartValues.t1 || +\"1\";P5X=this.grabStartValues.t1 + E3u / (\"2\" << 0);W$K.b8R(9);V2r=Math.abs(W$K.e7l(g2F,E3u));if(F$Y.allowScrollFuture === !({}) && F$Y.allowScrollPast === ![]){V2r=Math.max(V2r,F$Y.width / F$Y.dataSet.length);}n$T=this.layout.candleWidth;this.setCandleWidth(V2r,F$Y);if(F$Y.maxTicks < this.minimumZoomTicks){this.setCandleWidth(n$T,F$Y);return;}this.micropixels=+\"0\";f71=this.pixelFromTick(Math.round(P5X),F$Y);W$K.b8R(11);var w6f=W$K.e7l(0,19,21);T9F=this.pt.x1 - this.left + Math.round(g2F / w6f);W$K.G4m(4);j67=W$K.F9v(f71,T9F);W$K.b8R(9);g_8=W$K.F9v(j67,V2r);D0_=Math.round(g_8);F$Y.scroll-=D0_;W$K.G4m(4);this.microscroll=W$K.e7l(D0_,g_8);this.micropixels=V2r * this.microscroll;this.draw();}else {t3q=this.grabStartYAxis;this.goneVertical=!\"\";if(t3q){t3q.zoom=this.grabStartZoom + (this.gestureStartDistance - g2F);if(this.grabStartZoom < t3q.height){if(t3q.zoom >= t3q.height){W$K.b8R(149);var I0C=W$K.F9v(5,6,1,1,16);t3q.zoom=t3q.height - I0C;}}else {if(t3q.zoom <= t3q.height){t3q.zoom=t3q.height + 1;}}this.draw();}}this.updateChartAccessories();}}else if(j_Q.length == 3 && z9Z.ChartEngine.allowThreeFingerTouch){if(!this.displayCrosshairs){return;}t67=j_Q[0];h$u=t67.clientX;g2F=this.grabStartX - h$u;W$K.G4m(25);var v5W=W$K.F9v(7,7,7,8,1);this.grabEndPeriodicity=this.grabStartPeriodicity + Math.round(g2F / v5W);if(this.grabEndPeriodicity < 1){this.grabEndPeriodicity=+\"1\";}}this.runAppend(\"touchmove\",arguments);};z9Z.ChartEngine.prototype.touchstart=function(b2d){var e3X,Q1C,H0k,d5Y,F7$,f2Y,A6n,g7W,q4T,N78,G2L,X8V,C7g,v2t,U$p,I2e,X3u,b_J,w5C,p4c,U2z,T2O,d2p,J8m,j_I,A6v,j_p,f$w,F1J,Q6$,c6T,r3T;if(z9Z.ChartEngine.ignoreTouch){return;}if(z9Z.isSurface){this.movedPrimary=!({});this.movedSecondary=!\"1\";}else {if(this.touchingEvent){clearTimeout(this.touchingEvent);}this.touching=!\"\";this.touches=b2d.touches;this.changedTouches=b2d.changedTouches;}e3X=this.crosshairXOffset;Q1C=this.crosshairYOffset;if(this.touchPointerType == \"pen\"){e3X=Q1C=0;}if(this.runPrepend(\"touchstart\",arguments)){return;}var {layout:U$m}=this;var {vectorType:J84}=this.currentVectorParameters;H0k=U$m.crosshair && J84 !== \"\" || J84;if(this.manageTouchAndMouse && b2d && b2d.preventDefault && b2d.cancelable && this.captureTouchEvents){b2d.preventDefault();}this.hasDragged=!1;this.doubleFingerMoves=0;this.moveCount=0;this.twoFingerStart=!\"1\";W$K.j1L();if(this.touches.length == 1 || this.touches.length == 2){this.touchMoveTime=Date.now();q4T=this.touches[0];f2Y=q4T.clientX;A6n=q4T.clientY;this.moveA=f2Y;this.moveB=-1;if(this.openDialog === \"\"){this.registerPointerEvent({x:f2Y,y:A6n,time:this.touchMoveTime},\"down\");if(this.changedTouches.length == 1 && !this.isDoubleClick(!![])){z9Z.extend(this.clicks,{s1MS:this.touchMoveTime,e1MS:-1,s2MS:-1,e2MS:-1,x:this.changedTouches[0].pageX,y:this.changedTouches[0].pageY});}}N78=this.container.getBoundingClientRect();this.top=N78.top;this.left=N78.left;this.right=this.left + this.width;this.bottom=this.top + this.height;if(this.touches.length == 1){G2L=this.backOutY(A6n);this.currentPanel=this.whichPanel(G2L);}if(!this.currentPanel){this.currentPanel=this.chart.panel;}g7W=this.currentPanel;if(f2Y >= this.left && f2Y <= this.right && A6n >= this.top && A6n <= this.bottom){this.insideChart=!![];X8V=this.xAxisAsFooter === !\"\"?this.chart.canvasHeight:this.chart.panel.bottom;this.overXAxis=A6n <= this.top + X8V && A6n >= this.top + X8V - this.xaxisHeight;this.overYAxis=f2Y >= this.left + g7W.right || f2Y <= this.left + g7W.left;C7g=-+\"1\";this.cy=this.backOutY(A6n);this.cx=this.backOutX(f2Y);this.crosshairTick=this.tickFromPixel(this.cx,g7W.chart);this.crosshairValue=this.adjustIfNecessary(g7W,this.crosshairTick,this.valueFromPixel(this.cy,this.currentPanel));for(var D76=0;D76 < this.drawingObjects.length;D76++){v2t=this.drawingObjects[D76];if(v2t.highlighted){if(C7g < 0){C7g=D76;}U$p=v2t.highlighted;this.findHighlights(!0);if(D76 == C7g && v2t.highlighted && !v2t.permanent){if(this.clicks.s2MS == -1){this.activateRepositioning(v2t);}else {this.findHighlights(!!\"\",!!\"1\");}return;}this.anyHighlighted=!!({});v2t.highlighted=U$p;}}}else {this.insideChart=!\"1\";}if(this.insideChart && !H0k && U$m.headsUp !== \"floating\" && !(U$m.headsUp && U$m.headsUp.floating) && !J84 && !this.touchNoPan){e3X=Q1C=0;var {baselineHelper:Z0K}=this;if(Z0K.size){if(this.findBaselineHandle(b2d,!!({}))){return;}}if(this.controls.anchorHandles){I2e=Object.values(this.controls.anchorHandles);X3u=!1;for(var a3r=0;a3r < I2e.length;a3r++){b_J=I2e[a3r];var {handle:P7u, sd:o5E}=b_J;w5C=this.resolveX(this.cx);p4c=this.resolveY(this.cy);var {left:w1s, top:X0Y, right:o1q, bottom:L9l}=P7u.getBoundingClientRect();U2z=this.preferences.highlightsTapRadius;W$K.G4m(4);T2O=z9Z.boxIntersects(W$K.F9v(w1s,U2z),X0Y,W$K.F9v(o1q,U2z,W$K.b8R(0)),L9l,w5C,p4c,w5C,p4c);if(T2O){d2p=\"s\";d2p+=\"t\";d2p+=\"x-grab\";this.repositioningAnchorSelector={sd:o5E};P7u.classList.add(d2p);X3u=!!\"1\";}b_J.highlighted=T2O;}if(X3u){return;}}for(d5Y in this.panels){F7$=this.panels[d5Y];if(F7$.highlighted){this.grabHandle(F7$);return;}}this.grabbingScreen=!\"\";if(this.disableBackingStoreDuringTouch){this.disableBackingStore();}g7W.chart.spanLock=![];this.yToleranceBroken=![];W$K.G4m(0);this.grabStartX=W$K.F9v(f2Y,e3X);W$K.G4m(0);this.grabStartY=W$K.F9v(A6n,Q1C);this.grabStartMicropixels=this.micropixels;this.grabStartScrollX=g7W.chart.scroll;this.grabStartScrollY=g7W.yAxis.scroll;this.grabStartPanel=this.currentPanel;if(this.swipeStart){this.swipeStart(g7W.chart);}this.grabStartYAxis=this.whichYAxis(g7W,this.backOutX(f2Y));this.grabStartZoom=this.grabStartYAxis?this.grabStartYAxis.zoom:0;setTimeout((function(W7o){return function(){W7o.grabbingHand();};})(this),100);}else {this.grabbingScreen=!({});if(this.insideChart && g7W.subholder === b2d.target){J8m=this.currentVectorParameters.vectorType;if(z9Z.Drawing && J8m && z9Z.Drawing[J8m] && new z9Z.Drawing[J8m]().dragToDraw){this.userPointerDown=!!({});z9Z.ChartEngine.crosshairX=f2Y;z9Z.ChartEngine.crosshairY=A6n;if(g7W && g7W.chart.dataSet){this.crosshairTick=this.tickFromPixel(this.backOutX(z9Z.ChartEngine.crosshairX),this.currentPanel.chart);this.crosshairValue=this.adjustIfNecessary(g7W,this.crosshairTick,this.valueFromPixel(this.backOutY(z9Z.ChartEngine.crosshairY),this.currentPanel));}this.drawingClick(g7W,this.backOutX(f2Y),this.backOutY(A6n));this.headsUpHR();return;}}}if(this.touches.length == 1){if(!H0k){this.mouseTimer=Date.now();this.longHoldTookEffect=!({});if(this.longHoldTime || this.longHoldTime === 0){this.startLongHoldTimer((n16=>{W$K.y6g();return ()=>{W$K.j1L();return R_X(n16,f2Y,A6n);};})(this));}}else if(!J84 && g7W.subholder === b2d.target){j_I=-2021279895;A6v=-708765018;W$K.b8R(34);j_p=W$K.e7l(\"2\",0);for(var X9P=1;W$K.P6(X9P.toString(),X9P.toString().length,40930) !== j_I;X9P++){W$K.b8R(0);this.mousemoveinner(W$K.F9v(f2Y,e3X),W$K.F9v(A6n,Q1C));j_p+=2;}if(W$K.P6(j_p.toString(),j_p.toString().length,5055) !== A6v){W$K.G4m(3);this.mousemoveinner(W$K.F9v(f2Y,e3X),W$K.F9v(A6n,Q1C,W$K.G4m(4)));}}}}if(this.touches.length == 2){this.cancelLongHold=!![];this.swipe.end=!!({});if(!this.displayCrosshairs && !this.touchNoPan || !this.insideChart){return;}f$w=this.touches[1];F1J=f$w.clientX;Q6$=f$w.clientY;for(d5Y in this.panels){F7$=this.panels[d5Y];if(F7$.highlighted){this.grabHandle(F7$);return;}}g7W=this.currentPanel;W$K.b8R(148);this.gestureStartDistance=Math.sqrt(W$K.F9v(f2Y,F1J,f2Y,A6n,Q6$,A6n,F1J,Q6$));this.pt={x1:f2Y,x2:F1J,y1:A6n,y2:Q6$};this.grabbingScreen=!![];if(this.disableBackingStoreDuringTouch){this.disableBackingStore();}g7W.chart.spanLock=!!\"\";W$K.G4m(0);this.grabStartX=W$K.e7l(f2Y,e3X);W$K.G4m(0);this.grabStartY=W$K.e7l(A6n,Q1C);this.grabStartMicropixels=this.micropixels;this.grabStartScrollX=g7W.chart.scroll;this.grabStartScrollY=g7W.yAxis.scroll;this.grabStartPanel=g7W;if(this.swipeStart){this.swipeStart(g7W.chart);}this.grabStartCandleWidth=U$m.candleWidth;this.grabStartYAxis=this.whichYAxis(g7W,this.backOutX((f2Y + F1J) / 2)) || g7W.yAxis;this.grabStartZoom=this.grabStartYAxis?this.grabStartYAxis.zoom:0;this.grabStartPt=this.pt;this.grabStartValues={x1:this.pt.x1,x2:this.pt.x2,y1:this.valueFromPixel(this.pt.y1 - this.top,g7W),y2:this.valueFromPixel(this.pt.y2 - this.top,g7W),t1:this.tickFromPixel(this.pt.x1 - this.left,g7W.chart),t2:this.tickFromPixel(this.pt.x2 - this.left,g7W.chart)};this.twoFingerStart=!\"\";setTimeout((function(w34){return function(){w34.grabbingHand();};})(this),100);}else if(this.touches.length == 3){if(!this.displayCrosshairs){return;}c6T=this.touches[0];r3T=c6T.clientX;this.grabStartX=r3T;this.grabStartPeriodicity=U$m.periodicity;}this.runAppend(\"touchstart\",arguments);};z9Z.ChartEngine.prototype.touchend=function(n7i){var F3t,X3A,u3L,A$a,e5X,k97,j9b,I9j,W7z,J7N,z4U,B2n,t4G,s$h;F3t=\"t\";F3t+=\"ouc\";F3t+=\"hend\";if(z9Z.ChartEngine.ignoreTouch){return;}this.swipe.end=!!({});if(z9Z.isSurface){}else {this.touches=n7i.touches;this.changedTouches=n7i.changedTouches;}if(this.runPrepend(\"touchend\",arguments)){return;}var {touches:S0u, layout:k1i}=this;var {vectorType:I57}=this.currentVectorParameters;X3A=k1i.crosshair && I57 !== \"\" || I57;this.cancelLongHold=!![];if(S0u.length <= 1){if(X3A){if(!S0u.length || !this.twoFingerStart){this.grabbingScreen=!({});}}}if(S0u.length){this.grabStartX=-1;this.grabStartY=-1;}u3L=this.pinchingScreen;if(this.disableBackingStoreDuringTouch){this.reconstituteBackingStore();}if(!S0u.length){this.touchingEvent=setTimeout((function(G_t){return function(){W$K.y6g();G_t.touching=![];};})(this),500);if(z9Z.ChartEngine.resizingPanel){this.releaseHandle();if(this.changedTouches.length !== +\"1\" || this.grabStartY !== this.changedTouches[0].clientY){return;}}this.pinchingScreen=null;this.pinchingCenter=null;this.goneVertical=!({});this.grabbingScreen=!({});this.grabMode=\"\";if(this.highlightedDraggable){if(this.dragPlotOrAxis){this.dragPlotOrAxis(this.cx,this.cy);}this.currentPanel=this.whichPanel(this.cy);}this.grabStartYAxis=null;this.displayDragOK();this.doDisplayCrosshairs();this.updateChartAccessories();}else {if(z9Z.ChartEngine.resizingPanel){return;}}W$K.G4m(11);var s1c=W$K.F9v(0,13,14);A$a=S0u.length + s1c;if(this.changedTouches.length === 1){e5X=Date.now();k97=this.changedTouches[0];j9b=this.backOutY(k97.pageY) + this.crosshairYOffset;I9j=this.backOutX(k97.pageX) + this.crosshairXOffset;W7z=this.currentPanel;J7N=W7z && W7z.subholder === n7i.target;if(this.repositioningDrawing){this.changeOccurred(\"vector\");z9Z.clearCanvas(this.chart.tempCanvas,this);this.activateRepositioning(null);this.draw();if(!X3A){this.findHighlights(![],!![]);}return;}if(this.repositioningBaseline){this.repositioningBaseline=null;this.controls.baselineHandle.classList.remove(\"stx-grab\");z4U=this.mainSeriesRenderer || ({});if(z4U.params && z4U.params.baseline && z4U.params.type != \"mountain\"){}this.draw();return;}if(this.repositioningAnchorSelector){if(!this.repositioningAnchorSelector.hoverTick){this.repositioningAnchorSelector.hoverTick=this.tickFromPixel(I9j - this.crosshairXOffset,this.chart);}B2n=this.repositioningAnchorSelector.sd;z9Z.Studies.repositionAnchor(this,B2n);this.repositioningAnchorSelector=null;this.controls.anchorHandles[B2n.uniqueId].highlighted=!({});z9Z.Studies.displayAnchorHandleAndLine(this,B2n,this.chart.dataSegment);Object.values(this.controls.anchorHandles).forEach(({handle:h9m})=>{var m3u;W$K.y6g();m3u=\"s\";m3u+=\"t\";m3u+=\"x\";m3u+=\"-grab\";return h9m.classList.remove(m3u);});return;}if(this.openDialog === \"\"){this.registerPointerEvent({x:k97.clientX,y:k97.clientY,time:e5X},\"up\");}if(this.clicks.s2MS == -1){this.clicks.e1MS=e5X;if(!z9Z.Drawing || !I57 || !z9Z.Drawing[I57] || !new z9Z.Drawing[I57]().dragToDraw){var {up:E5k, down:D9b}=this.pointerEvents;t4G=1200;W$K.G4m(4);var c52=W$K.F9v(8,6);W$K.b8R(13);var g35=W$K.F9v(20,18);s$h=Math.pow(D9b[0].x - E5k[0].x,c52) + Math.pow(D9b[0].y - E5k[0].y,g35) <= t4G;if(s$h && this.clicks.e1MS - this.clicks.s1MS < 750 && !this.longHoldTookEffect && (!this.hasDragged || X3A)){setTimeout(this.touchSingleClick(A$a,this.clicks.x,this.clicks.y),this.doubleClickTime + 1);}else {this.clicks={s1MS:-+\"1\",e1MS:-1,s2MS:-1,e2MS:-1};}}this.userPointerDown=!!\"\";if(z9Z.Drawing && this.activeDrawing && this.activeDrawing.dragToDraw && J7N){this.drawingClick(W7z,I9j,j9b);return;}if(this.isDoubleClick(!!\"1\") && (J7N || this.overYAxis || this.overXAxis)){this.touchDoubleClick(A$a,this.clicks.x,this.clicks.y);}}else {this.clicks.e2MS=e5X;this.clicks={s1MS:-1,e1MS:-1,s2MS:-1,e2MS:-1};}}else if(this.displayCrosshairs){if(this.grabEndPeriodicity != -+\"1\" && !isNaN(this.grabEndPeriodicity)){if(z9Z.ChartEngine.isDailyInterval(this.layout.interval) || this.allowIntradayNMinute){this.setPeriodicity({period:this.grabEndPeriodicity,interval:this.layout.interval});}W$K.G4m(1);this.grabEndPeriodicity=-W$K.F9v(\"1\",32);}}if(this.changedTouches.length){if(!X3A && !this.currentVectorParameters.vectorType && A$a == 1 || this.twoFingerStart && !u3L && !this.touches.length){if(this.swipeRelease){this.swipeRelease();}this.findHighlights(![],!!1);}if(u3L && this.continuousZoom){this.continuousZoom.execute();this.continuousZoom.execute(!!({}));}}if(!S0u.length){this.twoFingerStart=!1;}this.runAppend(F3t,arguments);};D_8=!({});z9Z.ChartEngine.prototype.mousemoveinner=z9Z.ChartEngine.prototype.mousemoveinner || (function(V1K,P5l){if(!D_8){console.error(\"touch feature requires activating movement feature.\");}D_8=!0;});};A7=x7A=>{var E_X,L2Z;E_X=\"und\";E_X+=\"efi\";E_X+=\"n\";E_X+=\"ed\";L2Z=typeof _CIQ !== E_X?_CIQ:x7A.CIQ;L2Z.Visualization=L2Z.Visualization || (function(u9Q){k_Cdw.y6g();var y5n;if(!u9Q){y5n=\"CIQ.Visualizatio\";y5n+=\"n() missing a\";y5n+=\"ttributes a\";y5n+=\"rgument.\";console.log(y5n);return;}if(typeof u9Q.renderFunction !== \"function\"){console.log(\"CIQ.Visualization() missing renderFunction property in attributes.\");return;}this.container=null;this.attributes=u9Q;this.data=null;this.object=null;});L2Z.extend(L2Z.Visualization.prototype,{destroy:function(u44){var L_Q;L_Q=this.container || ({});L2Z.resizeObserver(L_Q,null,L_Q.resizeHandle);if(L_Q.autoGenerated){L_Q.remove();delete this.container;}else {L_Q.innerHTML=\"\";}k_Cdw.y6g();if(u44){return;}this.attributes=null;this.container=null;this.data=null;this.object=null;this.destroy=this.draw=this.setAttributes=function(){};this.updateData=function(){return undefined;};},draw:function(f9q){var f2X,b9t,k41,d5e,L2W,P3K;function G8r(Z9o,J$1){return Z9o.index < J$1.index?-1:Z9o.index > J$1.index?1:0;}if(!this.data || typeof this.data !== \"object\"){console.log(\"CIQ.Visualization.draw() missing data.\");return;}f2X=this.attributes || ({});b9t=f2X.document || document;k41=f2X.container || this.container;if(typeof k41 === \"string\"){k41=b9t.querySelector(k41);}if(!k41){k41=document.createElement(\"div\");k41.style.height=k41.style.width=\"300px\";b9t.body.appendChild(k41);k41.autoGenerated=!![];}if(f2X.stx){d5e=f2X.stx.chart.canvasShim;if(f2X.useCanvasShim && d5e && d5e !== k41 && d5e !== k41.parentNode){if(!k41.autoGenerated){k41=k41.cloneNode();k41.id=\"\";k41.autoGenerated=!![];}d5e.appendChild(k41);}}if(this.container && this.container !== k41){this.destroy(!!1);}if(!k41.resizeHandle){L2W=function(w$R){return function(){k_Cdw.j1L();if(w$R.data && w$R.container && b9t.body.contains(w$R.container)){w$R.draw.call(w$R,!!1);}};};k41.resizeHandle=L2Z.resizeObserver(k41,L2W(this),null);}this.container=k41;this.attributes=f2X;f2X=L2Z.ensureDefaults({container:this.container},this.attributes);P3K=f2X.renderFunction(Object.values(this.data).sort(G8r),f2X);if(P3K){if(f2X.id){P3K.id=f2X.id;}if(f9q || f2X.forceReplace){this.container.innerHTML=\"\";this.container.appendChild(P3K);}}this.attributes=f2X;this.object=P3K;},setAttributes:function(E10,D0V){var a3U,b4U,a5y;a3U=[\"renderFunction\",\"container\",\"stx\",\"useCanvasShim\",\"id\",\"forceReplace\"];b4U=!!\"\";a5y=E10;if(typeof E10 == \"string\"){a5y={};a5y[E10]=D0V;}if(typeof a5y == \"object\"){for(var K5m in a5y){if(this.attributes[K5m] !== a5y[K5m] && a3U.indexOf(K5m) !== -1){b4U=!!({});}this.attributes[K5m]=a5y[K5m];}}this.draw(b4U);},updateData:function(E2g,I6w){var v23,f_p,H0a,E1F,Q06,T7L;v23=\"a\";v23+=\"d\";v23+=\"d\";f_p=\"d\";f_p+=\"e\";f_p+=\"l\";f_p+=\"ete\";Q06=Array.isArray(E2g)?E2g.reduce(function(t0N,Z_D){k_Cdw.j1L();t0N[Z_D.name]=Z_D;return t0N;},{}):L2Z.shallowClone(E2g);for(H0a in Q06){T7L=\"[object O\";T7L+=\"bject]\";E1F=Q06[H0a];if(Object.prototype.toString.call(E1F) !== T7L){Q06[H0a]={value:E1F};}if(!Q06[H0a].name){Q06[H0a].name=H0a;}if(!Q06[H0a].value){Q06[H0a].value=0;}}if(!I6w){I6w=\"replace\";}switch(I6w.toLowerCase()){case f_p:for(H0a in Q06){delete this.data[H0a];}break;case \"replace\":this.data={};case \"update\":case v23:for(H0a in Q06){if(!this.data[H0a]){this.data[H0a]={name:H0a};}E1F=Q06[H0a].value;if(Object.prototype.toString.call(E1F) == \"[object Number]\"){if(!this.data[H0a].value || I6w == \"update\"){this.data[H0a].value=0;}this.data[H0a].value+=E1F;}else {this.data[H0a].value=E1F;}for(var b7b in Q06[H0a]){if(b7b !== \"value\"){this.data[H0a][b7b]=Q06[H0a][b7b];}}}break;default:console.log(\"Invalid or missing action. Valid values are 'add', 'delete', 'replace', or 'update'.\");}this.draw(this.attributes.forceReplace);return this;}});L2Z.ChartEngine.prototype.embedVisualization=function(I8z){if(!I8z){I8z={};}I8z.stx=this;k_Cdw.y6g();I8z.useCanvasShim=!!\"1\";I8z.translator=function(E3V){return I8z.stx.translateIf(E3V);};I8z.document=this.container.ownerDocument;return new L2Z.Visualization(I8z);};};W0=G0S=>{var u1r,X6q;u1r=typeof _CIQ !== \"undefined\"?_CIQ:G0S.CIQ;if(!u1r.Studies){X6q=\"medianPr\";X6q+=\"ice feature requires first activ\";X6q+=\"ating studies feature.\";console.error(X6q);}else {u1r.Studies.calculateTypicalPrice=function(Q5L,K7Y){var i9g=k_Cdw;var D6x,j81,D2U,O8d,b6l,i3B;D6x=\"hl\";D6x+=\"cc\";D6x+=\"/\";D6x+=\"4\";j81=K7Y.chart.scrubbed;D2U=K7Y.days;if(j81.length < D2U + 1){if(!K7Y.overlay){K7Y.error=!!({});}return;}O8d=K7Y.name;for(var m$X in K7Y.outputs){i9g.b8R(14);O8d=i9g.e7l(m$X,O8d,\" \");}b6l=\"hlc/3\";if(K7Y.type == \"Med Price\"){b6l=\"hl/2\";}else if(K7Y.type == \"Weighted Close\"){b6l=D6x;}i3B=0;if(K7Y.startFrom <= D2U){K7Y.startFrom=0;}for(var O$0=K7Y.startFrom;O$0 < j81.length;O$0++){if(O$0 && j81[O$0 - 1][O8d]){i9g.G4m(150);var Q86=i9g.e7l(1539,14,10,11);i3B=j81[O$0 - Q86][O8d] * D2U;}i3B+=j81[O$0][b6l];if(O$0 >= D2U){i9g.G4m(4);i3B-=j81[i9g.e7l(O$0,D2U)][b6l];i9g.G4m(9);j81[O$0][O8d]=i9g.e7l(i3B,D2U);}}};u1r.Studies.studyLibrary=u1r.extend(u1r.Studies.studyLibrary,{\"Med Price\":{name:\"Median Price\",calculateFN:u1r.Studies.calculateTypicalPrice,inputs:{Period:14}}});}};R8=A3T=>{var p5I;p5I=typeof _CIQ !== \"undefined\"?_CIQ:A3T.CIQ;if(!p5I.Studies){console.error(\"momentum feature requires first activating studies feature.\");}else {p5I.Studies.calculateRateOfChange=function(a3W,i7d){var T0v=k_Cdw;var z21,R4h,c8L,T33,g3p,o3k,X4c,X1I,d58,t9i,j6U;z21=\"V\";z21+=\"o\";z21+=\"lum\";z21+=\"e\";R4h=\"fie\";R4h+=\"l\";R4h+=\"d\";c8L=i7d.chart.scrubbed;if(c8L.length < i7d.days + 1){i7d.error=!!1;return;}T33=i7d.inputs.Field;if(!T33 || T33 == R4h){T33=\"Close\";}if(i7d.parameters.isVolume){T33=z21;}g3p=i7d.name;for(var o7c in i7d.outputs){T0v.G4m(14);g3p=T0v.F9v(o7c,g3p,\" \");}o3k=i7d.inputs[\"Center Line\"];if(!o3k){o3k=0;}else {o3k=parseInt(o3k,10);}for(var e1a=Math.max(i7d.startFrom,i7d.days);e1a < c8L.length;e1a++){X4c=\"Mome\";X4c+=\"nt\";X4c+=\"um\";X1I=\"ob\";X1I+=\"jec\";X1I+=\"t\";d58=c8L[e1a][T33];if(d58 && typeof d58 == X1I){d58=d58[i7d.subField];}t9i=c8L[e1a - i7d.days][T33];if(t9i && typeof t9i == \"object\"){t9i=t9i[i7d.subField];}if(i7d.type == X4c){T0v.b8R(11);c8L[e1a][g3p]=T0v.e7l(d58,t9i,o3k);}else {j6U=t9i;if(j6U){T0v.b8R(151);c8L[e1a][g3p]=T0v.e7l(j6U,\"100\",0,o3k,d58,1);}}}};p5I.Studies.studyLibrary=p5I.extend(p5I.Studies.studyLibrary,{\"Price ROC\":{name:\"Price Rate of Change\",calculateFN:p5I.Studies.calculateRateOfChange,inputs:{Period:14,Field:\"field\"}},Momentum:{name:\"Momentum Indicator\",calculateFN:p5I.Studies.calculateRateOfChange,inputs:{Period:14},centerline:0}});}};i$=m9e=>{var w72,s1G;w72=\"unde\";w72+=\"fined\";s1G=typeof _CIQ !== w72?_CIQ:m9e.CIQ;if(!s1G.Studies){console.error(\"priceRelative feature requires first activating studies feature.\");}else {s1G.Studies.initPriceRelative=function(W4G,e_a,O2u,z0w,W2P,N8a){k_Cdw.j1L();var Y9k,H8b;Y9k=s1G.Studies.initializeFN(W4G,e_a,O2u,z0w,W2P,N8a);H8b=[Y9k.inputs[\"Comparison Symbol\"].toUpperCase()];s1G.Studies.fetchAdditionalInstruments(W4G,Y9k,H8b);return Y9k;};s1G.Studies.calculatePriceRelative=function(O_o,N18){var V$y,F5E,L2B,a$w,t9n,N4I,R0o,l7e;V$y=\"Com\";k_Cdw.y6g();V$y+=\"parison S\";V$y+=\"ymb\";V$y+=\"ol\";F5E=N18.chart.scrubbed;L2B=N18.inputs[V$y].toUpperCase();if(!L2B){L2B=N18.study.inputs[\"Comparison Symbol\"];}a$w={};t9n=O_o.chart.symbol || \"\";t9n=t9n.replace(/[=+\\-*\\\\%]/g,\"\");a$w[t9n]=F5E.slice(N18.startFrom);if(!a$w[t9n].length){return;}if(t9n != L2B){a$w[L2B]=null;}k_Cdw.b8R(89);N4I=s1G.computeEquationChart(k_Cdw.F9v(t9n,L2B,\"]/[\",4020 < (9720,\"3567\" | 42)?(259.73,331.96):(28,4364) <= +\"6404\"?6600 == 5900?(\"4.21e+3\" | 50,!\"\"):\"]\":9.38e+3,(+\"4575\",2990) <= 6178?(5590,\"2610\" - 0) >= 1262?\"[\":(0xc81,\"B\"):\"A\"),a$w);R0o=+\"0\";for(var e9h=N18.startFrom;e9h < F5E.length && R0o < N4I.length;e9h++){l7e=\"Re\";l7e+=\"sul\";l7e+=\"t\";l7e+=\" \";while(R0o < N4I.length && F5E[e9h].DT.getTime() > N4I[R0o].DT.getTime()){R0o++;}if(F5E[e9h].DT.getTime() < N4I[R0o].DT.getTime())continue;F5E[e9h][l7e + N18.name]=N4I[R0o].Close;R0o++;}};s1G.Studies.displayVsComparisonSymbol=function(t_s,v8r,X2M){var N9k,K$1,B$p,a2c,W14;N9k=v8r.inputs[\"Comparison Symbol\"].toUpperCase();if(!t_s.getSeries({symbol:N9k,chart:v8r.chart}).length){K$1=\":\";K$1+=\" \";t_s.displayErrorAsWatermark(v8r.panel,t_s.translateIf(v8r.study.name) + K$1 + t_s.translateIf(\"Not Available\"));return;}B$p={skipTransform:t_s.panels[v8r.panel].name != v8r.chart.name,panelName:v8r.panel,band:\"Result \" + v8r.name,threshold:v8r.study.centerline,yAxis:v8r.getYAxis(t_s),gapDisplayStyle:!!({})};a2c=B$p.yAxis?B$p.yAxis.flipped:t_s.panels[v8r.panel].yAxis.flipped;W14=0.3;if(!v8r.highlight && t_s.highlightedDraggable){W14*=0.3;}for(var M2i=X2M.length - +\"1\";M2i >= 0;M2i--){if(X2M[M2i] && X2M[M2i][N9k]){s1G.Studies.displaySeriesAsLine(t_s,v8r,X2M);if(v8r.study.centerline || v8r.study.centerline === \"0\" * 1){if(v8r.outputs.Gain){s1G.preparePeakValleyFill(t_s,s1G.extend(B$p,{direction:a2c?-1:1,color:s1G.Studies.determineColor(v8r.outputs.Gain),opacity:W14}));}if(v8r.outputs.Loss){s1G.preparePeakValleyFill(t_s,s1G.extend(B$p,{direction:a2c?\"1\" - 0:-1,color:s1G.Studies.determineColor(v8r.outputs.Loss),opacity:W14}));}}return;}}};s1G.Studies.fetchAdditionalInstruments=function(j4I,U$W,R$U,Y0J){var g2V,a8M,I4v,q65,h8r,b7r,q0o,d7O;k_Cdw.y6g();if(!j4I.quoteDriver){g2V=\"CIQ.Studies.fetchAdditional\";g2V+=\"Instruments: No quotefeed to\";g2V+=\" fet\";g2V+=\"ch symbol\";console.log(g2V);return;}a8M=j4I.panels[U$W.panel].chart;U$W.symbols=R$U;function j8_(){j4I.createDataSet();k_Cdw.j1L();j4I.draw();}for(I4v=0;I4v < R$U.length;I4v++){b7r=\"a\";b7r+=\"dd-\";b7r+=\"study\";q65=h8r=R$U[I4v];if(typeof h8r == \"object\"){q65=h8r.symbol;}else {h8r={symbol:q65};}q0o={symbol:q65,symbolObject:h8r,bucket:\"study\",studyName:U$W.name,chartName:a8M.name,action:b7r};s1G.extend(q0o,Y0J);d7O=q0o.loadData;if(j4I.currentlyImporting){q0o.loadData=![];}if(!U$W.series){U$W.series={};}U$W.series[q65]=j4I.addSeries(null,q0o,j8_);U$W.series[q65].parameters.loadData=d7O;}};s1G.Studies.studyLibrary=s1G.extend(s1G.Studies.studyLibrary,{\"P Rel\":{name:\"Price Relative\",initializeFN:s1G.Studies.initPriceRelative,seriesFN:s1G.Studies.displayVsComparisonSymbol,calculateFN:s1G.Studies.calculatePriceRelative,centerline:0,inputs:{\"Comparison Symbol\":\"SPY\"},deferUpdate:!!({})}});}};H5=B55=>{var S54,M_T,T6w,h58,O0f,p9N,x6Z;S54=\"u\";S54+=\"ndef\";S54+=\"ined\";M_T=typeof _CIQ !== S54?_CIQ:B55.CIQ;T6w=typeof _timezoneJS !== \"undefined\"?_timezoneJS:B55.timezoneJS;if(!M_T.Studies){console.error(\"vwap feature requires first activating studies feature.\");}else {h58=\"#fff\";h58+=\"69\";h58+=\"e\";O0f=\"hh:\";O0f+=\"mm:ss\";p9N=\"#85c\";p9N+=\"99\";p9N+=\"e\";x6Z=\"fie\";x6Z+=\"ld\";M_T.Studies.calculateVWAP=function(C$l,I5s){var c5G=k_Cdw;var q6Q,X02,g2P,c0f,p8w,Q_K,m5$,g8d,i9k,w3p,W9e,y15,X2j,u0l,O6c,U0m,F68,V_0,f3$,x6o,y9s,Y78,J6l,z6w,j46,g7r,G2z,n$w,u$4;if((I5s.parameters.state || ({})).interactiveAdd){return;}var {inputs:L7g, name:B1d, chart:m0n}=I5s;var {market:a$J}=m0n;q6Q=I5s.type === \"AVWAP\";X02=m0n.scrubbed;if(!X02.length){return;}if(!q6Q && M_T.ChartEngine.isDailyInterval(C$l.layout.interval)){g2P=\"VWAP is Intr\";g2P+=\"ad\";g2P+=\"ay Only\";I5s.error=g2P;return;}c0f=\"hlc/3\";if(q6Q){p8w=\"f\";p8w+=\"ie\";p8w+=\"ld\";c0f=L7g.Field;if(!c0f || c0f == p8w){Q_K=\"lay\";Q_K+=\"ou\";Q_K+=\"t\";c0f=L7g.Field=\"hlc/3\";C$l.changeOccurred(Q_K);}}m5$=null;g8d=0;c5G.G4m(1);i9k=c5G.F9v(\"0\",96);c5G.G4m(42);w3p=c5G.e7l(\"0\",64);W9e=![];if(I5s.startFrom > 1){y15=\"_\";y15+=\"V\";y15+=\" \";g8d=X02[I5s.startFrom - (\"1\" ^ 0)][y15 + B1d] || 0;i9k=X02[I5s.startFrom - 1][\"_VxP \" + B1d] || 0;w3p=X02[I5s.startFrom - 1][\"_VxP2 \" + B1d] || 0;}if(q6Q){var {market_tz:I6f}=a$J.market_def || ({});var [,o8n,D4G,V6Z]=(L7g[\"Anchor Date\"] || \"\").match(/^(\\d{4})-?(\\d{2})-?(\\d{2})$/) || [];c5G.b8R(42);var [,e2O = 0,f5N = 0,b0z = k_Cdw.e7l(\"0\",32)]=(L7g[\"Anchor Time\"] || \"\").match(/^(\\d{2}):?(\\d{2}):?(\\d{2})?$/) || [];if(![o8n,D4G,V6Z].every(T$U=>{c5G.y6g();return T$U || T$U === 0;})){X2j=\"In\";X2j+=\"valid Ancho\";X2j+=\"r Date\";I5s.error=X2j;return;}c5G.b8R(4);u0l=new T6w.Date(o8n,c5G.e7l(D4G,1),V6Z,e2O,f5N,b0z,I6f || \"\");if(!I5s.startFrom && u0l >= X02[\"0\" - 0].DT){I5s.startFrom=C$l.tickFromDate(u0l,C$l.chart,null,!0);}if(L7g[\"Anchor Selector\"]){M_T.Studies.initAnchorHandle(C$l,I5s);}else {M_T.Studies.removeAnchorHandle(C$l,I5s);}}for(var G0f=I5s.startFrom;G0f < X02.length;G0f++){O6c=\"VW\";O6c+=\"AP \";U0m=\"_S\";U0m+=\"DVWAP\";U0m+=\" \";F68=\"_VxP\";F68+=\"2\";F68+=\" \";if(!q6Q){if(m5$ === null){m5$=M_T.Studies.getMarketOffset({stx:C$l,localQuoteDate:X02[G0f].DT,shiftToDateBoundary:!!({})});}if(X02[G0f - 1] && X02[G0f - 1].DT){V_0=new Date(new Date(+X02[G0f].DT).setMilliseconds(X02[G0f].DT.getMilliseconds() + m5$));f3$=new Date(new Date(+X02[G0f - 1].DT).setMilliseconds(X02[G0f - 1].DT.getMilliseconds() + m5$));if(f3$.getDate() !== V_0.getDate() && C$l.chart.market.isMarketDate(V_0)){m5$=null;c5G.G4m(34);g8d=i9k=w3p=c5G.F9v(\"0\",0);}}}x6o=X02[G0f][c0f];y9s=X02[G0f].Volume;if(q6Q && !y9s){y9s=1;}g8d+=y9s;c5G.b8R(3);i9k+=c5G.e7l(y9s,x6o);c5G.G4m(152);w3p+=c5G.e7l(x6o,x6o,y9s);if(!q6Q && !g8d)continue;c5G.G4m(0);X02[G0f][c5G.F9v(\"_V \",B1d)]=g8d;c5G.G4m(0);X02[G0f][c5G.F9v(\"_VxP \",B1d)]=i9k;c5G.G4m(0);X02[G0f][c5G.e7l(F68,B1d)]=w3p;c5G.G4m(0);Y78=X02[G0f][c5G.F9v(U0m,B1d)]=Math.sqrt(Math.max(0,w3p / g8d - Math.pow(i9k / g8d,2)));c5G.G4m(0);J6l=X02[G0f][c5G.e7l(O6c,B1d)]=c5G.F9v(i9k,g8d,c5G.G4m(9));for(var x7k=1;x7k <= 3;x7k++){z6w=\"S\";z6w+=\"D\";z6w+=\"V\";z6w+=\"WAP\";c5G.b8R(2);X02[G0f][c5G.F9v(\"+ \",B1d,x7k,\"SDVWAP\")]=c5G.F9v(Y78,x7k,J6l,c5G.G4m(26));c5G.b8R(2);X02[G0f][c5G.F9v(\"- \",B1d,x7k,z6w)]=c5G.F9v(Y78,J6l,x7k,c5G.G4m(153));}W9e=!\"\";}for(var m5e=1;m5e <= 3;m5e++){j46=\"\\u03C3\";j46+=\")\";if(L7g[\"Display \" + m5e + \" Standard Deviation (\" + m5e + j46]){g7r=\" Standard De\";g7r+=\"v\";g7r+=\"iatio\";g7r+=\"n (\";G2z=\"\\u03C3\";G2z+=\")\";n$w=\" Standard Dev\";n$w+=\"iation (\";c5G.b8R(2);I5s.outputMap[c5G.F9v(\"+ \",B1d,m5e,\"SDVWAP\")]=c5G.e7l(m5e,G2z,n$w,m5e);c5G.b8R(2);I5s.outputMap[c5G.e7l(\"- \",B1d,m5e,\"SDVWAP\")]=c5G.e7l(m5e,\"\\u03C3)\",g7r,m5e);}}if(!q6Q && !W9e){u$4=\"VWAP Requires\";u$4+=\" \";u$4+=\"Volume\";I5s.error=u$4;}};M_T.Studies.initAnchoredVWAP=function(H2L,r8j,P6A,Q2E,j4z,D0j){var A1M,I41,L3i,T94,u_w,W9V;A1M=\"Anchor \";A1M+=\"Date\";if(!j4z.state){j4z.state={};}var {interactiveAdd:k$0, interactiveAddCB:n_z, state:T9o}=j4z;I41=!(P6A[A1M] || P6A[\"Anchor Time\"]);L3i=\"Click to \";L3i+=\"selec\";L3i+=\"t AVWAP anchor time\";if(I41 && (T9o.interactiveAdd || H2L.repositioningAnchorSelector)){return \"abort\";}var {dataSegment:H1w}=H2L.chart;if(H1w && I41 && !k$0){for(var B3E=0;B3E < H1w.length;B3E++){if(H1w[B3E]){T94=\"Anchor \";T94+=\"T\";T94+=\"i\";T94+=\"me\";var {DT:i1E}=H1w[B3E];P6A[\"Anchor Date\"]=M_T.dateToStr(i1E,\"YYYY-MM-dd\");P6A[T94]=M_T.dateToStr(i1E,\"HH:mm:ss\");break;}}}if(I41 && k$0){T9o.interactiveAdd=!!\"1\";}else {delete T9o.interactiveAdd;delete j4z.interactiveAdd;if(n_z){setTimeout(n_z);}}u_w=M_T.Studies.initializeFN(H2L,r8j,P6A,Q2E,j4z,D0j);if(T9o.interactiveAdd){W9V=\"in\";W9V+=\"fo\";H2L.repositioningAnchorSelector={sd:u_w,tapToAdd:!!\"1\"};H2L.dispatch(\"notification\",{message:L3i,type:W9V,displayTime:0});}else {H2L.dispatch(\"notification\",{message:L3i,remove:!!\"1\"});}k_Cdw.y6g();return u_w;};M_T.Studies.displayVWAP=function(J$X,O2Y,Q_z){var u1E,b3_,J14,k50,s0q,c0e,l9q,a9H,d$N,d5q,N4H,f92,v13,V0T,E_l;k_Cdw.y6g();M_T.Studies.displaySeriesAsLine(J$X,O2Y,Q_z);u1E=O2Y.inputs[\"Display 1 Standard Deviation (1\\u03C3)\"];b3_=O2Y.inputs[\"Display 2 Standard Deviation (2\\u03C3)\"];J14=O2Y.inputs[\"Display 3 Standard Deviation (3\\u03C3)\"];if((u1E || b3_ || J14) && O2Y.inputs.Shading){k50=\"VW\";k50+=\"A\";k50+=\"P \";s0q=\"VWAP\";s0q+=\" \";c0e=J$X.panels[O2Y.panel];l9q={opacity:O2Y.parameters.opacity?O2Y.parameters.opacity:0.2,skipTransform:c0e.name != O2Y.chart.name,yAxis:O2Y.getYAxis(J$X)};if(!O2Y.highlight && J$X.highlightedDraggable){l9q.opacity*=0.3;}a9H=s0q + O2Y.name;d$N=k50 + O2Y.name;if(u1E){d5q=\"SDVWAP\";d5q+=\"1-\";d5q+=\" \";N4H=\"SD\";N4H+=\"V\";N4H+=\"WAP1\";N4H+=\"- \";M_T.prepareChannelFill(J$X,M_T.extend({panelName:O2Y.panel,topBand:\"SDVWAP1+ \" + O2Y.name,bottomBand:a9H,color:M_T.Studies.determineColor(O2Y.outputs[O2Y.outputMap[\"SDVWAP1+ \" + O2Y.name]])},l9q));M_T.prepareChannelFill(J$X,M_T.extend({panelName:O2Y.panel,topBand:N4H + O2Y.name,bottomBand:d$N,color:M_T.Studies.determineColor(O2Y.outputs[O2Y.outputMap[d5q + O2Y.name]])},l9q));a9H=\"SDVWAP1+ \" + O2Y.name;d$N=\"SDVWAP1- \" + O2Y.name;}if(b3_){f92=\"SDVW\";f92+=\"A\";f92+=\"P2+ \";v13=\"SD\";v13+=\"VWAP\";v13+=\"2- \";V0T=\"SDVWAP\";V0T+=\"2+ \";M_T.prepareChannelFill(J$X,M_T.extend({panelName:O2Y.panel,topBand:V0T + O2Y.name,bottomBand:a9H,color:M_T.Studies.determineColor(O2Y.outputs[O2Y.outputMap[\"SDVWAP2+ \" + O2Y.name]])},l9q));M_T.prepareChannelFill(J$X,M_T.extend({panelName:O2Y.panel,topBand:v13 + O2Y.name,bottomBand:d$N,color:M_T.Studies.determineColor(O2Y.outputs[O2Y.outputMap[\"SDVWAP2- \" + O2Y.name]])},l9q));a9H=f92 + O2Y.name;d$N=\"SDVWAP2- \" + O2Y.name;}if(J14){E_l=\"SDVWAP3-\";E_l+=\" \";M_T.prepareChannelFill(J$X,M_T.extend({panelName:O2Y.panel,topBand:\"SDVWAP3+ \" + O2Y.name,bottomBand:a9H,color:M_T.Studies.determineColor(O2Y.outputs[O2Y.outputMap[\"SDVWAP3+ \" + O2Y.name]])},l9q));M_T.prepareChannelFill(J$X,M_T.extend({panelName:O2Y.panel,topBand:E_l + O2Y.name,bottomBand:d$N,color:M_T.Studies.determineColor(O2Y.outputs[O2Y.outputMap[\"SDVWAP3- \" + O2Y.name]])},l9q));}}if(O2Y.anchorHandle || (O2Y.parameters.state || ({})).interactiveAdd){M_T.Studies.displayAnchorHandleAndLine(J$X,O2Y,Q_z);}};M_T.Studies.removeAnchoredVWAP=function(U5G,N8B){var R4B;R4B=\"Click\";R4B+=\" to select AVWAP anchor time\";U5G.dispatch(\"notification\",{message:R4B,remove:!0});M_T.Studies.removeAnchorHandle(U5G,N8B);};M_T.Studies.studyLibrary=M_T.extend(M_T.Studies.studyLibrary,{AVWAP:{name:\"Anchored VWAP\",overlay:!!({}),calculateFN:M_T.Studies.calculateVWAP,seriesFN:M_T.Studies.displayVWAP,initializeFN:M_T.Studies.initAnchoredVWAP,removeFN:M_T.Studies.removeAnchoredVWAP,inputs:{Field:x6Z,\"Anchor Date\":\"\",\"Anchor Time\":\"\",\"Display 1 Standard Deviation (1\\u03C3)\":!!0,\"Display 2 Standard Deviation (2\\u03C3)\":!!0,\"Display 3 Standard Deviation (3\\u03C3)\":![],Shading:!({}),\"Anchor Selector\":!!({})},outputs:{VWAP:\"#FF0000\",\"1 Standard Deviation (1\\u03C3)\":\"#e1e1e1\",\"2 Standard Deviation (2\\u03C3)\":p9N,\"3 Standard Deviation (3\\u03C3)\":\"#fff69e\"},parameters:{init:{opacity:0.2,interactiveAdd:!![]}},attributes:{\"Anchor Date\":{placeholder:\"yyyy-mm-dd\"},\"Anchor Time\":{placeholder:O0f,step:1}}},VWAP:{name:\"VWAP\",overlay:!!({}),calculateFN:M_T.Studies.calculateVWAP,seriesFN:M_T.Studies.displayVWAP,inputs:{\"Display 1 Standard Deviation (1\\u03C3)\":!1,\"Display 2 Standard Deviation (2\\u03C3)\":![],\"Display 3 Standard Deviation (3\\u03C3)\":![],Shading:!\"1\"},outputs:{VWAP:\"#FF0000\",\"1 Standard Deviation (1\\u03C3)\":\"#e1e1e1\",\"2 Standard Deviation (2\\u03C3)\":\"#85c99e\",\"3 Standard Deviation (3\\u03C3)\":h58},parameters:{init:{opacity:0.2}}}});}};H9=l2g=>{var J4T,E0w;J4T=typeof _CIQ !== \"undefined\"?_CIQ:l2g.CIQ;if(!J4T.Studies){console.error(\"zigzag feature requires first activating studies feature.\");}else {E0w=\"Zi\";E0w+=\"gZag\";J4T.Studies.calculateZigZag=function(Z2G,A__){var A2D=k_Cdw;var D96,x6z,x10,b70,U4a,w7w,P25,X_8,E7n,B9l,T9a,K73,O8t,L6K,U3x,g$g,b9y,S29;D96=A__.chart.scrubbed;if(!D96 || !D96.length){return;}x6z=A__.highLowChart;x10=null;b70=null;U4a=A__.inputs[\"Distance(%)\"];w7w=0;P25=0;X_8=0;E7n=null;B9l=null;A2D.y6g();T9a=0;for(var v2S=Math.min(D96.length - 1,A__.startFrom);v2S >= 0;v2S--){T9a=v2S;if(D96[v2S][\"_state \" + A__.name]){K73=D96[v2S][\"_state \" + A__.name];x10=K73[0];b70=K73[1];w7w=K73[2];P25=K73[3];X_8=K73[4];E7n=K73[5];B9l=K73[6];break;}}for(var r6f=T9a;r6f < D96.length;r6f++){O8t=\"L\";O8t+=\"o\";O8t+=\"w\";L6K=D96[r6f][x6z?\"High\":\"Close\"];U3x=D96[r6f][x6z?O8t:\"Close\"];if(b70 === null || b70 < L6K){b70=L6K;if(w7w < 0){x10=U3x;}A2D.G4m(154);E7n=A2D.e7l(1,U4a,b70,100);if(w7w > -1){if(B9l !== null && b70 > B9l){D96[P25][\"Result \" + A__.name]=D96[P25][x6z?\"Low\":\"Close\"];K8x(X_8,P25);w7w=-1;x10=U3x;X_8=P25;P25=r6f;continue;}}else {P25=r6f;}}if(x10 === null || x10 > U3x){x10=U3x;if(w7w > 0){b70=L6K;}A2D.b8R(155);B9l=A2D.F9v(100,U4a,1,x10);if(w7w < 1){if(E7n !== null && x10 < E7n){g$g=\"Re\";g$g+=\"s\";g$g+=\"ult\";g$g+=\" \";D96[P25][g$g + A__.name]=D96[P25][x6z?\"High\":\"Close\"];K8x(X_8,P25);A2D.b8R(42);w7w=A2D.e7l(\"1\",0);b70=L6K;X_8=P25;P25=r6f;continue;}}else {P25=r6f;}}}D96[P25][\"Result \" + A__.name]=D96[P25][x6z?w7w == 1?\"Low\":\"High\":\"Close\"];D96[P25][\"_state \" + A__.name]=[x10,b70,w7w,P25,X_8,E7n,B9l];K8x(X_8,P25);A2D.b8R(11);var u_9=A2D.F9v(4,12,9);b9y=D96.length - u_9;function K8x(V2f,i0v){var m7A;for(var J$7=V2f + 1;J$7 < i0v;J$7++){m7A=\"Res\";m7A+=\"ult\";m7A+=\" \";D96[J$7][\"ShadowResult \" + A__.name]=(D96[i0v][\"Result \" + A__.name] - D96[V2f][\"Result \" + A__.name]) * (J$7 - V2f) / (i0v - V2f) + D96[V2f][m7A + A__.name];delete D96[J$7][\"Result \" + A__.name];}}while(b9y > P25){if(D96[b9y].Close || D96[b9y].Close === 0){S29=\"H\";S29+=\"i\";S29+=\"gh\";D96[b9y][\"Result \" + A__.name]=D96[b9y][x6z?w7w == 1?S29:\"Low\":\"Close\"];break;}b9y--;}K8x(P25,b9y);};J4T.Studies.displayZigZag=function(j8c,r4v,V4S){var N58,V41,j$P,f_s,o_A,Z82,O7n,J3f,C99,o_N,H3k;N58=\"Sha\";N58+=\"dowResul\";N58+=\"t \";k_Cdw.j1L();V41=j8c.chart.highLowBars;if(r4v.highLowChart != V41){r4v.highLowChart=V41;r4v.startFrom=0;r4v.study.calculateFN(j8c,r4v);}j$P=j8c.chart;for(var T4H=0;T4H < V4S.length;T4H++){f_s=V4S[T4H];if(f_s){o_A=\"Resul\";o_A+=\"t \";if(f_s[\"_shadowCopy \" + r4v.name]){delete f_s[\"Result \" + r4v.name];delete f_s[\"_shadowCopy \" + r4v.name];}if(!f_s[o_A + r4v.name]){Z82=\"R\";Z82+=\"es\";Z82+=\"ult\";Z82+=\" \";if(f_s.transform){delete f_s.transform[Z82 + r4v.name];}}}}O7n=V4S[0];k_Cdw.b8R(123);var n7k=k_Cdw.e7l(104,12,8,9);J3f=V4S[V4S.length - n7k];if(O7n && O7n[N58 + r4v.name]){C99=\"Sh\";C99+=\"a\";C99+=\"dowRe\";C99+=\"sult \";O7n[\"Result \" + r4v.name]=O7n[C99 + r4v.name];if(O7n.transform){O7n.transform[\"Result \" + r4v.name]=j$P.transformFunc(j8c,j$P,O7n[\"ShadowResult \" + r4v.name]);}O7n[\"_shadowCopy \" + r4v.name]=1;}if(J3f && J3f[\"ShadowResult \" + r4v.name]){o_N=\"Sha\";o_N+=\"dowResult\";o_N+=\" \";H3k=\"Resul\";H3k+=\"t \";J3f[H3k + r4v.name]=J3f[o_N + r4v.name];if(J3f.transform){J3f.transform[\"Result \" + r4v.name]=j$P.transformFunc(j8c,j$P,J3f[\"ShadowResult \" + r4v.name]);}J3f[\"_shadowCopy \" + r4v.name]=+\"1\";}J4T.Studies.displaySeriesAsLine(j8c,r4v,V4S);};J4T.Studies.studyLibrary=J4T.extend(J4T.Studies.studyLibrary,{ZigZag:{name:E0w,overlay:!0,seriesFN:J4T.Studies.displayZigZag,calculateFN:J4T.Studies.calculateZigZag,inputs:{\"Distance(%)\":10},parameters:{init:{label:!!\"\"}},attributes:{\"Distance(%)\":{min:0.1,step:0.1}}}});}};I_={CIQ:q8,SplinePlotter:O9,timezoneJS:d3,$$:L7,$$$:h4};export {y4 as createEngine};export {S3 as customCharts};export {r4 as drawing};export {L3 as easeMachine};export {I3 as equations};export {B9 as i18n};export {V$ as interaction};export {X4 as markers};export {C3 as market};export {c8 as movement};export {t_ as nameValueStore};export {l2 as quoteFeed};export {a3 as series};export {Y3 as share};export {x4 as span};export {z9 as storage};export {g7 as studies};export {F4 as symbolLookupBase};export {S9 as theme};export {r3 as timezone};export {s2 as touch};export {A7 as visualization};export {W0 as medianPrice};export {R8 as momentum};export {i$ as priceRelative};export {H5 as vwap};export {H9 as zigzag};export {q8 as CIQ, O9 as SplinePlotter, d3 as timezoneJS, L7 as $$, h4 as $$$};if(typeof __TREE_SHAKE__ === \"undefined\" || !__TREE_SHAKE__){I_.CIQ.activateImports(y4,S3,r4,L3,I3,B9,V$,X4,C3,c8,t_,l2,a3,Y3,x4,z9,g7,F4,S9,r3,s2,A7,W0,R8,i$,H5,H9,null);}/* eslint-enable */ /* jshint ignore:end */ /* ignore jslint end */\n"],"names":[],"sourceRoot":""}