Commits

Seph Soliman committed 821cc80

widget now slides open

Comments (0)

Files changed (5)

 .widgetside .widgetcontent { padding: 20px 20px; height: 310px; position: relative; }
 
 #front { background: transparent url('../images/bg-front-collapsed.png') no-repeat 0px 0px; }
+#front.expanding { background: transparent url('../images/bg-front-collapsed-sliding.png') no-repeat 0px 0px; }
 #front.expanded { background-image: url('../images/bg-front.png'); }
 #back { background: transparent url('../images/bg-back.png') no-repeat 0px 0px; }
 
 #time_container #time { float: left; }
 #time_container input[type=button] { float: right; margin-left: 5px; vertical-align: middle; margin-top: 1px; }
 
-#reportcontainer { position: absolute; top: 155px; left: 20px; width: 250px; }
+#reportcontainerbutton { font-size: 9px; position: absolute; top: 109px; left: 0px; width: 100%; text-align: center;  }
+#reportcontainerbutton a { color: #fff; text-decoration: none; }
+
+#reportcontainer { position: absolute; top: 128px; left: -2px; width: 265px; padding-left: 22px; }
+#reportcontainer.sliding { background: transparent url('../images/slide-bottom.png') no-repeat 2px bottom; overflow: hidden; }
+#reportcontainer div:first-child { margin: 20px 0px 25px; position: absolute; bottom: 0px; }
 #reporthours { width: 30px; font-size: 11px; margin-left: 5px; }
 #reportdescription { width: 195px; font-size: 11px; margin-top: 3px; }
 #reportdate { margin: 3px 0px 0px; }
 #reportdate_toggle { font-size: 9px; margin: 3px 0px 0px; cursor: pointer; }
 #todolist { height: 70px; overflow: auto; width: 200px; }
 #todos { width: 248px; }
+#reportbtn { position: absolute; top: 51px; right: 0px; }
 
-#reportbtn { position: absolute; top: 65px; right: 0px; }
-
-#reportcontainerbutton { font-size: 9px; position: absolute; top: 129px; left: 0px; width: 100%; text-align: center;  }
-#reportcontainerbutton a { color: #fff; text-decoration: none; }
-
+#slidebottom { position: absolute; left: -17px; bottom: 0px; }

src/images/bg-front-collapsed-sliding.png

Added
New image

src/images/bg-front.png

Old
Old image
New
New image

src/images/slide-bottom.png

Added
New image
 	$("#show_project").click(openProjectURL);
 	$("#reportdate_toggle").click(function() { $("#reportdate").fadeToggle(200) });
 	$("#reportcontainerbutton").toggle(function() {
-		$("#front").addClass("expanded");
-		$("#reportcontainer").show(); 
+		$("#front").addClass("expanding");
+		$("#reportcontainer").css('height', '27px').addClass('sliding').animate({ height: '+=94px' }, 2500, 'swing', function() {
+			$("#front").removeClass("expanding");
+			$("#front").addClass("expanded");
+			$(this).removeClass('sliding').show();
+		});
 	}, function() {
-		$("#front").removeClass("expanded");
-		$("#reportcontainer").hide(); 
+		$("#front").addClass("expanding").removeClass('expanded');
+		$("#reportcontainer").addClass('sliding').animate({ height: '-=94px' }, 2500, 'swing', function() {
+			$("#front").removeClass("expanding");
+			$("#front").removeClass("expanded");
+			$(this).removeClass('sliding').hide();
+		});
 	});
 	// }}}
 }
 		} else {
 			pullProjectTodoLists(prj.id);
 		}
-		$("#reportcontainer").show();
 		$("#show_project").show();
 	}
 }