This commit adds a method that returns map of CSS variables and their values defined based on the theme.json
It is a preparation step for a postprocessor that will use this map to replace variables with values in final HTML.
There are many clients that don't support CSS variables
[MAILPOET-5918]
After we updated the oldest supported WP and PHP versions, we don't need this theme anymore.
When I checked recent builds, I notice we are getting:
Error: The 'twentynineteen' theme could not be found.
So it already works for some time without the theme being activated.
[MAILPOET-5925]
I want to avoid the SettingsController becoming some kind of a god class
so in this step, I extracted themejson-related stuff to an extra class.
In the future, we should also move methods for manipulating CSS to a helper.
[MAILPOET-5741]