With new 'text/layout', no classes are available
A new 'Text/layout' plugin instance has not been saved to the database. This means there is no link to the 'page', and hence it is impossible to know what template to use. This means that it ends up making a call to:
which returns an empty list of styles.
It is difficult to get the information about the template through to the place it is needed in the server side code, because the plugin form is created in a completely different request to the main page.