lightweight-charts-drawing 0.6.0 → 0.6.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.
- package/CHANGELOG.md +12 -0
- package/dist/index.d.ts +16 -3
- package/dist/lightweight-charts-drawing.es.js +960 -942
- package/dist/lightweight-charts-drawing.es.js.map +1 -1
- package/dist/lightweight-charts-drawing.umd.cjs +7 -7
- package/dist/lightweight-charts-drawing.umd.cjs.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.6.1 (15/10/2026)
|
|
4
|
+
|
|
5
|
+
### Added
|
|
6
|
+
|
|
7
|
+
- `makeCoords(..., getFuture)` (optional 6th argument, `FutureAxis`): bars
|
|
8
|
+
after the last bar on the symbol's trading calendar, given by the host
|
|
9
|
+
(`slots(time, lastTime)`, `time(k, lastTime)`). With it a point placed after
|
|
10
|
+
the last bar takes the open time of its nearest future bar, a future time is
|
|
11
|
+
drawn on the future bar that holds it (`timeToX`, `xToTime`,
|
|
12
|
+
`timeToBarIndex`, `barIndexToTime`, `timeToXFallback`). Without it, calendar
|
|
13
|
+
time with the median bar interval as before.
|
|
14
|
+
|
|
3
15
|
## 0.6.0 (13/10/2026)
|
|
4
16
|
|
|
5
17
|
### Added
|
package/dist/index.d.ts
CHANGED
|
@@ -692,6 +692,16 @@ declare type FourPoint = {
|
|
|
692
692
|
* finalized with a double-click (the spec carries `variableLength: true`). */
|
|
693
693
|
declare type FreehandKind = "polyline" | "path" | "brush" | "highlighter";
|
|
694
694
|
|
|
695
|
+
/** Bars after the last bar on the symbol's trading calendar (the host knows the sessions). The time scale continues
|
|
696
|
+
* after the last bar with the bars the symbol would open: the rest of the session, then the next sessions (nights,
|
|
697
|
+
* weekends and holidays skipped). Times are epoch seconds. */
|
|
698
|
+
declare type FutureAxis = {
|
|
699
|
+
/** Future bars that open after `lastTime` and at or before `time` (0 = still on the last bar). */
|
|
700
|
+
slots: (time: number, lastTime: number) => number;
|
|
701
|
+
/** Open time of the k-th future bar (k >= 1), null past the host's range. */
|
|
702
|
+
time: (k: number, lastTime: number) => number | null;
|
|
703
|
+
};
|
|
704
|
+
|
|
695
705
|
/** One regression trend line (TV study plot style). */
|
|
696
706
|
/** Gann level line (TV levels.N: color, width, visible). */
|
|
697
707
|
declare type GannLine = {
|
|
@@ -817,7 +827,9 @@ export declare function makeCoords(chart: IChartApi, series: ISeriesApi<SeriesTy
|
|
|
817
827
|
getIndicatorValues?: (sec: number | null) => number[], getTimeInfo?: () => {
|
|
818
828
|
timeZone: string;
|
|
819
829
|
intraday: boolean;
|
|
820
|
-
}
|
|
830
|
+
},
|
|
831
|
+
/** Future bars on the trading calendar; null (or absent) = calendar time extrapolated with the bar interval. */
|
|
832
|
+
getFuture?: () => FutureAxis | null): Coords;
|
|
821
833
|
|
|
822
834
|
/** Point-count migration (10/07/2026): several kinds moved to TV's point
|
|
823
835
|
* models. Old saved drawings are padded/synthesized best-effort so they keep
|
|
@@ -1287,8 +1299,9 @@ export declare type TimeAxisLabel = {
|
|
|
1287
1299
|
/** Shared time→x with the off-bar fallback, for non-drawing renderers (event
|
|
1288
1300
|
* markers, etc.) that paint at arbitrary times. Mirrors the `timeToX` method:
|
|
1289
1301
|
* try lightweight-charts' exact mapping first, then the gap-aware logical
|
|
1290
|
-
* interpolation. `sec` is UNIX seconds.
|
|
1291
|
-
|
|
1302
|
+
* interpolation (future bars on `future` when given). `sec` is UNIX seconds.
|
|
1303
|
+
* Returns null with no data. */
|
|
1304
|
+
export declare function timeToXFallback(chart: IChartApi, sec: number, bars: OHLC[], future?: FutureAxis | null): number | null;
|
|
1292
1305
|
|
|
1293
1306
|
/** TV _onAnchoredChange: anchoring stores the current screen point as pane
|
|
1294
1307
|
* fractions; unanchoring turns the fixed point back into a data point (bar
|