From d0102fa48400c35906531589e94e93b05cb3d5b3 Mon Sep 17 00:00:00 2001 From: brandonkelly Date: Fri, 8 Mar 2024 11:55:19 -0800 Subject: [PATCH] 4.0.0-beta.9 - Fixed rendering bug --- CHANGELOG.md | 4 ++++ src/Field.php | 12 ++++++++++++ 2 files changed, 16 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index ce66397e..224637f9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Release Notes for CKEditor for Craft CMS +## 4.0.0-beta.9 - 2024-03-08 + +- Fixed a bug where nested entries weren’t getting rendered in front-end output. + ## 4.0.0-beta.8 - 2024-03-07 - CKEditor fields now support multiple instances. ([#188](https://github.com/craftcms/ckeditor/pull/188)) diff --git a/src/Field.php b/src/Field.php index 69efdc62..6d713946 100644 --- a/src/Field.php +++ b/src/Field.php @@ -628,6 +628,18 @@ public function getSettings(): array return $settings; } + /** + * @inheritdoc + */ + public function normalizeValue(mixed $value, ?ElementInterface $element = null): mixed + { + if (!$this->isCpRequest()) { + $value = $this->prepValueForInput($value, $element); + } + + return parent::normalizeValue($value, $element); + } + /** * @inheritdoc */