From 46b503e1b4cfe926dd0da410bf9caf1ec13553a6 Mon Sep 17 00:00:00 2001 From: Tor Hveem Date: Fri, 21 Feb 2014 09:32:52 +0100 Subject: [PATCH] Use ngAnimate to animate sidebar hiding/showing --- css/glowingbear.css | 17 ++++++++++++++++- index.html | 5 +++-- js/glowingbear.js | 18 ++++++++++++++---- 3 files changed, 33 insertions(+), 7 deletions(-) diff --git a/css/glowingbear.css b/css/glowingbear.css index a98992c..a4d5a07 100644 --- a/css/glowingbear.css +++ b/css/glowingbear.css @@ -174,9 +174,17 @@ input[type=text], input[type=password], .badge { overflow-x: hidden; margin-top: 35px; /* topbar */ font-size: smaller; + -webkit-transition:0.35s ease all; + transition:0.35s ease all; } #sidebar form { } +#sidebar.ng-hide-add, #sidebar.ng-hide-remove { + /* this needs to be here to make it visible during the animation + since the .ng-hide class is already on the element rendering + it as hidden. */ + display:block!important; +} #sidebar .badge { border-radius: 0; @@ -187,6 +195,10 @@ input[type=text], input[type=password], .badge { padding-left: 10px; } +#sidebar.ng-hide { + width: 0; +} + #nicklist { position: fixed; width: 100px; @@ -249,6 +261,8 @@ input[type=text], input[type=password], .badge { top: 35px; /* topbar */ padding-bottom: 10px; margin-right: -5px; + -webkit-transition:0.35s ease all; + transition:0.35s ease all; } .withnicklist { margin-right: 100px !important; /* nicklist */ @@ -259,6 +273,8 @@ input[type=text], input[type=password], .badge { .navbar-fixed-bottom { margin: 0 5px 0 145px; /* sidebar */ + -webkit-transition:0.35s ease all; + transition:0.35s ease all; } .navbar-inverse { background-color: #181818; @@ -311,7 +327,6 @@ table.notimestamp td.time { display: none; } - /* */ /* Mobile layout */ /* */ diff --git a/index.html b/index.html index 62fc52e..3c8fb7b 100644 --- a/index.html +++ b/index.html @@ -18,6 +18,7 @@ + @@ -183,7 +184,7 @@ $ openssl req -nodes -newkey rsa:4096 -keyout relay.pem -x509 -days 365 -out rel
- + brand @@ -272,7 +273,7 @@ $ openssl req -nodes -newkey rsa:4096 -keyout relay.pem -x509 -days 365 -out rel
-