From e59fcddb13d13af91fe1678e5c8faa2fb3ceee49 Mon Sep 17 00:00:00 2001 From: Shubham Dhama Date: Mon, 4 Jun 2018 13:48:18 +0530 Subject: [PATCH] portico: Stop wraping of slides in landing page carousel. --- static/js/portico/landing-page.js | 10 ++++++++++ templates/zerver/hello.html | 14 +++++++++----- 2 files changed, 19 insertions(+), 5 deletions(-) diff --git a/static/js/portico/landing-page.js b/static/js/portico/landing-page.js index 42d4b3cc8f..6d1be4f58e 100644 --- a/static/js/portico/landing-page.js +++ b/static/js/portico/landing-page.js @@ -249,6 +249,16 @@ var load = function () { } }); + $('.carousel').on('slid', function () { + var $this = $(this); + $this.find('.visibility-control').show(); + if ($this.find('.carousel-inner .item:first').hasClass('active')) { + $this.find('.left.visibility-control').hide(); + } else if ($this.find('.carousel-inner .item:last').hasClass('active')) { + $this.find('.right.visibility-control').hide(); + } + }); + // Set up events / categories / search events(); }; diff --git a/templates/zerver/hello.html b/templates/zerver/hello.html index e5dc416616..a5b8062660 100644 --- a/templates/zerver/hello.html +++ b/templates/zerver/hello.html @@ -2,7 +2,7 @@ {% block customhead %} - + {{ render_bundle('landing-page') }} @@ -144,8 +144,8 @@ - - + +