Last active
December 14, 2015 14:19
-
-
Save ollieRogers/5099996 to your computer and use it in GitHub Desktop.
Typoscript Config for custom classes in HTML area plugin.
This need to be added to the sites root page "Page TSConfig" textarea under 'resources'
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /*these rules will only be enforced in the rte*/ | |
| /*the RTE is very fussy about the css syntax so make sure you assign the class to a Dom element*/ | |
| span.intro, p.intro { | |
| font-size: 2.4em; | |
| line-height: 30px; | |
| color: #999999; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ### CUSTOM RTE CLASSES ### | |
| # remove default classes from the RTE | |
| RTE.default.contentCSS > | |
| # Define classes | |
| # classes defined here must appear in the css file specified below | |
| RTE.classes{ | |
| # class name for CSS selector | |
| highlight { | |
| # name as it appears in RTE drop down | |
| name = highlight | |
| # color as it appears in the RTE | |
| value = color:#0A8AD2; | |
| } | |
| } | |
| # Typoscript Config | |
| RTE.default{ | |
| ignoreMainStyleOverride = 1 | |
| useCSS = 1 | |
| contentCSS = fileadmin/template/css/rte.css | |
| classesCharacter := addToList(highlight) | |
| classesParagraph := addToList(highlight) | |
| } | |
| RTE.default.proc.allowedClasses := addToList( highlight) | |
| ### CUSTOM RTE CLASSES END ### |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment