Alasdair Smith 9 лет назад
Родитель
Сommit
9a073cdaf0

+ 4 - 0
services/web/app/views/project/list.pug

@@ -63,6 +63,10 @@ block content
 					aside.project-list-sidebar.col-md-2.col-xs-3
 					aside.project-list-sidebar.col-md-2.col-xs-3
 						include ./list/side-bar
 						include ./list/side-bar
 
 
+					.project-list-sidebar-v1-link.col-md-2.col-xs-3
+						span Want to go back to the V1 dashboard?
+						a.btn.btn-default(href=settings.overleaf.host + "/dash") Go back to V1
+
 					.project-list-main.col-md-10.col-xs-9
 					.project-list-main.col-md-10.col-xs-9
 						include ./list/notifications
 						include ./list/notifications
 						include ./list/project-list
 						include ./list/project-list

+ 29 - 1
services/web/public/stylesheets/app/project-list.less

@@ -1,4 +1,5 @@
 @announcements-shadow: 0 2px 20px rgba(0, 0, 0, 0.5);
 @announcements-shadow: 0 2px 20px rgba(0, 0, 0, 0.5);
+@v1-dash-link-height: 110px;
 
 
 @keyframes pulse {
 @keyframes pulse {
 	0% {
 	0% {
@@ -55,7 +56,7 @@
 		} 
 		} 
 
 
 		.project-list-sidebar when (@is-overleaf) {
 		.project-list-sidebar when (@is-overleaf) {
-			height: 100%;
+			height: calc(~"100% -" @v1-dash-link-height);
 			overflow-x: hidden;
 			overflow-x: hidden;
 			overflow-y: auto;
 			overflow-y: auto;
 			-ms-overflow-style: -ms-autohiding-scrollbar;
 			-ms-overflow-style: -ms-autohiding-scrollbar;
@@ -110,6 +111,33 @@
 	}
 	}
 }
 }
 
 
+.project-list-sidebar-v1-link {
+	position: absolute;
+	bottom: 0;
+	height: @v1-dash-link-height;
+	background-color: @sidebar-hover-bg; // TODO: Fix var names
+	text-align: center;
+	display: flex;
+	flex-direction: column;
+	justify-content: center;
+	color: white;
+}
+
+	.project-list-sidebar-v1-link a {
+		display: block;
+		margin-left: auto;
+		margin-right: auto;
+		margin-top: 4px;
+		padding-top: 0;
+		padding-bottom: 0;
+		background-color: @sidebar-bg; // TODO: Fix var names
+		color: #fff;
+	}
+
+	.project-list-sidebar-v1-link a:hover {
+		background-color: @sidebar-active-bg; // TODO: Fix var names
+	}
+
 .userNotifications {
 .userNotifications {
 	ul {
 	ul {
 		margin-bottom:0px;
 		margin-bottom:0px;