diff --git a/Gemfile.lock b/Gemfile.lock index 78bdb8e0..9a4447a1 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,7 +1,7 @@ PATH remote: . specs: - jekyll-theme-conference (3.1.0) + jekyll-theme-conference (3.1.1) jekyll (~> 4.0) GEM diff --git a/_includes/js/conference-live.js b/_includes/js/conference-live.js index 0a3e124c..4e0fed67 100644 --- a/_includes/js/conference-live.js +++ b/_includes/js/conference-live.js @@ -101,7 +101,7 @@ window.conference.live = (function() { } }; - let resetTime = function (timeStr) { + let resetTime = function () { // Reset app time timeOffset = 0; freezeTime = false; @@ -109,12 +109,15 @@ window.conference.live = (function() { startUpdate(); }; - let setTime = function (newTime, newDay=1) { + let setTime = function (newTime, newDay) { // Set and pause app time pauseTime(); let dayIdx; - if (Number.isInteger(newDay)) { + if (arguments.length < 2) { + dayIdx = 0; + } + else if (Number.isInteger(newDay)) { dayIdx = newDay-1; } else if (/^[0-9]{4}-[0-9]{2}-[0-9]{2}$/.test(newDay)) { @@ -123,7 +126,7 @@ window.conference.live = (function() { else { dayIdx = data.days.find(o => o.name === newDay); } - newDate = data.days[dayIdx].date; + let newDate = data.days[dayIdx].date; let d = new Date(newDate); newTime = newTime.split(':'); @@ -134,8 +137,10 @@ window.conference.live = (function() { update(); }; - let getTime = function (tConvert=time()) { + let getTime = function () { // Return app time as string + let tConvert = time(); + let d = new Date(tConvert * 1000); let dStr = d.toISOString().slice(0,10); let h = d.getHours(); @@ -564,7 +569,7 @@ window.conference.live = (function() { } }; - let hideModal = function (event) { + let hideModal = function () { // Close stream modal streamModal.find('iframe').attr('src', ''); streamModal.find('.modal-footer .btn').removeClass('active'); @@ -581,8 +586,8 @@ window.conference.live = (function() { let roomName = button.data('room'); setStream(roomName); }); - streamModal.on('hide.bs.modal', function (event) { - hideModal(event); + streamModal.on('hide.bs.modal', function () { + hideModal(); }); // configure room selection buttons in modal diff --git a/_includes/js/conference-map.js b/_includes/js/conference-map.js index 96ea9d2c..5b73dfa2 100644 --- a/_includes/js/conference-map.js +++ b/_includes/js/conference-map.js @@ -24,7 +24,7 @@ window.conference.mapConfig = (function() { }; let init = function () { - elId = 'map'; + let elId = 'map'; if (document.getElementById(elId)) { setup(elId); diff --git a/_includes/js/conference-modal.js b/_includes/js/conference-modal.js index 12fae9de..4134a7d9 100644 --- a/_includes/js/conference-modal.js +++ b/_includes/js/conference-modal.js @@ -51,7 +51,7 @@ window.conference.modal = (function () { } }; - let hide = function (el, event) { + let hide = function (el) { let modal = $(el); modal.find('.modal-title h3').text(''); @@ -61,13 +61,13 @@ window.conference.modal = (function () { }; let init = function() { - elSel = '#link-modal'; + let elSel = '#link-modal'; $(elSel).on('show.bs.modal', function (event) { show(this, event); }); - $(elSel).on('hide.bs.modal', function (event) { - hide(this, event); + $(elSel).on('hide.bs.modal', function () { + hide(this); }); }; diff --git a/_includes/js/conference-program.js b/_includes/js/conference-program.js index 4c4d7b2d..71243b0b 100644 --- a/_includes/js/conference-program.js +++ b/_includes/js/conference-program.js @@ -34,7 +34,7 @@ window.conference.program = (function() { } // Add current selected day as hash to URL while keeping current scrolling position - $('a[data-toggle="tab"]').on('shown.bs.tab', function (e) { + $('a[data-toggle="tab"]').on('shown.bs.tab', function () { updateHash(this.hash); }); } diff --git a/_includes/js/syncscroll.js b/_includes/js/syncscroll.js index 5e1446c8..52972e0a 100644 --- a/_includes/js/syncscroll.js +++ b/_includes/js/syncscroll.js @@ -29,7 +29,7 @@ function (exports) { var elems = document.getElementsByClassName('syncscroll'); var i, j, el, found, name; for (name in names) { - if (names.hasOwnProperty(name)) { + if (Object.prototype.hasOwnProperty.call(names, name)) { for (i = 0; i < names[name].length; i++) { names[name][i].removeEventListener( 'scroll', names[name][i].syn, 0 diff --git a/jekyll-theme-conference.gemspec b/jekyll-theme-conference.gemspec index aa612413..2c2d5be8 100644 --- a/jekyll-theme-conference.gemspec +++ b/jekyll-theme-conference.gemspec @@ -2,7 +2,7 @@ Gem::Specification.new do |spec| spec.name = "jekyll-theme-conference" - spec.version = "3.1.0" + spec.version = "3.1.1" spec.authors = ["Lorenz Schmid"] spec.email = ["lorenzschmid@users.noreply.github.com"]