[PATCH 13/19] ui: Redesign the projects page

Stephen Finucane stephen.finucane at intel.com
Thu Feb 4 08:31:48 AEDT 2016


From: Damien Lespiau <damien.lespiau at intel.com>

Signed-off-by: Damien Lespiau <damien.lespiau at intel.com>
Acked-by: Stephen Finucane <stephen.finucane at intel.com>
---
 htdocs/css/style.css                        | 22 ++-----------------
 patchwork/templates/patchwork/projects.html | 33 ++++++++++++++++++-----------
 2 files changed, 23 insertions(+), 32 deletions(-)

diff --git a/htdocs/css/style.css b/htdocs/css/style.css
index 3e9a49d..13d4031 100644
--- a/htdocs/css/style.css
+++ b/htdocs/css/style.css
@@ -158,26 +158,8 @@ input#reorder-change {
 	font-weight:normal;
 }
 
-/* project list view */
-.project-set {
-}
-
-.project-set .project {
-	display: inline-block;
-	vertical-align: top;
-	background: #fcfcfc;
-	border: thin solid #f0f0f0;
-	box-shadow: 5px 5px 5px #c0c0c0;
-	margin: 2em 0.2em;
-	padding: 1em;
-	width: 20em;
-	min-height: 5em;
-}
-
-.project h2.project-title {
-	font-weight: bold;
-	font-size: 110%;
-	margin: 0.2em 0;
+.thumbnail {
+	min-height: 150px;
 }
 
 /* patch view */
diff --git a/patchwork/templates/patchwork/projects.html b/patchwork/templates/patchwork/projects.html
index 543a1d4..b027d7c 100644
--- a/patchwork/templates/patchwork/projects.html
+++ b/patchwork/templates/patchwork/projects.html
@@ -6,22 +6,31 @@
 {% block body %}
 
 {% if projects %}
- <div class="project-set">
- {% for p in projects %}
- <div class="project">
-  <h2 class="project-title">
-   <a href="{% url 'patch-list' project_id=p.linkname %}"
-    >{{p.linkname}}</a>
-  </h2>
-  <div class="project-name">{{p.name}}</div>
+<div class="row" style="margin-top:20px;">
+{% for p in projects %}
+ <div class="col-sm-6 col-md-4">
+   <div class="thumbnail">
+     <div class="caption">
+      <h3>{{p.name}}</h3>
+      <p class="core-info">
+       <span>
+        <a href="{% url 'patch-list' project_id=p.linkname %}">
+         View patches
+        </a>
+       </span>
+      </p>
 {% if p.web_url %}
-  <div class="project-url"><a href="{{p.web_url}}">website</a></div>
+      <p><a href="{{p.web_url}}">{{p.web_url}}</a></p>
+{% else %}
+      <p><a href="{{p.webscm_url}}">{{p.webscm_url}}</a></p>
 {% endif %}
-  </div>
- {% endfor %}
+     </div>
+   </div>
  </div>
+{% endfor %}
+</div>
 {% else %}
- <p>Patchwork doesn't have any projects to display!</p>
+<p>Patchwork doesn't have any projects to display!</p>
 {% endif %}
 
 {% endblock %}
-- 
2.0.0



More information about the Patchwork mailing list