fixed theme change and loading issues