Commit fd2f1ae1 authored by Andrew Nicols's avatar Andrew Nicols
Browse files

MDL-60558 calendar: Remove old SELECTORS

parent c8419f87
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
......@@ -56,7 +56,11 @@ define([], function() {
wrapper: '.calendarwrapper',
eventItem: '[data-type="event"]',
links: {
navLink: '.calendarwrapper .arrow_link',
eventLink: "[data-region='event-item']",
},
containers: {
loadingIcon: '[data-region="overlay-icon-container"]',
},
};
});
......@@ -45,11 +45,6 @@ define([
SummaryModal
) {
var SELECTORS = {
CALENDAR_NAV_LINK: ".calendarwrapper .arrow_link",
LOADING_ICON_CONTAINER: '[data-region="overlay-icon-container"]'
};
/**
* Register event listeners for the module.
*
......@@ -88,7 +83,8 @@ define([
}
});
root.on('click', SELECTORS.CALENDAR_NAV_LINK, function(e) {
root.on('click', CalendarSelectors.links.navLink, function(e) {
var wrapper = root.find(CalendarSelectors.wrapper);
var view = wrapper.data('view');
var courseId = wrapper.data('courseid');
......@@ -287,7 +283,7 @@ define([
* @method startLoading
*/
var startLoading = function(root) {
var loadingIconContainer = root.find(SELECTORS.LOADING_ICON_CONTAINER);
var loadingIconContainer = root.find(CalendarSelectors.containers.loadingIcon);
loadingIconContainer.removeClass('hidden');
};
......@@ -299,7 +295,7 @@ define([
* @method stopLoading
*/
var stopLoading = function(root) {
var loadingIconContainer = root.find(SELECTORS.LOADING_ICON_CONTAINER);
var loadingIconContainer = root.find(CalendarSelectors.containers.loadingIcon);
loadingIconContainer.addClass('hidden');
};
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment