Hey everyone, just posting as I think I'm loosing it atm š
Iām migrating to Umbraco v15. Historically we used a lot of macros inside RTE tables. Each macro had a contentKey that we resolved against the Dictionary in the macro partial. In v15 Iām replacing those macros with a Block that also takes a contentKey and resolves it from the Dictionary.
What Iāve built-
The blockās RTE setting label uses:
{umbDictionary: contentKey}
I provide a UFM renderer:
class DictionaryUfmApi extends UmbUfmComponentBase
which outputs:
The element:
class UfmDictByAlias extends UmbUfmElementBase
reads the blockās actual value for contentKey, calls a backoffice API, and returns the Dictionary value for the current culture.
End-to-end, the API wiring works and returns the right value.
The issue-
In TinyMCE āclassicā, I just get:
(empty). The custom element only seems to run after a full page reload.
In TinyMCE āinlineā, it does resolve and render the Dictionary valueābut the editor itself becomes unusable (fields arenāt editable and the floating toolbar is way off). This makes the editor experience pretty buggy.
What Iāve tried-
I also explored TipTap:
(a) Allowing custom elements inside
so I can use blocks in tables (had to configure table headers from scratch).
(b) Avoiding automatic
wrapping by introducing a custom
block node so I donāt affect existing site styles.
(c) Dealing with the trailing empty block (
) TipTap keeps appending at the end of every RTE field.
TipTap is close but the last bit (trailing empty node) makes the output noisy unless I strip it, and thus far almost impossible to do?
Any pointers (or known limitations) would be much appreciated.