Page MenuHomePhabricator

VisualEditor: In templates with both "default" and "example" values in TemplateData, only "default" shows in the input box
Closed, DuplicatePublic

Assigned To
None
Authored By
SUM1
Mar 11 2020, 5:24 AM
Referenced Files
F31675834: image.png
Mar 11 2020, 5:24 AM
F31675836: image.png
Mar 11 2020, 5:24 AM
F31675838: image.png
Mar 11 2020, 5:24 AM

Description

Currently, when a template has TemplateData and has both a "default" and an "example" value specified for a parameter, only the "default" value shows in the input box of the parameter. (Both show in the tooltip.)

image.png (131×484 px, 8 KB)

For comparison, here's a parameter with only "example":

image.png (109×477 px, 7 KB)

and a parameter with only "default":

image.png (112×478 px, 7 KB)

Please fix this so that a template with both "default" and "example parameters" show both in the input box, probably as follows:

  • e.g., example (default: default)

Additionally, "e.g." needs grammatically correcting. It should be "e.g.,".

Event Timeline

This has been made consistent by the WMDE Technical Wishes team as a part of their work on templates in visual editor. Although the consistency is now in the opposite direction than you requested – the examples are never shown in the input as a placeholder. (They are however shown prominently above the input.) The change is not enabled on Wikimedia wikis yet, please watch this page for updates: https://meta.wikimedia.org/wiki/WMDE_Technical_Wishes/VisualEditor_template_dialog_improvements.