From c0ccae0d1bc4c17b30e714d68d6c0101f538e074 Mon Sep 17 00:00:00 2001 From: "St. John Johnson" Date: Tue, 12 Nov 2024 16:38:20 -0800 Subject: [PATCH] Updating Jekyll and hiding the screen after the stream is done --- Gemfile | 2 +- Gemfile.lock | 75 ++++++++++++++++++++++++++++------------------------ js/site.js | 29 +++++++++++--------- 3 files changed, 58 insertions(+), 48 deletions(-) diff --git a/Gemfile b/Gemfile index 83abccb..d15c208 100644 --- a/Gemfile +++ b/Gemfile @@ -7,7 +7,7 @@ source "https://rubygems.org" # # This will help ensure the proper Jekyll version is running. # Happy Jekylling! -gem "jekyll", "~> 4.2.1" +gem "jekyll", "~> 4.3.4" # This is the default theme for new Jekyll sites. You may change this to anything you like. gem "minima", "~> 2.5" # If you want to use GitHub Pages, remove the "gem "jekyll"" above and diff --git a/Gemfile.lock b/Gemfile.lock index 3ebb119..21250f9 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,76 +1,83 @@ GEM remote: https://rubygems.org/ specs: - addressable (2.8.0) - public_suffix (>= 2.0.2, < 5.0) + addressable (2.8.7) + public_suffix (>= 2.0.2, < 7.0) + bigdecimal (3.1.8) colorator (1.1.0) - concurrent-ruby (1.1.9) - em-websocket (0.5.2) + concurrent-ruby (1.3.4) + em-websocket (0.5.3) eventmachine (>= 0.12.9) - http_parser.rb (~> 0.6.0) + http_parser.rb (~> 0) eventmachine (1.2.7) - ffi (1.15.4) + ffi (1.17.0) forwardable-extended (2.6.0) - http_parser.rb (0.6.0) - i18n (1.8.10) + google-protobuf (4.28.3) + bigdecimal + rake (>= 13) + http_parser.rb (0.8.0) + i18n (1.14.6) concurrent-ruby (~> 1.0) - jekyll (4.2.1) + jekyll (4.3.4) addressable (~> 2.4) colorator (~> 1.0) em-websocket (~> 0.5) i18n (~> 1.0) - jekyll-sass-converter (~> 2.0) + jekyll-sass-converter (>= 2.0, < 4.0) jekyll-watch (~> 2.0) - kramdown (~> 2.3) + kramdown (~> 2.3, >= 2.3.1) kramdown-parser-gfm (~> 1.0) liquid (~> 4.0) - mercenary (~> 0.4.0) + mercenary (>= 0.3.6, < 0.5) pathutil (~> 0.9) - rouge (~> 3.0) + rouge (>= 3.0, < 5.0) safe_yaml (~> 1.0) - terminal-table (~> 2.0) - jekyll-feed (0.15.1) + terminal-table (>= 1.8, < 4.0) + webrick (~> 1.7) + jekyll-feed (0.17.0) jekyll (>= 3.7, < 5.0) - jekyll-sass-converter (2.1.0) - sassc (> 2.0.1, < 3.0) - jekyll-seo-tag (2.7.1) + jekyll-sass-converter (3.0.0) + sass-embedded (~> 1.54) + jekyll-seo-tag (2.8.0) jekyll (>= 3.8, < 5.0) jekyll-watch (2.2.1) listen (~> 3.0) - kramdown (2.3.1) + kramdown (2.4.0) rexml kramdown-parser-gfm (1.1.0) kramdown (~> 2.0) - liquid (4.0.3) - listen (3.7.0) + liquid (4.0.4) + listen (3.9.0) rb-fsevent (~> 0.10, >= 0.10.3) rb-inotify (~> 0.9, >= 0.9.10) mercenary (0.4.0) - minima (2.5.1) + minima (2.5.2) jekyll (>= 3.5, < 5.0) jekyll-feed (~> 0.9) jekyll-seo-tag (~> 2.1) pathutil (0.16.2) forwardable-extended (~> 2.6) - public_suffix (4.0.6) - rb-fsevent (0.11.0) - rb-inotify (0.10.1) + public_suffix (6.0.1) + rake (13.2.1) + rb-fsevent (0.11.2) + rb-inotify (0.11.1) ffi (~> 1.0) rexml (3.3.9) - rouge (3.26.1) + rouge (4.5.1) safe_yaml (1.0.5) - sassc (2.4.0) - ffi (~> 1.9) - terminal-table (2.0.0) - unicode-display_width (~> 1.1, >= 1.1.1) - unicode-display_width (1.8.0) - webrick (1.8.2) + sass-embedded (1.80.6) + google-protobuf (~> 4.28) + rake (>= 13) + terminal-table (3.0.2) + unicode-display_width (>= 1.1.1, < 3) + unicode-display_width (2.6.0) + webrick (1.9.0) PLATFORMS ruby DEPENDENCIES - jekyll (~> 4.2.1) + jekyll (~> 4.3.4) jekyll-feed (~> 0.12) minima (~> 2.5) tzinfo (~> 1.2) @@ -79,4 +86,4 @@ DEPENDENCIES webrick (~> 1.8) BUNDLED WITH - 2.2.22 + 2.5.23 diff --git a/js/site.js b/js/site.js index af0a2f8..6339543 100644 --- a/js/site.js +++ b/js/site.js @@ -97,20 +97,23 @@ $(document).ready(function (){ }); // Countdown to November 2nd @ 9:30AM PT 2024 - $('div#countdown').countdown(1730565000000) + $('div#countdown').countdown(1730565000000, {elapse: true}) .on('update.countdown', function (event) { - $(this).html(event.strftime('

Starting in %-D day%!D %-H hour%!H %-M minute%!M %-S second%!S

')); - }) - .on('finish.countdown', function (event) { - $(this).html(''); - - // Show the twitch stream - new Twitch.Embed("twitch-embed", { - channel: "stjohnjohnson", - layout: "video" - }); - - $(".twitch-window").show(); + if (event.elapsed) { + if (event.offset.totalHours < 36) { + new Twitch.Embed("twitch-embed", { + channel: "stjohnjohnson", + layout: "video" + }); + + $(".twitch-window").show(); + } else { + $(this).html(''); + $(".twitch-window").hide(); + } + } else { + $(this).html(event.strftime('

Starting in %-D day%!D %-H hour%!H %-M minute%!M %-S second%!S

')); + } }); // load donation bar