mforms-dateselector MDL-24234 date selector no longer disables the select boxes and updates itself when user uses the selects rather than the component.
This commit is contained in:
@@ -1,5 +1,3 @@
|
||||
.dateselector-select-mask-point {background-color:transparent;position:absolute;width:0;display:inline;}
|
||||
.dateselector-select-mask-point .dateselector-select-mask {background-color:#FFF;position:relative;}
|
||||
#dateselector-calendar-panel {background-color:#999;border-bottom:3px solid #999;border-right:3px solid #999;}
|
||||
#dateselector-calendar-content {border:1px solid #666;margin-top:-3px;margin-left:-3px;}
|
||||
body.ie #dateselector-calendar-panel.yui3-overlay-hidden table {display:none;}
|
||||
+2
-14
@@ -104,24 +104,12 @@ YUI.add('moodle-form-dateselector', function(Y) {
|
||||
node.on('blur', this.blur_event, this);
|
||||
return;
|
||||
}
|
||||
node.maskDiv = Y.Node.create('<div class="dateselector-select-mask"></div>');
|
||||
node.maskDiv.on('click', this.focus_event, this);
|
||||
node.ancestor().insert(
|
||||
Y.Node.create('<div class="dateselector-select-mask-point"></div>').append(
|
||||
node.maskDiv.setStyles({
|
||||
width : node.get('offsetWidth')+'px',
|
||||
height : node.get('offsetHeight')+'px',
|
||||
opacity : 0
|
||||
})), node);
|
||||
node.on('click', this.focus_event, this);
|
||||
node.after('change', this.set_date_from_selects, this);
|
||||
}, this);
|
||||
|
||||
if (this.yearselect && this.monthselect && this.dayselect) {
|
||||
this.enablecheckbox = this.get('node').one('input');
|
||||
if (this.enablecheckbox) {
|
||||
this.enablecheckbox.on('focus', this.focus_event, this);
|
||||
this.enablecheckbox.on('change', this.focus_event, this);
|
||||
this.enablecheckbox.on('blur', this.blur_event, this);
|
||||
}
|
||||
}
|
||||
},
|
||||
focus_event : function(e) {
|
||||
|
||||
Reference in New Issue
Block a user