MediaWiki:Common.js: Difference between revisions
Appearance
Footer links to trust pages (owner-authorised) |
Footer: add Team and advisers (owner-authorised) |
||
| Line 5: | Line 5: | ||
return; | return; | ||
} | } | ||
[ [ 'Methodology', 'CasinoLeaks:Methodology' ], [ 'Corrections policy', 'CasinoLeaks:Corrections_policy' ], [ 'Contact', 'CasinoLeaks:Contact' ] ].forEach( function ( item ) { | [ [ 'Methodology', 'CasinoLeaks:Methodology' ], [ 'Corrections policy', 'CasinoLeaks:Corrections_policy' ], [ 'Team and advisers', 'CasinoLeaks:Team_and_advisers' ], [ 'Contact', 'CasinoLeaks:Contact' ] ].forEach( function ( item ) { | ||
var li = document.createElement( 'li' ), a = document.createElement( 'a' ); | var li = document.createElement( 'li' ), a = document.createElement( 'a' ); | ||
li.setAttribute( 'data-trust-links', '1' ); | li.setAttribute( 'data-trust-links', '1' ); | ||
Revision as of 19:48, 5 November 2026
/* Footer links to the trust pages (CURACAOFIL-6). Owner-authorised 2026-11-05. */
mw.hook( 'wikipage.content' ).add( function () {
var places = document.getElementById( 'footer-places' );
if ( !places || places.querySelector( '[data-trust-links]' ) ) {
return;
}
[ [ 'Methodology', 'CasinoLeaks:Methodology' ], [ 'Corrections policy', 'CasinoLeaks:Corrections_policy' ], [ 'Team and advisers', 'CasinoLeaks:Team_and_advisers' ], [ 'Contact', 'CasinoLeaks:Contact' ] ].forEach( function ( item ) {
var li = document.createElement( 'li' ), a = document.createElement( 'a' );
li.setAttribute( 'data-trust-links', '1' );
a.href = mw.util.getUrl( item[ 1 ] );
a.textContent = item[ 0 ];
li.appendChild( a );
places.appendChild( li );
} );
} );