update components
This commit is contained in:
@@ -1,28 +1,4 @@
|
||||
define(['tvguide', 'events'], function (tvguide, events) {
|
||||
|
||||
function onGuideLoaded() {
|
||||
|
||||
var context = this.options.element;
|
||||
|
||||
require(["headroom"], function () {
|
||||
|
||||
// construct an instance of Headroom, passing the element
|
||||
var headroom = new Headroom(context.querySelector('.tvGuideHeader'), {
|
||||
// or scroll tolerance per direction
|
||||
scroller: context.querySelector('.guideVerticalScroller'),
|
||||
|
||||
onPin: function () {
|
||||
context.classList.remove('headroomUnpinned');
|
||||
},
|
||||
// callback when unpinned, `this` is headroom object
|
||||
onUnpin: function () {
|
||||
context.classList.add('headroomUnpinned');
|
||||
}
|
||||
});
|
||||
// initialise
|
||||
headroom.init();
|
||||
});
|
||||
}
|
||||
define(['tvguide'], function (tvguide) {
|
||||
|
||||
window.LiveTvPage.initGuideTab = function (page, tabContent) {
|
||||
|
||||
@@ -35,9 +11,6 @@
|
||||
page.guideInstance = new tvguide({
|
||||
element: tabContent
|
||||
});
|
||||
|
||||
events.on(page.guideInstance, 'load', onGuideLoaded);
|
||||
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user