From 11c1310f490d316d5c9313ebc4d792ec8cf5c365 Mon Sep 17 00:00:00 2001 From: rob Date: Sun, 8 Mar 2026 13:33:43 -0300 Subject: [PATCH] Register all 61 candlestick patterns in frontend indicatorMap The new patterns were only added to the backend (indicators.py) but not registered in the frontend (indicators.js), causing "Unknown indicator type" errors when trying to display them on charts. Co-Authored-By: Claude Opus 4.5 --- src/static/indicators.js | 51 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) diff --git a/src/static/indicators.js b/src/static/indicators.js index 2e18e89..6b1c2ad 100644 --- a/src/static/indicators.js +++ b/src/static/indicators.js @@ -633,21 +633,72 @@ class CandlestickPattern extends Indicator { } // Register all candlestick pattern types to use the same CandlestickPattern class +// Single candle patterns indicatorMap.set("CDL_DOJI", CandlestickPattern); indicatorMap.set("CDL_HAMMER", CandlestickPattern); indicatorMap.set("CDL_INVERTEDHAMMER", CandlestickPattern); indicatorMap.set("CDL_SHOOTINGSTAR", CandlestickPattern); indicatorMap.set("CDL_SPINNINGTOP", CandlestickPattern); indicatorMap.set("CDL_MARUBOZU", CandlestickPattern); +indicatorMap.set("CDL_DRAGONFLYDOJI", CandlestickPattern); +indicatorMap.set("CDL_GRAVESTONEDOJI", CandlestickPattern); +indicatorMap.set("CDL_HANGINGMAN", CandlestickPattern); +indicatorMap.set("CDL_HIGHWAVE", CandlestickPattern); +indicatorMap.set("CDL_LONGLEGGEDDOJI", CandlestickPattern); +indicatorMap.set("CDL_LONGLINE", CandlestickPattern); +indicatorMap.set("CDL_SHORTLINE", CandlestickPattern); +indicatorMap.set("CDL_RICKSHAWMAN", CandlestickPattern); +indicatorMap.set("CDL_TAKURI", CandlestickPattern); +indicatorMap.set("CDL_BELTHOLD", CandlestickPattern); +indicatorMap.set("CDL_CLOSINGMARUBOZU", CandlestickPattern); + +// Two candle patterns indicatorMap.set("CDL_ENGULFING", CandlestickPattern); indicatorMap.set("CDL_HARAMI", CandlestickPattern); +indicatorMap.set("CDL_HARAMICROSS", CandlestickPattern); indicatorMap.set("CDL_PIERCING", CandlestickPattern); indicatorMap.set("CDL_DARKCLOUDCOVER", CandlestickPattern); +indicatorMap.set("CDL_COUNTERATTACK", CandlestickPattern); +indicatorMap.set("CDL_DOJISTAR", CandlestickPattern); +indicatorMap.set("CDL_HOMINGPIGEON", CandlestickPattern); +indicatorMap.set("CDL_KICKING", CandlestickPattern); +indicatorMap.set("CDL_KICKINGBYLENGTH", CandlestickPattern); +indicatorMap.set("CDL_MATCHINGLOW", CandlestickPattern); +indicatorMap.set("CDL_INNECK", CandlestickPattern); +indicatorMap.set("CDL_ONNECK", CandlestickPattern); +indicatorMap.set("CDL_THRUSTING", CandlestickPattern); +indicatorMap.set("CDL_SEPARATINGLINES", CandlestickPattern); +indicatorMap.set("CDL_STICKSANDWICH", CandlestickPattern); +indicatorMap.set("CDL_GAPSIDESIDEWHITE", CandlestickPattern); +indicatorMap.set("CDL_2CROWS", CandlestickPattern); + +// Three+ candle patterns indicatorMap.set("CDL_MORNINGSTAR", CandlestickPattern); indicatorMap.set("CDL_EVENINGSTAR", CandlestickPattern); +indicatorMap.set("CDL_MORNINGDOJISTAR", CandlestickPattern); +indicatorMap.set("CDL_EVENINGDOJISTAR", CandlestickPattern); indicatorMap.set("CDL_3WHITESOLDIERS", CandlestickPattern); indicatorMap.set("CDL_3BLACKCROWS", CandlestickPattern); indicatorMap.set("CDL_3INSIDE", CandlestickPattern); +indicatorMap.set("CDL_3OUTSIDE", CandlestickPattern); +indicatorMap.set("CDL_3LINESTRIKE", CandlestickPattern); +indicatorMap.set("CDL_3STARSINSOUTH", CandlestickPattern); +indicatorMap.set("CDL_ABANDONEDBABY", CandlestickPattern); +indicatorMap.set("CDL_ADVANCEBLOCK", CandlestickPattern); +indicatorMap.set("CDL_BREAKAWAY", CandlestickPattern); +indicatorMap.set("CDL_CONCEALBABYSWALL", CandlestickPattern); +indicatorMap.set("CDL_IDENTICAL3CROWS", CandlestickPattern); +indicatorMap.set("CDL_LADDERBOTTOM", CandlestickPattern); +indicatorMap.set("CDL_MATHOLD", CandlestickPattern); +indicatorMap.set("CDL_RISEFALL3METHODS", CandlestickPattern); +indicatorMap.set("CDL_STALLEDPATTERN", CandlestickPattern); +indicatorMap.set("CDL_TASUKIGAP", CandlestickPattern); +indicatorMap.set("CDL_TRISTAR", CandlestickPattern); +indicatorMap.set("CDL_UNIQUE3RIVER", CandlestickPattern); +indicatorMap.set("CDL_UPSIDEGAP2CROWS", CandlestickPattern); +indicatorMap.set("CDL_XSIDEGAP3METHODS", CandlestickPattern); +indicatorMap.set("CDL_HIKKAKE", CandlestickPattern); +indicatorMap.set("CDL_HIKKAKEMOD", CandlestickPattern); class Indicators {