Currently, I am working on implementing a remote styling feature. I have been unable to figure out how to modify the colorPrimary
value after the activity has been created and the remote style is fetched through the API. While I understand that theme styling is typically immutable, I am hopeful that there might be a way to instruct all Material components, status bar, and menu bar to adopt specific colors once they are ready for use. Any suggestions?
Below is my theme code for reference:
<style name="OrderingTheme" parent="@style/Theme.MaterialComponents.Light.NoActionBar">
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorAccent">@color/colorPrimary</item>
</style>
Thank you!