Commit 56cef564 authored by Christian Kuhn's avatar Christian Kuhn Committed by Frank Nägler
Browse files

[!!!][TASK] FormEngine: Drop "Show secondary options"

Resolves: #67753
Releases: master
Change-Id: I35195892b81a11026a6e6227337bb6da47166a67
Reviewed-on: http://review.typo3.org/40649


Reviewed-by: Markus Klein's avatarMarkus Klein <markus.klein@typo3.org>
Tested-by: Markus Klein's avatarMarkus Klein <markus.klein@typo3.org>
Reviewed-by: Frank Nägler's avatarFrank Nägler <frank.naegler@typo3.org>
Tested-by: Frank Nägler's avatarFrank Nägler <frank.naegler@typo3.org>
parent 8cad80b8
......@@ -273,21 +273,11 @@ class EditDocumentController {
*/
public $R_URI;
/**
* @var array
*/
public $MOD_MENU;
/**
* @var array
*/
public $MCONF;
/**
* @var array
*/
public $MOD_SETTINGS;
/**
* @var array
*/
......@@ -685,17 +675,8 @@ class EditDocumentController {
// Set other internal variables:
$this->R_URL_getvars['returnUrl'] = $this->retUrl;
$this->R_URI = $this->R_URL_parts['path'] . '?' . ltrim(GeneralUtility::implodeArrayForUrl('', $this->R_URL_getvars), '&');
// MENU-ITEMS:
// If array, then it's a selector box menu
// If empty string it's just a variable, that'll be saved.
// Values NOT in this array will not be saved in the settings-array for the module.
$this->MOD_MENU = array(
'showPalettes' => ''
);
// Setting virtual document name
$this->MCONF['name'] = 'xMOD_alt_doc.php';
// CLEANSE SETTINGS
$this->MOD_SETTINGS = BackendUtility::getModuleData($this->MOD_MENU, GeneralUtility::_GP('SET'), $this->MCONF['name']);
// Create an instance of the document template object
$this->doc = $GLOBALS['TBE_TEMPLATE'];
$this->doc->getPageRenderer()->addInlineLanguageLabelFile('EXT:lang/locallang_alt_doc.xml');
......@@ -880,7 +861,6 @@ class EditDocumentController {
$this->tceforms->localizationMode = GeneralUtility::inList('text,media', $this->localizationMode) ? $this->localizationMode : '';
// text,media is keywords defined in TYPO3 Core API..., see "l10n_cat"
$this->tceforms->returnUrl = $this->R_URI;
$this->tceforms->palettesCollapsed = !$this->MOD_SETTINGS['showPalettes'];
if ($this->editRegularContentFromId) {
$this->editRegularContentFromId();
}
......@@ -899,7 +879,6 @@ class EditDocumentController {
$body = $this->tceforms->printNeededJSFunctions_top();
$body .= $this->compileForm($editForm);
$body .= $this->tceforms->printNeededJSFunctions();
$body .= $this->functionMenus();
}
}
// Access check...
......@@ -1270,26 +1249,6 @@ class EditDocumentController {
return $formContent;
}
/**
* Create the checkbox buttons in the bottom of the pages.
*
* @return string HTML for function menus.
*/
public function functionMenus() {
if ($this->getBackendUser()->getTSConfigVal('options.enableShowPalettes')) {
// Show palettes
return '<div class="checkbox">' .
'<label for="checkShowPalettes">' .
BackendUtility::getFuncCheck('', 'SET[showPalettes]', $this->MOD_SETTINGS['showPalettes'], BackendUtility::getModuleUrl('record_edit'), (GeneralUtility::implodeArrayForUrl('', array_merge($this->R_URL_getvars, array('SET' => ''))) . BackendUtility::getUrlToken('editRecord')), 'id="checkShowPalettes"') .
$this->getLanguageService()->sL('LLL:EXT:lang/locallang_core.xlf:labels.showPalettes', TRUE) .
'</label>'.
'</div>';
} else {
return '';
}
}
/**
* Create shortcut icon
*
......@@ -1299,7 +1258,7 @@ class EditDocumentController {
if ($this->returnUrl == 'close.html' || !$this->getBackendUser()->mayMakeShortcut()) {
return '';
}
return $this->doc->makeShortcutIcon('returnUrl,edit,defVals,overrideVals,columnsOnly,returnNewPageId,editRegularContentFromId,noView', implode(',', array_keys($this->MOD_MENU)), $this->MCONF['name'], 1);
return $this->doc->makeShortcutIcon('returnUrl,edit,defVals,overrideVals,columnsOnly,returnNewPageId,editRegularContentFromId,noView', '', $this->MCONF['name'], 1);
}
/**
......
......@@ -345,7 +345,6 @@ class PageLayoutController {
// MENU-ITEMS:
$this->MOD_MENU = array(
'tt_content_showHidden' => '',
'showPalettes' => '',
'showDescriptions' => '',
'function' => array(
0 => $lang->getLL('m_function_0'),
......@@ -869,7 +868,6 @@ class PageLayoutController {
// If the record is an array (which it will always be... :-)
// Create instance of TCEforms, setting defaults:
$tceForms = GeneralUtility::makeInstance(FormEngine::class);
$tceForms->palettesCollapsed = !$this->MOD_SETTINGS['showPalettes'];
// Render form, wrap it:
$panel = '';
$panel .= $tceForms->getMainFields($this->eRParts[0], $rec);
......@@ -920,13 +918,6 @@ class PageLayoutController {
'</label>' .
'</div>';
$h_func_b .= '<div class="checkbox">' .
'<label for="checkShowPalettes">' .
BackendUtility::getFuncCheck($this->id, 'SET[showPalettes]', $this->MOD_SETTINGS['showPalettes'], '', '', 'id="checkShowPalettes"') .
$lang->sL('LLL:EXT:lang/locallang_core.xlf:labels.showPalettes', TRUE) .
'</label>' .
'</div>';
if (ExtensionManagementUtility::isLoaded('context_help')) {
$h_func_b .= '<div class="checkbox">' .
'<label for="checkShowDescriptions">' .
......
......@@ -16,7 +16,6 @@ namespace TYPO3\CMS\Backend\Form\Container;
use TYPO3\CMS\Core\Utility\GeneralUtility;
use TYPO3\CMS\Lang\LanguageService;
use TYPO3\CMS\Backend\Utility\IconUtility;
use TYPO3\CMS\Backend\Form\Utility\FormEngineUtility;
use TYPO3\CMS\Backend\Utility\BackendUtility;
use TYPO3\CMS\Backend\Form\NodeFactory;
......@@ -165,30 +164,7 @@ class PaletteAndSingleContainer extends AbstractContainer {
$isHiddenPalette = !empty($GLOBALS['TCA'][$table]['palettes'][$paletteName]['isHiddenPalette']);
$renderUnCollapseButtonWrapper = TRUE;
// No button if the palette is hidden
if ($isHiddenPalette) {
$renderUnCollapseButtonWrapper = FALSE;
}
// No button if palette can not collapse on ctrl level
if (!empty($GLOBALS['TCA'][$table]['ctrl']['canNotCollapse'])) {
$renderUnCollapseButtonWrapper = FALSE;
}
// No button if palette can not collapse on palette definition level
if (!empty($GLOBALS['TCA'][$table]['palettes'][$paletteName]['canNotCollapse'])) {
$renderUnCollapseButtonWrapper = FALSE;
}
// No button if palettes are not collapsed - this is the checkbox at the end of the form
if (!$this->globalOptions['palettesCollapsed']) {
$renderUnCollapseButtonWrapper = FALSE;
}
if ($renderUnCollapseButtonWrapper) {
$cssId = str_replace('.', '_', 'FORMENGINE_' . $this->globalOptions['table'] . '_' . $paletteName . '_' . $this->globalOptions['databaseRow']['uid']);
$paletteElementsHtml = $this->wrapPaletteWithCollapseButton($paletteElementsHtml, $cssId);
} else {
$paletteElementsHtml = '<div class="row">' . $paletteElementsHtml . '</div>';
}
$paletteElementsHtml = '<div class="row">' . $paletteElementsHtml . '</div>';
$content[] = $this->fieldSetWrap($paletteElementsHtml, $isHiddenPalette, $element['fieldLabel']);
} else {
......@@ -347,27 +323,6 @@ class PaletteAndSingleContainer extends AbstractContainer {
return implode(LF, $result);
}
/**
* Add a "collapsible" button around given content
*
* @param string $elementHtml HTML of handled palette content
* @param string $cssId A css id to be added
* @return string Wrapped content
*/
protected function wrapPaletteWithCollapseButton($elementHtml, $cssId) {
$content = array();
$content[] = '<p>';
$content[] = '<button class="btn btn-default" type="button" data-toggle="collapse" data-target="#' . $cssId . '" aria-expanded="false" aria-controls="' . $cssId . '">';
$content[] = IconUtility::getSpriteIcon('actions-system-options-view');
$content[] = htmlspecialchars($this->getLanguageService()->sL('LLL:EXT:lang/locallang_core.xlf:labels.moreOptions'));
$content[] = '</button>';
$content[] = '</p>';
$content[] = '<div id="' . $cssId . '" class="form-section-collapse collapse">';
$content[] = '<div class="row">' . $elementHtml . '</div>';
$content[] = '</div>';
return implode(LF, $content);
}
/**
* Wrap content in a field set
*
......
......@@ -92,14 +92,6 @@ class FormEngine {
*/
public $doSaveFieldName = '';
/**
* Can be set TRUE/FALSE to whether palettes (secondary options) are in the topframe or in form.
* TRUE means they are NOT IN-form. So a collapsed palette is one, which is shown in the top frame, not in the page.
*
* @var bool
*/
public $palettesCollapsed = FALSE;
/**
* If this evaluates to TRUE, the forms are rendering only localization relevant fields of the records.
*
......@@ -435,7 +427,6 @@ class FormEngine {
'renderReadonly' => $this->renderReadonly,
'disabledWizards' => $this->disableWizards,
'returnUrl' => $this->thisReturnUrl(),
'palettesCollapsed' => $this->palettesCollapsed,
'table' => $this->table,
'databaseRow' => $this->databaseRow,
'recordTypeValue' => '',
......@@ -911,7 +902,6 @@ class FormEngine {
// Create a new anonymous object:
$GLOBALS['SOBE'] = new \stdClass();
$GLOBALS['SOBE']->MOD_MENU = array(
'showPalettes' => '',
'showDescriptions' => '',
);
// Setting virtual document name
......@@ -923,8 +913,7 @@ class FormEngine {
$GLOBALS['SOBE']->doc = GeneralUtility::makeInstance(DocumentTemplate::class);
$GLOBALS['SOBE']->doc->backPath = $GLOBALS['BACK_PATH'];
// Initialize FormEngine (rendering the forms)
// @todo: check what of this part is still needed, simplify
$this->palettesCollapsed = !$GLOBALS['SOBE']->MOD_SETTINGS['showPalettes'];
// @todo: check if this is still needed, simplify
$GLOBALS['SOBE']->tceforms = $this;
}
......
......@@ -210,7 +210,6 @@ $GLOBALS['TCA']['tt_content']['palettes'] = array_replace(
image_link,
image_zoom
',
'canNotCollapse' => 1
),
'8' => array(
'showitem' => '
......@@ -231,7 +230,6 @@ $GLOBALS['TCA']['tt_content']['palettes'] = array_replace(
image_effects,
image_frames
',
'canNotCollapse' => 1
),
'12' => array(
'showitem' => '
......@@ -243,7 +241,6 @@ $GLOBALS['TCA']['tt_content']['palettes'] = array_replace(
imagewidth,
imageheight
',
'canNotCollapse' => 1
),
'14' => array(
'showitem' => '
......@@ -259,7 +256,6 @@ $GLOBALS['TCA']['tt_content']['palettes'] = array_replace(
--linebreak--,
longdescURL;LLL:EXT:cms/locallang_ttc.xlf:longdescURL_formlabel
',
'canNotCollapse' => 1
)
)
);
......@@ -275,7 +271,6 @@ if (!\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::isLoaded('css_styled_co
sectionIndex;LLL:EXT:cms/locallang_ttc.xlf:sectionIndex_formlabel,
linkToTop;LLL:EXT:cms/locallang_ttc.xlf:linkToTop_formlabel
',
'canNotCollapse' => 1
),
'frames' => array(
'showitem' => '
......@@ -284,7 +279,6 @@ if (!\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::isLoaded('css_styled_co
spaceAfter;LLL:EXT:cms/locallang_ttc.xlf:spaceAfter_formlabel,
section_frame;LLL:EXT:cms/locallang_ttc.xlf:section_frame_formlabel
',
'canNotCollapse' => 1
)
)
);
......@@ -312,7 +306,6 @@ $GLOBALS['TCA']['tt_content']['types']['search'] = array(
$GLOBALS['TCA']['tt_content']['palettes']['searchform'] = array(
'showitem' => 'pages;LLL:EXT:cms/locallang_ttc.xlf:pages.ALT.searchform',
'canNotCollapse' => 1
);
// check if there is already a forms tab and add the item after that, otherwise
......@@ -409,5 +402,4 @@ $GLOBALS['TCA']['tt_content']['types']['mailform']['columnsOverrides']['bodytext
$GLOBALS['TCA']['tt_content']['palettes']['mailform'] = array(
'showitem' => 'pages;LLL:EXT:cms/locallang_ttc.xlf:pages.ALT.mailform, --linebreak--, subheader;LLL:EXT:cms/locallang_ttc.xlf:subheader.ALT.mailform_formlabel',
'canNotCollapse' => 1
);
......@@ -338,7 +338,6 @@ return array(
'preloadLimit' => 50
),
'defaultUserTSconfig' => 'options.enableBookmarks=1
options.enableShowPalettes=1
options.file_list.enableDisplayBigControlPanel=selectable
options.file_list.enableDisplayThumbnails=selectable
options.file_list.enableClipBoard=selectable
......
......@@ -971,7 +971,6 @@ return array(
),
'5' => array(
'showitem' => 'author, author_email',
'canNotCollapse' => 1
),
'6' => array(
'showitem' => 'php_tree_stop, editlock'
......@@ -984,103 +983,78 @@ return array(
),
'standard' => array(
'showitem' => 'doktype;LLL:EXT:cms/locallang_tca.xlf:pages.doktype_formlabel',
'canNotCollapse' => 1
),
'shortcut' => array(
'showitem' => 'doktype;LLL:EXT:cms/locallang_tca.xlf:pages.doktype_formlabel, shortcut_mode;LLL:EXT:cms/locallang_tca.xlf:pages.shortcut_mode_formlabel',
'canNotCollapse' => 1
),
'shortcutpage' => array(
'showitem' => 'shortcut;LLL:EXT:cms/locallang_tca.xlf:pages.shortcut_formlabel',
'canNotCollapse' => 1
),
'mountpoint' => array(
'showitem' => 'doktype;LLL:EXT:cms/locallang_tca.xlf:pages.doktype_formlabel, mount_pid_ol;LLL:EXT:cms/locallang_tca.xlf:pages.mount_pid_ol_formlabel',
'canNotCollapse' => 1
),
'mountpage' => array(
'showitem' => 'mount_pid;LLL:EXT:cms/locallang_tca.xlf:pages.mount_pid_formlabel',
'canNotCollapse' => 1
),
'external' => array(
'showitem' => 'doktype;LLL:EXT:cms/locallang_tca.xlf:pages.doktype_formlabel, urltype;LLL:EXT:cms/locallang_tca.xlf:pages.urltype_formlabel, url;LLL:EXT:cms/locallang_tca.xlf:pages.url_formlabel',
'canNotCollapse' => 1
),
'title' => array(
'showitem' => 'title;LLL:EXT:cms/locallang_tca.xlf:pages.title_formlabel, --linebreak--, nav_title;LLL:EXT:cms/locallang_tca.xlf:pages.nav_title_formlabel, --linebreak--, subtitle;LLL:EXT:cms/locallang_tca.xlf:pages.subtitle_formlabel',
'canNotCollapse' => 1
),
'titleonly' => array(
'showitem' => 'title;LLL:EXT:cms/locallang_tca.xlf:pages.title_formlabel',
'canNotCollapse' => 1
),
'visibility' => array(
'showitem' => 'hidden;LLL:EXT:cms/locallang_tca.xlf:pages.hidden_formlabel, nav_hide;LLL:EXT:cms/locallang_tca.xlf:pages.nav_hide_formlabel',
'canNotCollapse' => 1
),
'hiddenonly' => array(
'showitem' => 'hidden;LLL:EXT:cms/locallang_tca.xlf:pages.hidden_formlabel',
'canNotCollapse' => 1
),
'access' => array(
'showitem' => 'starttime;LLL:EXT:cms/locallang_tca.xlf:pages.starttime_formlabel, endtime;LLL:EXT:cms/locallang_tca.xlf:pages.endtime_formlabel, extendToSubpages;LLL:EXT:cms/locallang_tca.xlf:pages.extendToSubpages_formlabel, --linebreak--, fe_group;LLL:EXT:cms/locallang_tca.xlf:pages.fe_group_formlabel, --linebreak--, fe_login_mode;LLL:EXT:cms/locallang_tca.xlf:pages.fe_login_mode_formlabel',
'canNotCollapse' => 1
),
'abstract' => array(
'showitem' => 'abstract;LLL:EXT:cms/locallang_tca.xlf:pages.abstract_formlabel',
'canNotCollapse' => 1
),
'metatags' => array(
'showitem' => 'keywords;LLL:EXT:cms/locallang_tca.xlf:pages.keywords_formlabel, --linebreak--, description;LLL:EXT:cms/locallang_tca.xlf:pages.description_formlabel',
'canNotCollapse' => 1
),
'editorial' => array(
'showitem' => 'author;LLL:EXT:cms/locallang_tca.xlf:pages.author_formlabel, author_email;LLL:EXT:cms/locallang_tca.xlf:pages.author_email_formlabel, lastUpdated;LLL:EXT:cms/locallang_tca.xlf:pages.lastUpdated_formlabel',
'canNotCollapse' => 1
),
'layout' => array(
'showitem' => 'layout;LLL:EXT:cms/locallang_tca.xlf:pages.layout_formlabel, newUntil;LLL:EXT:cms/locallang_tca.xlf:pages.newUntil_formlabel, --linebreak--, backend_layout;LLL:EXT:cms/locallang_tca.xlf:pages.backend_layout_formlabel, backend_layout_next_level;LLL:EXT:cms/locallang_tca.xlf:pages.backend_layout_next_level_formlabel',
'canNotCollapse' => 1
),
'module' => array(
'showitem' => 'module;LLL:EXT:cms/locallang_tca.xlf:pages.module_formlabel',
'canNotCollapse' => 1
),
'replace' => array(
'showitem' => 'content_from_pid;LLL:EXT:cms/locallang_tca.xlf:pages.content_from_pid_formlabel',
'canNotCollapse' => 1
),
'links' => array(
'showitem' => 'alias;LLL:EXT:cms/locallang_tca.xlf:pages.alias_formlabel, --linebreak--, target;LLL:EXT:cms/locallang_tca.xlf:pages.target_formlabel, --linebreak--, url_scheme;LLL:EXT:cms/locallang_tca.xlf:pages.url_scheme_formlabel',
'canNotCollapse' => 1
),
'caching' => array(
'showitem' => 'cache_timeout;LLL:EXT:cms/locallang_tca.xlf:pages.cache_timeout_formlabel, cache_tags, no_cache;LLL:EXT:cms/locallang_tca.xlf:pages.no_cache_formlabel',
'canNotCollapse' => 1
),
'language' => array(
'showitem' => 'l18n_cfg;LLL:EXT:cms/locallang_tca.xlf:pages.l18n_cfg_formlabel',
'canNotCollapse' => 1
),
'miscellaneous' => array(
'showitem' => 'is_siteroot;LLL:EXT:cms/locallang_tca.xlf:pages.is_siteroot_formlabel, no_search;LLL:EXT:cms/locallang_tca.xlf:pages.no_search_formlabel, editlock;LLL:EXT:cms/locallang_tca.xlf:pages.editlock_formlabel, php_tree_stop;LLL:EXT:cms/locallang_tca.xlf:pages.php_tree_stop_formlabel',
'canNotCollapse' => 1
),
'adminsonly' => array(
'showitem' => 'editlock;LLL:EXT:cms/locallang_tca.xlf:pages.editlock_formlabel',
'canNotCollapse' => 1
),
'media' => array(
'showitem' => 'media;LLL:EXT:cms/locallang_tca.xlf:pages.media_formlabel',
'canNotCollapse' => 1
),
'storage' => array(
'showitem' => 'storage_pid;LLL:EXT:cms/locallang_tca.xlf:pages.storage_pid_formlabel',
'canNotCollapse' => 1
),
'config' => array(
'showitem' => 'TSconfig;LLL:EXT:cms/locallang_tca.xlf:pages.TSconfig_formlabel',
'canNotCollapse' => 1
)
)
);
......@@ -263,7 +263,6 @@ return array(
// Used for basic overlays: having a file list etc
'basicoverlayPalette' => array(
'showitem' => 'title,description',
'canNotCollapse' => TRUE
),
// Used for everything that is an image (because it has a link and a alternative text)
'imageoverlayPalette' => array(
......@@ -271,12 +270,11 @@ return array(
title,alternative,--linebreak--,
link,description,--linebreak--,crop
',
'canNotCollapse' => TRUE
),
// File palette, hidden but needs to be included all the time
'filePalette' => array(
'showitem' => 'uid_local, hidden, sys_language_uid, l10n_parent',
'isHiddenPalette' => TRUE
)
)
'isHiddenPalette' => TRUE,
),
),
);
......@@ -115,6 +115,8 @@ return array(
'0' => array('showitem' => 'name, description, --div--;Configuration, driver, configuration, is_default, processingfolder, --div--;Access, --palette--;Capabilities;capabilities, is_online')
),
'palettes' => array(
'capabilities' => array('showitem' => 'is_browsable, is_public, is_writable', 'canNotCollapse' => TRUE)
)
'capabilities' => array(
'showitem' => 'is_browsable, is_public, is_writable',
),
),
);
......@@ -73,6 +73,8 @@ return array(
'0' => array('showitem' => '--palette--;;mount, description, base, path, read_only')
),
'palettes' => array(
'mount' => array('showitem' => 'title,hidden', 'canNotCollapse' => 1)
'mount' => array(
'showitem' => 'title,hidden',
),
),
);
================================================
Breaking: #67753 - Drop "Show secondary options"
================================================
Description
===========
When editing records, the checkbox at the bottom "Show secondary options (palettes)" has been dropped, palettes are now always shown and the collapse buttons are no longer rendered.
Impact
======
PageTSconfig
------------
Setting ``options.enableShowPalettes`` has no effect anymore and can be removed from ``PageTSconfig``.
TCA
---
Setting ``canNotCollapse`` in ``ctrl`` and ``palettes`` section are obsolete and can be dropped:
.. code-block:: php
$GLOBALS['TCA']['aTable']['ctrl']['canNotCollapse'] = 1; // Obsolete
$GLOBALS['TCA']['aTable']['palettes']['aPaletteName']['canNotCollapse'] = 1; // Obsolete
PHP
---
The following method has been dropped, if an extension calls it, a ``PHP`` fatal error will be thrown.
This was an internal method and external usage is unlikely:
.. code-block:: php
\TYPO3\CMS\Backend\Controller\EditDocumentController->functionMenus()
The following properties have been dropped, calling those may trigger a ``PHP`` warning level error, external usage is unlikely:
.. code-block:: php
\TYPO3\CMS\Backend\Controller\EditDocumentController->MOD_MENU
\TYPO3\CMS\Backend\Controller\EditDocumentController->MOD_SETTINGS
\TYPO3\CMS\Backend\Form\FormEngine->palettesCollapsed
Affected Installations
======================
In the rare case that an extension uses one of the above methods or properties, a fatal PHP error may be triggered.
Migration
=========
The above properties can be dropped, the ``PageTS`` and ``TCA`` settings have no effect anymore.
......@@ -418,7 +418,6 @@ $GLOBALS['TCA']['tt_content']['palettes'] = array_replace(
--linebreak--,
header_link;LLL:EXT:cms/locallang_ttc.xlf:header_link_formlabel
',
'canNotCollapse' => 1
),
'headers' => array(
'showitem' => '
......@@ -432,7 +431,6 @@ $GLOBALS['TCA']['tt_content']['palettes'] = array_replace(
--linebreak--,
subheader;LLL:EXT:cms/locallang_ttc.xlf:subheader_formlabel
',
'canNotCollapse' => 1
),
'imageblock' => array(
'showitem' => '
......@@ -442,7 +440,6 @@ $GLOBALS['TCA']['tt_content']['palettes'] = array_replace(
image_noRows;LLL:EXT:cms/locallang_ttc.xlf:image_noRows_formlabel,
imagecaption_position;LLL:EXT:cms/locallang_ttc.xlf:imagecaption_position_formlabel
',
'canNotCollapse' => 1
),
'tablelayout' => array(
'showitem' => '
......@@ -451,7 +448,6 @@ $GLOBALS['TCA']['tt_content']['palettes'] = array_replace(
table_cellspacing;LLL:EXT:cms/locallang_ttc.xlf:table_cellspacing_formlabel,
table_cellpadding;LLL:EXT:cms/locallang_ttc.xlf:table_cellpadding_formlabel
',
'canNotCollapse' => 1
),
'visibility' => array(
'showitem' => '
......@@ -459,7 +455,6 @@ $GLOBALS['TCA']['tt_content']['palettes'] = array_replace(
sectionIndex;LLL:EXT:cms/locallang_ttc.xlf:sectionIndex_formlabel,
linkToTop;LLL:EXT:cms/locallang_ttc.xlf:linkToTop_formlabel
',
'canNotCollapse' => 1
),
'frames' => array(
'showitem' => '
......@@ -468,12 +463,10 @@ $GLOBALS['TCA']['tt_content']['palettes'] = array_replace(
spaceAfter;LLL:EXT:cms/locallang_ttc.xlf:spaceAfter_formlabel,
section_frame;LLL:EXT:cms/locallang_ttc.xlf:section_frame_formlabel
',
'canNotCollapse' => 1
)
)
);
$GLOBALS['TCA']['tt_content']['palettes']['image_settings']['canNotCollapse'] = 1;
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addFieldsToPalette(
'tt_content',
'image_settings',
......
......@@ -78,12 +78,24 @@ $tca = array(
),
),
'palettes' => array(
'10' => array('showitem' => 'visible, status, ranking', 'canNotCollapse' => '1'),
'20' => array('showitem' => 'creator_tool, publisher, source, copyright', 'canNotCollapse' => '1'),
'30' => array('showitem' => 'latitude, longitude', 'canNotCollapse' => '1'),
'40' => array('showitem' => 'location_country, location_region, location_city', 'canNotCollapse' => '1'),
'50' => array('showitem' => 'width, height, unit, color_space', 'canNotCollapse' => '1'),
'60' => array('showitem' => 'content_creation_date, content_modification_date', 'canNotCollapse' => '1'),
'10' => array(
'showitem' => 'visible, status, ranking',
),
'20' => array(
'showitem' => 'creator_tool, publisher, source, copyright',
),
'30' => array(
'showitem' => 'latitude, longitude',
),
'40' => array(
'showitem' => 'location_country, location_region, location_city',
),