Human-readable section ID support
authorMax Semenik <maxsem.wiki@gmail.com>
Fri, 30 Jun 2017 00:13:12 +0000 (17:13 -0700)
committerMax Semenik <maxsem.wiki@gmail.com>
Wed, 2 Aug 2017 03:32:20 +0000 (20:32 -0700)
commitfd6e9ef2d481209b01fa6e1bb1c863b8257f0272
treef47713c63fdb6c8970faaa1a2d8ac7e69b3c61ab
parent1f2c768a9df46909932b44443f733d2185517435
Human-readable section ID support

It adds the ability to replace the current section ID escaping
schema (.C0.DE) with a HTML5-compliant escaping schema that is
displayed as Unicode in many modern browsers.

See the linked bug for discussion of various options that were
considered before the implementation. A few remarks:
* Because Sanitizer::escapeId() is used in a bunch of places without
  escaping, I'm deprecating it without altering its behavior.
* The bug described in comments for Parser::guessLegacySectionNameFromWikiText()
  is still there in some Edge versions that display mojibake.

Bug: T152540
Change-Id: Id304010a0342efbb7ef2d56c5b8b244f2e4fb2c5
31 files changed:
RELEASE-NOTES-1.30
autoload.php
includes/DefaultSettings.php
includes/EditPage.php
includes/Linker.php
includes/Sanitizer.php
includes/Setup.php
includes/Title.php
includes/actions/InfoAction.php
includes/api/ApiMain.php
includes/htmlform/HTMLForm.php
includes/htmlform/HTMLFormField.php
includes/htmlform/OOUIHTMLForm.php
includes/htmlform/fields/HTMLFormFieldCloner.php
includes/htmlform/fields/HTMLRadioField.php
includes/page/ImagePage.php
includes/parser/Parser.php
includes/resourceloader/ResourceLoaderMediaWikiUtilModule.php [new file with mode: 0644]
includes/skins/BaseTemplate.php
includes/skins/Skin.php
includes/specials/SpecialListgrants.php
includes/specials/SpecialListgrouprights.php
includes/specials/SpecialVersion.php
includes/specials/pagers/AllMessagesTablePager.php
resources/Resources.php
resources/src/mediawiki.action/mediawiki.action.edit.preview.js
resources/src/mediawiki/mediawiki.util.js
tests/parser/ParserTestRunner.php
tests/parser/parserTests.txt
tests/phpunit/includes/SanitizerTest.php
tests/qunit/suites/resources/mediawiki/mediawiki.util.test.js