Error adding element with element preview broken in development

Created on 23 June 2025, 14 days ago

Problem/Motivation

Something in the preview path for form elements seems to be generating invalid elements missing the webform_key component leading to the following error in the ajax response:

\nAn AJAX HTTP error occurred.\nHTTP Result Code: 200\nDebugging information follows.\nPath: /admin/structure/webform/manage/apqc_membership_demo/element/add\nStatusText: parsererror\nResponseText: Warning: Undefined array key "#webform_key" in /app/web/modules/contrib/webform/src/Plugin/WebformElement/WebformManagedFileBase.php on line 301\n{....}

Steps to reproduce

1. Open webform
2. Click add element
3. Click "Show Preview"

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

πŸ› Bug report
Status

Active

Version

6.2

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States neclimdul Houston, TX

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

Comments & Activities

  • Issue created by @neclimdul
  • πŸ‡ΊπŸ‡ΈUnited States neclimdul Houston, TX

    Filed against 6.2 as I've only had a chance to test it there so far but I don't see any obvious changes that would have fixed this in newer versions.

Production build 0.71.5 2024