From 2bf66aa429370069a6bf11c5fa690610fd635eb6 Mon Sep 17 00:00:00 2001 From: “Ryder <“r@okfoc.us”> Date: Mon, 28 Mar 2016 18:14:26 -0400 Subject: make gallery proper height --- public/assets/js/app.js | 44 ++++++++++++++++++++++++++------------------ public/assets/ok.css | 1 - 2 files changed, 26 insertions(+), 19 deletions(-) diff --git a/public/assets/js/app.js b/public/assets/js/app.js index 2bef5f5..dd2a7e1 100644 --- a/public/assets/js/app.js +++ b/public/assets/js/app.js @@ -3,30 +3,38 @@ var is_ipad = (navigator.userAgent.match(/iPad/i)); var is_android = (navigator.userAgent.match(/Android/i)) var is_mobile = is_iphone || is_ipad || is_android; $(function() { - if (is_mobile) { - $("html").addClass("mobile"); - } else { - $("html").addClass("desktop"); - } + if (is_mobile) { + $("html").addClass("mobile"); + } else { + $("html").addClass("desktop"); + } +}); + +$(".cell").css({ 'height': ($(".top").height() + 'px') }); + +$(window).resize(function() { + $(".cell").css({ 'height': ($(".top").height() + 'px') }); }); $('.top').flickity({ - cellAlign: 'left', - contain: true, - pageDots: false, - wrapAround: true, - arrowShape: { - x0: 10, - x1: 35, y1: 25, - x2: 40, y2: 25, - x3: 15 - } + cellAlign: 'left', + contain: true, + pageDots: false, + wrapAround: true, + arrowShape: { + x0: 10, + x1: 35, + y1: 25, + x2: 40, + y2: 25, + x3: 15 + } }); -$('.index').click( function(){ +$('.index').click(function() { $('body').toggleClass('navopen'); }); -$('.item').click( function(){ +$('.item').click(function() { $('body').removeClass('navopen'); -}); +}); \ No newline at end of file diff --git a/public/assets/ok.css b/public/assets/ok.css index e4193b8..d9e6008 100644 --- a/public/assets/ok.css +++ b/public/assets/ok.css @@ -228,7 +228,6 @@ button.previous:active svg { .cell { width: 100vw; - height: 70vh; /*THIS SHOULD BE DYNAMIC*/ background-position: center; background-size: cover; -- cgit v1.2.3-70-g09d2 From a086d316e82ec012bc8f84fa653fc4ae562848ea Mon Sep 17 00:00:00 2001 From: “Ryder <“r@okfoc.us”> Date: Mon, 28 Mar 2016 18:31:41 -0400 Subject: resize --- public/assets/js/app.js | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/public/assets/js/app.js b/public/assets/js/app.js index dd2a7e1..be7b585 100644 --- a/public/assets/js/app.js +++ b/public/assets/js/app.js @@ -12,9 +12,6 @@ $(function() { $(".cell").css({ 'height': ($(".top").height() + 'px') }); -$(window).resize(function() { - $(".cell").css({ 'height': ($(".top").height() + 'px') }); -}); $('.top').flickity({ cellAlign: 'left', @@ -37,4 +34,21 @@ $('.index').click(function() { $('.item').click(function() { $('body').removeClass('navopen'); +}); + + +var delay = (function() { + var timer = 0; + return function(callback, ms) { + clearTimeout(timer); + timer = setTimeout(callback, ms); + }; +})(); + +$(window).resize(function() { + $(".cell").css({ 'display': 'none' }); + delay(function() { + $(".cell").css({ 'height': ($(".top").height() + 'px'), 'display': 'inline-block' }); + $('.top').flickity('resize') + }, 400); }); \ No newline at end of file -- cgit v1.2.3-70-g09d2 From ba7c5d05ccaf30e78e5ce96c11f153101b157813 Mon Sep 17 00:00:00 2001 From: “Ryder <“r@okfoc.us”> Date: Mon, 28 Mar 2016 18:39:59 -0400 Subject: adding tomato --- public/assets/js/app.js | 4 +++- public/assets/ok.css | 4 ++++ public/assets/tomato20dancing.gif | Bin 0 -> 36620 bytes 3 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 public/assets/tomato20dancing.gif diff --git a/public/assets/js/app.js b/public/assets/js/app.js index be7b585..8a11dd8 100644 --- a/public/assets/js/app.js +++ b/public/assets/js/app.js @@ -47,8 +47,10 @@ var delay = (function() { $(window).resize(function() { $(".cell").css({ 'display': 'none' }); + $('body').addClass('resizing'); delay(function() { $(".cell").css({ 'height': ($(".top").height() + 'px'), 'display': 'inline-block' }); - $('.top').flickity('resize') + $('.top').flickity('resize'); + $('body').removeClass('resizing'); }, 400); }); \ No newline at end of file diff --git a/public/assets/ok.css b/public/assets/ok.css index d9e6008..34b6d1d 100644 --- a/public/assets/ok.css +++ b/public/assets/ok.css @@ -239,6 +239,10 @@ button.previous:active svg { background-color: #eee; } +.resizing .top { + background: url(tomato20dancing.gif)center; +} + .bottom { /*height: 20vh;*/ flex: 0 auto; diff --git a/public/assets/tomato20dancing.gif b/public/assets/tomato20dancing.gif new file mode 100644 index 0000000..0416665 Binary files /dev/null and b/public/assets/tomato20dancing.gif differ -- cgit v1.2.3-70-g09d2 From dca0b022e7aebf84828aa2182c68a6d348d7525a Mon Sep 17 00:00:00 2001 From: “Ryder <“r@okfoc.us”> Date: Mon, 28 Mar 2016 18:43:06 -0400 Subject: after and before --- public/assets/ok.css | 8 +++++++- templates/index.liquid | 4 ++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/public/assets/ok.css b/public/assets/ok.css index 34b6d1d..4696d95 100644 --- a/public/assets/ok.css +++ b/public/assets/ok.css @@ -116,8 +116,14 @@ nav span { #burger { width: 10px; + vertical-align: top +} +.index:after { + content:"INDEX"; +} +.navopen .index:after { + content:"CLOSE"; } - .index:hover, .navopen .index { color: white; diff --git a/templates/index.liquid b/templates/index.liquid index ef2af17..20df323 100644 --- a/templates/index.liquid +++ b/templates/index.liquid @@ -87,8 +87,8 @@ - -INDEX + +
OKFocus LLC. • 2016
SLIDE.1 • PG.1
-- cgit v1.2.3-70-g09d2