[MGNLUI-7256] Strikethrough can't be used in richTextField Created: 21/Jun/22  Updated: 25/Jul/22  Resolved: 15/Jul/22

Status: Closed
Project: Magnolia UI
Component/s: None
Affects Version/s: 6.3.0, 6.2.20
Fix Version/s: 6.2.22

Type: Bug Priority: Neutral
Reporter: Roman Kovařík Assignee: Sang Ngo Huu
Resolution: Fixed Votes: 0
Labels: None
Σ Remaining Estimate: Not Specified Remaining Estimate: Not Specified
Σ Time Spent: 1d 5.5h Time Spent: 2.5h
Σ Original Estimate: Not Specified Original Estimate: Not Specified

Issue Links:
causality
caused by MGNLUI-6975 CKEditor removes superscript and subs... Closed
Sub-Tasks:
Key
Summary
Type
Status
Assignee
MGNLUI-7340 Provide PRs Sub-task Completed Sang Ngo Huu  
MGNLUI-7341 Code review Sub-task Completed Quach Hao Thien  
MGNLUI-7342 Pre-int QA Sub-task Completed Jaromir Sarf  
MGNLUI-7343 QA Sub-task Completed Roman Kovařík  
MGNLUI-7344 Integrate Sub-task Completed Sang Ngo Huu  
MGNLUI-7354 Unit tests for validator config changes Sub-task Completed Antonín Juran  
MGNLUI-7355 Rename Strikethrough to Strike item i... Sub-task Closed Antonín Juran  
MGNLUI-7356 Rv/piQA for subtasks MGNLUI-7354 and ... Sub-task Closed Jaromir Sarf  
MGNLUI-7357 Integrate PRs for subtasks MGNLUI-735... Sub-task Closed Antonín Juran  
MGNLUI-7358 Final QA Sub-task Completed Quach Hao Thien  
Template:
Acceptance criteria:
Empty
Task DoD:
[X]* Doc/release notes changes? Comment present?
[X]* Downstream builds green?
[X]* Solution information and context easily available?
[X]* Tests
[X]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Release notes required:
Yes
Epic Link: richTextField HTML validation
Sprint: Nucleus 14
Story Points: 2
Team: Nucleus

 Description   

Steps to reproduce:

  1. Enable source=true for a richTextField
  2. Open this richTextField
  3. You can see that Strikethrough is not available in the toolbar.
  4. Switch to the Source mode
  5. Insert <s>something</s>
  6. Switch back from Source mode

Expected result

I can see the text with strikethrough.

Actual result

The s tag is removed by CKEditor because Strikethrough is not allowed from the toolbar.

Workaround

  1. By hotfixing the default magnolia config (Magnolia OnPrem) or providing a custom config (Cloud) from your light module:
  2. Replace "Strikethrough" with "Strike"
  3. Replace source: false, with source: true,
  4.       $type: richTextField
          configJsFile: http://localhost:8080/.resources/ckeditor/config-magnolia.js
          validators: {} # Only if you trust your editors!
     
  1. Clear your browser cache.
  2. Open the dialog with richTextField again.
  3. You might need to adjust other settings as now the config is loaded only from this file instead of from the richTextField properties.

Generated at Mon Feb 12 09:44:33 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.