New content element wizard 

Since TYPO3 v13 the new content element wizard is built from TCA. Every academic content element is an item of the type field of tt_content in the group academic, which this extension registers, and the wizard shows the items of a group in the order the extensions registered them. Page TSconfig below mod.wizards.newContentElement.wizardItems changes what the wizard shows. Everything on this page applies to TYPO3 v13 and v14 alike, except the ordering of elements with before and after, which needs TYPO3 v14.

The behaviour of the wizard this page describes is covered by the functional test Tests/Functional/Backend/NewContentElementWizardTest.php of this extension, which renders the wizard on both versions with the page TSconfig shown here.

Which academic elements the wizard offers 

Every academic extension hides its content elements for the whole installation and brings each one back through the set or the page TSconfig file of its component, see the Configuration chapter of the extension. The wizard follows the type field: a type that TCEFORM.tt_content.CType.removeItems removes is missing from the wizard as well.

Where the group appears 

The page TSconfig this extension loads for the whole installation labels the group and gives it no position:

mod.wizards.newContentElement.wizardItems.academic {
  header = LLL:EXT:academic_base/Resources/Private/Language/locallang_be.xlf:content.ctype.group.label
}
Copied!

Without a position the groups follow the order of their TCA registration, and the group follows the groups of TYPO3, because this extension registers it after them. An extension that registers a group of its own later adds it behind. On an installation without other groups and positions, the wizard shows:

  1. Typical page content (default)
  2. Lists (lists)
  3. Menu (menu)
  4. Form elements (forms)
  5. Special elements (special)
  6. Plugins (plugins)
  7. Academic (academic)

A group without elements is not shown.

To show the group first, place it before Typical page content:

mod.wizards.newContentElement.wizardItems.academic.before = default
Copied!

A single before or after changes how TYPO3 orders all groups. With one, TYPO3 orders them by those settings: the groups named in them come first, in the order the settings ask for, and every other group follows in the alphabetical order of its identifier. The setting above therefore shows Academic, Typical page content, Form elements, Lists, Menu, Plugins and Special elements, in this order.

Before version 3.0 this extension placed the group with after = special. That showed Special elements and Academic first, followed by the other groups in alphabetical order. A site that wants this placement back sets it again:

mod.wizards.newContentElement.wizardItems.academic.after = special
Copied!

The before and after of every extension and of the site take part in the same ordering, so an installation that positions groups of its own gets a different result.

Renaming the group and its elements 

The header of the group and the title and description of an element are replaced by page TSconfig. An element is addressed by its content type, the value of the type field:

mod.wizards.newContentElement.wizardItems.academic {
  header = University
  elements.academicpersons_list {
    title = Staff directory
    description = All people of a department, with a letter navigation
  }
}
Copied!

Each value may be a plain text or an LLL: reference.

TCEFORM.tt_content.CType.altLabels.<type> renames the type in the type field of the content element only. The wizard keeps its own title, so a project that wants both renamed sets both.

Hiding an element or the group 

removeItems of the group hides one element in the wizard, and removeItems of the wizard hides a whole group:

# Hides one element. Its type stays selectable in the type field.
mod.wizards.newContentElement.wizardItems.academic.removeItems := addToList(academicpersons_selectedcontracts)

# Hides the whole group.
mod.wizards.newContentElement.wizardItems.removeItems := addToList(academic)
Copied!

To hide an element in the type field too, remove the type with TCEFORM.tt_content.CType.removeItems , which the wizard follows.

The option show of TYPO3 v12 is no longer read, see Breaking: #102834.

Ordering the elements 

On TYPO3 v14, before and after order the elements inside a group, as they order the groups. TYPO3 added this in version 14.2 (Feature: #87435):

mod.wizards.newContentElement.wizardItems.academic.elements {
  academicpersons_listanddetail.before = academicpersons_list
}
Copied!

TYPO3 v13 reads before and after of a group only, and ignores them on an element. There, the order comes from defining the elements again in page TSconfig. An element whose tt_content_defValues set the type and nothing else replaces the one TYPO3 builds from TCA, and the elements defined again follow the elements that are not, in the order of the page TSconfig. Define every element of the group again, with the icon, the title and the description it should show:

mod.wizards.newContentElement.wizardItems.academic.elements {
  academicpersons_listanddetail {
    iconIdentifier = tx-academicpersons-plugin-persons
    title = LLL:EXT:academic_persons/Resources/Private/Language/locallang_be.xlf:plugin.listAndDetail.label
    tt_content_defValues.CType = academicpersons_listanddetail
  }
  academicpersons_list {
    iconIdentifier = tx-academicpersons-plugin-persons
    title = LLL:EXT:academic_persons/Resources/Private/Language/locallang_be.xlf:plugin.list.label
    tt_content_defValues.CType = academicpersons_list
  }
  # ... every other element of the group
}
Copied!

This works on TYPO3 v14 as well. An element defined again does not follow a later change of its icon, title or description in the extension, so prefer before and after once an installation runs TYPO3 v14.

The content types of every academic extension are listed in Permission sets.