Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

default font in SS admin is 1pt smaller than on published site?


Go to End


7 Posts   1540 Views

Avatar
TF-35Lightning

Community Member, 137 Posts

24 March 2010 at 8:18pm

Hi all,

I am just wondering how do I get the type shown in the admin (content area) to be the exct same size as what is shown in the published live website?

In my default untouched installation of SS my admin (content) font is clearly 1pt smaller than what is published on the live site.

Any help would be great

Avatar
baba-papa

Community Member, 279 Posts

24 March 2010 at 10:31pm

I can´t give you the kind of answer that you expected.
The frontend design is not in the hands of the content manager but the designer responibility. The designer makes desicions about colors, fonts, image sizes, font sizes. If you leave a sites layout to a content manager the site will soon look like a word document with 10 different fonts.

Avatar
TF-35Lightning

Community Member, 137 Posts

25 March 2010 at 12:37pm

baba-papa thanks but thats no help really.

Can anyone else tell me he reasons why their is a difference or tell me the type classes I need to invistigate / change in CSS.

Avatar
Chris Hope

Community Member, 18 Posts

25 March 2010 at 2:01pm

Edited: 25/03/2010 2:02pm

@baba-papa That's not actually what was asked. What was asked was how to make the fonts in the CMS editor the same as what's in the website. The answer is to look at the typography.css and editor.css files. There are rules in there that can be set to make the content in the CMS HTML editor look like the front end.

Avatar
TF-35Lightning

Community Member, 137 Posts

25 March 2010 at 2:39pm

yeah I'm in the tutorial theme which my site SS site is currently set to trying to alter the text there but I'm not having much luck.

Anyone know the exact classes I would need to modify, I'm chaning things left and right but arent getting much luck.

I'm in the themes\tutorial\css

changing typography.css file etc

Avatar
Chris Hope

Community Member, 18 Posts

25 March 2010 at 2:42pm

The default editor.css file looks like this in the tutorial theme:

@import "typography.css";

body.mceContentBody {
min-height: 200px;
font-size: 62.5%;
}
body.mceContentBody a.broken {
background-color: #FF7B71;
border: 1px red solid;
}

The typography.css file then sets a whole bunch of other stuff. Set your rules in these two files based on what's in your frontend CSS file(s) making sure to prefix the rules with .typography (e.g. .typography h1 { rules }) to make it work. At least that's how it worked for me.

Avatar
bummzack

Community Member, 904 Posts

25 March 2010 at 7:56pm

If your styles from typography.css aren't carried over to the backend, it's most likely a Bug that's been unresolved for some time now. For a workaround, please read here:
http://silverstripe.org/themes-2/show/278592?start=0#post278606