mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-12 09:09:25 +00:00
Merge "Make it possible for wikis to have the 2017 wikitext editor by default"
This commit is contained in:
commit
b9b729b615
|
@ -377,6 +377,7 @@
|
|||
"visualeditor-preference-core-info-link": "\/\/mediawiki.org\/wiki\/Special:MyLanguage\/VisualEditor\/Beta_Features\/General",
|
||||
"visualeditor-preference-core-label": "Visual editing",
|
||||
"visualeditor-preference-enable": "Enable the visual editor. It will be available in the following {{PLURAL:$2|namespace|namespaces}}: $1",
|
||||
"visualeditor-preference-newwikitexteditor-enable": "Use the wikitext mode inside the visual editor, instead of a different wikitext editor.",
|
||||
"visualeditor-preference-newwikitexteditor-description": "Enable the new wikitext mode inside the visual editor. It has many of the tools present in the visual editor, uses a similar design, and allows better switching between the two.",
|
||||
"visualeditor-preference-newwikitexteditor-discussion-link": "\/\/mediawiki.org\/wiki\/2017_wikitext_editor\/Feedback",
|
||||
"visualeditor-preference-newwikitexteditor-info-link": "\/\/mediawiki.org\/wiki\/Special:MyLanguage\/2017 wikitext editor",
|
||||
|
|
|
@ -390,6 +390,7 @@
|
|||
"visualeditor-preference-core-info-link": "{{optional|Used on [[Special:Preferences]] as a link to a page where users can learn about this Beta Feature. Defaults to a page on MediaWiki.org.}}",
|
||||
"visualeditor-preference-core-label": "Used in [[Special:Preferences]].\n\nUsed as label for checkbox to enable the visual editor.\n\nThe description for this checkbox is: {{msg-mw|Visualeditor-preference-core-description}}",
|
||||
"visualeditor-preference-enable": "Label for the user preference to enable VisualEditor while it is in alpha (opt-in) mode.\nLinks are in {{msg-mw|Visualeditor-mainnamespacepagelink}} and {{msg-mw|visualeditor-usernamespacepagelink}}.\n\nParameters:\n* $1 - Comma separated list of namespace names.\n* $2 - Number of namespaces in which it will be used.\n\nSee also:\n* {{msg-mw|Visualeditor-preference-core-description}}",
|
||||
"visualeditor-preference-newwikitexteditor-enable": "Label for the user preference to use the wikitext mode inside the visual editor. It replaces the wikitext editor software.",
|
||||
"visualeditor-preference-newwikitexteditor-description": "Used in [[Special:Preferences]].\n\nUsed as description for the checkbox to enable the new wikitext editor.\n\nThe label for this checkbox is {{msg-mw|Visualeditor-preference-newwikitexteditor-label}}.",
|
||||
"visualeditor-preference-newwikitexteditor-discussion-link": "{{optional|Used on [[Special:Preferences]] as a link to a page where users can discuss this Beta Feature. Defaults to a page on MediaWiki.org.}}",
|
||||
"visualeditor-preference-newwikitexteditor-info-link": "{{optional|Used on [[Special:Preferences]] as a link to a page where users can learn about this Beta Feature. Defaults to a page on MediaWiki.org.}}",
|
||||
|
|
|
@ -657,6 +657,15 @@ class VisualEditorHooks {
|
|||
$user->getOption( 'visualeditor-autodisable' )
|
||||
];
|
||||
|
||||
// Config option for wikitext editing "deployed" state (opt-out)
|
||||
if ( $config->get( 'VisualEditorEnableWikitext' ) ) {
|
||||
$preferences['visualeditor-newwikitext'] = [
|
||||
'type' => 'toggle',
|
||||
'label-message' => 'visualeditor-preference-newwikitexteditor-enable',
|
||||
'section' => 'editing/editor'
|
||||
];
|
||||
}
|
||||
|
||||
// Config option for Single Edit Tab
|
||||
if (
|
||||
$config->get( 'VisualEditorUseSingleEditTab' ) &&
|
||||
|
|
Loading…
Reference in a new issue