You are here

public function BookManagerInterface::addFormElements in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/book/src/BookManagerInterface.php \Drupal\book\BookManagerInterface::addFormElements()

Builds the common elements of the book form for the node and outline forms.

Parameters

array $form: An associative array containing the structure of the form.

\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.

\Drupal\node\NodeInterface $node: The node whose form is being viewed.

\Drupal\Core\Session\AccountInterface $account: The account viewing the form.

bool $collapsed: If TRUE, the fieldset starts out collapsed.

Return value

array The form structure, with the book elements added.

1 method overrides BookManagerInterface::addFormElements()
BookManager::addFormElements in core/modules/book/src/BookManager.php
Builds the common elements of the book form for the node and outline forms.

File

core/modules/book/src/BookManagerInterface.php, line 228

Class

BookManagerInterface
Provides an interface defining a book manager.

Namespace

Drupal\book

Code

public function addFormElements(array $form, FormStateInterface $form_state, NodeInterface $node, AccountInterface $account, $collapsed = TRUE);