|
| Summary: |
Use a number fields field for the number of events of the activity and notifications macros macro |
| Description: |
The activity and notifications macros take macro takes the number of events to list in a plain text field of the Edit Macro dialog, so any text can be typed and the user only sees the result after the macro renders.
The macros to change, with the file where most of the fix parameter is done: * activity: declared in [ ActivityMacro.xml|https://github.com/xwiki/xwiki-platform/blob/master/xwiki-platform-core/xwiki-platform-legacy/xwiki-platform-legacy-notifications/xwiki-platform-legacy-notification-activitymacro/src/main/resources/XWiki/Notifications/Code/Legacy/ActivityMacro.xml]. * notifications: [ NotificationsMacro.xml|https://github.com/xwiki/xwiki-platform/blob/master/xwiki-platform-core/xwiki-platform-notifications/xwiki-platform-notifications-macro/xwiki-platform-notifications-macro-ui/src/main/resources/XWiki/Notifications/Code/Macro/NotificationsMacro.xml]. The activity macro is left out: it is a legacy macro, to be deprecated in XWIKI-25515.
The main problem: * Both parameters are The parameter is declared without a numeric type, so the dialog cannot offer a number field even once one exists. They need It needs an integer type and a minimum of 1.
h2. Depends on Most of these fields cannot be offered before these generic changes, each giving the macro the means to declare the expected value: * XWIKI-25182, which gives a number input to the parameters of a numeric type. * XWIKI-25197, which lets a wiki macro parameter declare its minimum and maximum.
h2. KOs covered ||Macro||Criterion||Parameter||Problem||Depends on|| |[ activity|https://design.xwiki.org/xwiki/bin/view/Proposal/WYSIWYGusabilityofXWikimacros/Macros/activity/]|C4 input-assistance|{{entries}}|A plain text field for the maximum number of events listed.|XWIKI-25182, XWIKI-25197| |[ notifications|https://design.xwiki.org/xwiki/bin/view/Proposal/WYSIWYGusabilityofXWikimacros/Macros/notifications/]|C4 input-assistance|{{count}}|A plain text field for the number of events: {{count="-3"}} is accepted and shows one event.|XWIKI-25182, XWIKI-25197|
h2. Impact found on macro fluidity These 2 KOs come This KO comes from the [WYSIWYG usability audit of the macros|https://design.xwiki.org/xwiki/bin/view/Proposal/WYSIWYGusabilityofXWikimacros/Macros/], under the criterion C4 input-assistance of its [usability criteria|https://design.xwiki.org/xwiki/bin/view/Proposal/WYSIWYGusabilityofXWikimacros/Usability%20criteria/]. The page of each the macro, linked in the table, has the full notes and the steps to reproduce. Fixing them means changing the declaration of the parameters in the macro definitions. |
|