Module Description
The Block Form Alter module provides functions to alter block forms consistently across implementing plugins:


* hook_block_plugin_form_alter()
* hook_block_type_form_alter()

Block forms are rendered by implementing plugins, which may require duplicate code in some instances where a developer desires to alter a given block form. This is particularly true when altering forms rendered by Layout Builder.

Supported Modules
* Block (core)
* Block Content (core)
* Layout Builder (core)

hook_block_plugin_form_alter() The hook_block_plugin_form_alter() function allows for block forms to be targeted by plugin id. Block forms rendered by the 'block_content' and 'inline_block' plugins must be altered with hook_block_type_form_alter(). See block_form_alter.api.php for details.

hook_block_type_form_alter() The hook_block_type_form_alter() function modifies block forms rendered by both Block Content ('block_content' plugin) and Layout Builder ('inline_block' plugin). See block_form_alter.api.php for details.

Related Core Issue
* #3028391: It's very difficult to alter forms of inline (content blocks) placed via Layout Builder

Project Usage
1766
Creation Date
Changed Date
Security Covered
Covered By Security Advisory
Version Available
Production
Module Summary
The Block Form Alter module aims to provide consistent alteration of block forms across implementing plugins, particularly for forms rendered by Layout Builder.
Data Name
block_form_alter

OPENAI CHATBOT

OPENAI CHATBOT

10:25:56
Generic Chatbot
Hi, I'm a Drupal module expert powered by OpenAI, answering your questions about the Drupal module ecosystem. How can I be helpful today? Please note that we will log your question.