}
this.$oldBody = this.$body.addClass( 'mw-widget-calendarWidget-old-body' );
// Clone without children
- this.$body = $( this.$body[0].cloneNode( false ) )
+ this.$body = $( this.$body[ 0 ].cloneNode( false ) )
.removeClass( 'mw-widget-calendarWidget-old-body' )
.toggleClass( 'mw-widget-calendarWidget-body-month', this.displayLayer === 'month' )
.toggleClass( 'mw-widget-calendarWidget-body-year', this.displayLayer === 'year' )
/**
* Handle click events on the "up" button, switching to less precise view.
+ *
* @private
*/
mw.widgets.CalendarWidget.prototype.onUpButtonClick = function () {
/**
* Handle click events on the "previous" button, switching to previous pane.
+ *
* @private
*/
mw.widgets.CalendarWidget.prototype.onPrevButtonClick = function () {
/**
* Handle click events on the "next" button, switching to next pane.
+ *
* @private
*/
mw.widgets.CalendarWidget.prototype.onNextButtonClick = function () {
* Handle click events anywhere in the body of the widget, which contains the matrix of days,
* months or years to choose. Maybe change the pane or switch to more precise view, depending on
* what gets clicked.
+ *
* @private
*/
mw.widgets.CalendarWidget.prototype.onBodyClick = function ( e ) {