Macro Parameters Improvements (10.x)

Last modified by Vincent Massol on 2024/02/26 17:52

 XWiki
 Requirements
 Idea
 

Description

General

UC: Use auto-complete for "List of strings" type parameter that expect Pages, Wikis, Users
UC: Use checkboxes for any "Boolean" type parameter
UC: Use select if there are multiple allowed values
UC: Provide the default value as placeholder for any "String or numerical value" type parameter
UC: Display the available macro parameters options in more usable controls, allowing faster usage
UC: Good Defaults: Provide demo content examples that work and can be experimented

Macros Count

UC: Know how many available macros there are
  • There are 51 macros available in 10 categories (All + Other + 8)

Before
macros.png

After
macros_count_after.png
macros_count_after_expanded.png

Back to Gallery

UC: Have a button that takes the user back to the gallery
  • The button exists, but because of position / naming, users don't use it and they redo the steps from the start

Before
macros_back.png

After
macros_back_after.png

Macros Documentation

UC: Know how many available macros there are

Before
macros_doc.png

After
macros_doc_after.png

Deprecated Macros

UC: Remove these macros
  • Space Index Macro
  • Spaces Macro
  • Workspaces Legacy

Move Macros

  • Move from Content to Development category
    • Display, Include Macros
    • Translation Macro
  • Move from Content to Notifications category
    • Activity Macro
    • Watch List Macro
    • RSS Macro ?
  • Move from Social to Notifications category
    • Message Sender - being the only one listed

Macros

Macro: Activity

  • URL
  • Placeholders
  • Wiki/Page/Authors/(Tags) references autocomplete

activity_before.png

activity_after.png

Macro: Chart

  • URL
  • Good Defaults that have a demo example that can be tested
  • Placeholders
  • Select control instead of input for type and source params

chart_before.png

<select>
<option disabled="" selected="">Select an option</option>
<option>area </option>
<option>bar </option>
<option>bar3D </option>
<option>line  </option>
<option>line3D </option>
<option>pie </option>
<option>stackedbar </option>
<option>stackedbar3D </option>
<option>xy_area </option>
<option>xy_line_and_shape </option>
<option>xy_line3D </option>
<option>xy_step </option>
</select>
{{chart type="pie" params="range:B2-D5" source="inline"}}
|=|=X|=Y|=Z
|Q1|1.2|3.4|1.3
|Q2|4.5|3.4|2.3
|Q3|1.2|4.5|9.0
|Q4|3.4|1.2|1.2
{{/chart}}

Macro: Content

  • URL
  • Good Default
  • Select control for syntax param

content_before.png

content_after.png

Macro: Display, Include

display_before.png

display_after.png

Macro: Office Document Viewer

  • URL
  • Auto-complete

office_before.png

office_after.png

etc.



 

Tags:
    

Get Connected