DesignKit

Component ID

659700

Component name

DesignKit

Component type

module

Maintenance status

Development status

Component security advisory coverage

not-covered

Downloads

25516

Component created

Component changed

Component body

DesignKit is a small API module lets themes provide options for customizing colors and images. Themes can use entries in their .info file to specify what color variables should be made available. Designkit integrates with the Spaces module to enable distinct color schemes and images per site section or area. Designkit is used with Spaces and Organic Groups in Open Atrium to allow groups to have their own visual identity.

Themes using Designkit

Example theme .info file snippets

Drupal 7

; Background color
designkit[color][background][title] = "Background"
designkit[color][background][description] = "Background color."
designkit[color][background][default] = "#ffffff"              

; Foo bar color
designkit[color][foo][title] = "Foo"
designkit[color][foo][description] = "Foo bar baz."
designkit[color][foo][default] = "#cc0099"

; Site logo
designkit[image][logo][title] = "Site logo"
designkit[image][logo][description] = "Header logo."
designkit[image][logo][effect] = "image_scale:200x50"

; Print logo
designkit[image][logo_print][title] = "Print logo"
designkit[image][logo_print][description] = "Print logo."
designkit[image][logo_print][effect] = "image_scale:600x300"

Drupal 6

; Background color
designkit[color][background][title] = "Background"
designkit[color][background][description] = "Background color."
designkit[color][background][default] = "#ffffff"              

; Foo bar color
designkit[color][foo][title] = "Foo"
designkit[color][foo][description] = "Foo bar baz."
designkit[color][foo][default] = "#cc0099"

; Site logo
designkit[image][logo][title] = "Site logo"
designkit[image][logo][description] = "Header logo."
designkit[image][logo][imagecache] = "imagecache_scale:200x50"

; Print logo
designkit[image][logo_print][title] = "Print logo"
designkit[image][logo_print][description] = "Print logo."
designkit[image][logo_print][imagecache] = "imagecache_scale:600x300"

For more information, please take a look at README.txt.

Requirements

Drupal 7

  • Color module (included in Drupal core)
  • Image module (included in Drupal core)

Drupal 6

Upgrading from Drupal 6

To upgrade your Designkit-based theme from Drupal 6 to Drupal 7:

  • Remove the <style> and </style> from Designkit style templates.
  • In the theme's .info file, change the 'imagecache' property from e.g.
    designkit[image][logo][imagecache] = "imagecache_scale:200x50"
    to
    designkit[image][logo][effect] = "image_scale:200x50"
  • In your Designkit style template, make CSS changes needed for the new Drupal version.