Umbraco-CMS
Umbraco-CMS copied to clipboard
[V14] Make the backend work with the new localLinks format
Description
The new backoffice has removed UDI notation from the locallinks format in RTE tags and split up the type and key into 2 attributes (href and type).
The backend was not fully updated and so when rendering the content trough razor pages, or retrieving trough the content delivery api, the locallink notation was not properly replaced by the actual content/media urls.
This PR aims to fix this and update/improve the unittests along the way.
The old format was not migrated to the new format in the v14 migration and this is currently not changing as the backend can handle both.
Testing
Consider both RTEs on a document type and RTEs in block Both migrated and new data should work as expected Both Razor rendering and delivery api parsing should create similar output when comparing v13 and v14 data, both migrated and new, when it comes to v14. The backoffice should allow editing of both old and new formatted data. Non Local links should still work.
Notes
There is a decent amount of duplicated code, I chose not to refactor this as we should obsolete/remove it at some point anyway. This will require some form of migrating the old formatted data.