couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gar...@apache.org
Subject [1/4] fauxton commit: updated refs/heads/master to 7eca51c
Date Wed, 03 Sep 2014 14:05:21 GMT
Repository: couchdb-fauxton
Updated Branches:
  refs/heads/master 1e0f4de0c -> 7eca51c37


New Documents Pagination

Initial work by
deathbearbrown@gmail.com and Jenn Schiffer jenn@pancaketheorem.com.


Project: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/commit/0d5f0e7d
Tree: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/tree/0d5f0e7d
Diff: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/diff/0d5f0e7d

Branch: refs/heads/master
Commit: 0d5f0e7dcc2bc002dfd99f3b95bcc5119a9d6635
Parents: 1e0f4de
Author: Garren Smith <garren.smith@gmail.com>
Authored: Tue Sep 2 17:04:04 2014 +0200
Committer: Garren Smith <garren.smith@gmail.com>
Committed: Tue Sep 2 17:18:35 2014 +0200

----------------------------------------------------------------------
 .../documents/templates/all_docs_list.html      |  7 +++++--
 .../documents/templates/all_docs_number.html    |  5 +++--
 app/addons/documents/views.js                   |  1 +
 app/addons/fauxton/components.js                |  6 ++++++
 .../fauxton/templates/index_pagination.html     | 16 ++++++---------
 assets/index.underscore                         |  4 ----
 assets/less/fauxton.less                        | 21 +++++++++++++++++++-
 7 files changed, 41 insertions(+), 19 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/blob/0d5f0e7d/app/addons/documents/templates/all_docs_list.html
----------------------------------------------------------------------
diff --git a/app/addons/documents/templates/all_docs_list.html b/app/addons/documents/templates/all_docs_list.html
index a643427..8db7bbe 100644
--- a/app/addons/documents/templates/all_docs_list.html
+++ b/app/addons/documents/templates/all_docs_list.html
@@ -28,7 +28,6 @@ the License.
   <% } %>
   <p>
 
-  <div id="item-numbers"> </div>
   <table class="all-docs table table-striped table-condensed">
     <tbody></tbody>
   </table>
@@ -40,5 +39,9 @@ the License.
     </p>
     </div>
   <% } %>
-  <div id="documents-pagination"></div>
+
+  <footer class="index-pagination pagination-footer window-resizeable<%=resizeLayout%>">
+    <div id="item-numbers"> </div>
+    <div id="documents-pagination"></div>
+  </footer>
 </div>

http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/blob/0d5f0e7d/app/addons/documents/templates/all_docs_number.html
----------------------------------------------------------------------
diff --git a/app/addons/documents/templates/all_docs_number.html b/app/addons/documents/templates/all_docs_number.html
index 0461a4b..49d6898 100644
--- a/app/addons/documents/templates/all_docs_number.html
+++ b/app/addons/documents/templates/all_docs_number.html
@@ -12,9 +12,10 @@ License for the specific language governing permissions and limitations
under
 the License.
 -->
 <% if (totalRows === "unknown" || totalRows === 0){ %>
-Showing 0 documents. <a href="#/database/<%=database%>/new"> Create your first
document.</a>
+<p>Showing 0 documents.</p>
 <% } else { %>
-Showing <%=pageStart%> - <%= pageEnd %>
+
+<p>Showing <%=pageStart%> - <%= pageEnd %></p>
 <%}%>
 <% if (updateSeq) { %>
 -- Update Sequence: <%= updateSeq %>

http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/blob/0d5f0e7d/app/addons/documents/views.js
----------------------------------------------------------------------
diff --git a/app/addons/documents/views.js b/app/addons/documents/views.js
index c6a6bf9..22c324f 100644
--- a/app/addons/documents/views.js
+++ b/app/addons/documents/views.js
@@ -578,6 +578,7 @@ function(app, FauxtonAPI, Components, Documents, Databases, Views, QueryOptions,
     serialize: function() {
       return {
         viewList: this.viewList,
+        resizeLayout: this.viewList ? "-half":"",
         expandDocs: this.expandDocs,
         endOfResults: !this.pagination.canShowNextfn()
       };

http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/blob/0d5f0e7d/app/addons/fauxton/components.js
----------------------------------------------------------------------
diff --git a/app/addons/fauxton/components.js b/app/addons/fauxton/components.js
index 2087394..74f6c74 100644
--- a/app/addons/fauxton/components.js
+++ b/app/addons/fauxton/components.js
@@ -212,6 +212,8 @@ function(app, FauxtonAPI, ace, spin, ZeroClipboard) {
 
 
   Components.IndexPagination = FauxtonAPI.View.extend({
+    className: "pagination pagination-centered",
+    tagName: 'ul',
     template: "addons/fauxton/templates/index_pagination",
     events: {
       "click a": 'scrollTo',
@@ -256,6 +258,10 @@ function(app, FauxtonAPI, ace, spin, ZeroClipboard) {
       return this.collection.hasNext();
     },
 
+    afterRender: function () {
+      app.resizeColumns.onResizeHandler();
+    },
+
     previousClicked: function (event) {
       event.preventDefault();
       event.stopPropagation();

http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/blob/0d5f0e7d/app/addons/fauxton/templates/index_pagination.html
----------------------------------------------------------------------
diff --git a/app/addons/fauxton/templates/index_pagination.html b/app/addons/fauxton/templates/index_pagination.html
index f445377..92d6683 100644
--- a/app/addons/fauxton/templates/index_pagination.html
+++ b/app/addons/fauxton/templates/index_pagination.html
@@ -12,13 +12,9 @@ License for the specific language governing permissions and limitations
under
 the License.
 -->
 
-<div class="pagination pagination-centered">
-  <ul>
-    <li <% if (!canShowPreviousfn()) {%> class="disabled" <% } %>>
-       <a id="previous" href="#"> Previous </a>
-     </li>
-     <li <% if (!canShowNextfn()) {%> class="disabled" <% } %>>
-       <a id="next" href="#"> Next </a></li>
-  </ul>
-</div>
-
+<li <% if (!canShowPreviousfn()) {%> class="disabled" <% } %>>
+ <a id="previous" class="icon fonticon-left-open" href="#"></a>
+</li>
+<li <% if (!canShowNextfn()) {%> class="disabled" <% } %>>
+ <a id="next" class="icon fonticon-right-open" href="#"></a>
+</li>

http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/blob/0d5f0e7d/assets/index.underscore
----------------------------------------------------------------------
diff --git a/assets/index.underscore b/assets/index.underscore
index 396cce3..6a887b5 100644
--- a/assets/index.underscore
+++ b/assets/index.underscore
@@ -35,10 +35,6 @@
   <div role="main" id="main">
     <div id="global-notifications" class="container errors-container"></div>
     <div id="app-container"></div>
-
-    <footer>
-      <div id="footer-content"></div>
-    </footer>
   </div>
 
   <!-- Application source. -->

http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/blob/0d5f0e7d/assets/less/fauxton.less
----------------------------------------------------------------------
diff --git a/assets/less/fauxton.less b/assets/less/fauxton.less
index 86b2147..1ae9b15 100644
--- a/assets/less/fauxton.less
+++ b/assets/less/fauxton.less
@@ -999,7 +999,7 @@ div.add-dropdown {
   }
   .one-pane &{
     //margin-top:60px;
-    //padding-bottom:60px;
+    padding-bottom:25px;
   }
   .with-sidebar &{
     .left-shadow-border;
@@ -1304,3 +1304,22 @@ footer.pagination-footer {
   }
 }
 
+footer.index-pagination {
+  margin-left: -20px;
+}
+
+#item-numbers{
+  p {
+    margin: 20px;
+    font-size: 14px;
+  }
+}
+
+div#per-page {
+  position: absolute;
+  right: 86px;
+  top: 2px;
+  #select-per-page {
+    margin-top: 10px;
+  }
+}


Mime
View raw message