-
Notifications
You must be signed in to change notification settings - Fork 0
Customization
QA Reports comes with a default theme that (currently) holds MeeGo things and logos, and thus most users have chosen to customize the style. Now that Rails Asset Pipeline is taken in use the preferred way for customizing is to include your stylesheet into app/assets/stylesheets/application.css. If included the stylesheets are merged into a single stylesheet during deployment which reduces amount of HTTP requests. You should also place images for your theme under app/assets/images/yourtheme and use asset helpers such as asset_path and asset_data_uri instead of image uris in your CSS file.
So your theme could include e.g. files like this:
app |-- assets | |-- images | | |-- yourtheme | | | |-- yourlogo.png | |-- stylesheets | | |-- themes | | | |-- yourtheme.css.erb
Notice the erb extension on the stylesheet -- adding it enables using the asset helpers. Your stylesheet could then look like this:
#logo h3 a {
background-image: url(<%= asset_path 'yourtheme/yourlogo.png' %>);
}asset_path will set the correct path to your logo file. If the logo is smallish you could use asset_data_uri instead and have the image inlined as base64 encoded to your stylesheet and spare yet another HTTP request.
You would then include your theme by adding it to app/assets/stylesheets/application.css:
/* *= require jquery-ui-1.9.1.custom.min *= require jqModal *= require screen *= require themes/yourtheme */
and during next deployment it would be automatically included in the application stylesheet. Notice that the files need to be committed to your version control as well.
There are a few things, like allowing empty files or renaming the app, that can be customized using the config file config/config.yml. See the file for documentation of each feature.