@tradecanvas/chart 1.71.0 → 1.72.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (177) hide show
  1. package/dist/LayoutSession-DO4bYkUi.cjs +2 -0
  2. package/dist/LayoutSession-DO4bYkUi.cjs.map +1 -0
  3. package/dist/{LayoutSession-BOQCN6yY.js → LayoutSession-qRYG8GTD.js} +539 -552
  4. package/dist/LayoutSession-qRYG8GTD.js.map +1 -0
  5. package/dist/WidgetCommandPalette-CeCLHPy1.js +177 -0
  6. package/dist/WidgetCommandPalette-CeCLHPy1.js.map +1 -0
  7. package/dist/WidgetCommandPalette-ZZNbWwCZ.cjs +2 -0
  8. package/dist/WidgetCommandPalette-ZZNbWwCZ.cjs.map +1 -0
  9. package/dist/WidgetDrawingSettings-BeW8fX7r.js +474 -0
  10. package/dist/WidgetDrawingSettings-BeW8fX7r.js.map +1 -0
  11. package/dist/WidgetDrawingSettings-Cyl2u_u8.cjs +2 -0
  12. package/dist/WidgetDrawingSettings-Cyl2u_u8.cjs.map +1 -0
  13. package/dist/WidgetGoToDate-BNdngHlg.cjs +2 -0
  14. package/dist/WidgetGoToDate-BNdngHlg.cjs.map +1 -0
  15. package/dist/WidgetGoToDate-hcDtezRm.js +191 -0
  16. package/dist/WidgetGoToDate-hcDtezRm.js.map +1 -0
  17. package/dist/WidgetHotkeySheet-1lRFSdvt.js +416 -0
  18. package/dist/WidgetHotkeySheet-1lRFSdvt.js.map +1 -0
  19. package/dist/WidgetHotkeySheet-y5LWKSG6.cjs +2 -0
  20. package/dist/WidgetHotkeySheet-y5LWKSG6.cjs.map +1 -0
  21. package/dist/WidgetIndicatorPicker-CGvZ5kYd.js +245 -0
  22. package/dist/WidgetIndicatorPicker-CGvZ5kYd.js.map +1 -0
  23. package/dist/WidgetIndicatorPicker-DuKJFPRC.cjs +2 -0
  24. package/dist/WidgetIndicatorPicker-DuKJFPRC.cjs.map +1 -0
  25. package/dist/WidgetIndicatorSettings-C7vpco6e.cjs +2 -0
  26. package/dist/WidgetIndicatorSettings-C7vpco6e.cjs.map +1 -0
  27. package/dist/WidgetIndicatorSettings-dDkqzzYo.js +326 -0
  28. package/dist/WidgetIndicatorSettings-dDkqzzYo.js.map +1 -0
  29. package/dist/WidgetSettings-D7Pq42zW.cjs +2 -0
  30. package/dist/WidgetSettings-D7Pq42zW.cjs.map +1 -0
  31. package/dist/WidgetSettings-eOo93L7Z.js +546 -0
  32. package/dist/WidgetSettings-eOo93L7Z.js.map +1 -0
  33. package/dist/WidgetSymbolSearch-C4OR42nZ.cjs +2 -0
  34. package/dist/WidgetSymbolSearch-C4OR42nZ.cjs.map +1 -0
  35. package/dist/WidgetSymbolSearch-CvPpjIwa.js +580 -0
  36. package/dist/WidgetSymbolSearch-CvPpjIwa.js.map +1 -0
  37. package/dist/focusTrap-Br9Zfje0.js +27 -0
  38. package/dist/focusTrap-Br9Zfje0.js.map +1 -0
  39. package/dist/focusTrap-DrhhmG0V.cjs +2 -0
  40. package/dist/focusTrap-DrhhmG0V.cjs.map +1 -0
  41. package/dist/i18n-C2nQBZTY.cjs +2 -0
  42. package/dist/i18n-C2nQBZTY.cjs.map +1 -0
  43. package/dist/{i18n-DUmd4Z_r.js → i18n-C5v6Tzp1.js} +3 -1
  44. package/dist/i18n-C5v6Tzp1.js.map +1 -0
  45. package/dist/index.cjs +1 -1
  46. package/dist/index.d.ts +1 -1
  47. package/dist/index.d.ts.map +1 -1
  48. package/dist/index.js +1 -1
  49. package/dist/indicatorInputWords-Bd9Pt6qp.js +25 -0
  50. package/dist/indicatorInputWords-Bd9Pt6qp.js.map +1 -0
  51. package/dist/indicatorInputWords-CTA4IcJR.cjs +2 -0
  52. package/dist/indicatorInputWords-CTA4IcJR.cjs.map +1 -0
  53. package/dist/indicatorLabel-BNZvaOcl.cjs +2 -0
  54. package/dist/indicatorLabel-BNZvaOcl.cjs.map +1 -0
  55. package/dist/indicatorLabel-Sbegyhp2.js +17 -0
  56. package/dist/indicatorLabel-Sbegyhp2.js.map +1 -0
  57. package/dist/indicatorSettingsTabs-B0liE3ST.cjs +2 -0
  58. package/dist/indicatorSettingsTabs-B0liE3ST.cjs.map +1 -0
  59. package/dist/indicatorSettingsTabs-XcgMdbLp.js +161 -0
  60. package/dist/indicatorSettingsTabs-XcgMdbLp.js.map +1 -0
  61. package/dist/monthView-B-CieFDJ.cjs +2 -0
  62. package/dist/monthView-B-CieFDJ.cjs.map +1 -0
  63. package/dist/monthView-N8yDaTqZ.js +198 -0
  64. package/dist/monthView-N8yDaTqZ.js.map +1 -0
  65. package/dist/platformKeys-B82-j1Fs.cjs +2 -0
  66. package/dist/platformKeys-B82-j1Fs.cjs.map +1 -0
  67. package/dist/platformKeys-Dd1qOCjF.js +5 -0
  68. package/dist/platformKeys-Dd1qOCjF.js.map +1 -0
  69. package/dist/settingsControls-DIjzCFHI.js +379 -0
  70. package/dist/settingsControls-DIjzCFHI.js.map +1 -0
  71. package/dist/settingsControls-Tn8_vJJv.cjs +2 -0
  72. package/dist/settingsControls-Tn8_vJJv.cjs.map +1 -0
  73. package/dist/symbolCatalog-CA1fpz3s.js +90 -0
  74. package/dist/symbolCatalog-CA1fpz3s.js.map +1 -0
  75. package/dist/symbolCatalog-Dx1YnZgm.cjs +2 -0
  76. package/dist/symbolCatalog-Dx1YnZgm.cjs.map +1 -0
  77. package/dist/widget/ChartWidget.d.ts +102 -582
  78. package/dist/widget/ChartWidget.d.ts.map +1 -1
  79. package/dist/widget/WidgetAlerts.d.ts +35 -0
  80. package/dist/widget/WidgetAlerts.d.ts.map +1 -0
  81. package/dist/widget/WidgetChartSettings.d.ts +194 -0
  82. package/dist/widget/WidgetChartSettings.d.ts.map +1 -0
  83. package/dist/widget/WidgetCommands.d.ts +54 -0
  84. package/dist/widget/WidgetCommands.d.ts.map +1 -0
  85. package/dist/widget/WidgetCompares.d.ts +140 -0
  86. package/dist/widget/WidgetCompares.d.ts.map +1 -0
  87. package/dist/widget/WidgetDockArea.d.ts +89 -0
  88. package/dist/widget/WidgetDockArea.d.ts.map +1 -0
  89. package/dist/widget/WidgetDrawingEdit.d.ts +73 -0
  90. package/dist/widget/WidgetDrawingEdit.d.ts.map +1 -0
  91. package/dist/widget/WidgetGoToDate.d.ts +1 -14
  92. package/dist/widget/WidgetGoToDate.d.ts.map +1 -1
  93. package/dist/widget/WidgetIndicatorSettings.d.ts.map +1 -1
  94. package/dist/widget/WidgetIntervals.d.ts +66 -0
  95. package/dist/widget/WidgetIntervals.d.ts.map +1 -0
  96. package/dist/widget/WidgetLayouts.d.ts +85 -0
  97. package/dist/widget/WidgetLayouts.d.ts.map +1 -0
  98. package/dist/widget/WidgetLegendView.d.ts +54 -0
  99. package/dist/widget/WidgetLegendView.d.ts.map +1 -0
  100. package/dist/widget/WidgetMenus.d.ts +79 -0
  101. package/dist/widget/WidgetMenus.d.ts.map +1 -0
  102. package/dist/widget/WidgetReplay.d.ts +199 -0
  103. package/dist/widget/WidgetReplay.d.ts.map +1 -0
  104. package/dist/widget/WidgetTrading.d.ts +48 -0
  105. package/dist/widget/WidgetTrading.d.ts.map +1 -0
  106. package/dist/widget/WidgetWatchlists.d.ts +77 -0
  107. package/dist/widget/WidgetWatchlists.d.ts.map +1 -0
  108. package/dist/widget/drawingSettingsTabs.d.ts +2 -19
  109. package/dist/widget/drawingSettingsTabs.d.ts.map +1 -1
  110. package/dist/widget/drawingText.d.ts +24 -0
  111. package/dist/widget/drawingText.d.ts.map +1 -0
  112. package/dist/widget/index.cjs +22 -23
  113. package/dist/widget/index.cjs.map +1 -1
  114. package/dist/widget/index.js +6193 -9868
  115. package/dist/widget/index.js.map +1 -1
  116. package/dist/widget/keyTarget.d.ts +4 -0
  117. package/dist/widget/keyTarget.d.ts.map +1 -1
  118. package/dist/widget/lazyPart.d.ts +47 -0
  119. package/dist/widget/lazyPart.d.ts.map +1 -0
  120. package/dist/widget/locales/ar.d.ts.map +1 -1
  121. package/dist/widget/locales/cs.d.ts.map +1 -1
  122. package/dist/widget/locales/da.d.ts.map +1 -1
  123. package/dist/widget/locales/de.d.ts.map +1 -1
  124. package/dist/widget/locales/el.d.ts.map +1 -1
  125. package/dist/widget/locales/en.d.ts +1 -0
  126. package/dist/widget/locales/en.d.ts.map +1 -1
  127. package/dist/widget/locales/es.d.ts.map +1 -1
  128. package/dist/widget/locales/et.d.ts.map +1 -1
  129. package/dist/widget/locales/fa.d.ts.map +1 -1
  130. package/dist/widget/locales/fr.d.ts.map +1 -1
  131. package/dist/widget/locales/he.d.ts.map +1 -1
  132. package/dist/widget/locales/hu.d.ts.map +1 -1
  133. package/dist/widget/locales/id.d.ts.map +1 -1
  134. package/dist/widget/locales/index.cjs +1 -1
  135. package/dist/widget/locales/index.cjs.map +1 -1
  136. package/dist/widget/locales/index.js +29 -1
  137. package/dist/widget/locales/index.js.map +1 -1
  138. package/dist/widget/locales/it.d.ts.map +1 -1
  139. package/dist/widget/locales/ja.d.ts.map +1 -1
  140. package/dist/widget/locales/ko.d.ts.map +1 -1
  141. package/dist/widget/locales/ms.d.ts.map +1 -1
  142. package/dist/widget/locales/nb.d.ts.map +1 -1
  143. package/dist/widget/locales/nl.d.ts.map +1 -1
  144. package/dist/widget/locales/pl.d.ts.map +1 -1
  145. package/dist/widget/locales/pt.d.ts.map +1 -1
  146. package/dist/widget/locales/ro.d.ts.map +1 -1
  147. package/dist/widget/locales/ru.d.ts.map +1 -1
  148. package/dist/widget/locales/sk.d.ts.map +1 -1
  149. package/dist/widget/locales/sv.d.ts.map +1 -1
  150. package/dist/widget/locales/th.d.ts.map +1 -1
  151. package/dist/widget/locales/tr.d.ts.map +1 -1
  152. package/dist/widget/locales/vi.d.ts.map +1 -1
  153. package/dist/widget/locales/zh.d.ts.map +1 -1
  154. package/dist/widget/locales/zhHant.d.ts.map +1 -1
  155. package/dist/widget/pageEnv.d.ts +5 -0
  156. package/dist/widget/pageEnv.d.ts.map +1 -0
  157. package/dist/widget/signals.d.ts +41 -0
  158. package/dist/widget/signals.d.ts.map +1 -0
  159. package/dist/widget/wallTime.d.ts +15 -0
  160. package/dist/widget/wallTime.d.ts.map +1 -0
  161. package/dist/widget/widgetDialogs.d.ts +17 -0
  162. package/dist/widget/widgetDialogs.d.ts.map +1 -0
  163. package/dist/widgetFeatures-BM6u0u74.js +186 -0
  164. package/dist/widgetFeatures-BM6u0u74.js.map +1 -0
  165. package/dist/widgetFeatures-BZ8OVPN2.cjs +3 -0
  166. package/dist/widgetFeatures-BZ8OVPN2.cjs.map +1 -0
  167. package/dist/widgetLocales-BPK5i0Ok.cjs +2 -0
  168. package/dist/widgetLocales-BPK5i0Ok.cjs.map +1 -0
  169. package/dist/widgetLocales-DgTR8JSu.js +838 -0
  170. package/dist/widgetLocales-DgTR8JSu.js.map +1 -0
  171. package/package.json +3 -3
  172. package/dist/LayoutSession-BOQCN6yY.js.map +0 -1
  173. package/dist/LayoutSession-RF8OqOXy.cjs +0 -2
  174. package/dist/LayoutSession-RF8OqOXy.cjs.map +0 -1
  175. package/dist/i18n-BsstZ9md.cjs +0 -2
  176. package/dist/i18n-BsstZ9md.cjs.map +0 -1
  177. package/dist/i18n-DUmd4Z_r.js.map +0 -1
@@ -11,18 +11,43 @@ import { CompareWay } from './widgetCompare.js';
11
11
  import { Translator } from './i18n.js';
12
12
  import { WidgetFeature, WidgetFeatures } from './widgetFeatures.js';
13
13
  export declare class ChartWidget {
14
+ /** The intervals the widget offers: the menu, the ones pinned, typed ones and the range bar's. */
15
+ private readonly intervals;
16
+ /** Editing a drawing: its toolbar, its words typed in place, its settings and its templates. */
17
+ private readonly drawingEdit;
18
+ /** The chart settings: their state, where they are kept, the dialog's edit, and the scale they show. */
19
+ private readonly chartSettings;
20
+ /** The dock by the chart: its panels, its rail and how wide it is. */
21
+ private readonly docking;
22
+ /** Saved layouts and shared views: what a layout holds, where it is kept, and the link to a view. */
23
+ private readonly layouts;
24
+ /** The command palette's entries and the actions they run. */
25
+ private readonly commands;
26
+ /** The legend over the chart: the symbol's row and the indicators' rows, and their menu. */
27
+ private readonly legend;
28
+ /** The chart's context menus: on the chart, on a drawing, and the clear menu. */
29
+ private readonly menus;
30
+ /** Trading by the chart: the account panel, the order ticket, the depth ladder and the bracket bar. */
31
+ private readonly trading;
32
+ /** Price alerts: their panel, what they are checked against, and the notices when one fires. */
33
+ private readonly alerting;
34
+ /** The watchlists by the chart: their symbols, lists and quotes. */
35
+ private readonly watching;
36
+ /** Other symbols compared with the chart's: their bars, the compare dialog, the scale they hold. */
37
+ private readonly comparing;
14
38
  private chart;
15
39
  private state;
16
40
  /** The theme for each mode: the host's own where it gave one, so the toggle brings it back. */
17
41
  private themeOf;
18
42
  private toolbar;
19
43
  private sidebar;
20
- private settings;
44
+ private settingsPart;
45
+ private get settings();
21
46
  private statusBar;
22
- private goToDate;
47
+ private goToDatePart;
48
+ private get goToDate();
23
49
  private readonly tooltip;
24
50
  private indicatorLegend;
25
- private legendFrame;
26
51
  /**
27
52
  * Modals (settings, search, command palette, hotkeys) mount here: it carries
28
53
  * the theme tokens to `document.body`, and moves inside the widget while
@@ -38,42 +63,25 @@ export declare class ChartWidget {
38
63
  /** Stops following presses for the page's shortcuts (see keyTarget). */
39
64
  private unregisterKeys;
40
65
  private readonly onFullscreenChange;
41
- private commandPalette;
42
- private symbolSearch;
43
- /** The panels by the chart (watchlist, alerts, objects, data window, symbol info) and their rail. */
44
- private dock;
45
- /** Whether the widget was narrow when the dock last looked (null: not yet). */
46
- private dockNarrow;
47
- /** Follows the widget's width for the dock. */
48
- private dockObserver;
49
- private hotkeySheet;
50
- private replayBar;
66
+ private commandPalettePart;
67
+ private get commandPalette();
68
+ private symbolSearchPart;
69
+ private get symbolSearch();
70
+ /** Letters typed on the chart while the symbol search's code loads: it opens with all of them. */
71
+ private typedWhileLoading;
72
+ private hotkeySheetPart;
73
+ private get hotkeySheet();
74
+ /** Bar replay: its panel over the chart and the session it drives. Made in the constructor, once the chart is up. */
75
+ private replay;
51
76
  private dragDrop;
52
- private alertsPanel;
53
77
  private objectTree;
54
- private indicatorSettings;
55
- private indicatorPicker;
78
+ private indicatorSettingsPart;
79
+ private get indicatorSettings();
80
+ private indicatorPickerPart;
81
+ private get indicatorPicker();
56
82
  private drawingStyle;
57
- private drawingSettings;
58
- private drawingMenu;
59
- /** A text drawn just now whose words the settings ask for: Cancel there takes it back. */
60
- private justDrawnText;
61
- /** A text drawing's words typed in place over it. */
62
- private inlineText;
63
- /** The drawing whose words are being typed in place, and whether it was just drawn. */
64
- private inlineTextId;
65
- private inlineTextNew;
66
- /** The chart's type sizes the look last wrote: a host's own change since makes them the new base. */
67
- private chartFontWritten;
68
- /** Stops waiting to ask for a just-drawn text's words (the widget goes, or another text is drawn first). */
69
- private cancelTextPrompt;
70
- /** The trash button's menu, made the first time it opens. */
71
- private clearMenu;
72
- private selectionToolbar;
73
- private selectionToolbarFrame;
74
- private chartMenu;
75
- /** The pane a chart menu was opened on (its scale switches act on it). */
76
- private menuPane;
83
+ private drawingSettingsPart;
84
+ private get drawingSettings();
77
85
  /** Whether the chart menu offers a download of the data. */
78
86
  private canExport;
79
87
  /** The latest fetch of each symbol the chart's indicators read. */
@@ -87,32 +95,10 @@ export declare class ChartWidget {
87
95
  /** The chart's type sizes before the look scaled them. */
88
96
  private chartFontBase;
89
97
  private scaleObserver;
90
- /** The legend row's "more" menu: move the indicator to another pane. */
91
- private legendMenu;
92
98
  private templates;
93
99
  private templatePrompt;
94
- /** The chart templates of the settings' Template menu, and the prompt that names a new one. */
95
- private chartTemplates;
96
- private chartTemplatePrompt;
97
- /** Asks a drawing template's name, over the drawing's settings. */
98
- private drawingTemplatePrompt;
99
- /**
100
- * The settings open now: as they were on opening, and the keys changed since
101
- * (a change, a reset, a template). Cancel puts those back, OK records them
102
- * as one step; the rest (an axis dragged meanwhile) is left as it is.
103
- */
104
- private settingsEdit;
105
- private intervalInput;
106
100
  /** The note shown over a signal marker under the pointer. */
107
101
  private markerTip;
108
- private accountPanel;
109
- private orderTicket;
110
- private accountFrame;
111
- private layoutSession;
112
- private layoutsUI;
113
- private bracketBar;
114
- private alertNotifier;
115
- private depthLadder;
116
102
  private dataWindow;
117
103
  private lastHoverIndex;
118
104
  /** The bar the crosshair reported at it: on Renko and the like a brick, not a data bar. */
@@ -133,21 +119,7 @@ export declare class ChartWidget {
133
119
  private customTimeframes;
134
120
  /** Timeframes on offer, shortest first. */
135
121
  private timeframes;
136
- private watchlist;
137
- private watchlistSparkBuffer;
138
122
  private sessionRefPrice;
139
- /** Per-symbol refPrice explicitly pushed by the host via `setWatchlistEntry` — takes precedence over `sessionRefPrice`. */
140
- private hostWatchlistRefPrice;
141
- private watchlistInterval;
142
- private watchlistStore;
143
- /** The list follows `setSymbols` (no lists given, none kept). */
144
- private watchlistFromSymbols;
145
- private quoteSource;
146
- private stopQuotes;
147
- /** The symbols quotes are coming for, joined. */
148
- private quotedKey;
149
- /** The latest quote of each symbol. */
150
- private quotes;
151
123
  private symbolInfoPanel;
152
124
  /** Headlines per symbol, kept a few minutes; a late answer for an earlier symbol is dropped. */
153
125
  private news;
@@ -157,29 +129,6 @@ export declare class ChartWidget {
157
129
  private chartNav;
158
130
  /** Bars on screen, for the navigation's scroll step. */
159
131
  private visibleBarCount;
160
- private replayPollInterval;
161
- /** The replay's speed, a multiplier: 1 plays one bar of the chart a second. */
162
- private replaySpeed;
163
- /** The chart's bars the replay goes through, and when the step shown opened (from `replayStep`). */
164
- private replayBarsTotal;
165
- private replayStepTime;
166
- /** The symbol and interval of the finer steps given to the replay running (null: none given). */
167
- private replayStepsKey;
168
- /** `'auto'`, `'bar'`, or the finer interval a replay steps through. */
169
- private replayStep;
170
- private replayStartSeq;
171
- /** The time of a bar picked while the next bars loaded: the replay starts there once they come. */
172
- private replayPickTime;
173
- /** A replay start waiting for its finer steps: a Play pressed meanwhile plays it once it starts. */
174
- private replayStartPending;
175
- private replayPlayWanted;
176
- /** Finer bars fetched or built for the last replay in steps. */
177
- private replayStepsCache;
178
- /** While picking the start bar: shades the bars right of the pointer. */
179
- private replayShade;
180
- private layoutKeyPrefix;
181
- private layoutDebounceMs;
182
- private activeLayoutKey;
183
132
  private root;
184
133
  private chartContainer;
185
134
  private loading;
@@ -191,6 +140,14 @@ export declare class ChartWidget {
191
140
  /** Duration of the last local resample + setData, for SLOW_LOCAL_SWITCH_MS. */
192
141
  private lastLocalSwitchMs;
193
142
  private destroyed;
143
+ /** The widget's effects, disposed with it. */
144
+ private readonly scope;
145
+ /** Calls off the dialogs' preload when the widget goes before it ran. */
146
+ private stopPreload;
147
+ /** What each dialog loading now opens with when its code is in: the last ask. */
148
+ private readonly waitingShow;
149
+ /** The mode and the theme shown: what the root, the portal, the chart and the watermark follow. */
150
+ private look;
194
151
  private options;
195
152
  /** The tickers on offer, cleaned: what the toolbar, the watchlist and the saved state work with. */
196
153
  private symbols;
@@ -206,26 +163,6 @@ export declare class ChartWidget {
206
163
  * told of the new one; anything told since is the new one's.
207
164
  */
208
165
  private chartInfoAtSwitch;
209
- private settingsState;
210
- /** What Reset in the settings panel goes back to: the defaults, as the host's features set them. */
211
- private settingsDefaults;
212
- /** Where `persistSettings` keeps the settings; null while it is off. */
213
- private settingsStore;
214
- /**
215
- * The settings as last kept and told to the listeners, as JSON: a change
216
- * that leaves them so (a Cancel, a call setting what is already set) is
217
- * neither. Null while the widget is being made, which tells nobody.
218
- */
219
- private settingsPublished;
220
- /**
221
- * The settings shared links set this visit (`shown`) and the viewer's own
222
- * they took the place of (`own`): what `persistSettings` keeps for a
223
- * setting still as a link set it. Null when no link set any.
224
- */
225
- private linkSettings;
226
- private readonly settingsListeners;
227
- /** Switches the host's features turned off: a setting kept, shared or in a layout can't turn them on. */
228
- private settingsLocked;
229
166
  private t;
230
167
  private adapter;
231
168
  private boundGlobalKeydown;
@@ -235,28 +172,6 @@ export declare class ChartWidget {
235
172
  private builtInZone;
236
173
  /** The timeframe the user (or the host) picked: ranges never show finer than it, layouts keep it. */
237
174
  private chosenTimeframe;
238
- /** Counts range clicks and the user's own picks: a range waiting behind a newer one gives way. */
239
- private rangeSeq;
240
- /** Ranges apply one at a time, each reading the bars the last one brought. */
241
- private rangeQueue;
242
- private compares;
243
- /** How the compare dialog adds a symbol: the way picked last. */
244
- private compareWay;
245
- /** Symbols whose bars are on the way to be compared in percent. */
246
- private readonly comparesLoading;
247
- /**
248
- * Set by the first percent compare, cleared when the last one goes or the
249
- * user picks a scale meanwhile: while set, a regular price scale reads in
250
- * percent, as the compare lines do (`effectiveScaleMode`). Never saved.
251
- */
252
- private compareScaleHeld;
253
- /** The latest round of percent compare fetches: an older round's answers are dropped. */
254
- private compareFetchSeq;
255
- /** The percent compares' older stretches are on their way; `compareOlderAgain`: more pages came meanwhile. */
256
- private compareOlderBusy;
257
- private compareOlderAgain;
258
- /** Older bars asked no stretch of a compare whose bars were still at another interval: a round once they come. */
259
- private compareOlderPassed;
260
175
  /** Every switch, on or off (see `setFeatures`). */
261
176
  private featureState;
262
177
  /** The host's own shortcuts, first added first. */
@@ -268,8 +183,11 @@ export declare class ChartWidget {
268
183
  /** Whether the chart shows the "+" by the price axis while its switch is on. */
269
184
  private priceAxisAddDefault;
270
185
  constructor(container: HTMLElement, givenOptions?: ChartWidgetOptions);
271
- /** A view shared in the URL (`#tcw=`), when `shareUrl` is on. */
272
- private restoreSharedView;
186
+ /**
187
+ * The dialogs' code, loaded once the page has a moment to spare: not in the way of the chart
188
+ * coming up, and in before the user opens one, so the first opens at once too.
189
+ */
190
+ private preloadDialogsWhenIdle;
273
191
  /**
274
192
  * Replace the symbols on offer, tickers or SymbolInfo as in the `symbols`
275
193
  * option. Does not change the active symbol. A watchlist made from
@@ -315,8 +233,6 @@ export declare class ChartWidget {
315
233
  * depth ladder (the `depthLadder` option), or its switch off.
316
234
  */
317
235
  openPanel(panel: WidgetPanel): boolean;
318
- /** Whether the widget has `panel`: the watchlist and the ladder only when made with them, every one with its switch on. */
319
- private hasPanel;
320
236
  /** Shut the dock. */
321
237
  closePanel(): void;
322
238
  /** The panel open in the dock, or null. */
@@ -333,10 +249,6 @@ export declare class ChartWidget {
333
249
  private intlLocale;
334
250
  /** The language words in the panels are written in ("in 3 hours", weekday names): the widget's. */
335
251
  private textLocale;
336
- private createWatchlist;
337
- /** Quotes for the shown list's symbols: a new subscription when they change. */
338
- private followQuotes;
339
- private takeQuotes;
340
252
  setSymbol(symbol: string): Promise<void>;
341
253
  /**
342
254
  * Push an entry into the watchlist (e.g., from your own WebSocket).
@@ -348,7 +260,6 @@ export declare class ChartWidget {
348
260
  * auto-tick loop stops clobbering it (see `tickWatchlist`).
349
261
  */
350
262
  setWatchlistEntry(symbol: string, entry: Partial<WatchlistEntry>): void;
351
- private tickWatchlist;
352
263
  /** Ignored when the chart's `features.timeframes` whitelist leaves `tf` out. */
353
264
  setTimeframe(tf: TimeFrame): Promise<void>;
354
265
  /**
@@ -405,67 +316,17 @@ export declare class ChartWidget {
405
316
  private handleSymbolClick;
406
317
  /** The symbol search, started from `query` (a letter typed on the chart). */
407
318
  private openSymbolSearch;
319
+ /** The symbol search for another job (a symbol to add to a list, one to compare with), once its code is in. */
320
+ private withSymbolSearch;
408
321
  /** The host's symbol search, else the adapter's; none filters `symbols`. */
409
322
  private symbolSearchFn;
410
323
  private handleTimeframe;
411
- /**
412
- * A range from the range bar. A long one switches to the timeframe whose
413
- * bars it fits (five years of days in weeks, decades in months), a short
414
- * one back toward the user's own (`timeframeForRange`); then the range is
415
- * shown. Off with `features: { 'statusBar.rangeTimeframe': false }`.
416
- */
417
- private applyRangePreset;
418
- private runRangePreset;
419
- /** The timeframe `preset` shows in, from the bars on the chart now. */
420
- private timeframeForPreset;
421
- /** Whether a switch to `tf` brings bars: the feed serves it, or the bars here resample to it. */
422
- private canShowTimeframe;
423
324
  /** Fill the screen with the widget, or leave fullscreen. */
424
325
  toggleFullscreen(): void;
425
326
  /** A drawing tool's name in the widget's language. */
426
327
  private drawingToolName;
427
328
  /** The chart container's top-left in the widget root's coordinates. */
428
329
  private chartOffset;
429
- /** `updateSelectionToolbar` on the next frame, once, while the toolbar shows. */
430
- private scheduleSelectionToolbar;
431
- /**
432
- * Show the selection toolbar over the selected drawings, or hide it: when
433
- * nothing is selected, or while a tool, the eraser or the zoom area is on.
434
- */
435
- private updateSelectionToolbar;
436
- /**
437
- * Type a text drawing's words in place, over its box: Enter or a click away
438
- * keeps them, Escape puts them back. One just drawn (`justDrawn`) is taken
439
- * back on Escape or with no words. False when its box is not on the chart
440
- * (hidden, its text turned off): the settings ask for the words instead.
441
- */
442
- private editTextInPlace;
443
- /** Open a drawing's settings (double-click on it, or the object tree's settings button). */
444
- private openDrawingSettings;
445
- /** Save a drawing's look as a template of its tool, asking for its name over the drawing's settings. */
446
- private promptSaveDrawingTemplate;
447
- /** Add a "price crosses this drawing" alert and say so. */
448
- private addDrawingAlert;
449
- /** The menu of a right-clicked drawing; the chart has selected it (and its group) by now. */
450
- private openDrawingMenu;
451
- private runDrawingMenuAction;
452
- /** What the chart's menus can offer here, and how the chart is set now. */
453
- private chartMenuContext;
454
- /** The indicators "Remove indicators" takes away: a comparison with another symbol stays, as it has a dialog of its own. */
455
- private removableIndicators;
456
- /**
457
- * The exchange's zone, offered when the chart knows one (the symbol's, or
458
- * its market's) or the adapter can name the symbol's; its zone is null
459
- * while unknown.
460
- */
461
- private exchangeChoice;
462
- /** The time zones on offer, the exchange's among them when there is one. */
463
- private timezoneChoices;
464
- /**
465
- * Open a chart menu at (x, y) in the chart's pixels, the host's own entries
466
- * last; nothing when it has no entries.
467
- */
468
- private openChartMenu;
469
330
  /**
470
331
  * Turn switches on or off while running, by name (`WIDGET_FEATURES`): a
471
332
  * name without a dot is a whole capability (`alerts`, `settings`), a dotted
@@ -497,6 +358,8 @@ export declare class ChartWidget {
497
358
  addHotkey(spec: import('./types.js').HotkeySpec): import('./types.js').HotkeyHandle | null;
498
359
  /** Runs the host's shortcut a key press is, if any; whether it did. */
499
360
  private handleHostHotkey;
361
+ /** The symbol behind the bars, in the ink of the mode shown. */
362
+ private paintWatermark;
500
363
  /**
501
364
  * Runs a theme change, the user's look that isn't a colour (a grid way hidden, a dash) going
502
365
  * with them to the new theme: colours stay with the theme they were picked on.
@@ -528,47 +391,24 @@ export declare class ChartWidget {
528
391
  * name it doesn't know.
529
392
  */
530
393
  getSlot(name: import('./types.js').WidgetSlot): HTMLElement | null;
531
- private runChartMenuAction;
532
394
  /** Open or close the account panel (no argument: the other way from now). */
533
395
  toggleAccountPanel(open?: boolean): void;
534
- /** The order ticket, at a price from the chart (or the market). */
535
- private openOrderTicket;
536
- /** A market's rules for the order ticket (`setMarket`): its step, the day's limits, its lot. */
537
- private orderRules;
538
- /** Redraw the account panel once a frame at most (ticks, fills and order changes come in bursts). */
539
- private refreshAccountSoon;
540
- private refreshAccount;
541
- /** Ask for a limit or stop order at `price` (one unit), and say so. */
542
- private placeOrderAt;
543
396
  /** The time now in the display zone ("14:05:09") and the zone's offset ("UTC+7"), for the status bar's clock. */
544
397
  private clockNow;
545
398
  /** Whether every drawing is locked, and every one hidden: the sidebar's lock all and hide all say so. */
546
399
  private refreshDrawingsState;
547
- /** The status bar's scale switches as the chart is now (a shared link or your code may have set it). */
548
- private refreshScaleSwitches;
549
- /** `mode` on, or back to a regular scale when it is on already, through the settings. */
550
- private toggleScaleMode;
551
400
  /** The display timezone from the settings; 'exchange' is the zone the chart resolved it to. */
552
401
  private displayTimezone;
553
402
  private toggleGoToDate;
403
+ private toggleLoadedGoToDate;
554
404
  /** A moment to centre, or a span to show edge to edge, from the Go to dialog. */
555
405
  private goTo;
556
- /** Pinned timeframes that are still on offer, shortest first. */
557
- private pinnedTimeframes;
558
- /** The timeframe menu's rows, typed intervals marked so they can be removed. */
559
- private timeframeMenu;
560
- /** A typed interval: switch to it, adding and pinning it when it is new. False when it isn't one. */
561
- private handleAddTimeframe;
562
406
  /** A note by a signal marker: its source or label, side, confidence, price and time; null hides it. */
563
407
  private showMarkerTip;
564
- /** A typed interval: one on offer is picked; another joins the menu (not the toolbar's pins). */
565
- private selectTypedTimeframe;
566
408
  /** Put a template's indicators in place of the chart's (one undo step). */
567
409
  private applyIndicatorTemplate;
568
410
  /** Save the chart's indicators as a template, asking for its name. */
569
411
  private promptSaveIndicatorTemplate;
570
- private handleRemoveTimeframe;
571
- private handleToggleTimeframeFavorite;
572
412
  /**
573
413
  * Load the widget's base series. Prefer this over `getChart().setData()` so
574
414
  * client-side timeframe resampling has a finest-resolution source to
@@ -606,9 +446,6 @@ export declare class ChartWidget {
606
446
  private timeToKeepInView;
607
447
  private handleDataUpdate;
608
448
  private setConnectionState;
609
- /** The depth ladder, a page of the dock: open or shut it (the Trade menu's entry). */
610
- private toggleLadder;
611
- private toggleAlerts;
612
449
  private handleToggleFavorite;
613
450
  /**
614
451
  * Encode the current view (symbol, timeframe, chart type, scale,
@@ -617,22 +454,6 @@ export declare class ChartWidget {
617
454
  * host's features set, from where they set them).
618
455
  */
619
456
  exportState(): string;
620
- /**
621
- * A link's settings, for this visit: shown, but neither kept nor told.
622
- * They are someone else's choices (an upside-down scale, a hidden price),
623
- * so `persistSettings` keeps the viewer's own in their place until the
624
- * viewer changes them, and listeners hear of them with the next change.
625
- */
626
- private showLinkSettings;
627
- /** `settings` with each one still as a link set it back to the viewer's own: what `persistSettings` keeps. */
628
- private ownSettings;
629
- /**
630
- * Settings the viewer or the host just set: a link's no more, so from here
631
- * on they are kept as they are, the link's value too when it is picked
632
- * again on purpose. Kept at once, since a pick of the value on screen (a
633
- * Reset where the link set the defaults) changes nothing to tell.
634
- */
635
- private claimSettings;
636
457
  /** Restore a view from an `exportState()` string. Returns false if malformed. */
637
458
  importState(encoded: string): Promise<boolean>;
638
459
  /**
@@ -650,46 +471,8 @@ export declare class ChartWidget {
650
471
  setDepth(depth: DepthData | null): void;
651
472
  /** Begin a draggable bracket order at the latest price and show the action bar. */
652
473
  startBracket(side: 'buy' | 'sell'): void;
653
- /**
654
- * The bar under the pointer and the close before it. On candles the data
655
- * bar at the index, as it is now (a live tick moves it); on Renko and the
656
- * like the brick the crosshair reported, whose index is not the data's.
657
- */
658
- private hoveredBar;
659
- private buildDataWindowModel;
660
- private toggleDataWindow;
661
- private toggleObjects;
662
- /**
663
- * The dock's pages, in the rail's order: the watchlist, alerts, objects,
664
- * the data window, the symbol info and the depth ladder, all shut to start
665
- * with. Each draws itself as it shows, and says so on the toolbar's button.
666
- */
667
- private setupDock;
668
- /**
669
- * The dock and the widget's width. Going narrow (a phone, a rotated
670
- * tablet) shuts any panel: it would be a sheet over the chart. No panel
671
- * opens by itself: the chart has the room until one is asked for.
672
- */
673
- private fitDockToWidth;
674
- /** Whether the rail shows now: on, and the widget not narrow. */
675
- private railShown;
676
- /**
677
- * The rail's Tab stop on a button that shows, and the toolbar's alerts and
678
- * objects buttons hidden while the rail has its own for them (so the
679
- * "more" menu leaves them out too).
680
- */
681
- private syncRail;
682
- /** Where the keyboard goes when a panel shuts and the rail can't take it: its toolbar button, or "more" on a phone. */
683
- private panelFocusTarget;
684
- /** A panel shut by its own close button: by hand. */
685
- private closePanelByHand;
686
474
  private openIndicatorSettings;
687
- private refreshObjects;
688
- private handleAddCompare;
689
- /** What is compared with the chart's symbol now, as the compare dialog lists it. */
690
- private comparedNow;
691
- /** The compare dialog's list, after something was compared or taken off. */
692
- private refreshCompareDialog;
475
+ private showIndicatorSettings;
693
476
  /**
694
477
  * Compare with another symbol: its percent change on the price scale
695
478
  * (`'percent'`, the default), its price on a scale of its own (`'scale'`)
@@ -700,100 +483,8 @@ export declare class ChartWidget {
700
483
  * no bars at the chart's interval, nothing is added and a toast says why.
701
484
  */
702
485
  addCompareSymbol(symbol: string, way?: CompareWay): Promise<void>;
703
- /**
704
- * A compare that is an indicator (on its own scale or pane, a spread, a
705
- * correlation), its bars first, as the percent way does. A symbol the feed
706
- * can't serve at this interval then adds nothing, rather than an empty
707
- * line that stays in the chart's saves. The bars go to the chart before
708
- * the indicator, so it finds them there and asks for none.
709
- */
710
- private addCompareIndicator;
711
- /**
712
- * The other symbol's bars at the chart's interval, for a compare about to
713
- * be added: fetched again when the interval changed while they loaded, so
714
- * they are checked, and added, at the one on screen. Null, with a toast,
715
- * when they fail or there are none.
716
- */
717
- private fetchCompareBars;
718
- /** The other symbol's bars didn't come: the adapter's reason, or that they failed. */
719
- private sayCompareFailed;
720
- /** Take a compare off, an overlay or an indicator, as the compare dialog and Objects do. */
721
- private removeCompared;
722
- private handleRemoveCompare;
723
- /** A compare line the host added on the chart itself: the widget holds no scale nor list for it. */
724
- private removeHostCompare;
725
- /** `id` is a symbol compared in percent (a line, not an indicator). */
726
- private isPercentCompare;
727
- /**
728
- * How many bars of another symbol to fetch: as many as the chart has (it
729
- * may have paged older ones in), so a compare starts where the chart does.
730
- */
731
- private compareDepth;
732
- /**
733
- * Percent compares hold a regular price scale in percent: the user's has
734
- * not been picked meanwhile, and the chart draws their lines (Renko, Kagi
735
- * and the like draw none).
736
- */
737
- private holdsPercentScale;
738
- /**
739
- * The scale on screen: the user's, or percent while percent compares hold a
740
- * regular one. Logarithmic, percentage and indexed to 100 are left alone: a
741
- * log scale draws the compare lines true, and the other two read them right.
742
- */
743
- private effectiveScaleMode;
744
- /** The scale the user picked, for a shared link, a layout and the settings: never the percent a compare holds. */
745
- private userScaleMode;
746
- /** The settings as the dialog shows them: the scale on screen. */
747
- private shownSettings;
748
- /** Put the chart's price scale on the one it should show now. */
749
- private showScaleMode;
750
- /** The first percent compare holds the scale in percent; the last one gone lets it go. */
751
- private holdCompareScale;
752
- /** The scale a hold of percent compares puts on screen, in the status bar and in the settings. */
753
- private showHeldScale;
754
- /**
755
- * Bars of a symbol the chart's indicators read (a compare on its own
756
- * scale, a spread), at the chart's interval. A later interval wins.
757
- */
758
- private loadSymbolSeries;
759
- /** Refetch every comparison overlay at the current symbol/timeframe. */
760
- private refetchCompares;
761
- /** Each percent compare's bars again, as deep as the chart's, at its interval. The latest round wins. */
762
- private refetchPercentCompares;
763
- /**
764
- * Older bars in: each percent compare's older stretch, so its line starts
765
- * where the chart does. One round at a time: pages that load meanwhile
766
- * get one more round, for what is missing by then.
767
- */
768
- private extendPercentCompares;
769
- /**
770
- * Each percent compare's bars before its first, as many as the chart has
771
- * before it; from a feed that can't page back, its bars again, as deep as
772
- * the chart's. A round of full fetches meanwhile (a new interval) drops them.
773
- */
774
- private fetchOlderCompares;
775
- /**
776
- * A percent compare's bars fetched again `depth` deep, from a feed that
777
- * can't page back. Fewer than asked, or none older than `first`: the
778
- * feed's history starts there, and no page asks again.
779
- */
780
- private deepenCompareBars;
781
- /** A percent compare's older bars in front of its own; none older: the feed's history starts there. */
782
- private prependCompareBars;
783
- /** A percent compare's line on new bars at `timeframe`, which may reach further back again. */
784
- private setCompareBars;
785
- /** A percent compare's bars at `timeframe` didn't come: it keeps the ones it has. */
786
- private compareFailedAt;
787
- private refreshAlerts;
788
486
  /** The prices the panels show, written again in the decimals the chart has now. */
789
487
  private refreshPriceTexts;
790
- private alertListItem;
791
- /** An alert in words, for a toast or a notification: "Price crossing EMA 20", "RSI greater than 70". */
792
- private alertText;
793
- /** Price + every active indicator line, as selectable alert sources. */
794
- private buildAlertSources;
795
- /** Latest value for an alert source channel (price or indicator line). */
796
- private getAlertChannelValue;
797
488
  /**
798
489
  * Money in the quote's units (a stop's risk, an order's value), in the
799
490
  * number locale: to the decimals of the price step, two at most (a forex
@@ -830,10 +521,6 @@ export declare class ChartWidget {
830
521
  /** "Save as default": new indicators of the kind start like this one, here and next time. */
831
522
  private saveIndicatorDefault;
832
523
  private handleRemoveIndicator;
833
- private toggleCommandPalette;
834
- private buildCommandItems;
835
- /** Whether the widget has what a command works on: a watchlist, a feed to compare from, layouts to save to. */
836
- private commandThere;
837
524
  /**
838
525
  * `keys` as a command's shortcut, where they work: their switch on (and
839
526
  * what they need there), and no shortcut of the host's on them instead.
@@ -841,17 +528,6 @@ export declare class ChartWidget {
841
528
  private keysShown;
842
529
  /** The shortcut sheet: the keys switched on, and the host's. */
843
530
  private openHotkeySheet;
844
- /** Whether a command's switch (when it has one) is on. */
845
- private commandOn;
846
- /**
847
- * The trash button's menu: the drawings, the indicators, or both, each with
848
- * how many would go (locked drawings stay). Nothing to remove, no menu; a
849
- * second press closes it.
850
- */
851
- private openClearMenu;
852
- /** Remove the drawings, the indicators or both, as one undo step, and leave any drawing tool. */
853
- private removeAll;
854
- private handleAction;
855
531
  private handleDrawingTool;
856
532
  /** The cursor button: no tool, no eraser, no zoom box. */
857
533
  private handleCancelDrawing;
@@ -859,21 +535,18 @@ export declare class ChartWidget {
859
535
  /** The magnet button goes off → weak → strong → off. */
860
536
  private handleToggleMagnet;
861
537
  private handleToggleTheme;
862
- private openSettings;
863
- /** The whole series in view, the price scale fitted to it (the menus' Reset, Alt+R). */
864
- private resetView;
865
- /** The settings closed: OK keeps what they changed as one undo step, Cancel puts it back as it was on opening. */
866
- private endSettingsEdit;
538
+ /** A dialog's code, loaded the first time it opens; a failed load says so. */
539
+ private lazyPart;
867
540
  /**
868
- * The keys a change touched: in the open settings, what Cancel and the
869
- * undo step go by (and what OK takes from a link); outside them, a link's
870
- * no more.
541
+ * Runs `show` with a dialog: at once when its code is in, else once it has loaded, unless the
542
+ * widget went or its switch turned off meanwhile. Of the asks made while it loads, the last
543
+ * one opens it (another indicator's settings, another tab), once.
871
544
  */
872
- private touchSettings;
873
- /** A chart template in place of the chart's look: its switches, and its colours over the theme's. */
874
- private applyChartTemplate;
875
- /** Save the chart's look as a template, asking for its name over the open settings. */
876
- private promptSaveChartTemplate;
545
+ private whenLoaded;
546
+ /** A toggle pressed again while its dialog's code loads: the dialog no longer opens. Whether one was waiting. */
547
+ private cancelWaiting;
548
+ /** The whole series in view, the price scale fitted to it (the menus' Reset, Alt+R). */
549
+ private resetView;
877
550
  /**
878
551
  * Show a transient toast inside the widget. Auto-dismisses after 3.5s.
879
552
  * Used by the drag-drop importer for success / failure feedback, but
@@ -920,38 +593,12 @@ export declare class ChartWidget {
920
593
  * safe to give back right after the constructor.
921
594
  */
922
595
  setSettings(patch: Partial<ChartSettingsState>): void;
923
- /**
924
- * A patch without auto-scale off while the chart has no bars. Off holds the
925
- * price range on screen; before the first bars there is none, and the chart
926
- * would keep its empty 0 to 1 for every series after them.
927
- */
928
- private withoutEarlyFreeze;
929
596
  /**
930
597
  * Hear of each change to the Chart Settings, with `getSettings()`: once
931
598
  * when the settings dialog closes with OK, never for Cancel or for a
932
599
  * change that leaves them as they were. Returns the function that stops it.
933
600
  */
934
601
  onSettingsChange(listener: (settings: ChartSettingsState) => void): () => void;
935
- /**
936
- * The settings the chart says itself, over the widget's: what a host set
937
- * on `getChart()` directly, a scale a drag or a switched-off feature
938
- * changed, a type's own settings a layout brought. The scale is the
939
- * user's, never the percent a compare holds.
940
- */
941
- private syncSettingsFromChart;
942
- /**
943
- * A patch without what the host's features switched off: a bar countdown,
944
- * a legend, a volume or a log scale that isn't there stays off. Keys given
945
- * no value are left out too.
946
- */
947
- private allowedSettings;
948
- /** The settings the user kept in this browser (`persistSettings`) back on the chart; from here on each change is kept and told. */
949
- private restoreKeptSettings;
950
- /** Once telling has begun, the settings as they are now count as told: the next change is measured from them. */
951
- private markSettingsTold;
952
- /** The settings changed: kept (`persistSettings`) and told to the listeners, unless they are as last time. */
953
- private publishSettings;
954
- private setupLayouts;
955
602
  /** Save into the open layout, or ask for a name when there is none. */
956
603
  saveLayout(): Promise<void>;
957
604
  /** Open a saved layout by id; `false` when it could not be. */
@@ -961,8 +608,6 @@ export declare class ChartWidget {
961
608
  * Useful as an "Reset layout" command in user-facing menus.
962
609
  */
963
610
  clearSavedLayout(symbol?: string): void;
964
- private applySymbolLayout;
965
- private flushActiveLayout;
966
611
  /** Rebuild the chip strip from the chart's indicator instances. */
967
612
  private syncIndicatorsFromChart;
968
613
  /** Open the indicators dialog, or close it when it is open. */
@@ -977,170 +622,45 @@ export declare class ChartWidget {
977
622
  private templateNames;
978
623
  /** Open (or close) bar replay with its scrubber — what the toolbar's Replay button does. */
979
624
  toggleReplay(): void;
980
- /**
981
- * Open replay in "pick a start bar" mode: the bars right of the pointer
982
- * are shaded, and a click cuts the chart there and waits paused. Play
983
- * starts from a default point; "random bar" picks one.
984
- */
985
- private enterReplay;
986
- /** While picking the start bar: the shade over the bars a pick would hide. */
987
- private showReplayShade;
988
- private removeReplayShade;
989
- /**
990
- * Select bar, inside the replay: it pauses and picks again among the bars
991
- * shown, so the bars still to come stay hidden, the view stays and grid
992
- * followers go on. Cancel (or Esc) comes back to the same place.
993
- */
994
- private pickReplayBarAgain;
995
- /** Cancel picking: back to the replay when there is one, else out of it. */
996
- private cancelReplayPick;
997
- /**
998
- * Where the bar sits: on the main pane's foot (bottom panes stay
999
- * readable), centred on its plot, in the tier its width allows; and how
1000
- * high it reaches, for the toasts and the drawing button to clear it.
1001
- */
1002
- private layoutReplayBar;
1003
- /**
1004
- * How high the bar reaches over the widget's foot and its body's, for the
1005
- * toasts and the drawing button to clear it. Also run as the panel follows
1006
- * the chart: the bar's height changes with its rows and its words.
1007
- */
1008
- private liftOverReplayBar;
1009
- /** Where the plot starts in the body, for the phone's drawing button to sit over it. */
1010
- private placeDrawingButton;
1011
- private bodyEl;
1012
- /**
1013
- * Where the replay is, as the readout says it: the step's open time in
1014
- * the display timezone and the widget's language; the date alone on a
1015
- * daily chart and above, seconds under a minute (or with no interval),
1016
- * the year only when it isn't this one.
1017
- */
1018
- private replayTimeText;
1019
- /** The chart's bars the replay goes through (not its steps), or those loaded before it starts. */
1020
- private replayBarCount;
1021
- private readonly hideReplayShade;
1022
625
  /**
1023
626
  * Open replay (if it isn't open) and start it at bar `index` — paused, or
1024
627
  * playing when `play` is set — skipping the pick-a-bar step.
1025
628
  */
1026
629
  replayFrom(index: number, play?: boolean): void;
1027
- /**
1028
- * The steps a replay can take on this interval, the one picked kept while
1029
- * it is still one of them (else whole bars).
1030
- */
1031
- private replayStepMenu;
1032
- /** The interval changed: the step menu offers its steps. */
1033
- private refreshReplaySteps;
1034
- /**
1035
- * The replay went on over new bars at the same time: the panel shows their
1036
- * total, and a replay in finer steps fetches them for the new bars and
1037
- * goes on from the bar it is on.
1038
- */
1039
- private afterReplayCarryOver;
1040
- /**
1041
- * A bar picked while the next bars loaded: once they are in, start the replay at the bar
1042
- * holding its time; let it go if they failed or the pick was left.
1043
- */
1044
- private startPickedReplay;
1045
- /** Whether the bars on screen are about to be replaced: a new symbol's or interval's on their way. */
1046
- private seriesPending;
1047
- /** The panel follows the chart, and whether the bars are on their way, a few times a second. */
1048
- private watchReplayBar;
1049
- /**
1050
- * Cut the chart at `index` and wait paused (or play at once). `ofBars`:
1051
- * `index` is one of the chart's bars (a pick), not a step of the replay.
1052
- */
1053
- private startReplayAt;
1054
- private replayStepsKeyNow;
1055
- /** How many steps of `tf` make a bar of the chart (1 for whole bars, or a chart without an interval). */
1056
- private replayStepsPerBar;
1057
- /** Finer intervals a replay can step through: they divide the chart's, and the feed (or the bars loaded) has them. */
1058
- private replayStepOptions;
1059
- /** Whether the feed serves `tf`, or the bars loaded build it. */
1060
- private hasReplayStep;
1061
- /** The finer interval the step picked stands for (`'auto'` worked out here); null for whole bars. */
1062
- private replayStepInterval;
1063
- /**
1064
- * Whether the chart fetches a replay's finer bars itself: its bars form, a
1065
- * step is picked and the feed pages back. A feed that can't page back gets
1066
- * its finer bars fetched here, in one request, as before.
1067
- */
1068
- private chartFetchesReplaySteps;
1069
- /** The finer bars for a replay in `tf` steps: from the feed, or built from the bars loaded. Null when there are none. */
1070
- private replayStepsFor;
1071
- /**
1072
- * The zone the feed's wrapper builds `tf` in for `symbol` ('' when the feed
1073
- * serves it): after no answer about the symbol it builds on UTC's days
1074
- * until the chart loads the symbol afresh, so steps fetched before then
1075
- * are stale after it.
1076
- */
1077
- private builtStepsZone;
1078
- /** Bars available to replay: the whole series, not the slice on screen. */
1079
- private replayTotal;
1080
- /** Mirror the replay engine in the bar; close it if the session ended elsewhere. */
1081
- private syncReplayBar;
1082
- private stepReplay;
1083
- /**
1084
- * Replay shortcuts: Shift+←/→ step one bar, Space on the chart plays or
1085
- * pauses, Escape cancels picking a start bar. Only for the widget used
1086
- * last, with focus in it (or nowhere), not while typing or in a dialog.
1087
- */
1088
- private handleReplayKey;
1089
- /** Focus on the chart itself (its container or the canvas in it), not on a control over it. */
1090
- private onChartSurface;
1091
- private toggleReplayPlay;
1092
- private replayBarAtEnd;
1093
- private positionReplayShade;
1094
- /** Leave replay and return to the live series (with updates that arrived meanwhile). */
1095
- private exitReplay;
1096
- private teardownReplayUi;
1097
- /**
1098
- * Focus was in the bar: back to the toolbar's Bar replay button, or the
1099
- * "more" menu that folds it on a narrow toolbar, or the chart.
1100
- */
1101
- private focusAfterReplay;
1102
- /** `told` false leaves the change unkept and untold (a link's). */
1103
- private applySettings;
1104
- private resetSettings;
1105
- /**
1106
- * A change to the look in the settings: style keys on the user's layer (null
1107
- * takes one away), kept with the theme they were picked on, and in the
1108
- * chart's undo history. A burst on the same keys (a colour dragged across
1109
- * the picker) is one step.
1110
- */
1111
- private changeStyle;
1112
- /**
1113
- * A settings change the user made: applied, and put in the chart's undo
1114
- * history with its drawings and indicators. A burst on the same settings
1115
- * (a colour dragged across the picker) is one step.
1116
- */
1117
- private changeSettings;
1118
- /**
1119
- * The user's overrides on `keys` (null: none set), with the theme they go
1120
- * with: what an undo of the look puts back.
1121
- */
1122
- private settingsStyle;
1123
- /**
1124
- * Settings back as they were (an undo or redo), shown in the settings if
1125
- * they're open; `held` puts back whether percent compares held the scale.
1126
- */
1127
- private restoreSettings;
630
+ /** What the replay reads of the widget and asks of it. */
631
+ private replayHost;
632
+ /** Where the plot starts in the body, for the phone's drawing button to sit over it. */
633
+ private placeDrawingButton;
634
+ private bodyEl;
1128
635
  private connectStream;
1129
- /** Redraw the on-chart indicator list on the next frame (coalesced). */
1130
- private scheduleLegend;
1131
- private renderLegend;
1132
- /** A pane's button on the chart. */
1133
- private runPaneAction;
1134
- /**
1135
- * An indicator's "more" menu: into the pane above or below it (the price
1136
- * pane at the top), a pane of its own, back to the price pane; then its
1137
- * settings and remove.
1138
- */
1139
- private openLegendMenu;
1140
636
  private updateUI;
1141
637
  private resolveIsDark;
1142
638
  private resolveTheme;
1143
639
  private isColorDark;
640
+ /** What WidgetCompares reads of the widget and asks of it. */
641
+ private comparingHost;
642
+ /** What WidgetWatchlists reads of the widget and asks of it. */
643
+ private watchingHost;
644
+ /** What WidgetAlerts reads of the widget and asks of it. */
645
+ private alertingHost;
646
+ /** What WidgetTrading reads of the widget and asks of it. */
647
+ private tradingHost;
648
+ /** What WidgetMenus reads of the widget and asks of it. */
649
+ private menusHost;
650
+ /** What WidgetLegendView reads of the widget and asks of it. */
651
+ private legendHost;
652
+ /** What WidgetCommands reads of the widget and asks of it. */
653
+ private commandsHost;
654
+ /** What WidgetLayouts reads of the widget and asks of it. */
655
+ private layoutsHost;
656
+ /** What WidgetDockArea reads of the widget and asks of it. */
657
+ private dockingHost;
658
+ /** What WidgetChartSettings reads of the widget and asks of it. */
659
+ private chartSettingsHost;
660
+ /** What WidgetDrawingEdit reads of the widget and asks of it. */
661
+ private drawingEditHost;
662
+ /** What WidgetIntervals reads of the widget and asks of it. */
663
+ private intervalsHost;
1144
664
  }
1145
665
  export { indicatorChipLabel };
1146
666
  type ActiveIndicator = ReturnType<Chart['getActiveIndicators']>[number];