Page MenuHomePhabricator

Enable multiline TemplateData descriptions with \n
Closed, DeclinedPublic

Description

Currently, template description and params description are on a single line whereas it is sometimes clearer to view an help on several lines.

\n symbol works on documentation page : we see a line break. But it does not show on TemplateData visual editor and on VisualEditor. On fr.wp there is a CSS edit suggestion.

Is it possible to allow to insert line breaks with <br> markup or with \n character please ?
Exemple of utilisation : fr:template:Lien web

Event Timeline

Pols12 raised the priority of this task from to Needs Triage.
Pols12 updated the task description. (Show Details)
Pols12 added a project: TemplateData.
Pols12 subscribed.

<br> would be part of T52656, but I think we should probably make \n get handled as a newline?

Jdforrester-WMF renamed this task from Enable multiline descriptions : allow line breaks with \n or <br> to Enable multiline TemplateData descriptions with \n.Jan 26 2016, 10:18 PM
Jdforrester-WMF triaged this task as Low priority.
Jdforrester-WMF set Security to None.

<br> would be part of T52656, but I think we should probably make \n get handled as a newline?

The equivalent of nl2br() basically. While that seems fine, this would be the beginning of TemplateData defining a proprietary markup language for its descriptions.

Do we really want multi-paragraph text in parameter descriptions?

Jdforrester-WMF subscribed.

Agreed. On reflection, I'm going to Decline.

270723-64n.png (261×553 px, 18 KB)
This sounds like a dealbreaker for some people (us included) then. The examples look horrible when using a template inside template. You should at the very least consider making it toggleable.

For nested templates, T52355 is a better feature request.
Also, that template could be rewrote to support direct values instead of requesting a template call as a value.