I’m scratching my head with this problem for a while, not sure how to solve it efficiently: I have two sets of off-peak hours for electricity per day in my country (France), it goes from 3h04 to 8h04 then from 12h04 to 15h04.
Do you only want to use this for display purposes?
You could keep these sensors and create a third template binary sensor that’s only off when both these tod sensors are off and otherwise on (fairly easy to do).
Or, you could ditch all of those and make a single trigger-based template sensor that triggers on the time boundaries you have, but will require a lot more logic in the template value field (but not crazy complicated).
A third option is to have an input boolean set with an automation (using the same triggers as in option 2) and wrap the input boolean in a sensor (but this is not strictly needed, since I think you can plot the input boolean directly, depending on which card you’re using).
It looks like you’re using the custom mini graph card, so your boolean values should be converted to 0 and 1.