mirror of
https://gerrit.wikimedia.org/r/mediawiki/skins/Vector.git
synced 2024-12-01 02:37:05 +00:00
3f7f355a2e
Log a console warning to assist developers in migrating to the new markup. Bug: T360633 Change-Id: Iaa1a3fc3b910c5fe491459fc82c61bc329f3408d
12 lines
425 B
JavaScript
12 lines
425 B
JavaScript
/**
|
|
* Checks if the page is using legacy message box styles
|
|
*/
|
|
module.exports = function () {
|
|
mw.requestIdleCallback( () => {
|
|
if ( document.querySelectorAll( '.mw-message-box:not(.cdx-message)' ).length ) {
|
|
mw.log.warn( `[T360668] A message box on this page is not using standard markup.
|
|
See https://doc.wikimedia.org/codex/latest/components/demos/message.html#markup-structure for more information.` );
|
|
}
|
|
} );
|
|
};
|