Commit bf14134a authored by Thomas Schlumberger's avatar Thomas Schlumberger Committed by Andreas Fernandez
Browse files

[TASK] Replace typo3- specific CSS Classes with Bootstrap

All custom typo3-classes (typo3-red, typo3-dimmed) are replaced
with bootstrap alternatives. Through that, some PHP Tree classes
don't need to overload the method anymore from the AbstractTreeView
and are removed.

Resolves: #67994
Releases: master
Change-Id: Ie95b70e9b402a7a66eb6c5a2dbe2e2a87c96c5aa
Reviewed-on: http://review.typo3.org/41012


Reviewed-by: Benni Mack's avatarBenjamin Mack <benni@typo3.org>
Tested-by: Benni Mack's avatarBenjamin Mack <benni@typo3.org>
Reviewed-by: Wouter Wolters's avatarWouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters's avatarWouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Andreas Fernandez's avatarAndreas Fernandez <typo3@scripting-base.de>
Tested-by: Andreas Fernandez's avatarAndreas Fernandez <typo3@scripting-base.de>
parent cdfdba8f
......@@ -177,7 +177,7 @@ class RteController extends AbstractWizardController {
$this->content .= $formEngine->printNeededJSFunctions_top() . $formContent . $formEngine->printNeededJSFunctions();
} else {
// ERROR:
$this->content .= $this->doc->section($this->getLanguageService()->getLL('forms_title'), '<span class="typo3-red">' . $this->getLanguageService()->getLL('table_noData', TRUE) . '</span>', 0, 1);
$this->content .= $this->doc->section($this->getLanguageService()->getLL('forms_title'), '<span class="text-danger">' . $this->getLanguageService()->getLL('table_noData', TRUE) . '</span>', 0, 1);
}
// Setting up the buttons and markers for docHeader
$docHeaderButtons = $this->getButtons();
......
......@@ -148,7 +148,7 @@ class TableController extends AbstractWizardController {
if ($this->P['table'] && $this->P['field'] && $this->P['uid']) {
$this->content .= $this->doc->section($this->getLanguageService()->getLL('table_title'), $this->tableWizard(), 0, 1);
} else {
$this->content .= $this->doc->section($this->getLanguageService()->getLL('table_title'), '<span class="typo3-red">' . $this->getLanguageService()->getLL('table_noData', TRUE) . '</span>', 0, 1);
$this->content .= $this->doc->section($this->getLanguageService()->getLL('table_title'), '<span class="text-danger">' . $this->getLanguageService()->getLL('table_noData', TRUE) . '</span>', 0, 1);
}
// Setting up the buttons and markers for docHeader
$docHeaderButtons = $this->getButtons();
......
......@@ -576,7 +576,7 @@ abstract class AbstractTreeView {
*/
public function wrapStop($str, $row) {
if ($row['php_tree_stop']) {
$str .= '<span class="typo3-red"><a href="' . htmlspecialchars(GeneralUtility::linkThisScript(array('setTempDBmount' => $row['uid']))) . '" class="typo3-red">+</a> </span>';
$str .= '<a href="' . htmlspecialchars(GeneralUtility::linkThisScript(array('setTempDBmount' => $row['uid']))) . '" class="text-danger">+</a> ';
}
return $str;
}
......
......@@ -108,21 +108,4 @@ class BrowseTreeView extends \TYPO3\CMS\Backend\Tree\View\AbstractTreeView {
return $title;
}
/**
* Adds a red "+" to the input string, $str, if the field "php_tree_stop" in the $row (pages) is set
*
* @param string $str Input string, like a page title for the tree
* @param array $row Record row with "php_tree_stop" field
* @return string Modified string
* @access private
*/
public function wrapStop($str, $row) {
if ($row['php_tree_stop']) {
$str .= '<span class="typo3-red">
<a href="' . htmlspecialchars(\TYPO3\CMS\Core\Utility\GeneralUtility::linkThisScript(array('setTempDBmount' => $row['uid']))) . '" class="typo3-red">+</a>
</span>';
}
return $str;
}
}
......@@ -49,7 +49,7 @@ class ElementBrowserFolderTreeView extends FolderTreeView {
$aOnClick = 'return jumpToUrl(' . \TYPO3\CMS\Core\Utility\GeneralUtility::quoteJSvalue($this->getThisScript() . 'act=' . $GLOBALS['SOBE']->browser->act . '&mode=' . $GLOBALS['SOBE']->browser->mode . '&expandFolder=' . rawurlencode($folderObject->getCombinedIdentifier())) . ');';
return '<a href="#" onclick="' . htmlspecialchars($aOnClick) . '">' . $title . '</a>';
} else {
return '<span class="typo3-dimmed">' . $title . '</span>';
return '<span class="text-muted">' . $title . '</span>';
}
}
......
......@@ -52,7 +52,7 @@ class ElementBrowserPageTreeView extends BrowseTreeView {
$aOnClick = 'return link_typo3Page(' . \TYPO3\CMS\Core\Utility\GeneralUtility::quoteJSvalue($v['uid']) . ');';
return '<a href="#" onclick="' . htmlspecialchars($aOnClick) . '">' . $title . '</a>';
} else {
return '<span style="color: #666666;">' . $title . '</span>';
return '<span class="text-muted">' . $title . '</span>';
}
}
......
......@@ -99,21 +99,6 @@ class PageTreeView extends \TYPO3\CMS\Backend\Tree\View\BrowseTreeView {
return $dragDropIcon . $lockIcon . $pageIdStr . $stat;
}
/**
* Adds a red "+" to the input string, $str, if the field "php_tree_stop" in the $row (pages) is set
*
* @param string $str Input string, like a page title for the tree
* @param array $row Record row with "php_tree_stop" field
* @return string Modified string
* @access private
*/
public function wrapStop($str, $row) {
if ($row['php_tree_stop']) {
$str .= '<a href="' . htmlspecialchars(GeneralUtility::linkThisScript(array('setTempDBmount' => $row['uid']))) . '" class="typo3-red">+</a> ';
}
return $str;
}
/**
* Wrapping $title in a-tags.
*
......
......@@ -200,7 +200,7 @@ class FormsController extends \TYPO3\CMS\Backend\Controller\Wizard\AbstractWizar
if ($this->P['table'] && $this->P['field'] && $this->P['uid']) {
$this->content .= $this->doc->section($this->getLanguageService()->getLL('forms_title'), $this->formsWizard(), 0, 1);
} else {
$this->content .= $this->doc->section($this->getLanguageService()->getLL('forms_title'), '<span class="typo3-red">' . $this->getLanguageService()->getLL('table_noData', 1) . '</span>', 0, 1);
$this->content .= $this->doc->section($this->getLanguageService()->getLL('forms_title'), '<span class="text-danger">' . $this->getLanguageService()->getLL('table_noData', 1) . '</span>', 0, 1);
}
// Setting up the buttons and markers for docheader
$docHeaderButtons = $this->getButtons();
......
......@@ -471,7 +471,7 @@ class ExtendedTemplateService extends TemplateService {
$ln = '';
}
if ($this->tsbrowser_searchKeys[$depth] & 4) {
$label = '<strong style="color: red;">' . $label . '</strong>';
$label = '<strong class="text-danger">' . $label . '</strong>';
}
// The key has matched the search string
$label = '<a href="' . htmlspecialchars($aHref) . '" title="' . htmlspecialchars($ln) . '">' . $label . '</a>';
......@@ -487,7 +487,7 @@ class ExtendedTemplateService extends TemplateService {
}
// The value has matched the search string
if ($this->tsbrowser_searchKeys[$depth] & 2) {
$HTML .= '&nbsp;=&nbsp;<strong style="color: red;">' . htmlspecialchars($theValue) . '</strong>';
$HTML .= '&nbsp;=&nbsp;<strong class="text-danger">' . htmlspecialchars($theValue) . '</strong>';
} else {
$HTML .= '&nbsp;=&nbsp;<strong>' . htmlspecialchars($theValue) . '</strong>';
}
......@@ -820,10 +820,10 @@ class ExtendedTemplateService extends TemplateService {
$cArr[$k] = $lineNum . str_replace(' ', '&nbsp;', $v);
$firstChar = substr(trim($v), 0, 1);
if ($firstChar == '[') {
$cArr[$k] = '<strong style="color: green">' . $cArr[$k] . '</strong>';
$cArr[$k] = '<strong class="text-success">' . $cArr[$k] . '</strong>';
} elseif ($firstChar == '/' || $firstChar == '#') {
if ($comments) {
$cArr[$k] = '<span class="typo3-dimmed">' . $cArr[$k] . '</span>';
$cArr[$k] = '<span class="text-muted">' . $cArr[$k] . '</span>';
} else {
unset($cArr[$k]);
}
......@@ -1318,7 +1318,7 @@ class ExtendedTemplateService extends TemplateService {
$constantEditRow = '<div class="typo3-tstemplate-ceditor-row" id="' . $userTyposcriptID . '" '
. $userTyposcriptStyle . '>' . $deleteIconHTML . $p_field . $color . '</div>';
$constantLabel = '<dt class="typo3-tstemplate-ceditor-label">' . htmlspecialchars($head) . '</dt>';
$constantName = '<dt class="typo3-dimmed">[' . $params['name'] . ']</dt>';
$constantName = '<dt class="text-muted">[' . $params['name'] . ']</dt>';
$constantDescription = $body ? '<dd>' . htmlspecialchars($body) . '</dd>' : '';
$constantData = '<dd>' . $constantCheckbox . $constantEditRow . $constantDefaultRow . '</dd>';
$output .= '<a name="' . $raname . '"></a>' . $help['constants'][$params['name']];
......
......@@ -910,7 +910,7 @@ class ImportExportController extends \TYPO3\CMS\Backend\Module\BaseScriptClass {
<th colspan="2">' . $this->lang->getLL('importdata_selectFileToImport', TRUE) . '</th>
</tr>';
$noCompressorAvailable = !$import->compress
? '<br /><span class="typo3-red">' . $this->lang->getLL('importdata_noteNoDecompressorAvailable', TRUE) . '</span>'
? '<br /><span class="text-danger">' . $this->lang->getLL('importdata_noteNoDecompressorAvailable', TRUE) . '</span>'
: '';
$row[] = '
<tr>
......@@ -960,7 +960,7 @@ class ImportExportController extends \TYPO3\CMS\Backend\Module\BaseScriptClass {
<br/>
<input type="checkbox" name="tx_impexp[force_all_UIDS]" id="checkForce_all_UIDS" value="1"'
. ($inData['force_all_UIDS'] ? ' checked="checked"' : '') . ' />
<label for="checkForce_all_UIDS"><span class="typo3-red">'
<label for="checkForce_all_UIDS"><span class="text-danger">'
. $this->lang->getLL('importdata_force_all_UIDS', TRUE) . '</span></label><br/>
<em>(' . $this->lang->getLL('importdata_force_all_UIDS_descr', TRUE) . ')</em>'
: '';
......@@ -1042,7 +1042,7 @@ class ImportExportController extends \TYPO3\CMS\Backend\Module\BaseScriptClass {
if (GeneralUtility::_POST('_upload')) {
$noFileUploaded = $this->fileProcessor->internalUploadMap[1]
? $this->lang->getLL('importdata_success', TRUE) . ' ' . $this->uploadedFiles[0]->getName()
: '<span class="typo3-red">' . $this->lang->getLL('importdata_failureNoFileUploaded', TRUE) . '</span>';
: '<span class="text-danger">' . $this->lang->getLL('importdata_failureNoFileUploaded', TRUE) . '</span>';
$row[] = '<tr class="bgColor4">
<td>' . $this->lang->getLL('importdata_uploadStatus', TRUE) . '</td>
<td>' . $noFileUploaded . '</td>
......
......@@ -3408,7 +3408,7 @@ class ImportExport {
<td>' . $this->renderControls($r) . '</td>
<td nowrap="nowrap">' . $r['preCode'] . $r['title'] . '</td>
<td nowrap="nowrap">' . GeneralUtility::formatSize($r['size']) . '</td>
<td nowrap="nowrap">' . ($r['msg'] && !$this->doesImport ? '<span class="typo3-red">' . htmlspecialchars($r['msg']) . '</span>' : '') . '</td>
<td nowrap="nowrap">' . ($r['msg'] && !$this->doesImport ? '<span class="text-danger">' . htmlspecialchars($r['msg']) . '</span>' : '') . '</td>
' . ($this->update ? '<td nowrap="nowrap">' . $r['updateMode'] . '</td>' : '') . '
' . ($this->update ? '<td nowrap="nowrap">' . $r['updatePath'] . '</td>' : '') . '
' . ($this->showDiff ? '<td>' . $r['showDiffContent'] . '</td>' : '') . '
......@@ -3444,7 +3444,7 @@ class ImportExport {
<td>' . $this->renderControls($r) . '</td>
<td nowrap="nowrap">' . $r['preCode'] . $r['title'] . '</td>
<td nowrap="nowrap">' . GeneralUtility::formatSize($r['size']) . '</td>
<td nowrap="nowrap">' . ($r['msg'] && !$this->doesImport ? '<span class="typo3-red">' . htmlspecialchars($r['msg']) . '</span>' : '') . '</td>
<td nowrap="nowrap">' . ($r['msg'] && !$this->doesImport ? '<span class="text-danger">' . htmlspecialchars($r['msg']) . '</span>' : '') . '</td>
' . ($this->update ? '<td nowrap="nowrap">' . $r['updateMode'] . '</td>' : '') . '
' . ($this->update ? '<td nowrap="nowrap">' . $r['updatePath'] . '</td>' : '') . '
' . ($this->showDiff ? '<td>' . $r['showDiffContent'] . '</td>' : '') . '
......
......@@ -55,7 +55,7 @@ class ElementBrowserFolderTreeView extends \TYPO3\CMS\Backend\Tree\View\ElementB
return '<a href="#" onclick="' . htmlspecialchars($aOnClick) . '">' . $title . '</a>';
} else {
return '<span class="typo3-dimmed">' . $title . '</span>';
return '<span class="text-muted">' . $title . '</span>';
}
}
}
......@@ -68,7 +68,7 @@ class FolderTree extends \TYPO3\CMS\Backend\Tree\View\ElementBrowserFolderTreeVi
. '\');';
return '<a href="#" onclick="' . htmlspecialchars($aOnClick) . '">' . $title . '</a>';
} else {
return '<span class="typo3-dimmed">' . $title . '</span>';
return '<span class="text-muted">' . $title . '</span>';
}
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment