Commit 5ca6e7dc authored by Frank Nägler's avatar Frank Nägler Committed by Markus Klein
Browse files

[TASK] Remove additionalClasses option from FontawesomeProvider.

This option was introduced with the new Icon API but is not useful
and must be removed now.

Resolves: #69441
Releases: master
Change-Id: I7d02a320e9c7eaa91e877b703c78d535ee3d45cd
Reviewed-on: http://review.typo3.org/42945

Reviewed-by: Wouter Wolters's avatarWouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Alexander Opitz's avatarAlexander Opitz <opitz.alexander@googlemail.com>
Tested-by: Alexander Opitz's avatarAlexander Opitz <opitz.alexander@googlemail.com>
Reviewed-by: Markus Klein's avatarMarkus Klein <markus.klein@typo3.org>
Tested-by: Markus Klein's avatarMarkus Klein <markus.klein@typo3.org>
parent 3d50d733
......@@ -120,10 +120,10 @@
//
// Special icons
//
.icon-default-not-found {
color: @brand-danger;
}
.icon-overlay-read-only {
.icon-default-not-found,
.icon-actions-edit-copy-release,
.icon-actions-edit-cut-release,
.icon-overlay-read-only,
.icon-status-status-current {
color: @brand-danger;
}
......@@ -44,7 +44,6 @@ class FontawesomeIconProvider implements IconProviderInterface {
if (preg_match('/^[a-zA-Z0-9\\-]+$/', $options['name']) !== 1) {
throw new \InvalidArgumentException('The option "name" must only contain characters a-z, A-Z, 0-9 or -', 1440754979);
}
$additionalClasses = (!empty($options['additionalClasses'])) ? ' ' . $options['additionalClasses'] : '';
return '<span class="icon-unify"><i class="fa fa-' . htmlspecialchars($options['name']) . htmlspecialchars($additionalClasses) . '"></i></span>';
return '<span class="icon-unify"><i class="fa fa-' . htmlspecialchars($options['name']) . '"></i></span>';
}
}
......@@ -140,7 +140,6 @@ class IconRegistry implements \TYPO3\CMS\Core\SingletonInterface {
'provider' => FontawesomeIconProvider::class,
'options' => array(
'name' => 'copy',
'additionalClasses' => 'text-danger',
)
),
'actions-edit-cut' => array(
......@@ -153,7 +152,6 @@ class IconRegistry implements \TYPO3\CMS\Core\SingletonInterface {
'provider' => FontawesomeIconProvider::class,
'options' => array(
'name' => 'scissors',
'additionalClasses' => 'text-danger',
)
),
'actions-edit-download' => array(
......@@ -318,7 +316,6 @@ class IconRegistry implements \TYPO3\CMS\Core\SingletonInterface {
'provider' => FontawesomeIconProvider::class,
'options' => array(
'name' => 'caret-right',
'additionalClasses' => 'text-danger',
)
),
......
......@@ -26,6 +26,30 @@ The core implement three icon provider classes, which all implements the ``IconP
Third party extensions can provide own icon provider classes, each class must implement the ``IconProviderInterface``.
BitmapIconProvider
------------------
The ``BitmapIconProvider`` has the following options
* ``source`` The path to the bitmap file, this can also contains the EXT: prefix
FontawesomeIconProvider
-----------------------
The ``FontawesomeIconProvider`` has the following options
* ``name`` The name of the icon whithout the icon prefix e.g. ``check`` instead of ``fa-check``
SvgIconProvider
---------------
The ``SvgIconProvider`` has the following options
* ``source`` The path to the svg file, this can also contains the EXT: prefix
Register an icon
----------------
......
......@@ -7849,10 +7849,11 @@ button.close {
line-height: 30px;
font-size: 26px;
}
.icon-default-not-found {
color: #c83c3c;
}
.icon-overlay-read-only {
.icon-default-not-found,
.icon-actions-edit-copy-release,
.icon-actions-edit-cut-release,
.icon-overlay-read-only,
.icon-status-status-current {
color: #c83c3c;
}
.clearfix:before,
......
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