Skip to content

Commit

Permalink
MDL-55244 js: build changes
Browse files Browse the repository at this point in the history
There should be no changes to minified code
  • Loading branch information
danpoltawski committed Jul 25, 2016
1 parent bc8b6dc commit 3a0bc0f
Show file tree
Hide file tree
Showing 133 changed files with 4,565 additions and 4,387 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ SEARCH.prototype = {
* @type Node
* @protected
*/
form : null,
form: null,
/**
* The capability select node.
* @property select
Expand All @@ -38,7 +38,7 @@ SEARCH.prototype = {
* @type Object
* @protected
*/
selectoptions : {},
selectoptions: {},
/**
* The search input field.
* @property input
Expand All @@ -60,12 +60,12 @@ SEARCH.prototype = {
* @type Node
* @protected
*/
lastsearch : null,
lastsearch: null,
/**
* Constructs the search manager.
* @method initializer
*/
initializer : function() {
initializer: function() {
this.form = Y.one('#capability-overview-form');
this.select = this.form.one('select[data-search=capability]');
this.select.setStyle('minWidth', this.select.get('offsetWidth'));
Expand All @@ -77,7 +77,7 @@ SEARCH.prototype = {
this.lastsearch = this.form.one('input[name=search]');

var div = Y.Node.create('<div id="capabilitysearchui"></div>'),
label = Y.Node.create('<label for="capabilitysearch">'+this.get('strsearch')+'</label>');
label = Y.Node.create('<label for="capabilitysearch">' + this.get('strsearch') + '</label>');
this.input = Y.Node.create('<input type="text" id="capabilitysearch" />');

div.append(label).append(this.input);
Expand All @@ -101,15 +101,15 @@ SEARCH.prototype = {
* Disables the submit button if there are no capabilities selected.
* @method validate
*/
validate : function() {
validate: function() {
this.button.set('disabled', (this.select.get('value') === ''));
},
/**
* Called when ever the user types into the search field.
* This method hides any capabilities that don't match the search term.
* @method typed
*/
typed : function() {
typed: function() {
var search = this.input.get('value'),
matching = 0,
last = null,
Expand Down Expand Up @@ -137,9 +137,9 @@ SEARCH.prototype = {
}
};
Y.extend(SEARCH, Y.Base, SEARCH.prototype, {
NAME : 'tool_capability-search',
ATTRS : {
strsearch : {}
NAME: 'tool_capability-search',
ATTRS: {
strsearch: {}
}
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ SEARCH.prototype = {
* @type Node
* @protected
*/
form : null,
form: null,
/**
* The capability select node.
* @property select
Expand All @@ -38,7 +38,7 @@ SEARCH.prototype = {
* @type Object
* @protected
*/
selectoptions : {},
selectoptions: {},
/**
* The search input field.
* @property input
Expand All @@ -60,12 +60,12 @@ SEARCH.prototype = {
* @type Node
* @protected
*/
lastsearch : null,
lastsearch: null,
/**
* Constructs the search manager.
* @method initializer
*/
initializer : function() {
initializer: function() {
this.form = Y.one('#capability-overview-form');
this.select = this.form.one('select[data-search=capability]');
this.select.setStyle('minWidth', this.select.get('offsetWidth'));
Expand All @@ -77,7 +77,7 @@ SEARCH.prototype = {
this.lastsearch = this.form.one('input[name=search]');

var div = Y.Node.create('<div id="capabilitysearchui"></div>'),
label = Y.Node.create('<label for="capabilitysearch">'+this.get('strsearch')+'</label>');
label = Y.Node.create('<label for="capabilitysearch">' + this.get('strsearch') + '</label>');
this.input = Y.Node.create('<input type="text" id="capabilitysearch" />');

div.append(label).append(this.input);
Expand All @@ -101,15 +101,15 @@ SEARCH.prototype = {
* Disables the submit button if there are no capabilities selected.
* @method validate
*/
validate : function() {
validate: function() {
this.button.set('disabled', (this.select.get('value') === ''));
},
/**
* Called when ever the user types into the search field.
* This method hides any capabilities that don't match the search term.
* @method typed
*/
typed : function() {
typed: function() {
var search = this.input.get('value'),
matching = 0,
last = null,
Expand Down Expand Up @@ -137,9 +137,9 @@ SEARCH.prototype = {
}
};
Y.extend(SEARCH, Y.Base, SEARCH.prototype, {
NAME : 'tool_capability-search',
ATTRS : {
strsearch : {}
NAME: 'tool_capability-search',
ATTRS: {
strsearch: {}
}
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,9 @@ Y.extend(DRAGREORDER, M.core.dragdrop, {
Y.one('.' + args.parentNodeClass)
.all('.' + args.dragHandleInsertClass)
.each(
function (node) {
function(node) {
node.insert(this.draghandle.cloneNode(true));
} , this);
}, this);
},

drop_hit: function(e) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,9 @@ Y.extend(DRAGREORDER, M.core.dragdrop, {
Y.one('.' + args.parentNodeClass)
.all('.' + args.dragHandleInsertClass)
.each(
function (node) {
function(node) {
node.insert(this.draghandle.cloneNode(true));
} , this);
}, this);
},

drop_hit: function(e) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,16 +47,16 @@ M.availability_date.form.getNode = function(json) {

var url = M.cfg.wwwroot + '/availability/condition/date/ajax.php?action=fromtime' +
'&time=' + json.t;
Y.io(url, { on : {
success : function(id, response) {
Y.io(url, {on: {
success: function(id, response) {
var fields = Y.JSON.parse(response.responseText);
for (var field in fields) {
var select = node.one('select[name=x\\[' + field + '\\]]');
select.set('value', '' + fields[field]);
select.set('disabled', false);
}
},
failure : function() {
failure: function() {
window.alert(M.util.get_string('ajaxerror', 'availability_date'));
}
}});
Expand Down Expand Up @@ -125,12 +125,12 @@ M.availability_date.form.updateTime = function(node) {
'&day=' + node.one('select[name=x\\[day\\]]').get('value') +
'&hour=' + node.one('select[name=x\\[hour\\]]').get('value') +
'&minute=' + node.one('select[name=x\\[minute\\]]').get('value');
Y.io(url, { on : {
success : function(id, response) {
Y.io(url, {on: {
success: function(id, response) {
node.setData('time', response.responseText);
M.core_availability.form.update();
},
failure : function() {
failure: function() {
window.alert(M.util.get_string('ajaxerror', 'availability_date'));
}
}});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,16 +47,16 @@ M.availability_date.form.getNode = function(json) {

var url = M.cfg.wwwroot + '/availability/condition/date/ajax.php?action=fromtime' +
'&time=' + json.t;
Y.io(url, { on : {
success : function(id, response) {
Y.io(url, {on: {
success: function(id, response) {
var fields = Y.JSON.parse(response.responseText);
for (var field in fields) {
var select = node.one('select[name=x\\[' + field + '\\]]');
select.set('value', '' + fields[field]);
select.set('disabled', false);
}
},
failure : function() {
failure: function() {
window.alert(M.util.get_string('ajaxerror', 'availability_date'));
}
}});
Expand Down Expand Up @@ -125,12 +125,12 @@ M.availability_date.form.updateTime = function(node) {
'&day=' + node.one('select[name=x\\[day\\]]').get('value') +
'&hour=' + node.one('select[name=x\\[hour\\]]').get('value') +
'&minute=' + node.one('select[name=x\\[minute\\]]').get('value');
Y.io(url, { on : {
success : function(id, response) {
Y.io(url, {on: {
success: function(id, response) {
node.setData('time', response.responseText);
M.core_availability.form.update();
},
failure : function() {
failure: function() {
window.alert(M.util.get_string('ajaxerror', 'availability_date'));
}
}});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -151,8 +151,8 @@ M.availability_grade.form.fillErrors = function(errors, node) {
}

// Check numeric values.
if ((value.min !== undefined && typeof(value.min) === 'string') ||
(value.max !== undefined && typeof(value.max) === 'string')) {
if ((value.min !== undefined && typeof (value.min) === 'string') ||
(value.max !== undefined && typeof (value.max) === 'string')) {
errors.push('availability_grade:error_invalidnumber');
} else if (value.min !== undefined && value.max !== undefined &&
value.min >= value.max) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -151,8 +151,8 @@ M.availability_grade.form.fillErrors = function(errors, node) {
}

// Check numeric values.
if ((value.min !== undefined && typeof(value.min) === 'string') ||
(value.max !== undefined && typeof(value.max) === 'string')) {
if ((value.min !== undefined && typeof (value.min) === 'string') ||
(value.max !== undefined && typeof (value.max) === 'string')) {
errors.push('availability_grade:error_invalidnumber');
} else if (value.min !== undefined && value.max !== undefined &&
value.min >= value.max) {
Expand Down
Loading

0 comments on commit 3a0bc0f

Please sign in to comment.