Don't know if this was the best way, but this is what i did.
I used [ngClass]="setPrimary() on the top most component
this setPrimary function checked the time of the day (https://api.sunrise-sunset.org) and depending upon the hour of night or sunrise/sunset or day it would set the class on this top most component
inside the scss file: i developed 3 different color sets for day, night, sunrise/sunset
on page load, default value was day, but as soon as setPrimary() would place the appropriate class, the rest of the styling will follow it
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…