Closed (fixed)
Project:
Sweaver
Version:
7.x-1.1
Component:
Documentation
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
3 Apr 2011 at 00:18 UTC
Updated:
18 Jun 2011 at 20:11 UTC
I'd love to see more documentation on theme styles. I'm not exactly clear on how to use or write them. Even an example of one and how to implement it would be helpful. Can you provide something like that?
Comments
Comment #1
mattsmith3 commentedIt's been over a month since I asked for help here.. about 6 weeks in fact. Can I get some assistance?
Comment #2
jyve commentedHi, sorry for the delay.
This is how the theme styles plugin works:
1. Go to Configuration > Sweaver > Theme styles and add 'mystyles' in the list.
2. Go to your .info file of your theme and add the styles that you want to target. Example:
mystyles[style1][label] = Blocks
mystyles[style1][class] = block
In this example, 'mystyles' is picked up because we added it to the list in step 1. The label will be shown in the Sweaver frontend, and the class is an actual css class.
3. Clear your cache for the .info file changes to be picked up.
4. Go to your site and click on the 'Theme styles' tab. You should see 'Blocks'. If you click on it, all elements with the class '.block' will be highlighted, and you will be able to theme them directly.
So in short: by defining theme styles, you could prepare some styles (classes) that you use throughout your theme, and can then easily acces them from the 'Theme styles' tab. This approach was used as a kind of integration with Skinr, since Skinr addes classes to elements.