Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions Classes/Hooks/T3libTcemainHook.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@ function clearCachePostProc($params, &$pObj) {
return;
}
switch($params['cacheCmd']) {
case 'pages':
case 'all':
case 'dyncss':
GeneralUtility::rmdir(
PATH_site . 'typo3temp/Cache/Data/DynCss',
Expand Down
19 changes: 19 additions & 0 deletions Classes/XClass/RteHtmlAreaBase.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
<?php


namespace KayStrobach\Dyncss\XClass;


class RteHtmlAreaBase extends \TYPO3\CMS\Rtehtmlarea\RteHtmlAreaBase {
/**
* @return string
*/
public function getContentCssFileName() {

$this->thisConfig['contentCSS'] = parent::getContentCssFileName();

$this->thisConfig['contentCSS'] = substr(\KayStrobach\Dyncss\Service\DyncssService::getCompiledFile($this->thisConfig['contentCSS']), 3);

return parent::getContentCssFileName();
}
}
5 changes: 4 additions & 1 deletion ext_conf_template.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,7 @@
state =

# cat=basic; type=boolean; label= Enable Debugmode (e.g. for firesass or similar), if the used parser is able to do that
enableDebugMode =
enableDebugMode =

# cat=basic; type=boolean; label= Enable xclass for parsing RTE.default.contentCSS
enableRteXclass = 1
8 changes: 8 additions & 0 deletions ext_localconf.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,11 @@
// clear cache item
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tcemain.php']['clearCachePostProc'][] = 'KayStrobach\Dyncss\Hooks\T3libTcemainHook->clearCachePostProc';
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['additionalBackendItems']['cacheActions'][] = 'KayStrobach\Dyncss\Hooks\Backend\Toolbar\ClearCacheActionsHook';

// pagets rte xclass parsing RTE.default.contentCSS
$dynCssConfig = unserialize($GLOBALS['TYPO3_CONF_VARS']['EXT']['extConf']['dyncss']);
if($dynCssConfig['enableRteXclass']) {
$GLOBALS['TYPO3_CONF_VARS']['SYS']['Objects']['TYPO3\CMS\Rtehtmlarea\RteHtmlAreaBase'] = array(
'className' => 'KayStrobach\Dyncss\XClass\RteHtmlAreaBase',
);
}