]> git.ipfire.org Git - thirdparty/patchwork.git/commitdiff
ui: Split the tiles in columns and increase the mininum size
authorDamien Lespiau <damien.lespiau@intel.com>
Sun, 20 Dec 2015 17:20:29 +0000 (17:20 +0000)
committerStephen Finucane <stephen.finucane@intel.com>
Mon, 8 Feb 2016 19:03:48 +0000 (19:03 +0000)
Let's try to make that page looks better when the natural size of the
tiles are different (because the contents have varying sizes).

Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
Acked-by: Stephen Finucane <stephen.finucane@intel.com>
htdocs/css/style.css
patchwork/templates/patchwork/projects.html

index 13d40311e589d415a7407d2489e45fd4a7339b64..05d9db93e61e1d0e6625f354a22b3e0617a05edc 100644 (file)
@@ -159,7 +159,7 @@ input#reorder-change {
 }
 
 .thumbnail {
-       min-height: 150px;
+       min-height: 200px;
 }
 
 /* patch view */
index b027d7c321e11c6ded9dad95fca1544fcffdfe9c..3743d499076961080c2bad46f79e4e80651bb074 100644 (file)
@@ -5,20 +5,22 @@
 
 {% block body %}
 
+<div style="margin-top:20px;"></div>
+
 {% if projects %}
-<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>
+{% cycle '<div class="row">' '' '' %}
+  <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 %}
       <p><a href="{{p.web_url}}">{{p.web_url}}</a></p>
 {% else %}
      </div>
    </div>
  </div>
-{% endfor %}
+{% if forloop.last %}
 </div>
 {% else %}
+{% cycle '' '' '</div>' %}
+{% endif %}
+{% endfor %}
+{% else %}
 <p>Patchwork doesn't have any projects to display!</p>
 {% endif %}