Use CKEditor 5 for text area prop's example form element in code editor, adjust prop shape sent to backend

Created on 14 April 2025, 28 days ago

Overview

Text area props can be defined for code components using the code editor. The form element that allows users to enter an example value currently outputs an HTML element with no WYSIWYG editor.

Proposed resolution

  1. Add CKEditor 5 to the example for element;
  2. Adjust the shape sent to the backend that describes a text area — update prop serialization/deserialization in ui/src/features/code-editor/utils.ts;
    1. Make this new shape the default for text areas — we can assume all of them want a WYSIWYG editor;
    2. See 📌 `StringSemanticsConstraint::MARKUP`: agree how SDC prop JSON schema can convey it should be markup, and Needs review for more details;
    3. See example prop shapes here;
  3. Update component test to ensure CKEditor 5 appears: ui/tests/unit/code-editor-component-data-props.cy.jsx;
  4. Update prop serialization/deserialization unit test in ui/tests/unit/code-editor-utils.cy.jsx.

User interface changes

CKEditor 5 appears over text area example value form element in code editor.

Feature request
Status

Active

Version

0.0

Component

Theme builder

Created by

🇳🇱Netherlands balintbrews Amsterdam, NL

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

Merge Requests

Comments & Activities

Production build 0.71.5 2024