@363045841yyt/klinechart 0.8.4 → 0.8.6
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.
- package/README.md +6 -1
- package/dist/components/BaseModal.vue.d.ts +54 -0
- package/dist/components/BaseModal.vue.d.ts.map +1 -0
- package/dist/components/BatchStockDialog.vue.d.ts +13 -0
- package/dist/components/BatchStockDialog.vue.d.ts.map +1 -0
- package/dist/components/ChartSettingsDialog.vue.d.ts.map +1 -1
- package/dist/components/ColorPresetPanel.vue.d.ts +4 -1
- package/dist/components/ColorPresetPanel.vue.d.ts.map +1 -1
- package/dist/components/CompareSymbolSelector.vue.d.ts.map +1 -1
- package/dist/components/DrawingStyleToolbar.vue.d.ts.map +1 -1
- package/dist/components/Dropdown.vue.d.ts.map +1 -1
- package/dist/components/ExportProgressDialog.vue.d.ts +15 -0
- package/dist/components/ExportProgressDialog.vue.d.ts.map +1 -0
- package/dist/components/IndicatorParams.vue.d.ts.map +1 -1
- package/dist/components/IndicatorSelector.vue.d.ts.map +1 -1
- package/dist/components/KLineChart.vue.d.ts +5 -9
- package/dist/components/KLineChart.vue.d.ts.map +1 -1
- package/dist/components/LeftToolbar.vue.d.ts.map +1 -1
- package/dist/components/RangeSelectionExport.vue.d.ts +23 -0
- package/dist/components/RangeSelectionExport.vue.d.ts.map +1 -0
- package/dist/components/SymbolSelector.vue.d.ts.map +1 -1
- package/dist/components/TopToolbar.vue.d.ts.map +1 -1
- package/dist/components/common/CanvasToolbar.vue.d.ts +14 -0
- package/dist/components/common/CanvasToolbar.vue.d.ts.map +1 -0
- package/dist/components/common/CanvasToolbarStack.vue.d.ts +14 -0
- package/dist/components/common/CanvasToolbarStack.vue.d.ts.map +1 -0
- package/dist/composables/chart/useChartTheme.d.ts +329 -0
- package/dist/composables/chart/useChartTheme.d.ts.map +1 -0
- package/dist/composables/chart/useDrawingManager.d.ts +86 -0
- package/dist/composables/chart/useDrawingManager.d.ts.map +1 -0
- package/dist/composables/chart/useIndicatorManager.d.ts +38 -0
- package/dist/composables/chart/useIndicatorManager.d.ts.map +1 -0
- package/dist/composables/chart/useRangeSelection.d.ts +66 -0
- package/dist/composables/chart/useRangeSelection.d.ts.map +1 -0
- package/dist/composables/useTeleportedPopup.d.ts +8 -0
- package/dist/composables/useTeleportedPopup.d.ts.map +1 -0
- package/dist/index.cjs +9 -2
- package/dist/index.css +1 -1
- package/dist/index.js +2149 -1409
- package/dist/tools/calcRangeOverlayPixel.d.ts +15 -0
- package/dist/tools/calcRangeOverlayPixel.d.ts.map +1 -0
- package/dist/tools/getKLineIndexByTimestamp.d.ts +4 -0
- package/dist/tools/getKLineIndexByTimestamp.d.ts.map +1 -0
- package/dist/web-component.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/components/BaseModal.vue +292 -0
- package/src/components/BatchStockDialog.vue +128 -0
- package/src/components/ChartSettingsDialog.vue +248 -405
- package/src/components/ColorPresetPanel.vue +58 -106
- package/src/components/CompareSymbolSelector.vue +37 -10
- package/src/components/DrawingStyleToolbar.vue +33 -72
- package/src/components/Dropdown.vue +42 -19
- package/src/components/ExportProgressDialog.vue +118 -0
- package/src/components/IndicatorParams.vue +194 -321
- package/src/components/IndicatorSelector.vue +188 -405
- package/src/components/KLineChart.vue +228 -403
- package/src/components/LeftToolbar.vue +3 -2
- package/src/components/RangeSelectionExport.vue +117 -0
- package/src/components/SymbolSelector.vue +37 -10
- package/src/components/TopToolbar.vue +55 -2
- package/src/components/common/CanvasToolbar.vue +70 -0
- package/src/components/common/CanvasToolbarStack.vue +32 -0
- package/src/composables/chart/useChartTheme.ts +86 -0
- package/src/composables/chart/useDrawingManager.ts +67 -0
- package/src/composables/chart/useIndicatorManager.ts +307 -0
- package/src/composables/chart/useRangeSelection.ts +424 -0
- package/src/composables/useTeleportedPopup.ts +46 -0
- package/src/tools/calcRangeOverlayPixel.ts +28 -0
- package/src/tools/getKLineIndexByTimestamp.ts +40 -0
|
@@ -0,0 +1,329 @@
|
|
|
1
|
+
import { Ref } from 'vue';
|
|
2
|
+
import { ChartSettings } from '@363045841yyt/klinechart-core/config';
|
|
3
|
+
import { ChartController } from '@363045841yyt/klinechart-core/controllers';
|
|
4
|
+
export declare function useChartTheme(ctrl: Ref<ChartController | null>): {
|
|
5
|
+
chartTheme: Ref<"light" | "dark", "light" | "dark">;
|
|
6
|
+
chartSettings: Ref<{
|
|
7
|
+
[x: string]: string | boolean | {
|
|
8
|
+
light?: {
|
|
9
|
+
background?: string | undefined;
|
|
10
|
+
foreground?: string | undefined;
|
|
11
|
+
chartBackground?: string | undefined;
|
|
12
|
+
candleUpBody?: string | undefined;
|
|
13
|
+
candleUpBorder?: string | undefined;
|
|
14
|
+
candleUpWick?: string | undefined;
|
|
15
|
+
candleDownBody?: string | undefined;
|
|
16
|
+
candleDownBorder?: string | undefined;
|
|
17
|
+
candleDownWick?: string | undefined;
|
|
18
|
+
volumeUp?: string | undefined;
|
|
19
|
+
volumeDown?: string | undefined;
|
|
20
|
+
axisText?: string | undefined;
|
|
21
|
+
axisLine?: string | undefined;
|
|
22
|
+
axisTick?: string | undefined;
|
|
23
|
+
gridMajor?: string | undefined;
|
|
24
|
+
gridMinor?: string | undefined;
|
|
25
|
+
crosshairLine?: string | undefined;
|
|
26
|
+
crosshairLabelBg?: string | undefined;
|
|
27
|
+
crosshairLabelText?: string | undefined;
|
|
28
|
+
selectionFill?: string | undefined;
|
|
29
|
+
selectionStroke?: string | undefined;
|
|
30
|
+
tooltipBg?: string | undefined;
|
|
31
|
+
tooltipText?: string | undefined;
|
|
32
|
+
tooltipBorder?: string | undefined;
|
|
33
|
+
volumeProfilePoc?: string | undefined;
|
|
34
|
+
footprintAsk?: string | undefined;
|
|
35
|
+
footprintBid?: string | undefined;
|
|
36
|
+
footprintImbalance?: string | undefined;
|
|
37
|
+
alertActive?: string | undefined;
|
|
38
|
+
alertTriggered?: string | undefined;
|
|
39
|
+
alertMuted?: string | undefined;
|
|
40
|
+
avwapLine?: string | undefined;
|
|
41
|
+
avwapBand?: string | undefined;
|
|
42
|
+
mtfOverlay?: string | undefined;
|
|
43
|
+
} | undefined;
|
|
44
|
+
dark?: {
|
|
45
|
+
background?: string | undefined;
|
|
46
|
+
foreground?: string | undefined;
|
|
47
|
+
chartBackground?: string | undefined;
|
|
48
|
+
candleUpBody?: string | undefined;
|
|
49
|
+
candleUpBorder?: string | undefined;
|
|
50
|
+
candleUpWick?: string | undefined;
|
|
51
|
+
candleDownBody?: string | undefined;
|
|
52
|
+
candleDownBorder?: string | undefined;
|
|
53
|
+
candleDownWick?: string | undefined;
|
|
54
|
+
volumeUp?: string | undefined;
|
|
55
|
+
volumeDown?: string | undefined;
|
|
56
|
+
axisText?: string | undefined;
|
|
57
|
+
axisLine?: string | undefined;
|
|
58
|
+
axisTick?: string | undefined;
|
|
59
|
+
gridMajor?: string | undefined;
|
|
60
|
+
gridMinor?: string | undefined;
|
|
61
|
+
crosshairLine?: string | undefined;
|
|
62
|
+
crosshairLabelBg?: string | undefined;
|
|
63
|
+
crosshairLabelText?: string | undefined;
|
|
64
|
+
selectionFill?: string | undefined;
|
|
65
|
+
selectionStroke?: string | undefined;
|
|
66
|
+
tooltipBg?: string | undefined;
|
|
67
|
+
tooltipText?: string | undefined;
|
|
68
|
+
tooltipBorder?: string | undefined;
|
|
69
|
+
volumeProfilePoc?: string | undefined;
|
|
70
|
+
footprintAsk?: string | undefined;
|
|
71
|
+
footprintBid?: string | undefined;
|
|
72
|
+
footprintImbalance?: string | undefined;
|
|
73
|
+
alertActive?: string | undefined;
|
|
74
|
+
alertTriggered?: string | undefined;
|
|
75
|
+
alertMuted?: string | undefined;
|
|
76
|
+
avwapLine?: string | undefined;
|
|
77
|
+
avwapBand?: string | undefined;
|
|
78
|
+
mtfOverlay?: string | undefined;
|
|
79
|
+
} | undefined;
|
|
80
|
+
} | undefined;
|
|
81
|
+
showGridLines?: string | boolean | undefined;
|
|
82
|
+
showVolumePriceMarkers?: string | boolean | undefined;
|
|
83
|
+
axisType?: string | boolean | undefined;
|
|
84
|
+
disableMainPaneVerticalScroll?: string | boolean | undefined;
|
|
85
|
+
isAsiaMarket?: string | boolean | undefined;
|
|
86
|
+
enableWebGLRendering?: string | boolean | undefined;
|
|
87
|
+
theme?: string | boolean | undefined;
|
|
88
|
+
enableCanvasProfiler?: string | boolean | undefined;
|
|
89
|
+
colorPresetSettings?: {
|
|
90
|
+
light?: {
|
|
91
|
+
background?: string | undefined;
|
|
92
|
+
foreground?: string | undefined;
|
|
93
|
+
chartBackground?: string | undefined;
|
|
94
|
+
candleUpBody?: string | undefined;
|
|
95
|
+
candleUpBorder?: string | undefined;
|
|
96
|
+
candleUpWick?: string | undefined;
|
|
97
|
+
candleDownBody?: string | undefined;
|
|
98
|
+
candleDownBorder?: string | undefined;
|
|
99
|
+
candleDownWick?: string | undefined;
|
|
100
|
+
volumeUp?: string | undefined;
|
|
101
|
+
volumeDown?: string | undefined;
|
|
102
|
+
axisText?: string | undefined;
|
|
103
|
+
axisLine?: string | undefined;
|
|
104
|
+
axisTick?: string | undefined;
|
|
105
|
+
gridMajor?: string | undefined;
|
|
106
|
+
gridMinor?: string | undefined;
|
|
107
|
+
crosshairLine?: string | undefined;
|
|
108
|
+
crosshairLabelBg?: string | undefined;
|
|
109
|
+
crosshairLabelText?: string | undefined;
|
|
110
|
+
selectionFill?: string | undefined;
|
|
111
|
+
selectionStroke?: string | undefined;
|
|
112
|
+
tooltipBg?: string | undefined;
|
|
113
|
+
tooltipText?: string | undefined;
|
|
114
|
+
tooltipBorder?: string | undefined;
|
|
115
|
+
volumeProfilePoc?: string | undefined;
|
|
116
|
+
footprintAsk?: string | undefined;
|
|
117
|
+
footprintBid?: string | undefined;
|
|
118
|
+
footprintImbalance?: string | undefined;
|
|
119
|
+
alertActive?: string | undefined;
|
|
120
|
+
alertTriggered?: string | undefined;
|
|
121
|
+
alertMuted?: string | undefined;
|
|
122
|
+
avwapLine?: string | undefined;
|
|
123
|
+
avwapBand?: string | undefined;
|
|
124
|
+
mtfOverlay?: string | undefined;
|
|
125
|
+
} | undefined;
|
|
126
|
+
dark?: {
|
|
127
|
+
background?: string | undefined;
|
|
128
|
+
foreground?: string | undefined;
|
|
129
|
+
chartBackground?: string | undefined;
|
|
130
|
+
candleUpBody?: string | undefined;
|
|
131
|
+
candleUpBorder?: string | undefined;
|
|
132
|
+
candleUpWick?: string | undefined;
|
|
133
|
+
candleDownBody?: string | undefined;
|
|
134
|
+
candleDownBorder?: string | undefined;
|
|
135
|
+
candleDownWick?: string | undefined;
|
|
136
|
+
volumeUp?: string | undefined;
|
|
137
|
+
volumeDown?: string | undefined;
|
|
138
|
+
axisText?: string | undefined;
|
|
139
|
+
axisLine?: string | undefined;
|
|
140
|
+
axisTick?: string | undefined;
|
|
141
|
+
gridMajor?: string | undefined;
|
|
142
|
+
gridMinor?: string | undefined;
|
|
143
|
+
crosshairLine?: string | undefined;
|
|
144
|
+
crosshairLabelBg?: string | undefined;
|
|
145
|
+
crosshairLabelText?: string | undefined;
|
|
146
|
+
selectionFill?: string | undefined;
|
|
147
|
+
selectionStroke?: string | undefined;
|
|
148
|
+
tooltipBg?: string | undefined;
|
|
149
|
+
tooltipText?: string | undefined;
|
|
150
|
+
tooltipBorder?: string | undefined;
|
|
151
|
+
volumeProfilePoc?: string | undefined;
|
|
152
|
+
footprintAsk?: string | undefined;
|
|
153
|
+
footprintBid?: string | undefined;
|
|
154
|
+
footprintImbalance?: string | undefined;
|
|
155
|
+
alertActive?: string | undefined;
|
|
156
|
+
alertTriggered?: string | undefined;
|
|
157
|
+
alertMuted?: string | undefined;
|
|
158
|
+
avwapLine?: string | undefined;
|
|
159
|
+
avwapBand?: string | undefined;
|
|
160
|
+
mtfOverlay?: string | undefined;
|
|
161
|
+
} | undefined;
|
|
162
|
+
} | undefined;
|
|
163
|
+
}, ChartSettings | {
|
|
164
|
+
[x: string]: string | boolean | {
|
|
165
|
+
light?: {
|
|
166
|
+
background?: string | undefined;
|
|
167
|
+
foreground?: string | undefined;
|
|
168
|
+
chartBackground?: string | undefined;
|
|
169
|
+
candleUpBody?: string | undefined;
|
|
170
|
+
candleUpBorder?: string | undefined;
|
|
171
|
+
candleUpWick?: string | undefined;
|
|
172
|
+
candleDownBody?: string | undefined;
|
|
173
|
+
candleDownBorder?: string | undefined;
|
|
174
|
+
candleDownWick?: string | undefined;
|
|
175
|
+
volumeUp?: string | undefined;
|
|
176
|
+
volumeDown?: string | undefined;
|
|
177
|
+
axisText?: string | undefined;
|
|
178
|
+
axisLine?: string | undefined;
|
|
179
|
+
axisTick?: string | undefined;
|
|
180
|
+
gridMajor?: string | undefined;
|
|
181
|
+
gridMinor?: string | undefined;
|
|
182
|
+
crosshairLine?: string | undefined;
|
|
183
|
+
crosshairLabelBg?: string | undefined;
|
|
184
|
+
crosshairLabelText?: string | undefined;
|
|
185
|
+
selectionFill?: string | undefined;
|
|
186
|
+
selectionStroke?: string | undefined;
|
|
187
|
+
tooltipBg?: string | undefined;
|
|
188
|
+
tooltipText?: string | undefined;
|
|
189
|
+
tooltipBorder?: string | undefined;
|
|
190
|
+
volumeProfilePoc?: string | undefined;
|
|
191
|
+
footprintAsk?: string | undefined;
|
|
192
|
+
footprintBid?: string | undefined;
|
|
193
|
+
footprintImbalance?: string | undefined;
|
|
194
|
+
alertActive?: string | undefined;
|
|
195
|
+
alertTriggered?: string | undefined;
|
|
196
|
+
alertMuted?: string | undefined;
|
|
197
|
+
avwapLine?: string | undefined;
|
|
198
|
+
avwapBand?: string | undefined;
|
|
199
|
+
mtfOverlay?: string | undefined;
|
|
200
|
+
} | undefined;
|
|
201
|
+
dark?: {
|
|
202
|
+
background?: string | undefined;
|
|
203
|
+
foreground?: string | undefined;
|
|
204
|
+
chartBackground?: string | undefined;
|
|
205
|
+
candleUpBody?: string | undefined;
|
|
206
|
+
candleUpBorder?: string | undefined;
|
|
207
|
+
candleUpWick?: string | undefined;
|
|
208
|
+
candleDownBody?: string | undefined;
|
|
209
|
+
candleDownBorder?: string | undefined;
|
|
210
|
+
candleDownWick?: string | undefined;
|
|
211
|
+
volumeUp?: string | undefined;
|
|
212
|
+
volumeDown?: string | undefined;
|
|
213
|
+
axisText?: string | undefined;
|
|
214
|
+
axisLine?: string | undefined;
|
|
215
|
+
axisTick?: string | undefined;
|
|
216
|
+
gridMajor?: string | undefined;
|
|
217
|
+
gridMinor?: string | undefined;
|
|
218
|
+
crosshairLine?: string | undefined;
|
|
219
|
+
crosshairLabelBg?: string | undefined;
|
|
220
|
+
crosshairLabelText?: string | undefined;
|
|
221
|
+
selectionFill?: string | undefined;
|
|
222
|
+
selectionStroke?: string | undefined;
|
|
223
|
+
tooltipBg?: string | undefined;
|
|
224
|
+
tooltipText?: string | undefined;
|
|
225
|
+
tooltipBorder?: string | undefined;
|
|
226
|
+
volumeProfilePoc?: string | undefined;
|
|
227
|
+
footprintAsk?: string | undefined;
|
|
228
|
+
footprintBid?: string | undefined;
|
|
229
|
+
footprintImbalance?: string | undefined;
|
|
230
|
+
alertActive?: string | undefined;
|
|
231
|
+
alertTriggered?: string | undefined;
|
|
232
|
+
alertMuted?: string | undefined;
|
|
233
|
+
avwapLine?: string | undefined;
|
|
234
|
+
avwapBand?: string | undefined;
|
|
235
|
+
mtfOverlay?: string | undefined;
|
|
236
|
+
} | undefined;
|
|
237
|
+
} | undefined;
|
|
238
|
+
showGridLines?: string | boolean | undefined;
|
|
239
|
+
showVolumePriceMarkers?: string | boolean | undefined;
|
|
240
|
+
axisType?: string | boolean | undefined;
|
|
241
|
+
disableMainPaneVerticalScroll?: string | boolean | undefined;
|
|
242
|
+
isAsiaMarket?: string | boolean | undefined;
|
|
243
|
+
enableWebGLRendering?: string | boolean | undefined;
|
|
244
|
+
theme?: string | boolean | undefined;
|
|
245
|
+
enableCanvasProfiler?: string | boolean | undefined;
|
|
246
|
+
colorPresetSettings?: {
|
|
247
|
+
light?: {
|
|
248
|
+
background?: string | undefined;
|
|
249
|
+
foreground?: string | undefined;
|
|
250
|
+
chartBackground?: string | undefined;
|
|
251
|
+
candleUpBody?: string | undefined;
|
|
252
|
+
candleUpBorder?: string | undefined;
|
|
253
|
+
candleUpWick?: string | undefined;
|
|
254
|
+
candleDownBody?: string | undefined;
|
|
255
|
+
candleDownBorder?: string | undefined;
|
|
256
|
+
candleDownWick?: string | undefined;
|
|
257
|
+
volumeUp?: string | undefined;
|
|
258
|
+
volumeDown?: string | undefined;
|
|
259
|
+
axisText?: string | undefined;
|
|
260
|
+
axisLine?: string | undefined;
|
|
261
|
+
axisTick?: string | undefined;
|
|
262
|
+
gridMajor?: string | undefined;
|
|
263
|
+
gridMinor?: string | undefined;
|
|
264
|
+
crosshairLine?: string | undefined;
|
|
265
|
+
crosshairLabelBg?: string | undefined;
|
|
266
|
+
crosshairLabelText?: string | undefined;
|
|
267
|
+
selectionFill?: string | undefined;
|
|
268
|
+
selectionStroke?: string | undefined;
|
|
269
|
+
tooltipBg?: string | undefined;
|
|
270
|
+
tooltipText?: string | undefined;
|
|
271
|
+
tooltipBorder?: string | undefined;
|
|
272
|
+
volumeProfilePoc?: string | undefined;
|
|
273
|
+
footprintAsk?: string | undefined;
|
|
274
|
+
footprintBid?: string | undefined;
|
|
275
|
+
footprintImbalance?: string | undefined;
|
|
276
|
+
alertActive?: string | undefined;
|
|
277
|
+
alertTriggered?: string | undefined;
|
|
278
|
+
alertMuted?: string | undefined;
|
|
279
|
+
avwapLine?: string | undefined;
|
|
280
|
+
avwapBand?: string | undefined;
|
|
281
|
+
mtfOverlay?: string | undefined;
|
|
282
|
+
} | undefined;
|
|
283
|
+
dark?: {
|
|
284
|
+
background?: string | undefined;
|
|
285
|
+
foreground?: string | undefined;
|
|
286
|
+
chartBackground?: string | undefined;
|
|
287
|
+
candleUpBody?: string | undefined;
|
|
288
|
+
candleUpBorder?: string | undefined;
|
|
289
|
+
candleUpWick?: string | undefined;
|
|
290
|
+
candleDownBody?: string | undefined;
|
|
291
|
+
candleDownBorder?: string | undefined;
|
|
292
|
+
candleDownWick?: string | undefined;
|
|
293
|
+
volumeUp?: string | undefined;
|
|
294
|
+
volumeDown?: string | undefined;
|
|
295
|
+
axisText?: string | undefined;
|
|
296
|
+
axisLine?: string | undefined;
|
|
297
|
+
axisTick?: string | undefined;
|
|
298
|
+
gridMajor?: string | undefined;
|
|
299
|
+
gridMinor?: string | undefined;
|
|
300
|
+
crosshairLine?: string | undefined;
|
|
301
|
+
crosshairLabelBg?: string | undefined;
|
|
302
|
+
crosshairLabelText?: string | undefined;
|
|
303
|
+
selectionFill?: string | undefined;
|
|
304
|
+
selectionStroke?: string | undefined;
|
|
305
|
+
tooltipBg?: string | undefined;
|
|
306
|
+
tooltipText?: string | undefined;
|
|
307
|
+
tooltipBorder?: string | undefined;
|
|
308
|
+
volumeProfilePoc?: string | undefined;
|
|
309
|
+
footprintAsk?: string | undefined;
|
|
310
|
+
footprintBid?: string | undefined;
|
|
311
|
+
footprintImbalance?: string | undefined;
|
|
312
|
+
alertActive?: string | undefined;
|
|
313
|
+
alertTriggered?: string | undefined;
|
|
314
|
+
alertMuted?: string | undefined;
|
|
315
|
+
avwapLine?: string | undefined;
|
|
316
|
+
avwapBand?: string | undefined;
|
|
317
|
+
mtfOverlay?: string | undefined;
|
|
318
|
+
} | undefined;
|
|
319
|
+
} | undefined;
|
|
320
|
+
}>;
|
|
321
|
+
tooltipColors: import('vue').ComputedRef<{
|
|
322
|
+
upColor: string;
|
|
323
|
+
downColor: string;
|
|
324
|
+
}>;
|
|
325
|
+
themeCssVars: import('vue').ComputedRef<Record<string, string>>;
|
|
326
|
+
handleSettingsChange: (settings: ChartSettings) => void;
|
|
327
|
+
applyThemeFromSettings: (themeSetting: string | undefined) => void;
|
|
328
|
+
};
|
|
329
|
+
//# sourceMappingURL=useChartTheme.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useChartTheme.d.ts","sourceRoot":"","sources":["../../../src/composables/chart/useChartTheme.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,KAAK,CAAA;AAQ9B,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,sCAAsC,CAAA;AACzE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,2CAA2C,CAAA;AAEhF,wBAAgB,aAAa,CAAC,IAAI,EAAE,GAAG,CAAC,eAAe,GAAG,IAAI,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qCAiDrB,aAAa;2CAnBP,MAAM,GAAG,SAAS;EAsCjE"}
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
import { Ref } from 'vue';
|
|
2
|
+
import { DrawingInteractionController, ChartController } from '@363045841yyt/klinechart-core/controllers';
|
|
3
|
+
import { DrawingObject, DrawingStyle } from '@363045841yyt/klinechart-core/plugin';
|
|
4
|
+
export declare function useDrawingManager(ctrl: Ref<ChartController | null>): {
|
|
5
|
+
drawingController: import('vue').ShallowRef<DrawingInteractionController | null, DrawingInteractionController | null>;
|
|
6
|
+
selectedDrawingId: Ref<string | null, string | null>;
|
|
7
|
+
selectedDrawing: import('vue').ComputedRef<{
|
|
8
|
+
id: string;
|
|
9
|
+
kind: import('@363045841yyt/klinechart-core/plugin').DrawingKind;
|
|
10
|
+
paneId: string;
|
|
11
|
+
visible: boolean;
|
|
12
|
+
locked?: boolean | undefined;
|
|
13
|
+
zIndex?: number | undefined;
|
|
14
|
+
anchors: {
|
|
15
|
+
id: string;
|
|
16
|
+
index: number;
|
|
17
|
+
time?: number | string | undefined;
|
|
18
|
+
price: number;
|
|
19
|
+
}[];
|
|
20
|
+
params: Record<string, unknown>;
|
|
21
|
+
style: {
|
|
22
|
+
stroke?: string | undefined;
|
|
23
|
+
strokeWidth?: number | undefined;
|
|
24
|
+
strokeStyle?: "solid" | "dashed" | "dotted" | undefined;
|
|
25
|
+
fill?: string | undefined;
|
|
26
|
+
fillOpacity?: number | undefined;
|
|
27
|
+
pointRadius?: number | undefined;
|
|
28
|
+
textColor?: string | undefined;
|
|
29
|
+
fontSize?: number | undefined;
|
|
30
|
+
};
|
|
31
|
+
} | null>;
|
|
32
|
+
drawings: Ref<{
|
|
33
|
+
id: string;
|
|
34
|
+
kind: import('@363045841yyt/klinechart-core/plugin').DrawingKind;
|
|
35
|
+
paneId: string;
|
|
36
|
+
visible: boolean;
|
|
37
|
+
locked?: boolean | undefined;
|
|
38
|
+
zIndex?: number | undefined;
|
|
39
|
+
anchors: {
|
|
40
|
+
id: string;
|
|
41
|
+
index: number;
|
|
42
|
+
time?: number | string | undefined;
|
|
43
|
+
price: number;
|
|
44
|
+
}[];
|
|
45
|
+
params: Record<string, unknown>;
|
|
46
|
+
style: {
|
|
47
|
+
stroke?: string | undefined;
|
|
48
|
+
strokeWidth?: number | undefined;
|
|
49
|
+
strokeStyle?: "solid" | "dashed" | "dotted" | undefined;
|
|
50
|
+
fill?: string | undefined;
|
|
51
|
+
fillOpacity?: number | undefined;
|
|
52
|
+
pointRadius?: number | undefined;
|
|
53
|
+
textColor?: string | undefined;
|
|
54
|
+
fontSize?: number | undefined;
|
|
55
|
+
};
|
|
56
|
+
}[], DrawingObject[] | {
|
|
57
|
+
id: string;
|
|
58
|
+
kind: import('@363045841yyt/klinechart-core/plugin').DrawingKind;
|
|
59
|
+
paneId: string;
|
|
60
|
+
visible: boolean;
|
|
61
|
+
locked?: boolean | undefined;
|
|
62
|
+
zIndex?: number | undefined;
|
|
63
|
+
anchors: {
|
|
64
|
+
id: string;
|
|
65
|
+
index: number;
|
|
66
|
+
time?: number | string | undefined;
|
|
67
|
+
price: number;
|
|
68
|
+
}[];
|
|
69
|
+
params: Record<string, unknown>;
|
|
70
|
+
style: {
|
|
71
|
+
stroke?: string | undefined;
|
|
72
|
+
strokeWidth?: number | undefined;
|
|
73
|
+
strokeStyle?: "solid" | "dashed" | "dotted" | undefined;
|
|
74
|
+
fill?: string | undefined;
|
|
75
|
+
fillOpacity?: number | undefined;
|
|
76
|
+
pointRadius?: number | undefined;
|
|
77
|
+
textColor?: string | undefined;
|
|
78
|
+
fontSize?: number | undefined;
|
|
79
|
+
};
|
|
80
|
+
}[]>;
|
|
81
|
+
handleSelectTool: (toolId: string) => void;
|
|
82
|
+
onUpdateDrawingStyle: (style: Partial<DrawingStyle>) => void;
|
|
83
|
+
onDeleteDrawing: () => void;
|
|
84
|
+
setupDrawing: (chartCtrl: ChartController) => void;
|
|
85
|
+
};
|
|
86
|
+
//# sourceMappingURL=useDrawingManager.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useDrawingManager.d.ts","sourceRoot":"","sources":["../../../src/composables/chart/useDrawingManager.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EAA6B,KAAK,GAAG,EAAE,MAAM,KAAK,CAAA;AACzD,OAAO,EACL,4BAA4B,EAC5B,KAAK,eAAe,EAErB,MAAM,2CAA2C,CAAA;AAClD,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAA;AAEvF,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,GAAG,CAAC,eAAe,GAAG,IAAI,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;+BAU/B,MAAM;kCAIH,OAAO,CAAC,YAAY,CAAC;;8BAczB,eAAe,KAAG,IAAI;EAwBxD"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { Ref } from 'vue';
|
|
2
|
+
import { ChartController, PaneSpec, SubIndicatorType } from '@363045841yyt/klinechart-core/controllers';
|
|
3
|
+
import { SemanticChartConfig } from '@363045841yyt/klinechart-core/semantic';
|
|
4
|
+
interface SubPaneSlot {
|
|
5
|
+
id: string;
|
|
6
|
+
indicatorId: SubIndicatorType;
|
|
7
|
+
params: Record<string, unknown>;
|
|
8
|
+
}
|
|
9
|
+
export declare function useIndicatorManager(ctrl: Ref<ChartController | null>, paneRatiosRef: Ref<Record<string, number>>): {
|
|
10
|
+
mainActiveIndicators: Ref<string[], string[]>;
|
|
11
|
+
subActiveIndicators: import('vue').ComputedRef<string[]>;
|
|
12
|
+
activeIndicators: import('vue').ComputedRef<string[]>;
|
|
13
|
+
indicatorParams: Ref<Record<string, Record<string, unknown>>, Record<string, Record<string, unknown>>>;
|
|
14
|
+
subPanes: Ref<{
|
|
15
|
+
id: string;
|
|
16
|
+
indicatorId: SubIndicatorType;
|
|
17
|
+
params: Record<string, unknown>;
|
|
18
|
+
}[], SubPaneSlot[] | {
|
|
19
|
+
id: string;
|
|
20
|
+
indicatorId: SubIndicatorType;
|
|
21
|
+
params: Record<string, unknown>;
|
|
22
|
+
}[]>;
|
|
23
|
+
maxSubPanes: number;
|
|
24
|
+
buildPaneLayoutIntent: () => PaneSpec[];
|
|
25
|
+
getDefaultParams: (indicatorId: SubIndicatorType) => Record<string, number | boolean | string>;
|
|
26
|
+
isSubPaneIndicator: (id: string) => boolean;
|
|
27
|
+
addSubPane: (indicatorId?: SubIndicatorType, params?: Record<string, number | boolean | string>) => boolean;
|
|
28
|
+
removeSubPane: (paneId: string) => void;
|
|
29
|
+
clearAllSubPanes: () => void;
|
|
30
|
+
initIndicatorsFromConfig: (semanticConfig?: SemanticChartConfig) => void;
|
|
31
|
+
switchSubIndicator: (paneId: string, newIndicatorId: SubIndicatorType) => void;
|
|
32
|
+
handleIndicatorToggle: (indicatorId: string, active: boolean) => void;
|
|
33
|
+
handleUpdateParams: (indicatorId: string, params: Record<string, unknown>) => void;
|
|
34
|
+
handleReorderSubIndicators: (orderedIndicatorIds: string[]) => void;
|
|
35
|
+
setupIndicatorSubscriptions: (chartCtrl: ChartController) => () => void;
|
|
36
|
+
};
|
|
37
|
+
export {};
|
|
38
|
+
//# sourceMappingURL=useIndicatorManager.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useIndicatorManager.d.ts","sourceRoot":"","sources":["../../../src/composables/chart/useIndicatorManager.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EAAiB,KAAK,GAAG,EAAE,MAAM,KAAK,CAAA;AAC7C,OAAO,KAAK,EACV,eAAe,EACf,QAAQ,EAER,gBAAgB,EACjB,MAAM,2CAA2C,CAAA;AAElD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,wCAAwC,CAAA;AAEjF,UAAU,WAAW;IACnB,EAAE,EAAE,MAAM,CAAA;IACV,WAAW,EAAE,gBAAgB,CAAA;IAC7B,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;CAChC;AAED,wBAAgB,mBAAmB,CACjC,IAAI,EAAE,GAAG,CAAC,eAAe,GAAG,IAAI,CAAC,EACjC,aAAa,EAAE,GAAG,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;;;;;;YAPtC,MAAM;qBACG,gBAAgB;gBACrB,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;YAF3B,MAAM;qBACG,gBAAgB;gBACrB,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;;iCAgCG,QAAQ,EAAE;oCAgB7B,gBAAgB,KAC5B,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,GAAG,MAAM,CAAC;6BASZ,MAAM,KAAG,OAAO;+BAOjC,gBAAgB,WACpB,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,GAAG,MAAM,CAAC,KACjD,OAAO;4BAYqB,MAAM,KAAG,IAAI;4BAIf,IAAI;gDAMkB,mBAAmB,KAAG,IAAI;iCAmBzC,MAAM,kBAAkB,gBAAgB,KAAG,IAAI;yCAKvC,MAAM,UAAU,OAAO;sCAoC1B,MAAM,UAAU,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;sDAmBvB,MAAM,EAAE;6CAuCjB,eAAe,KAAG,MAAM,IAAI;EAgF7E"}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { Ref, ComputedRef } from 'vue';
|
|
2
|
+
import { ChartController, DataFetcher } from '@363045841yyt/klinechart-core/controllers';
|
|
3
|
+
import { Bounds } from '../../tools/calcRangeOverlayPixel';
|
|
4
|
+
interface RangeSelectionState {
|
|
5
|
+
startTimestamp: number | null;
|
|
6
|
+
endTimestamp: number | null;
|
|
7
|
+
isDragging: boolean;
|
|
8
|
+
}
|
|
9
|
+
export declare function useRangeSelection(options: {
|
|
10
|
+
controller: Ref<ChartController | null>;
|
|
11
|
+
activeToolId: Ref<string>;
|
|
12
|
+
containerRef: Ref<HTMLElement | null>;
|
|
13
|
+
dataVersion: Ref<number>;
|
|
14
|
+
viewportVersion: Ref<number>;
|
|
15
|
+
dataFetcher: Ref<DataFetcher | null>;
|
|
16
|
+
batchStockCodes: Ref<string[]>;
|
|
17
|
+
}): {
|
|
18
|
+
rangeSelection: Ref<{
|
|
19
|
+
startTimestamp: number | null;
|
|
20
|
+
endTimestamp: number | null;
|
|
21
|
+
isDragging: boolean;
|
|
22
|
+
}, RangeSelectionState | {
|
|
23
|
+
startTimestamp: number | null;
|
|
24
|
+
endTimestamp: number | null;
|
|
25
|
+
isDragging: boolean;
|
|
26
|
+
}>;
|
|
27
|
+
customStartDate: Ref<string, string>;
|
|
28
|
+
customEndDate: Ref<string, string>;
|
|
29
|
+
containerScrollLeft: Ref<number, number>;
|
|
30
|
+
isRangeSelectActive: ComputedRef<boolean>;
|
|
31
|
+
rangeSelectionReady: ComputedRef<boolean>;
|
|
32
|
+
rangeSelectionBounds: ComputedRef<Bounds | null>;
|
|
33
|
+
rangeSelectionCount: ComputedRef<number>;
|
|
34
|
+
rangeSelectionStartLabel: ComputedRef<string>;
|
|
35
|
+
rangeSelectionEndLabel: ComputedRef<string>;
|
|
36
|
+
rangeSelectionOverlayStyle: ComputedRef<{
|
|
37
|
+
left: string;
|
|
38
|
+
width: string;
|
|
39
|
+
height: string;
|
|
40
|
+
} | null>;
|
|
41
|
+
clearRangeSelection: () => void;
|
|
42
|
+
handleRangePointerDown: (e: PointerEvent, container: HTMLElement) => boolean;
|
|
43
|
+
handleRangePointerMove: (e: PointerEvent, container: HTMLElement) => boolean;
|
|
44
|
+
handleRangePointerUp: (e: PointerEvent, container: HTMLElement) => boolean;
|
|
45
|
+
exportRangeToCsv: () => Promise<void>;
|
|
46
|
+
exportingProgress: Ref<{
|
|
47
|
+
current: number;
|
|
48
|
+
total: number;
|
|
49
|
+
label: string;
|
|
50
|
+
} | null, {
|
|
51
|
+
current: number;
|
|
52
|
+
total: number;
|
|
53
|
+
label: string;
|
|
54
|
+
} | {
|
|
55
|
+
current: number;
|
|
56
|
+
total: number;
|
|
57
|
+
label: string;
|
|
58
|
+
} | null>;
|
|
59
|
+
onEdgePointerDown: (side: "left" | "right", e: PointerEvent) => void;
|
|
60
|
+
onEdgePointerMove: (e: PointerEvent) => void;
|
|
61
|
+
onEdgePointerUp: (e: PointerEvent) => void;
|
|
62
|
+
onScroll: () => void;
|
|
63
|
+
syncScrollLeft: () => void;
|
|
64
|
+
};
|
|
65
|
+
export {};
|
|
66
|
+
//# sourceMappingURL=useRangeSelection.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useRangeSelection.d.ts","sourceRoot":"","sources":["../../../src/composables/chart/useRangeSelection.ts"],"names":[],"mappings":"AAAA,OAAO,EAAwB,KAAK,GAAG,EAAE,KAAK,WAAW,EAAE,MAAM,KAAK,CAAA;AAEtE,OAAO,KAAK,EAAa,eAAe,EAAE,WAAW,EAAE,MAAM,2CAA2C,CAAA;AAExG,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,mCAAmC,CAAA;AAM/D,UAAU,mBAAmB;IAC3B,cAAc,EAAE,MAAM,GAAG,IAAI,CAAA;IAC7B,YAAY,EAAE,MAAM,GAAG,IAAI,CAAA;IAC3B,UAAU,EAAE,OAAO,CAAA;CACpB;AAsCD,wBAAgB,iBAAiB,CAAC,OAAO,EAAE;IACzC,UAAU,EAAE,GAAG,CAAC,eAAe,GAAG,IAAI,CAAC,CAAA;IACvC,YAAY,EAAE,GAAG,CAAC,MAAM,CAAC,CAAA;IACzB,YAAY,EAAE,GAAG,CAAC,WAAW,GAAG,IAAI,CAAC,CAAA;IACrC,WAAW,EAAE,GAAG,CAAC,MAAM,CAAC,CAAA;IACxB,eAAe,EAAE,GAAG,CAAC,MAAM,CAAC,CAAA;IAC5B,WAAW,EAAE,GAAG,CAAC,WAAW,GAAG,IAAI,CAAC,CAAA;IACpC,eAAe,EAAE,GAAG,CAAC,MAAM,EAAE,CAAC,CAAA;CAC/B;;wBAjDiB,MAAM,GAAG,IAAI;sBACf,MAAM,GAAG,IAAI;oBACf,OAAO;;wBAFH,MAAM,GAAG,IAAI;sBACf,MAAM,GAAG,IAAI;oBACf,OAAO;;;;;;;;;;;;;;;;;gCA+JgB,YAAY,aAAa,WAAW,KAAG,OAAO;gCAwB9C,YAAY,aAAa,WAAW,KAAG,OAAO;8BAchD,YAAY,aAAa,WAAW,KAAG,OAAO;;;iBA/ItC,MAAM;eAAS,MAAM;eAAS,MAAM;;iBAApC,MAAM;eAAS,MAAM;eAAS,MAAM;;iBAApC,MAAM;eAAS,MAAM;eAAS,MAAM;;8BAsK5C,MAAM,GAAG,OAAO,KAAK,YAAY;2BAQpC,YAAY;yBA0Cd,YAAY;;;EA4IzC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Ref } from 'vue';
|
|
2
|
+
export declare function useTeleportedPopup(triggerRef: Ref<HTMLElement | null>, popupRef: Ref<HTMLElement | null>, gap?: number): {
|
|
3
|
+
popupStyle: Ref<Record<string, string>, Record<string, string>>;
|
|
4
|
+
updatePosition: () => void;
|
|
5
|
+
startPositionSync: () => void;
|
|
6
|
+
stopPositionSync: () => void;
|
|
7
|
+
};
|
|
8
|
+
//# sourceMappingURL=useTeleportedPopup.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useTeleportedPopup.d.ts","sourceRoot":"","sources":["../../src/composables/useTeleportedPopup.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiB,KAAK,GAAG,EAAE,MAAM,KAAK,CAAA;AAE7C,wBAAgB,kBAAkB,CAChC,UAAU,EAAE,GAAG,CAAC,WAAW,GAAG,IAAI,CAAC,EACnC,QAAQ,EAAE,GAAG,CAAC,WAAW,GAAG,IAAI,CAAC,EACjC,GAAG,SAAI;;;;;EAwCR"}
|