Difference between revisions of "Features/Customized design"

From TempusServa wiki
Jump to navigation Jump to search
(Created page with "== Usage == To customize the look and feel of your platform, you can excert detailed control of all design elements * '''Stylesheets''' defining colors, graphics and fonts * '''Templates (rendering)''' controlling how pages are rendered * '''Wrapper''' controlling the header and footer on all pages * '''Language''' where labels on buttons are set * '''Buttons''' which controls the iconography == Design quickstart == For a most basic functional customer design you can...")
 
 
(10 intermediate revisions by the same user not shown)
Line 6: Line 6:
* '''Wrapper''' controlling the header and footer on all pages
* '''Wrapper''' controlling the header and footer on all pages
* '''Language''' where labels on buttons are set
* '''Language''' where labels on buttons are set
* '''Buttons''' which controls the iconography  
* '''Buttons''' which controls the iconography
 
Note that default design is well tested 100% responsive, so take care not using too many !important or fixed width declarations.


== Design quickstart ==
== Design quickstart ==
Line 14: Line 16:
# Designer > Design > Stylesheet
# Designer > Design > Stylesheet
# Edit values in  
# Edit values in  
#*  
#* themePrimary
#*  
#* themeSecondary
#*  
#* background
# Reload page with CTRL + SHIFT + R
# Reload page with CTRL + SHIFT + R


== Stylesheets ==  
== Stylesheets ==
Styling is written using CSS declarations. The different stylesheets can be used both genericly, for a single entity or a single interface.
 
Th TS stylesheets are modular in the sense, that the can inherit content from each other. All stylesheets can refer a parent stylesheet: The parents styleheets are simply prepended to child styleheet.
 
The TS design is based on Bootstrap 4.1, whos declarations can be used and changed if needed.
 
Colors and most size definitions are set in CSS variables, which which use we strongly encourage. 
 
=== Instructions ===
The following will create a new styesheet and use it on the whole application
# Module > Design > Stylesheet
# Add a new stylesheet
#* Specify parent
#* Insert CSS declarations
#* Note the ID after udate
# Modules > Configuration
# Set defaultStylesheet = ID
 
== Context sensitive styling ==
In some cases your design needs to change according to usecase, user in question or choices made using the application.
 
By default the following CSS classes are added to the page depending on the situation
* Command requested: Ex. editCommand
* Language selected: Ex. daDK, enUK
* User template: Ex. IsAdministrator, IsAnonoumous
 
In addition it is possible to add a CSS class to a group, and then all users in that group will have that class added to their page.
 
== Templates ==
The HTML templates contains tags, that helps the system render correctly. The template can contain bothe generic field markers, and specific ones tied to a single field. The rendering will first look for a specific tag, and if that is not present default to the generic ones. Templates can be shared between multiple entities, or be tied to a single one.
 
Note: When editing templates make sure that they are still WCAG compliant. Ordering of elements and ID markup is important for it to work.
 
 
== Website wrappers ==
Wrapper allow TempusServa installations to wrap itself in content from other sites.
 
You provide an URL for page you want to look like, and the server will download and rewrite the contents in the page. The method is however not flawless, and some sites due to poor design or security restrictions cannot be mimicked at all. Normally the contens will get refreshed on fixed schedule, but in some instances it will be required to do some manual tweaking of the code afterwards.
 
=== Instructions ===
# Add a new Wrapper
# Insert URL of the page
# Insert HTML tag where output should begin
#* Display the source of the page in another browser
#* Note at which tag the dynmaic content starts
#* Optionally provide an end tag to
# Optionally insert extra code before and after the content
# Test the page
# Change the defaultWrapperID in Designer > Modules > Configuration


== Templates and wrappers ==
Troubleshooting tips
* Check stylesheets for local references (TS will only collect the main page)
* Disable any <form> tags in the page

Latest revision as of 13:16, 9 November 2024

Usage

To customize the look and feel of your platform, you can excert detailed control of all design elements

  • Stylesheets defining colors, graphics and fonts
  • Templates (rendering) controlling how pages are rendered
  • Wrapper controlling the header and footer on all pages
  • Language where labels on buttons are set
  • Buttons which controls the iconography

Note that default design is well tested 100% responsive, so take care not using too many !important or fixed width declarations.

Design quickstart

For a most basic functional customer design you can define 3 colors and a URL to a logo.

Instructions

  1. Designer > Design > Stylesheet
  2. Edit values in
    • themePrimary
    • themeSecondary
    • background
  3. Reload page with CTRL + SHIFT + R

Stylesheets

Styling is written using CSS declarations. The different stylesheets can be used both genericly, for a single entity or a single interface.

Th TS stylesheets are modular in the sense, that the can inherit content from each other. All stylesheets can refer a parent stylesheet: The parents styleheets are simply prepended to child styleheet.

The TS design is based on Bootstrap 4.1, whos declarations can be used and changed if needed.

Colors and most size definitions are set in CSS variables, which which use we strongly encourage.

Instructions

The following will create a new styesheet and use it on the whole application

  1. Module > Design > Stylesheet
  2. Add a new stylesheet
    • Specify parent
    • Insert CSS declarations
    • Note the ID after udate
  3. Modules > Configuration
  4. Set defaultStylesheet = ID

Context sensitive styling

In some cases your design needs to change according to usecase, user in question or choices made using the application.

By default the following CSS classes are added to the page depending on the situation

  • Command requested: Ex. editCommand
  • Language selected: Ex. daDK, enUK
  • User template: Ex. IsAdministrator, IsAnonoumous

In addition it is possible to add a CSS class to a group, and then all users in that group will have that class added to their page.

Templates

The HTML templates contains tags, that helps the system render correctly. The template can contain bothe generic field markers, and specific ones tied to a single field. The rendering will first look for a specific tag, and if that is not present default to the generic ones. Templates can be shared between multiple entities, or be tied to a single one.

Note: When editing templates make sure that they are still WCAG compliant. Ordering of elements and ID markup is important for it to work.


Website wrappers

Wrapper allow TempusServa installations to wrap itself in content from other sites.

You provide an URL for page you want to look like, and the server will download and rewrite the contents in the page. The method is however not flawless, and some sites due to poor design or security restrictions cannot be mimicked at all. Normally the contens will get refreshed on fixed schedule, but in some instances it will be required to do some manual tweaking of the code afterwards.

Instructions

  1. Add a new Wrapper
  2. Insert URL of the page
  3. Insert HTML tag where output should begin
    • Display the source of the page in another browser
    • Note at which tag the dynmaic content starts
    • Optionally provide an end tag to
  4. Optionally insert extra code before and after the content
  5. Test the page
  6. Change the defaultWrapperID in Designer > Modules > Configuration

Troubleshooting tips

  • Check stylesheets for local references (TS will only collect the main page)
  • Disable any <form> tags in the page