In today's world,
MediaWiki:Gadget-Page descriptions.js has become a topic of great relevance and interest to many people. It has become a point of discussion and debate in different areas, whether on a personal, professional or academic level. The impact of
MediaWiki:Gadget-Page descriptions.js has been felt in society in a significant way, generating conflicting opinions and triggering research and studies that seek to delve deeper into its implications. Since its inception,
MediaWiki:Gadget-Page descriptions.js has captured the attention of millions of people around the world, sparking genuine interest and motivating professionals and experts to address its various facets and dimensions. In this context, it is important to fully explore the role of
MediaWiki:Gadget-Page descriptions.js today and its influence on daily life, as well as reflect on its projection in the future.
if ( mw.config.get( 'wgNamespaceNumber' ) === 0 && mw.config.get( 'wgAction' ) === 'view' ) {
mw.loader.using( 'mediawiki.api' ).then( function () {
// Adds a page description just below the "page title"
// Behaves a lot like the mobile version
var wgQid = mw.config.get( 'wgWikibaseItemId' ),
api = new mw.Api(),
callPromise = api.get( {
action: 'query',
titles: mw.config.get( 'wgTitle' ),
prop: 'description',
formatversion: 2
} ),
isEditor = mw.config.get( 'wgUserGroups' ).indexOf( 'autoconfirmed' ) !== -1;
$.when( callPromise, $.ready ).then( function ( results ) {
var pageDescription, $description,
response = results;
if (
response.query &&
response.query.pages &&
response.query.pages.description
) {
pageDescription = response.query.pages.description;
$description = $( '<span>' )
.addClass( 'mw-page-description' )
.text( pageDescription );
if ( response.query.pages.descriptionsource !== 'local' && isEditor ) {
$description.append(
' (',
$( '<a>' )
.attr( 'href', 'https://www.wikidata.orghttps://wiki386.com/en/Special:SetLabelDescriptionAliases/' + wgQid + '/' + mw.config.get( 'wgContentLanguage' ) )
.css( 'color', 'darkorange' )
.text( 'Wikidata' ),
')'
);
}
$description.append( '. ' );
} else if ( isEditor ) {
$description = $( '<span>' )
.css( 'color', 'red' )
.append(
'Missing ',
$( '<a>' )
.attr( 'href', 'https://wiki386.com/en/Template:Short_description' )
.text( 'page description' ),
'. '
);
}
if ( $description ) {
$( '#siteSub' ).prepend( $description );
}
} );
} );
}