Theme properties

Theme properties

This question is answered

In Telligent Community 6.x, is it possible to expose custom theme properties to group owners like you could in Telligent Community 5.6? On a related note, I noticed that 6.x themes still use references to ${theme:widgetspacing} in the Custom Styles CSS. Where are these substitution values set and are they modifiable?

Verified Answer
  • There are a few ways to do this that I can thing of:

    1.  Just as you've done, expose a widget with an extended attribute that allows each group to define their color scheme and use this value to insert necessary markup (I would expect custom CSS) based on the selection.

    2.  Distribute the color variant CSS files and allow group owners to add the custom style sheet via the group's theme configuration page.

    3.  Create a single widget that is a locked part of the group theme's header that exposes configuration enabling the selection of color options and adds the appropriate headers/etc as its implementation (but otherwise has nothing to render).  

All Replies
  • Maybe I should just say what I really want to do. Smile

    We are using Telligent Community as the foundation for 24 separate school "websites". We want to build a single, custom theme for all of these sites that includes different color choices for each school based on the school's colors. Each school website may be comprised of several nested groups to control ownership of different content areas. 

    The best solution I've come up with is to use extended attributes to identify the color variant that each group should use and then rely on custom header/footer widgets that read the extended attribute and creates a classed DIV wrapper around the page content. Relying on two separate widgets to wrap the content feels a little kludgy, but it inserts the desired markup server-side instead of relying on client-side DOM modifications. Is there a better way to achieve what we are trying to do?

  • There are a few ways to do this that I can thing of:

    1.  Just as you've done, expose a widget with an extended attribute that allows each group to define their color scheme and use this value to insert necessary markup (I would expect custom CSS) based on the selection.

    2.  Distribute the color variant CSS files and allow group owners to add the custom style sheet via the group's theme configuration page.

    3.  Create a single widget that is a locked part of the group theme's header that exposes configuration enabling the selection of color options and adds the appropriate headers/etc as its implementation (but otherwise has nothing to render).  

  • Thanks, Ben! I really appreciate you taking the time to outline some different approaches.

    After reading your suggestions, I think we'll use a widget to add a CSS link to the page header if the group has a "style variant" extended property. I'll also add a background job to periodically traverse each school group hierarchy and apply the appropriate extended property to any new sub-groups that pass validation and do not already have a styling property set. This will allow us to centrally revise stylesheets whenever we wish without relying on our group owners to perform the updates—most of them are teachers doing this work on the side.