Improve chart trade overlays and paper fill markers.
Deploy / lint (push) Successful in 9s
Deploy / test (push) Successful in 1m12s
Deploy / deploy (push) Successful in 39s

De-clutter setup labels (left roles, right prices; hide Entry near Now; S/R in-plot), and draw green/red arrows for paper trade entry and exit on the matching sessions.
This commit is contained in:
2026-07-14 10:44:56 +02:00
parent 8db535b889
commit d5b0ebf895
2 changed files with 240 additions and 49 deletions
+18
View File
@@ -145,12 +145,21 @@ export default function TickerDetailPage() {
// Status labels: is there an open paper trade on this ticker, and is it the
// current top pick (same ranking the dashboard highlights)?
const openTrades = usePaperTrades('open');
// Full history for chart entry/exit arrows (open + closed on this symbol).
const paperTradeHistory = usePaperTrades();
const allTrades = useTrades();
const activation = useActivation();
const hasOpenTrade = useMemo(
() => (openTrades.data ?? []).some((t) => t.symbol.toUpperCase() === symbol.toUpperCase()),
[openTrades.data, symbol],
);
const symbolPaperTrades = useMemo(
() =>
(paperTradeHistory.data ?? []).filter(
(t) => t.symbol.toUpperCase() === symbol.toUpperCase(),
),
[paperTradeHistory.data, symbol],
);
const isTopPick = useMemo(
() => topPickSymbol(allTrades.data, activation.data)?.toUpperCase() === symbol.toUpperCase(),
[allTrades.data, activation.data, symbol],
@@ -456,11 +465,20 @@ export default function TickerDetailPage() {
onShowGateTrafficChange={setShowGateTraffic}
tradeSetup={overlayWithTarget}
currentPrice={priceInfo?.price}
paperTrades={symbolPaperTrades}
/>
<p className="mt-2 text-[11px] text-gray-500">
Only the nearest support &amp; resistance are drawn. Full list in the S/R Levels tab.
{srLevels.isError && ' S/R levels unavailable.'}
{gateTargetLadder.isError && ' GTL diagnostic unavailable.'}
{symbolPaperTrades.length > 0 && (
<>
{' '}
<span className="text-emerald-400/90"></span> paper entry
{' · '}
<span className="text-red-400/90"></span> paper exit
</>
)}
</p>
<ProductionRankStrip
setup={longSetup ?? shortSetup}