RainbowThemeContainer = ({ theme, children }) => {
    const [normalizedTheme, setTheme] = useState(() => normalizeTheme(theme));

    useEffect(() => {
        setTheme(normalizeTheme(theme));
    }, [theme]);

    return <ThemeProvider theme={normalizedTheme}>{children}</ThemeProvider>;
}
RainbowThemeContainer allows to overwrite the theme for specific parts of your tree.