couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gar...@apache.org
Subject [06/21] git commit: updated refs/heads/1846-dev-server-improvements to 5da4bbf
Date Mon, 08 Jul 2013 15:59:59 GMT
Fauxton: Change select header to data attribute


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

Branch: refs/heads/1846-dev-server-improvements
Commit: 2f5ae05136bc68a4753c5bb09b6cd2f9f4e6bcd0
Parents: 6e8f47c
Author: Garren Smith <garren.smith@gmail.com>
Authored: Mon Jul 1 15:51:53 2013 +0200
Committer: Garren Smith <garren.smith@gmail.com>
Committed: Mon Jul 1 15:51:53 2013 +0200

----------------------------------------------------------------------
 src/fauxton/app/addons/config/base.js          | 2 +-
 src/fauxton/app/addons/config/routes.js        | 2 +-
 src/fauxton/app/addons/logs/base.js            | 2 +-
 src/fauxton/app/addons/logs/routes.js          | 2 +-
 src/fauxton/app/addons/stats/base.js           | 2 +-
 src/fauxton/app/addons/stats/routes.js         | 2 +-
 src/fauxton/app/api.js                         | 4 ++--
 src/fauxton/app/modules/databases/routes.js    | 2 +-
 src/fauxton/app/modules/fauxton/base.js        | 2 +-
 src/fauxton/app/templates/fauxton/nav_bar.html | 2 +-
 10 files changed, 11 insertions(+), 11 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/couchdb/blob/2f5ae051/src/fauxton/app/addons/config/base.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/config/base.js b/src/fauxton/app/addons/config/base.js
index 6d3261c..f589b16 100644
--- a/src/fauxton/app/addons/config/base.js
+++ b/src/fauxton/app/addons/config/base.js
@@ -21,7 +21,7 @@ define([
 
 function(app, FauxtonAPI, Config) {
   Config.initialize = function() {
-    FauxtonAPI.addHeaderLink({title: "Config", href: "#_config", id: "config"});
+    FauxtonAPI.addHeaderLink({title: "Config", href: "#_config"});
   };
 
   return Config;

http://git-wip-us.apache.org/repos/asf/couchdb/blob/2f5ae051/src/fauxton/app/addons/config/routes.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/config/routes.js b/src/fauxton/app/addons/config/routes.js
index 3f8d7ac..f521c53 100644
--- a/src/fauxton/app/addons/config/routes.js
+++ b/src/fauxton/app/addons/config/routes.js
@@ -30,7 +30,7 @@ function(app, FauxtonAPI, Config) {
 
     roles: ["_admin"],
 
-    selectedHeaderId: "config",
+    selectedHeader: "Config",
 
     crumbs: [
       {"name": "Config","link": "_config"}

http://git-wip-us.apache.org/repos/asf/couchdb/blob/2f5ae051/src/fauxton/app/addons/logs/base.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/logs/base.js b/src/fauxton/app/addons/logs/base.js
index dfecb03..c17e159 100644
--- a/src/fauxton/app/addons/logs/base.js
+++ b/src/fauxton/app/addons/logs/base.js
@@ -21,7 +21,7 @@ define([
 
 function(app, FauxtonAPI, Log) {
   Log.initialize = function() {
-    FauxtonAPI.addHeaderLink({title: "Log", href: "#_log", id: "log"});
+    FauxtonAPI.addHeaderLink({title: "Log", href: "#_log"});
   };
 
   return Log;

http://git-wip-us.apache.org/repos/asf/couchdb/blob/2f5ae051/src/fauxton/app/addons/logs/routes.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/logs/routes.js b/src/fauxton/app/addons/logs/routes.js
index 0961f7b..7c498b0 100644
--- a/src/fauxton/app/addons/logs/routes.js
+++ b/src/fauxton/app/addons/logs/routes.js
@@ -32,7 +32,7 @@ function(app, FauxtonAPI, Log) {
       "_log": "showLog"
     },
 
-    selectedHeaderId: "log",
+    selectedHeader: "Log",
 
     roles: ["_admin"],
 

http://git-wip-us.apache.org/repos/asf/couchdb/blob/2f5ae051/src/fauxton/app/addons/stats/base.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/stats/base.js b/src/fauxton/app/addons/stats/base.js
index ac09437..4721399 100644
--- a/src/fauxton/app/addons/stats/base.js
+++ b/src/fauxton/app/addons/stats/base.js
@@ -19,7 +19,7 @@ define([
 function(app, FauxtonAPI, Stats) {
 
   Stats.initialize = function() {
-    FauxtonAPI.addHeaderLink({title: "Statistics", href: "#stats", id: "stats"});
+    FauxtonAPI.addHeaderLink({title: "Statistics", href: "#stats"});
   };
 
   return Stats;

http://git-wip-us.apache.org/repos/asf/couchdb/blob/2f5ae051/src/fauxton/app/addons/stats/routes.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/stats/routes.js b/src/fauxton/app/addons/stats/routes.js
index 994b4e2..5f1affe 100644
--- a/src/fauxton/app/addons/stats/routes.js
+++ b/src/fauxton/app/addons/stats/routes.js
@@ -26,7 +26,7 @@ function(app, FauxtonAPI, Stats) {
       "_stats": "showStats"
     },
 
-    selectedHeaderId: "stats",
+    selectedHeader: "Statistics",
 
     initialize: function () {
       this.stats = new Stats.Collection();

http://git-wip-us.apache.org/repos/asf/couchdb/blob/2f5ae051/src/fauxton/app/api.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/api.js b/src/fauxton/app/api.js
index b54a080..4732528 100644
--- a/src/fauxton/app/api.js
+++ b/src/fauxton/app/api.js
@@ -258,8 +258,8 @@ function(app, Fauxton) {
         masterLayout.setTemplate(this.layout);
           $('#nav-links li').removeClass('active');
 
-        if (this.selectedHeaderId) {
-          $('#nav-links li#' + this.selectedHeaderId).addClass('active');
+        if (this.selectedHeader) {
+          $('#nav-links li[data-nav-name="' + this.selectedHeader + '"]').addClass('active');
         }
       }
 

http://git-wip-us.apache.org/repos/asf/couchdb/blob/2f5ae051/src/fauxton/app/modules/databases/routes.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/modules/databases/routes.js b/src/fauxton/app/modules/databases/routes.js
index 88c939f..fe1a441 100644
--- a/src/fauxton/app/modules/databases/routes.js
+++ b/src/fauxton/app/modules/databases/routes.js
@@ -40,7 +40,7 @@ function(app, FauxtonAPI, Databases, Views) {
       return this.databases.url();
     },
 
-    selectedHeaderId: "database",
+    selectedHeader: "Databases",
 
     initialize: function() {
       this.databases = new Databases.List();

http://git-wip-us.apache.org/repos/asf/couchdb/blob/2f5ae051/src/fauxton/app/modules/fauxton/base.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/modules/fauxton/base.js b/src/fauxton/app/modules/fauxton/base.js
index 3d7d93d..716e9e7 100644
--- a/src/fauxton/app/modules/fauxton/base.js
+++ b/src/fauxton/app/modules/fauxton/base.js
@@ -64,7 +64,7 @@ function(app, Backbone) {
     template: "templates/fauxton/nav_bar",
     // TODO: can we generate this list from the router?
     navLinks: [
-      {href:"#/_all_dbs", title:"Databases", id: "database"}
+      {href:"#/_all_dbs", title:"Databases"}
     ],
 
     initialize: function() {

http://git-wip-us.apache.org/repos/asf/couchdb/blob/2f5ae051/src/fauxton/app/templates/fauxton/nav_bar.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/templates/fauxton/nav_bar.html b/src/fauxton/app/templates/fauxton/nav_bar.html
index decc07a..75731e0 100644
--- a/src/fauxton/app/templates/fauxton/nav_bar.html
+++ b/src/fauxton/app/templates/fauxton/nav_bar.html
@@ -25,7 +25,7 @@ the License.
         <ul id="nav-links" class="nav pull-right">
           <% _.each(navLinks, function(link) { %>
             <% if (!link.view) { %>
-            <li id= "<%= link.id %>" ><a href="<%= link.href %>"><%=
link.title %></a></li>
+            <li data-nav-name= "<%= link.title %>" ><a href="<%= link.href
%>"><%= link.title %></a></li>
             <% } %>
           <% }); %>
         </ul>


Mime
View raw message