Page MenuHomePhabricator

Remove leading dashes from signature button on the edit toolbar
Closed, DeclinedPublic

Description

Author: rememberthedot

Description:
EditPage.php patch

The "Your signature with timestamp" button on the edit toolbar should generate ~~~~, not --~~~~. The extra dashes make it inconsistent with the character map below the edit box which uses ~~~~, and they also interfere with users who include the dashes in their custom signature.

This has been an issue for some time. See http://en.wikipedia.org/w/index.php?title=Wikipedia:Village_pump_%28proposals%29&oldid=181428756#Disparity_between_signature_.28.7E.7E.7E.7E.29_toolbar_buttons_and_character_map for an example of Wikipedians annoyed by this issue.

The fix to this is extremely simple. I've created a patch, based on MediaWiki 1.11.0, that works excellently.


Version: unspecified
Severity: enhancement

attachment EditPage.php ignored as obsolete

Details

Reference
bz12472

Event Timeline

bzimport raised the priority of this task from to Low.Nov 21 2014, 9:58 PM
bzimport set Reference to bz12472.
bzimport added a subscriber: Unknown Object (MLST).

sean.van.der.smythe wrote:

This should be an open and shut case right? Just implement the patch and achieve consistency.

robert wrote:

The button in question has always produce --~~~~ so the fact that it is inconsistent with the character map below the edit box is completely irrelevant as the character map is done on a wiki-by-wiki basis and is not part of the core code. I'm sure it would be possible to write a JavaScript function that replaces it.

An alternate solution would be to create a new interface message so it could be customized on a per-wiki basis -- I'm renaming this bug to that effect, although I would suggest this be closed as WONTFIX.

Also patches should be submitted in unified diff format, not the entire file, so they can be easily patched into the code.

rememberthedot wrote:

Isn't there already [[MediaWiki:Signature]] for customizing signature behavior? Doesn't it make more sense for wikis to use that if they want to add leading dashes to signatures? Creating yet another interface message is not what we want at all. We just want the leading dashes gone from the edit toolbar, and we can put them into [[MediaWiki:Signature]] if there is consensus to do so.

robert wrote:

Fair enough, thank you for the clarification, in this case I suggest you submit a patch that adds them to the default MediaWiki:Signature message (probably in languages/messages/MessagesEn.php) and removes them from the edit toolbar as you have already demonstrated a patch for. If you submit it in unified diff format on a copy of the latest SVN trunk then it will most likely get quickly commited.

rememberthedot wrote:

EditPage.php patch in unified diff format

OK, here is the same patch I submitted before, but in unified diff format. I looked and looked but couldn't find where the default value of Mediawiki:Signature and Mediawiki:Signature-ip is kept. It is a good idea to add the dashes there, but I just can't find the right file to edit.

Attached:

I'll echo Minute's comments that that particular button has given --~~~~ for an incredibly long time, and a change to its function would be abrupt, and I would guess most likely unwelcome, by everyday editors.

rememberthedot wrote:

If we change the default signature to include the two dashes, then it would alleviate the problem, and I suspect that most users use ~~~~ instead of --~~~~ anyway.

rotemliss wrote:

*** Bug 12468 has been marked as a duplicate of this bug. ***

Changing the default sig would be disruptive for all those times you want to use the sig in eg voting or other areas where you don't want a preceding dash. I'm a bit leery of changing the toolbar button either since it's been this way for some time.

Consistency on that particular wiki may be achieved by making the custom edit tool congruent with the standard toolbar.

  • Bug 25216 has been marked as a duplicate of this bug. ***

It seems like we need to be consistent above all else. The question is, what is the functional purpose of the dashes? Is this documented anywhere?

This is probably the easiest thing to fix ever, but I don't want to "fix" it only to get slapped by someone else.

(In reply to comment #11)

It seems like we need to be consistent above all else. The question is, what is
the functional purpose of the dashes? Is this documented anywhere?

I think it makes copying and pasting much clearer. You're more likely to realize when the message has ended and the username has begun with the two dashes.

This is probably the easiest thing to fix ever, but I don't want to "fix" it
only to get slapped by someone else.

LiquidThreads is presumably going to replace most wiki-page discussions, so I'm not sure if it's worth changing this for the sake of changing it at this point. I'm biased in that I like the current default, though.

*Bulk BZ Change: +Patch to open bugs with patches attached that are missing the keyword*

WONTFIXING per above. It's just stupid changing the default for arbitary reasons