hook_field_widget_paragraphs_form_alter() not called in D10

Created on 14 April 2023, over 1 year ago
Updated 8 July 2024, 5 months ago

Problem/Motivation

Drupal Version: 10.2.5

None of following hooks are called in Edit form.

my_module_field_widget_paragraphs_form_alter()
my_module_field_widget_entity_reference_paragraphs_form_alter()
my_module_field_widget_single_element_WIDGET_TYPE_form_alter()
hook_field_widget_single_element_paragraphs_form_alter
hook_common_field_widget_complete_paragraphs_form_alter
hook_field_widget_paragraphs_form_alter

Steps to reproduce

1. Add paragraph reference field to a node.
2. Try to add or edit.
3. hook is not called, thus I do not see any dump result for following code in my module.

<?php
function my_module_field_widget_entity_reference_paragraphs_form_alter(&$element, &$form_state, $context) {
  dump($element);
}
?>

Proposed resolution

Identify and document the proper hook

Remaining tasks

Add the appropriate hook to paragraphs.api.php

User interface changes

None

API changes

None

Data model changes

None

πŸ’¬ Support request
Status

Fixed

Version

1.0

Component

Code

Created by

πŸ‡¨πŸ‡¦Canada Austin986

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024