The indicator is for a strategy I saw on YouTube. Check the link below to know the conditions and setup. I also added a threshold to exclude doji candles from signals, but you can adjust it to your liking.
Updated conditions for a bearish reversal, where the high is higher than or equal to the previous high, and for a bullish reversal, where the low is lower than or equal to the previous low.