mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-24 22:35:41 +00:00
Merge "Use prefixed page title for browser title bar"
This commit is contained in:
commit
f17414f9d5
|
@ -1311,9 +1311,14 @@ ve.init.mw.ViewPageTarget.prototype.tearDownDebugBar = function () {
|
|||
* Change the document title to state that we are now editing.
|
||||
*/
|
||||
ve.init.mw.ViewPageTarget.prototype.changeDocumentTitle = function () {
|
||||
var pageName = mw.config.get( 'wgPageName' ),
|
||||
title = mw.Title.newFromText( pageName );
|
||||
if ( title ) {
|
||||
pageName = title.getPrefixedText();
|
||||
}
|
||||
document.title = ve.msg(
|
||||
this.pageExists ? 'editing' : 'creating',
|
||||
mw.config.get( 'wgTitle' )
|
||||
pageName
|
||||
) + ' - ' + mw.config.get( 'wgSiteName' );
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue