Page MenuHomePhabricator

Cosmetic changes: sort template parameters
Open, LowestPublic

Description

e.g. překlady section on https://cs.wiktionary.org/w/index.php?title=a&action=edit&section=5 should have languages sorted alphabetically. Collation doesn't matter here, but it would be good to implement anyway, as it might matter for other templates.

Event Timeline

valhallasw raised the priority of this task from to Needs Triage.
valhallasw updated the task description. (Show Details)
valhallasw added a project: Pywikibot.
valhallasw added subscribers: valhallasw, Danny_B.
Restricted Application added subscribers: Aklapper, Unknown Object (MLST). · View Herald TranscriptMay 25 2015, 8:35 AM

@Danny_B: as far as I can see, _cswiktionary_preklady_sort.py already implements this? I also don't immediately see any existing sort in cosmetic_changes.py, so I'm not entirely sure anymore what the issue was here...

@Danny_B: /home/valhallasw/dannyb/_cswiktionary_preklady_sort.py has the code to do collation-aware sorting now.

(see code in T100265: Implement collation-aware sorting)

Xqt triaged this task as Lowest priority.Aug 26 2016, 7:38 AM
Xqt subscribed.

I guess cosmetic changes should not change template parameters generally. I propose to decline this request.

In VisualEditor is parameter sorting also implemented (through TemplateData), maybe this will be needed in the future, but for now this could be stalled on lowest priority and wait for its time

The parameter order is handled by TemplateData. Basically we should load TemplateData for every template on page and if paramOrder is present there, we should sort according to that. But this needs to load TemplateData first