Hi There -
Have created a local.css file in Acquia Prosper and also in the copy of Acquia Prosper that I really want to modify. Acquia Prosper's local.css file overrides Fusion's typography, but my otherly named copy doesn't. In Firebug it shows that it's being overridden by typography.css.
What am I missing?
Since Sub-sub-theming isn't in the cards, is there a best practice for having a differently named theme?
Most of the issues I'm encountering are naming issues because I'm using a copy and not the original Acquia Prosper. Modifying the original seems to be a Bad Idea, especially since I've come to rely on the pristine copy as a reference, and it just seems Wrong to be modifying something of the same name.
So far, the things I've needed to watch are in the .info file: the skinr styles and the .js file, when I've done a find and replace for the name.
Is there a checklist that I haven't found in the documentation?
Comments
Comment #1
newbstah commentedMake that 6.x-1.0-beta4 instead of dev.
Comment #2
sheena_d commentedHi newbstah,
When you say that firebug shows that local.css is being overridden by typography.css, are you looking at the CSS being applied to a specific HTML element? Your issue may be with CSS specificity.
For example, if the following is written in typography.css:
and you have this in your local.css file:
Then your local.css file's styles will be overridden by typography.css on h2 tags that have the class "title", because the styles in typography.css are more specific than the styles in your local.css file.
You can learn more about CSS specificity here: http://www.smashingmagazine.com/2007/07/27/css-specificity-things-you-sh...
If you do not think this is your problem, it would be very helpful to provide a link to your site so we can take a look at exactly what is going on to override your local.css file.
Thanks!
Sheena
Comment #3
newbstah commentedSheena! Thanks for replying!
Unfortunately, since it's only on my local machine, I cannot share the site with you, but I can be more clear.
When I'm looking at the site title - on the front page, when I'm in Acquia Prosper, the local.css overrides Fusion's typography.css with no problem.
When I'm in my COPY of Acquia Prosper, the IDENTICAL local.css does not override Fusion's typography.css.
The local.css is:
body {
font-family:"Agenda","Gill Sans",sans-serif;
}
The typography.css that overrides in the copy but not the original:
Inherited from body#pid-node.front
.font-family-sans-serif-sm, .font-family-sans-serif-sm .form-text {
font-family:Arial,Helvetica,"Nimbus Sans L",FreeSans,sans-serif;
}
typography.css (line 281)
I literally dragged the identical local.css file from my copy of Acquia Prosper to the original. It works in the original, but not the copy. It's the only CSS I've tried to change so far.
It's reading the local.css file, Firebug shows the CSS as being there, but overridden, so it's linked correctly in the .info file. The only difference is that I'm using the blue theme in my version. As far as I understand, that shouldn't affect it.
Comment #4
sheena_d commentednewbstah,
from the code you posted, it looks like CSS specificity is the issue here.
if you look at the CSS selector being used in the typography.css rule that is overriding your local.css rule, you will see that it is much more specific than the rule written in your local.css file. I am not sure why it is happening in one theme and not the other, there are many potential variables.
Try this: replace your styles for body in local.css with the following code:
Also, be sure to try clearing your site's cache.
If that works, then CSS specificity is your problem.
Comment #5
newbstah commentedWhat are some of these variables that could be causing it to work in the original and not the copy? I know that I'm not the only one who's going to try to work from a copy, since we cannot sub-sub theme. Because the copy's a pretty clean install, I haven't fussed with it beyond doing a find and replace on the .info and relevant filenames and adding a logo, It's a good candidate to figure this out with.
I'm much more concerned with why it isn't working identically in both themes than I am trying to find a workaround. If it's going to behave inconsistently in a duplicated theme, or if it's something that is going to be unsupported, then isn't it best that it's public knowledge, since this is the most common practice when modifying non sub-themable themes?
If you guys have any idea why this is happening, I'm willing to try just about anything to make it work and document it here so someone else doesn't have to go through this time-waster.
Comment #6
sheena_d commentedthe classes that are being applied to the body tag, which are overriding the non-specific CSS in local.css are applied through theme settings.
My best guess is that you did not have a font family specified in your theme settings originally, thus not setting this class and thus not overriding the non-specific CSS. Then, when you created the new sub-sub-theme, either you edited the theme settings to specify a font family, or a default theme setting of some sort set the option, thus providing the new classes on the body tag and overriding the non-specific CSS in local.css. Also, this could be caused by using the blue theme in the sub-sub-theme and not in the original copy of Prosper.
What version of Fusion core are you using?
I am currently trying to reproduce the issue on my local machine, I will let you know what I find.
Comment #7
sheena_d commentednewbstah,
After setting up fresh copies of Acquia Prosper and Fusion on my local machine, copying Prosper and creating a sub-theme that uses the blue skin instead of the gray, and creating identical local.css files in Acquia Prosper and my sub-theme of Prosper, my conclusion is that your theme settings must not have been consistent between Acquia Prosper and the sub-theme you created.
The code that you provided as having been in your local.css file worked fine across both themes when I first created local.css in each theme. After changing theme settings to specify a font family (rather than using the option "theme default), the CSS in local.css was overridden by more-specific CSS in Fusion Core's typography.css file.
Be sure that the settings under "typography" on your theme configuration page are the same for Acquia Prosper and the sub-theme. If the settings are the same, then the CSS should be overridden (or not) consistently.
Thanks,
Sheena
Comment #8
newbstah commentedWow! Sheena!
You are beyond awesome! Will check this out. I cannot tell you how much I appreciate your time on this. I hope others find this thread and find it helpful. Will let you know what happens.
Comment #9
stephthegeek commented