Problem/Motivation

If you use an 'Advanced HTML/Text' element in a a webform it doesn't get displayed properly: its (HTML) content is left out. It has a type of 'processed_text' but when Civictheme's 'form-element--civictheme-field.html.twig' is invoked it isn't capable of handling that type.

Steps to reproduce

Add 'Advanced HTML/Text' element to webform and give it some default contents. Display the webform: contents is missng.

Proposed resolution

Either some extra preprocessing to allow 'form-element--civictheme-field.html.twig' to deal it or an additional
'form-element--civictheme-field--processed-text.html.twig' template that maps it to a paragraph (see example - but I don't know if this would have any unintended side-effect).

Remaining tasks

User interface changes

API changes

Data model changes

Comments

mwjansen created an issue. See original summary.

mwjansen’s picture

Issue summary: View changes
fionamorrison23’s picture

Assigned: Unassigned » richardgaunt

Hi @mwjansen thanks for logging this issue. We'll have a look at this. We're doing some work on webforms at the moment. we'll let you know if our work will fix the issue you're encountering.

richardgaunt’s picture

WE are actively working on this branch to create an opt-in system for form element preprocessing rather than the current opt-out.

https://github.com/civictheme/monorepo-drupal/pull/1306

The ck editor webform fields are something we are testing and ensuring are working before we are releasing a fix.

richardgaunt’s picture

sonam.chaturvedi’s picture

StatusFileSize
new392.12 KB
new2.04 MB

Verified and tested on 1.x-dev

Testing Results:
1. 'Advanced HTML/Text' element in a webform, the text is displayed properly - PASS
2. Webform elements and their respective HTML output correctly on the front-end - PASS

Screenshot:
advhtml

PFA screenshot of webform with Basic HTML element, Advanced HTML/Text & Horizontal rules.

richardgaunt’s picture

Version: 1.8.1 » 1.8.2
Status: Active » Reviewed & tested by the community
richardgaunt’s picture

Version: 1.8.2 » 1.9.0
Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

fionamorrison23’s picture