Hi everyone,
we have certain macros like mentions or footnotes, for which it just doesn’t make any sense to use them in standalone mode - it would be totally surprising for a user to insert them in the WYSIWYG editor and then not to be able to insert text in the same line before or after them.
I would therefore suggest introducing a way for macros to indicate that they don’t support standalone mode similar to how macros can already indicate that they don’t support inline mode.
There are several options for this:
- Duplicate what we have for
supportsInlineMode
assupportsStandaloneMode
, at least the part in the macro descriptor and in the wiki macro descriptor. The default would betrue
for this new property. - Refactor the macro descriptor and the wiki macro definition to have a set of supported modes with
inline
andstandalone
as possible values and deprecate the existingsupportsInlineMode
methods. Of course, there would be backwards compatibility code to ensure that the existing methods still work, which might be a bit complex to support all possibilities.
I propose the following consequences when a macro is marked as supporting inline mode only:
- Ensure that CKEditor always inserts such macros as inline, similar to the existing
inline: enforce
property. - Before the macro transformation executes such a macro, if the macro is marked as standalone, the macro is wrapped in a paragraph.
Do you have any opinions on this, in particular related to how this property should be stored?
5 posts - 2 participants