Details
-
Improvement
-
Resolution: Unresolved
-
Major
-
None
-
17.10.14, 18.8.0
-
None
-
Unknown
-
Description
Some macros take their input either from their content or from a parameter that replaces it. For example, the source parameter of the Code macro highlights a script variable or a page instead of the content. The two are exclusive, but the Edit Macro dialog shows them as unrelated fields: the user can fill both, and nothing says that source replaces the content.
Parameters that are alternatives of each other can already be grouped as one feature with @PropertyFeature, and the dialog then shows them as one choice. The content is not a parameter, so it cannot be part of a feature.
Steps to reproduce
- Edit a page with the WYSIWYG editor.
- Insert a Code macro.
Expected
The dialog offers to either type the code or pick a source, as one choice.
Actual
The Content field and the Source field, under the advanced parameters, are separate. Filling both is accepted.
Proposal
Allow the content descriptor of a macro to be part of a feature, like a parameter, and show the content and the parameters of that feature as one choice in the Edit Macro dialog.
Impact found on macro fluidity
The WYSIWYG usability audit of the macros checks with criterion C7 alternatives that the alternative ways to set the same thing are presented as one choice in the Edit Macro dialog. Three macros have a source parameter that replaces their content, and the dialog shows it as a separate field in all three:
- Code: the code to highlight, typed as the content or read by source from a script variable or a page.
- Content: the content to render, typed or read by source.
- Context: the content to render in the context of another page, typed or read by source.
The criterion was recorded OK on these macros, with a note pointing to the cross-macro findings of the WYSIWYG usability audit of the macros, since they cannot do better until it is fixed.
Attachments
Issue Links
- relates to
-
XCOMMONS-2738 Introduce the notion of mandatory property feature
-
- Closed
-
-
XWIKI-23043 Provide validation and UI for group of macro parameters belonging to same feature
-
- Closed
-