Closed bjarnef closed 5 months ago
@AndyButland is this an oversight in Forms Delivery API? I can't check the source code, but I guess it doesn't parse the richtext like is does in Umbraco core 🙃
Yes, we handle this for the Razor rendering of the rich text field, but don't have an equivalent for the API. Thanks for the link to how this is done in the CMS - does seem we can use that same service - so we've prepared this for the next release.
I am seeing the same issue with Umbraco 14 V2 endpoint: /umbraco/delivery/api/v2/content/item/
Possibly it needs to be patched there as well?
@jlfolland - just tested, and although we have patched it there, I see that it's not working as expected.
I think the issue though lies with the CMS and how the markup for local links is being generated from the rich text editor, so I've raised an issue here: https://github.com/umbraco/Umbraco-CMS/issues/16631
In a headless setup we can fetch form using Deliery API: https://docs.umbraco.com/umbraco-forms/developer/ajaxforms
However it seems a link inserted in richtext field, with a node selected, returns
/{localLink:umb...}
from API./umbraco/forms/api/v1/definitions/82fd5604-186f-404c-b5cc-12335690a77f
when I check the same for a content page using Content Delivery API is has resolved the value.
/umbraco/delivery/api/v1/content/item/b665966b-7da7-4f04-bc61-18314b83a1a7
For Content / Media Delivery API it seems to happen here: https://github.com/umbraco/Umbraco-CMS/blob/v13/dev/src/Umbraco.Infrastructure/DeliveryApi/ApiRichTextMarkupParser.cs#L35-L37
which comes from a
ApiRichTextParserBase
class: https://github.com/umbraco/Umbraco-CMS/blob/v13/dev/src/Umbraco.Infrastructure/DeliveryApi/ApiRichTextParserBase.cs