Skip to content

Commit

Permalink
parse refs for front-end
Browse files Browse the repository at this point in the history
  • Loading branch information
i-just committed Apr 5, 2024
1 parent 5d67b21 commit 331989d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/Field.php
Original file line number Diff line number Diff line change
Expand Up @@ -1007,6 +1007,11 @@ protected function prepValueForInput($value, ?ElementInterface $element, bool $s
$value = $this->_prepNestedEntriesForDisplay($value, $element?->siteId, $static);
}

// @see https://github.com/craftcms/ckeditor/issues/197
if (!$this->isCpRequest()) {
$value = Craft::$app->getElements()->parseRefs($value, $element?->siteId);
}

return parent::prepValueForInput($value, $element);
}

Expand Down

0 comments on commit 331989d

Please sign in to comment.