Add support for a 'Tenant' css Tab in the Theme Style Sheet

By Daniel Kuhlmann on 8 Nov 2017

For multi-tenant applications it would be nice if there would be a tenant override of CSS possible, this would ease the implementation of tenant branding like logo, background, fonts and color usage.

Have you thought about how would a tenant change it? Is the tenant going to open Service Studio and change the CSS, then publish? Wouldn't that overwrite other tenants' styles?

I don't think most tenants would be willing to write CSS themselves - yes, I know it really depends on the application you are building. Wouldn't it be a better idea if you could have a backoffice that the tentant could change the logo and background image, and choose the primary color for your site? You could store those customisations in the database, and use an unescaped expression to inject CSS into your pages.

Daniel Kuhlmann9 Nov 2017

Yes we did implement such a solution where the tenant can chase those parameters, based on this article:

For webapps this works fine, for mobile apps, we don't have this solution working yet.

Daniel Kuhlmann9 Nov 2017

Maybe the real change we would need is that the Theme Style sheet editor could support parameters that are substituted at runtime.

Justin James9 Nov 2017

"Tenants" are run-time data, there is no way for Service Studio to be aware of them at design-time. That said, there are a number of different ways to do this, depending on your needs, and I think that any implementation is going to be too project-specific to build into Service Studio anyways.