mirror of
https://gerrit.wikimedia.org/r/mediawiki/skins/MinervaNeue
synced 2024-12-22 18:42:51 +00:00
ab1b4873df
In ES5 you can override getters via prototype but not with ES6. Rather than patch MobileFrontend just for this use case its easier to patch Minerva. Bug: T380314 Change-Id: I69ccdb93287dc5e080a0d5a8faa9d208dc67779d
34 lines
531 B
JavaScript
34 lines
531 B
JavaScript
const
|
|
mobile = require( 'mobile.startup' ),
|
|
View = mobile.View;
|
|
|
|
/**
|
|
* IssueNotice
|
|
*
|
|
* @class
|
|
* @ignore
|
|
* @extends View
|
|
*
|
|
* @param {IssueSummary} props
|
|
*/
|
|
class IssueNotice extends View {
|
|
constructor( props ) {
|
|
super( props );
|
|
}
|
|
|
|
get tagName() {
|
|
return 'li';
|
|
}
|
|
|
|
get template() {
|
|
return mw.template.get( 'skins.minerva.scripts', 'IssueNotice.mustache' );
|
|
}
|
|
|
|
postRender() {
|
|
super.postRender();
|
|
this.$el.find( '.issue-notice' ).prepend( this.options.issue.iconElement );
|
|
}
|
|
}
|
|
|
|
module.exports = IssueNotice;
|