webapp: Repository list is now included in the dashboard, and other UI tweaks.

This commit is contained in:
Joey Hess 2013-03-15 00:34:42 -04:00
parent 6c7ce8f193
commit 810a06b771
18 changed files with 77 additions and 108 deletions

View file

@ -20,7 +20,7 @@
<div .form-actions>
<button .btn .btn-primary type=submit>
Save Changes
<a .btn href="@{RepositoriesR}">
<a .btn href="@{DashboardR}">
Cancel
$if new
<p>

View file

@ -6,5 +6,5 @@
<p>
<a .btn href="@{AddDriveR}">
On a removable drive
<a .btn href="@{RepositoriesR}">
<a .btn href="@{DashboardR}">
Cancel

View file

@ -1,24 +0,0 @@
<div .span9 ##{ident} .hero-unit>
$maybe reldir <- relDir webapp
<h2>
git-annex is watching over your files in <small><tt>#{reldir}</tt></small>
<p>
It will automatically notice changes, and keep files in sync #
$if (null repolist)
with repositories elsewhere ...
<h2>
But no other repositories are set up yet.
<a .btn .btn-primary .btn-large href="@{RepositoriesR}">Add another repository</a>
$else
\ with these repositories:
<table .table .table-striped .table-condensed>
<tbody>
$forall (num, name, _, _) <- repolist
<tr>
<td>
#{num}
<td>
#{name}
<a .btn .btn-primary .btn-large href="@{RepositoriesR}">Add another repository</a>
<p>
Or just sit back, watch the magic, and get on with using your files.

View file

@ -1,5 +1,11 @@
<div .span9>
<div .row-fluid>
<div .span4>
<h3>
<a href="@{AddRepositoryR}">
Repositories
<p>
Configure the repositories that git-annex syncs with.
<div .span4>
<h3>
<a href="@{PreferencesR}">

View file

@ -1,10 +1,12 @@
^{content}
$if warnNoScript
<noscript>
<div .navbar .navbar-fixed-bottom>
<div .navbar-inner>
<div .container>
Javascript is disabled; cannot update in real-time.
<div .btn-group>
<a .btn .btn-primary href="@{NoScriptAutoR}">Auto-refresh every 3 seconds #
<a .btn .btn-primary href="@{NoScriptR}">Manually refresh
<div .span9>
^{repolist}
^{transferlist}
$if warnNoScript
<noscript>
<div .navbar .navbar-fixed-bottom>
<div .navbar-inner>
<div .container>
Javascript is disabled; cannot update in real-time.
<div .btn-group>
<a .btn .btn-primary href="@{NoScriptAutoR}">Auto-refresh every 3 seconds #
<a .btn .btn-primary href="@{NoScriptR}">Manually refresh

View file

@ -1,15 +1,9 @@
<div .span9 ##{ident}>
$maybe reldir <- relDir webapp
<div .alert .alert-info>
<p>
git-annex is watching over your files in #
<small><tt>#{reldir}</tt></small>, #
and keeping them in sync with #
<a href="@{RepositoriesR}">
other repositories.
<div ##{ident}>
<h2>Transfers
$if null transfers
<i>
(no file transfers running)
$else
<h2>Transfers
$forall (transfer, info) <- transfers
$with percent <- maybe "unknown" (showPercentage 0) $ percentComplete transfer info
<div .row-fluid>

View file

@ -11,7 +11,7 @@
Repositories
<table .table .table-condensed>
<tbody #costsortable>
$forall (_num, name, uuid, actions) <- repolist
$forall (name, uuid, actions) <- repolist
<tr .repoline ##{fromUUID uuid}>
<td .handle>
<i .icon-resize-vertical></i>
@ -33,3 +33,15 @@
$else
<a href="@{setupRepoLink actions}">
configure
$if addmore
<tr>
<td colspan="3">
$if nootherrepos
<a .btn .btn-primary .btn-large href="@{AddRepositoryR}">
<i .icon-plus-sign></i> Add another repository
$else
<a .btn .btn-small href="@{AddRepositoryR}">
<i .icon-plus-sign></i> Add another repository
<span>
&nbsp; Sync your files with another drive, device, or #
share with a friend.

View file

@ -1,6 +1,7 @@
$(function() {
var setup = function() {
$("#costsortable").sortable({
items: ".repoline",
handle: ".handle",
cursor: "move",
forceHelperSize: true,