Merge "Avoid deprecated View.$"
This commit is contained in:
commit
cfca2184dd
|
@ -40,7 +40,7 @@
|
||||||
* @instance
|
* @instance
|
||||||
*/
|
*/
|
||||||
enableLogging: function () {
|
enableLogging: function () {
|
||||||
this.$( 'a' ).on( 'click', function () {
|
this.$el.find( 'a' ).on( 'click', function () {
|
||||||
var $link = $( this ),
|
var $link = $( this ),
|
||||||
eventName = $link.data( 'event-name' );
|
eventName = $link.data( 'event-name' );
|
||||||
if ( eventName ) {
|
if ( eventName ) {
|
||||||
|
|
|
@ -19,7 +19,7 @@
|
||||||
template: mw.template.get( 'skins.minerva.scripts', 'IssueNotice.hogan' ),
|
template: mw.template.get( 'skins.minerva.scripts', 'IssueNotice.hogan' ),
|
||||||
postRender: function () {
|
postRender: function () {
|
||||||
View.prototype.postRender.apply( this, arguments );
|
View.prototype.postRender.apply( this, arguments );
|
||||||
this.$( '.issue-notice' ).prepend( this.options.issue.icon.$el );
|
this.$el.find( '.issue-notice' ).prepend( this.options.issue.icon.$el );
|
||||||
}
|
}
|
||||||
} );
|
} );
|
||||||
M.define( 'skins.minerva.scripts/IssueNotice', IssueNotice );
|
M.define( 'skins.minerva.scripts/IssueNotice', IssueNotice );
|
||||||
|
|
|
@ -29,7 +29,7 @@
|
||||||
heading: '<strong>' + headingText + '</strong>'
|
heading: '<strong>' + headingText + '</strong>'
|
||||||
} );
|
} );
|
||||||
|
|
||||||
overlay.$( '.overlay-content' ).append(
|
overlay.$el.find( '.overlay-content' ).append(
|
||||||
new IssueList( issues ).$el
|
new IssueList( issues ).$el
|
||||||
);
|
);
|
||||||
return overlay;
|
return overlay;
|
||||||
|
|
|
@ -44,7 +44,7 @@
|
||||||
issueSummaries = [];
|
issueSummaries = [];
|
||||||
|
|
||||||
if ( section === KEYWORD_ALL_SECTIONS ) {
|
if ( section === KEYWORD_ALL_SECTIONS ) {
|
||||||
$metadata = page.$( selector );
|
$metadata = page.$el.find( selector );
|
||||||
} else {
|
} else {
|
||||||
// find heading associated with the section
|
// find heading associated with the section
|
||||||
$metadata = page.findChildInSectionLead( parseInt( section, 10 ), selector );
|
$metadata = page.findChildInSectionLead( parseInt( section, 10 ), selector );
|
||||||
|
@ -163,7 +163,7 @@
|
||||||
if ( newTreatmentEnabled ) {
|
if ( newTreatmentEnabled ) {
|
||||||
// parse other sections but only in group B. In treatment A no issues are shown
|
// parse other sections but only in group B. In treatment A no issues are shown
|
||||||
// for sections.
|
// for sections.
|
||||||
page.$( Page.HEADING_SELECTOR ).each( function ( i, headingEl ) {
|
page.$el.find( Page.HEADING_SELECTOR ).each( function ( i, headingEl ) {
|
||||||
var $headingEl = $( headingEl ),
|
var $headingEl = $( headingEl ),
|
||||||
sectionNum = $headingEl.find( '.edit-page' ).data( 'section' );
|
sectionNum = $headingEl.find( '.edit-page' ).data( 'section' );
|
||||||
|
|
||||||
|
|
|
@ -19,7 +19,7 @@
|
||||||
* @private
|
* @private
|
||||||
*/
|
*/
|
||||||
function onSkinClick( ev ) {
|
function onSkinClick( ev ) {
|
||||||
var $target = this.$( ev.target );
|
var $target = $( ev.target );
|
||||||
|
|
||||||
// Make sure the menu is open and we are not clicking on the menu button
|
// Make sure the menu is open and we are not clicking on the menu button
|
||||||
if (
|
if (
|
||||||
|
|
|
@ -94,7 +94,7 @@
|
||||||
* @param {Page} page
|
* @param {Page} page
|
||||||
*/
|
*/
|
||||||
function setup( page ) {
|
function setup( page ) {
|
||||||
var $refs = page.$( 'sup.reference a' );
|
var $refs = page.$el.find( 'sup.reference a' );
|
||||||
|
|
||||||
if ( $refs.length ) {
|
if ( $refs.length ) {
|
||||||
$refs
|
$refs
|
||||||
|
|
Loading…
Reference in New Issue