couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexander Shorin <kxe...@gmail.com>
Subject Re: git commit: updated refs/heads/master to b865a1d
Date Thu, 12 Sep 2013 19:29:15 GMT
Hi Sue!

I see you'd added direct links to some docs stuff. It's good idea,
really. But I'm finishing some changes in
1781-reorganize-and-improve-docs branch that will make all of them
(most of) broken after merge. Is it possible to extract these links
into some standalone file from which they will be embed into the
Fauxton? Maintaining such special file will help much with keeping
docs and fauxton in consistent state. I feel this file would be some
kind of JS object with fixed keys for Fauxton references and URL for
docs content.

What do you think about?

--
,,,^..^,,,


On Thu, Sep 12, 2013 at 9:54 PM,  <deathbear@apache.org> wrote:
> Updated Branches:
>   refs/heads/master d3d19660c -> b865a1dc2
>
>
> Views weren't saving & there was a console error from CodeMirror.
>
>
> Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
> Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/b865a1dc
> Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/b865a1dc
> Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/b865a1dc
>
> Branch: refs/heads/master
> Commit: b865a1dc27fbbbdf158b0dec68d68144c58a9a5e
> Parents: d3d1966
> Author: suelockwood <deathbearbrown@gmail.com>
> Authored: Wed Sep 11 16:23:30 2013 -0400
> Committer: suelockwood <deathbearbrown@gmail.com>
> Committed: Thu Sep 12 13:53:51 2013 -0400
>
> ----------------------------------------------------------------------
>  .../app/addons/replication/templates/form.html  |  2 +-
>  src/fauxton/app/modules/documents/views.js      |  2 +-
>  .../app/templates/documents/view_editor.html    | 77 +++++++++-----------
>  3 files changed, 37 insertions(+), 44 deletions(-)
> ----------------------------------------------------------------------
>
>
> http://git-wip-us.apache.org/repos/asf/couchdb/blob/b865a1dc/src/fauxton/app/addons/replication/templates/form.html
> ----------------------------------------------------------------------
> diff --git a/src/fauxton/app/addons/replication/templates/form.html b/src/fauxton/app/addons/replication/templates/form.html
> index 2c09b76..ad8c9b2 100644
> --- a/src/fauxton/app/addons/replication/templates/form.html
> +++ b/src/fauxton/app/addons/replication/templates/form.html
> @@ -63,7 +63,7 @@ the License.
>
>                         <label for="createTarget">
>                                 <input type="checkbox" name="create_target" value="true"
id="createTarget">
> -                               Create Target <i class="icon-question-sign " rel="tooltip"
title="Create the target database"></i>
> +                               Create Target <a href="http://docs.couchdb.org/en/latest/json-structure.html?highlight=replication#replication-settings"><i
class="icon-question-sign" rel="tooltip" title="Create the target database"></i></a>
>                         </label>
>                 </div>
>
>
> http://git-wip-us.apache.org/repos/asf/couchdb/blob/b865a1dc/src/fauxton/app/modules/documents/views.js
> ----------------------------------------------------------------------
> diff --git a/src/fauxton/app/modules/documents/views.js b/src/fauxton/app/modules/documents/views.js
> index 14fa546..148dc76 100644
> --- a/src/fauxton/app/modules/documents/views.js
> +++ b/src/fauxton/app/modules/documents/views.js
> @@ -1059,7 +1059,7 @@ function(app, FauxtonAPI, Paginate, Documents, pouchdb, Codemirror,
JSHint, resi
>        var json, notification,
>        that = this;
>
> -      event.preventDefault();
> +      if (event) { event.preventDefault();}
>
>        if (this.hasValidCode()) {
>          var mapVal = this.mapEditor.getValue(),
>
> http://git-wip-us.apache.org/repos/asf/couchdb/blob/b865a1dc/src/fauxton/app/templates/documents/view_editor.html
> ----------------------------------------------------------------------
> diff --git a/src/fauxton/app/templates/documents/view_editor.html b/src/fauxton/app/templates/documents/view_editor.html
> index 13b92b1..e04caa4 100644
> --- a/src/fauxton/app/templates/documents/view_editor.html
> +++ b/src/fauxton/app/templates/documents/view_editor.html
> @@ -22,54 +22,49 @@ the License.
>      <div class="tab-pane active" id="index">
>        <div id="define-view" class="ddoc-alert well">
>          <div class="errors-container"></div>
> -        <form class="form-horizontal">
> -          <h3>Define your index</h3>
> +        <form class="form-horizontal view-query-save">
> +
>            <div class="control-group">
> -            <div class="row" style="margin-left:10px">
> -              <div class="span3">
> -                <label class="control-label" for="ddoc">Design document <a
target="_couch_docs" href="http://docs.couchdb.org/en/latest/ddocs/#design-docs"><i
class="icon-question-sign"></i></a></label>
> -                <div class="controls">
> -                  <select id="ddoc">
> -                    <optgroup label="Select a document">
> -                      <option id="new-doc">New document</option>
> -                      <% ddocs.each(function(ddoc) { %>
> -                      <% if (ddoc.id === ddocName) { %>
> -                      <option selected="selected"><%= ddoc.id %></option>
> -                      <% } else { %>
> -                      <option><%= ddoc.id %></option>
> -                      <% } %>
> -                      <% }); %>
> -                    </optgroup>
> -                  </select>
> -                </div>
> -              </div>
> -              <div id="new-ddoc-section" class="span5 offset1" style="display:none">
> -                <label class="control-label" for="new-ddoc"> _design/ </label>
> -                <div class="controls">
> -                  <input type="text" id="new-ddoc" placeholder="newDesignDoc">
> -                </div>
> +            <label for="ddoc">Design document <a target="_couch_docs" href="http://docs.couchdb.org/en/latest/ddocs/#design-docs"><i
class="icon-question-sign"></i></a></label>
> +              <select id="ddoc">
> +                <optgroup label="Select a document">
> +                  <option id="new-doc">New document</option>
> +                  <% ddocs.each(function(ddoc) { %>
> +                  <% if (ddoc.id === ddocName) { %>
> +                  <option selected="selected"><%= ddoc.id %></option>
> +                  <% } else { %>
> +                  <option><%= ddoc.id %></option>
> +                  <% } %>
> +                  <% }); %>
> +                </optgroup>
> +              </select>
> +            <div id="new-ddoc-section" class="span5 offset1" style="display:none">
> +              <label class="control-label" for="new-ddoc"> _design/ </label>
> +              <div class="controls">
> +                <input type="text" id="new-ddoc" placeholder="newDesignDoc">
>                </div>
>              </div>
>            </div>
> +
>            <div class="control-group">
> -            <label class="control-label" for="index-name">Index name <a target="_couch_docs"
href="http://docs.couchdb.org/en/latest/ddocs/#view-functions"><i class="icon-question-sign"></i></a></label>
> -            <div class="controls">
> -              <input type="text" id="index-name" value="<%= viewName %>" placeholder="Index
name" />
> -            </div>
> +            <label for="index-name">Index name <a target="_couch_docs" href="http://docs.couchdb.org/en/latest/ddocs/#view-functions"><i
class="icon-question-sign"></i></a></label>
> +            <input type="text" id="index-name" value="<%= viewName %>" placeholder="Index
name" />
>            </div>
> +
> +
>            <div class="control-group">
> -            <label class="control-label" for="map-function">Map function <a
target="_couch_docs" href="http://docs.couchdb.org/en/latest/ddocs/#map-functions"><i
class="icon-question-sign"></i></a></label>
> -            <div class="controls">
> +            <label for="map-function">Map function <a target="_couch_docs"
href="http://docs.couchdb.org/en/latest/ddocs/#map-functions"><i class="icon-question-sign"></i></a></label>
>                <% if (newView) { %>
>                <textarea class="js-editor" id="map-function"><%= langTemplates.map
%></textarea>
>                <% } else { %>
>                <textarea class="js-editor" id="map-function"><%= ddoc.get('views')[viewName].map
%></textarea>
>                <% } %>
> -            </div>
>            </div>
> +
> +
>            <div class="control-group">
> -            <label class="control-label" for="reduce-function-selector">Reduce
function <a target="_couch_docs" href="http://docs.couchdb.org/en/latest/ddocs.html#reduce-and-rereduce-functions"><i
class="icon-question-sign"></i></a></label>
> -            <div class="controls">
> +            <label for="reduce-function-selector">Reduce function <a target="_couch_docs"
href="http://docs.couchdb.org/en/latest/ddocs.html#reduce-and-rereduce-functions"><i
class="icon-question-sign"></i></a></label>
> +
>                <select id="reduce-function-selector">
>                  <option value="" <%= !reduceFunStr ? 'selected="selected"' : ''
%>>None</option>
>                  <% _.each(["_sum", "_count", "_stats"], function(reduce) { %>
> @@ -78,25 +73,23 @@ the License.
>                  <option value="CUSTOM" <% if (isCustomReduce) { %>selected<%
} %>>Custom reduce</option>
>                </select>
>                <span class="help-block">Reduce functions are optional.</span>
> -            </div>
>            </div>
> +
> +
>            <div class="control-group reduce-function">
> -            <label class="control-label" for="reduce-function">Custom Reduce</label>
> -            <div class="controls">
> +            <label for="reduce-function">Custom Reduce</label>
>                <% if (newView) { %>
>                <textarea class="js-editor" id="reduce-function"><%= langTemplates.reduce
%></textarea>
>                <% } else { %>
>                <textarea class="js-editor" id="reduce-function"><%= ddoc.get('views')[viewName].reduce
%></textarea>
>                <% } %>
> -            </div>
>            </div>
> +
>            <div class="control-group">
> -            <div class="controls">
> -              <button class="btn btn-success btn-large save">Save</button>
> +              <button class="button green save fonticon-circle-check">Save</button>
>                <% if (!this.newView) { %>
> -              <button class="btn btn-danger btn-large delete">Delete</button>
> +              <button class="button cancel-button outlineGray fonticon-circle-x">Delete</button>
>                <% } %>
> -            </div>
>            </div>
>            <div class="clearfix"></div>
>          </form>
>

Mime
View raw message