vishwamano

source of vishwamano.com
git clone git://git.ricketyspace.net/vishwamano.git
Log | Files | Refs

commit ff02ad9b439efaf85008f3d365e8e1c3ea12067c
parent 8d335bef0ffc347d58dfd1d694a4198bf27acf44
Author: rsiddharth <rsiddharth@ninthfloor.org>
Date:   Tue,  6 Jan 2015 14:29:37 -0500

themes/bs3/templates/frontpage.tpl: col changes when screen width >= 1400

Diffstat:
themes/bs3/templates/frontpage.tpl | 20++++++++++++++++++--
1 file changed, 18 insertions(+), 2 deletions(-)

diff --git a/themes/bs3/templates/frontpage.tpl b/themes/bs3/templates/frontpage.tpl @@ -2,13 +2,13 @@ <div class="container-fluid"> <!-- top container start --> <div class="row"> <!-- top row start --> - <div class="col-sm-8"> <!-- carousel column start --> + <div id="carousel-col" class="col-sm-8"> <!-- carousel column start --> {include file='carousel.tpl' link="/as/photography-classes" cimages=$carousel.imgs cpath=$carousel.path control="true"} </div> <!-- carousel column end --> - <div class="col-sm-4"> + <div id="content-col" class="col-sm-4"> <h2> Welcome </h2> <p>"That extra hour, that additional mile; <br /> Trekking a long lost path, walking a bustling street; <br /> @@ -83,4 +83,20 @@ <script> $('#nav-link-home').addClass("active"); </script> +<script> +$(document).ready(colMod); + +$(window).resize(colMod); + +function colMod() { + screenSize = $(window).width(); + if(screenSize >= 1400) { + $("#carousel-col").addClass("col-md-offset-1 col-md-5"); + $("#content-col").addClass("col-md-offset-1 col-md-5"); + } else { + $("#carousel-col").removeClass("col-md-offset-1 col-md-5"); + $("#content-col").removeClass("col-md-offset-1 col-md-5"); + } +} +</script> {include file='footer.tpl'}