Page MenuHomePhabricator

Comments after template name broke template highlighting in CodeMirror
Open, LowPublic

Description

Steps to reproduce:

  1. Open the code with multi-line template transclusion and put cursor right after template name (e. g. {{Example).
  2. Add at least one newline (important!)
  3. Add a comment

The rest of the template will be highlighted as a plain code.

Example: ru:(619) Триберга


If comment goes on the same line with template start, the problem does not occurs:

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptAug 10 2018, 7:46 PM
Facenapalm triaged this task as Low priority.Aug 10 2018, 7:46 PM
Restricted Application added a project: Community-Tech. · View Herald TranscriptAug 10 2018, 7:46 PM
Facenapalm updated the task description. (Show Details)Aug 10 2018, 7:47 PM

This problem also occurs on frwiki.

fr:Constitution bolivienne de 2009

{{Infobox Norme juridique
<!-- PRESENTATION -->
 | désignation courte = 
 | image              = 
 | upright            = 
 | légende            = 
 ...
}}

HTML comment breaks the CodeMirror syntax highlighting, as on the screenshot above.

(sorry for my bad English)

Restricted Application added a subscriber: Liuxinyu970226. · View Herald TranscriptMar 20 2019, 10:16 AM