Added tooltips to settings and manage

This commit is contained in:
Brinken
2012-03-15 15:08:06 +01:00
parent 4c04341382
commit 2c5ac9586c
5 changed files with 204 additions and 100 deletions

View File

@@ -232,16 +232,20 @@ background-image: -ms-linear-gradient(bottom, rgb(97,0,0) 0%, rgb(122,0,0) 100%)
a.update-link
{
margin: 30px;
border: 1px solid #000;
border-radius: 3px;
padding: 10px 5px 10px 5px;
font-size: 22px;
background-image: linear-gradient(bottom, rgb(8,97,0) 0%, rgb(0,199,7) 100%);
background-image: -o-linear-gradient(bottom, rgb(8,97,0) 0%, rgb(0,199,7) 100%);
background-image: -moz-linear-gradient(bottom, rgb(8,97,0) 0%, rgb(0,199,7) 100%);
background-image: -webkit-linear-gradient(bottom, rgb(8,97,0) 0%, rgb(0,199,7) 100%);
background-image: -ms-linear-gradient(bottom, rgb(8,97,0) 0%, rgb(0,199,7) 100%);
}
padding: 5px 10px 5px 10px;
font-size: 16px;
font-weight: bold;
background-image: linear-gradient(bottom, rgb(8,97,0) 0%, rgb(0,153,7) 100%);
background-image: -o-linear-gradient(bottom, rgb(8,97,0) 0%, rgb(0,153,7) 100%);
background-image: -moz-linear-gradient(bottom, rgb(8,97,0) 0%, rgb(0,153,7) 100%);
background-image: -webkit-linear-gradient(bottom, rgb(8,97,0) 0%, rgb(0,153,7) 100%);
background-image: -ms-linear-gradient(bottom, rgb(8,97,0) 0%, rgb(0,153,7) 100%);
text-shadow: 1px 1px 0px rgb(0,173,7);
color: #000;
}
div#logo { padding-left: 10px; }
ul#nav { position: fixed; top: 60px; left: 0px; list-style-type: none; height: 100%; width: 200px; padding: 0; margin: 0; background-color: #343434; border-right: 1px solid #000; padding-top: 30px; z-index: 300;}
@@ -524,24 +528,92 @@ text-shadow: 1px 1px 0px rgb(87,160,0);
}
.table_wrapper { border-radius: 5px; -webkit-border-radius: 5px; -moz-border-radius: 5px; width: 100%; background-color: #313131; position: relative; min-height: 50px; clear: both; _height: 302px; zoom: 1; }
/*All inputs in the main content */
.table_wrapper input[type="text"],
.table_wrapper input[type="password"],
.table_wrapper input[type="select"]
.table_wrapper input[type="radio"]
/*All inputs in the main content
/*Tooltip*/
.tooltip
{
margin-right: 3px;
float: left;
position: relative;
color: #000;
border-radius: 20px;
border: 1px solid #000;
box-shadow: 1px 1px 0px rgb(90,90,90);
width: 20px;
font-weight: bold;
font-size: 12px;
height: 20px;
text-align: center;
line-height: 20px;
cursor: help;
background-image: linear-gradient(bottom, rgb(117,117,117) 0%, rgb(156,156,156) 100%);
background-image: -o-linear-gradient(bottom, rgb(117,117,117) 0%, rgb(156,156,156) 100%);
background-image: -moz-linear-gradient(bottom, rgb(117,117,117) 0%, rgb(156,156,156) 100%);
background-image: -webkit-linear-gradient(bottom, rgb(117,117,117) 0%, rgb(156,156,156) 100%);
background-image: -ms-linear-gradient(bottom, rgb(117,117,117) 0%, rgb(156,156,156) 100%);
text-shadow: 1px 1px 0px rgb(180,180,180);
}
.tooltip:after {
content: "!";
}
/*Tooltip info*/
.tooltip span
{
display: none;
}
.tooltip:hover span
{
border: 1px solid #000;
border-radius: 3px;
box-shadow: 0px 0px 3px #000;
color: #000;
display: block;
font-style: italic;
font-weight: normal;
position: absolute;
z-index: 999;
top: 10px;
left: 30px;
text-align: left;
padding: 3px 6px 3px 6px;
width: 15em;
background-image: linear-gradient(bottom, rgb(117,117,117) 0%, rgb(156,156,156) 100%);
background-image: -o-linear-gradient(bottom, rgb(117,117,117) 0%, rgb(156,156,156) 100%);
background-image: -moz-linear-gradient(bottom, rgb(117,117,117) 0%, rgb(156,156,156) 100%);
background-image: -webkit-linear-gradient(bottom, rgb(117,117,117) 0%, rgb(156,156,156) 100%);
background-image: -ms-linear-gradient(bottom, rgb(117,117,117) 0%, rgb(156,156,156) 100%);
}
form input[type="radio"],
form input[type='submit']
{
border: 1px solid #000;
border-radius: 3px;
color: #000;
font-weight: bold;
padding: 3px 6px 3px 6px;
background-image: linear-gradient(bottom, rgb(117,117,117) 0%, rgb(156,156,156) 100%);
background-image: -o-linear-gradient(bottom, rgb(117,117,117) 0%, rgb(156,156,156) 100%);
background-image: -moz-linear-gradient(bottom, rgb(117,117,117) 0%, rgb(156,156,156) 100%);
background-image: -webkit-linear-gradient(bottom, rgb(117,117,117) 0%, rgb(156,156,156) 100%);
background-image: -ms-linear-gradient(bottom, rgb(117,117,117) 0%, rgb(156,156,156) 100%);
text-shadow: 1px 1px 0px rgb(180,180,180);
}
input[type="password"],
input[type="text"]
{
color: rgb(120,120,120);
padding: 3px 10px 3px 10px;
border-radius: 20px;
background-color: rgb(30,30,30);
border:0;
border: 0;
border-top: 1px solid rgb(20,20,20);
border-left: 1px solid rgb(20,20,20);
box-shadow: 1px 1px 1px rgb(70,70,70);
}
.manage_wrapper { width: 88%; margin: 20px auto 0 auto; padding: 25px; min-height: 150px; clear: both; _height: 302px; zoom: 1; }
.table_wrapper_left { float: left; width: 40%; min-height: 100px; margin-top: 25px; }
.table_wrapper_right{ float: right; width: 40%; min-height: 100px; margin-top: 25px; }
.table_wrapper_half { float: left; width: 50%; min-height: 100px; margin-top: 25px; }
.configtable { font-size: 14px; line-height:18px; }
.configtable td { width: 350px; padding: 10px; }

View File

@@ -59,15 +59,17 @@
<br />
<br />
<br />
<a class="update-link" href="update">Validate</a>
<a class="update-link" href="update">Update</a>
</div>
% elif headphones.CURRENT_VERSION != headphones.LATEST_VERSION and headphones.INSTALL_TYPE != 'win':
<div id="updatebar">
<div class="btnClose" title="Close" >X</div>
A <a class="update-link" href="http://github.com/rembo10/headphones/compare/${headphones.CURRENT_VERSION}...${headphones.LATEST_VERSION}"> newer version</a> is available. You're ${headphones.COMMITS_BEHIND} commits behind.
A newer version is available. <br />
You're ${headphones.COMMITS_BEHIND} commits behind.
<br />
<br />
<br />
<a class="update-link" href="http://github.com/rembo10/headphones/compare/${headphones.CURRENT_VERSION}...${headphones.LATEST_VERSION}">Version</a>
<a class="update-link" href="update">Update</a>
</div>
% endif

View File

@@ -20,24 +20,28 @@
<tr>
<td>
<h3>HTTP Host:</h3>
<input type="text" name="http_host" value="${config['http_host']}" size="30" maxlength="40"><br>
<i class="smalltext">i.e. localhost or 0.0.0.0</i>
<input type="text" name="http_host" value="${config['http_host']}" size="30" maxlength="40" />
<div class="tooltip">
<span>
i.e. localhost or 0.0.0.0
</span>
</div>
</td>
<td>
<h3>HTTP Username:</h3>
<input type="text" name="http_username" value="${config['http_user']}" size="30" maxlength="40">
<input type="text" name="http_username" value="${config['http_user']}" size="30" maxlength="40" />
</td>
</tr>
<tr>
<td>
<h3>HTTP Port:</h3>
<input type="text" name="http_port" value="${config['http_port']}" size="10" maxlength="40">
<input type="text" name="http_port" value="${config['http_port']}" size="10" maxlength="40" />
</td>
<td>
<h3>HTTP Password:</h3>
<input type="password" name="http_password" value="${config['http_pass']}" size="30" maxlength="40">
<input type="password" name="http_password" value="${config['http_pass']}" size="30" maxlength="40" />
</td>
</tr>
@@ -58,36 +62,41 @@
</tr>
<tr>
<td>
<h3>SABnzbd Host:</h3><input type="text" name="sab_host" value="${config['sab_host']}" size="30" maxlength="40"><br>
<i class="smalltext">usually http://localhost:8080</i>
<h3>SABnzbd Host:</h3><input type="text" name="sab_host" value="${config['sab_host']}" size="30" maxlength="40" />
<div class="tooltip">
<span>
Usually http://localhost:8080
</span>
</div>
</td>
<td>
<h3>SABnzbd Username:</h3><input type="text" name="sab_username" value="${config['sab_user']}" size="20" maxlength="40">
<h3>SABnzbd Username:</h3><input type="text" name="sab_username" value="${config['sab_user']}" size="20" maxlength="40" />
</td>
</tr>
<tr>
<td>
<h3>SABnzbd API:</h3><input type="text" name="sab_apikey" value="${config['sab_api']}" size="36" maxlength="40">
<h3>SABnzbd API:</h3><input type="text" name="sab_apikey" value="${config['sab_api']}" size="36" maxlength="40" />
</td>
<td>
<h3>SABnzbd Password:</h3><input type="password" name="sab_password" value="${config['sab_pass']}" size="20" maxlength="40">
<h3>SABnzbd Password:</h3><input type="password" name="sab_password" value="${config['sab_pass']}" size="20" maxlength="40" />
</td>
</tr>
<tr>
<td>
<h3>SABnzbd Category:</h3><input type="text" name="sab_category" value="${config['sab_cat']}" size="20" maxlength="40">
<h3>SABnzbd Category:</h3><input type="text" name="sab_category" value="${config['sab_cat']}" size="20" maxlength="40" />
</td>
<td>
<h3>Music Download Directory:</h3><input type="text" name="download_dir" value="${config['download_dir']}" size="50"><br>
<i class="smalltext">Full path to the directory where SAB downloads your music<br>
i.e. /Users/name/Downloads/music</i>
<h3>Music Download Directory:</h3><input type="text" name="download_dir" value="${config['download_dir']}" size="40" />
<div class="tooltip">
<span>
Full path to the directory where SAB downloads your music | i.e. /Users/name/Downloads/music
</span>
</div>
</td>
</tr>
@@ -97,9 +106,9 @@
</td>
<td>
<h3>Black Hole Directory:</h3><input type="text" name="blackhole_dir" value="${config['blackhole_dir']}" size="50"><br>
<h3>Black Hole Directory:</h3><input type="text" name="blackhole_dir" value="${config['blackhole_dir']}" size="40" />
<i class="smalltext">Folder your Download program watches for NZBs</i>
<div class="tooltip"><span>Folder your Download program watches for NZBs</span></div>
</td>
</tr>
@@ -113,30 +122,32 @@
<tr>
<td>
<br><br><br><br><h2>Torrent:</h2>
<br /><br /><br /><br /><h2>Torrent:</h2>
</td>
</tr>
<tr>
<td>
<h3>Black Hole Directory:</h3><input type="text" name="torrentblackhole_dir" value="${config['torrentblackhole_dir']}" size="50"><br>
<i class="smalltext">Folder your Download program watches for Torrents</i>
<h3>Black Hole Directory:</h3><input type="text" name="torrentblackhole_dir" value="${config['torrentblackhole_dir']}" size="40">
<div class="tooltip">
<span>Folder your Download program watches for Torrents</span>
</div>
</td>
<td>
<h3>Minimum seeders:</h3><input type="text" name="numberofseeders" value="${config['numberofseeders']}" size="5"><br>
<h3>Minimum seeders:</h3><input type="text" name="numberofseeders" value="${config['numberofseeders']}" size="5" />
<i class="smalltext">Number of minimum seeders a torrent must have to be accepted</i>
<div class="tooltip">
<span>Number of minimum seeders a torrent must have to be accepted</span></div>
</td>
</tr>
<tr>
<td>
<h3>Music Download Directory:</h3><input type="text" name="download_torrent_dir" value="${config['download_torrent_dir']}" size="50"><br>
<h3>Music Download Directory:</h3><input type="text" name="download_torrent_dir" value="${config['download_torrent_dir']}" size="40" />
<i class="smalltext">Full path to the directory where your torrent client downloads your music<br>
i.e. /Users/name/Downloads/music</i>
<div class="tooltip"><span>Full path to the directory where your torrent client downloads your music
i.e. /Users/name/Downloads/music</span></div>
</td>
<td></td>
@@ -174,8 +185,8 @@
<td>
<h3>Newznab Host: </h3>
<input type="text" name="newznab_host" value="${config['newznab_host']}" size="30" maxlength="40"><br>
<i class="smalltext">i.e. http://nzb.su</i>
<input type="text" name="newznab_host" value="${config['newznab_host']}" size="30" maxlength="40">
<div class="tooltip"><span>i.e. http://nzb.su</span></div>
</td>
<td>
@@ -224,17 +235,17 @@
<tr>
<td>
<h2>Torrent:</h2><br>
<h2>Torrent:</h2><br />
</td>
</tr>
<tr>
<td id="middle">
<h3>Isohunt: <input type="checkbox" name="use_isohunt" value="1" ${config['use_isohunt']} /></h3><br>
<h3>Isohunt: <input type="checkbox" name="use_isohunt" value="1" ${config['use_isohunt']} /></h3><br />
</td>
<td id="middle">
<h3>Mininova: <input type="checkbox" name="use_mininova" value="1" ${config['use_mininova']} /></h3><br>
<h3>Mininova: <input type="checkbox" name="use_mininova" value="1" ${config['use_mininova']} /></h3><br />
</td>
</tr>
@@ -251,7 +262,7 @@
<table class="configtable" summary="Quality & Post Processing">
<tr>
<td>
<h2>Album Quality:</h2><br>
<h2>Album Quality:</h2><br />
<h4><input type="radio" name="preferred_quality" value="0" ${config['pref_qual_0']} /> Highest Quality excluding Lossless</h4>
<h4><input type="radio" name="preferred_quality" value="1" ${config['pref_qual_1']} /> Highest Quality including Lossless</h4>
<h4><input type="radio" name="preferred_quality" value="3" ${config['pref_qual_3']} /> Lossless Only</h4>
@@ -273,11 +284,14 @@
<tr>
<td>
<br>
<br />
<h3>Path to Destination folder:</h3><input type="text" name="destination_dir" value="${config['dest_dir']}" size="50">
<br>
<i class="smalltext">i.e. /Users/name/Music/iTunes or /Volumes/share/music</i>
<h3>Path to Destination folder:</h3><input type="text" name="destination_dir" value="${config['dest_dir']}" size="40" />
<div class="tooltip">
<span>
i.e. /Users/name/Music/iTunes or /Volumes/share/music
</span>
</div>
</td>
</tr>
</table>
@@ -289,21 +303,20 @@
<tr>
<td>
<h2>Renaming Options:</h2>
<br>
<h3>Folder Format:</h3><input type="text" name="folder_format" value="${config['folder_format']}" size="43"><br>
<i class="smalltext">Use: artist, album, year, releasetype and first (first letter in artist name)<br />
E.g.: first/artist/album [year] = G/Girl Talk/All Day [2010]</i>
<br><br>
<h3>File Format:</h3><input type="text" name="file_format" value="${config['file_format']}" size="43">
<br>
<i class="smalltext">Use: tracknumber, title, artist, album and year</i>
<br />
<h3>Folder Format:</h3><input type="text" name="folder_format" value="${config['folder_format']}" size="43" />
<div class="tooltip"><span>Use: artist, album, year, releasetype and first (first letter in artist name)
E.g.: first/artist/album [year] = G/Girl Talk/All Day [2010]</span></div>
<br /><br />
<h3>File Format:</h3><input type="text" name="file_format" value="${config['file_format']}" size="43" />
<div class="tooltip"><span>Use: tracknumber, title, artist, album and year</span></div>
</td>
<td>
<h2>Miscellaneous:</h2>
<br>
<br />
<h3><input type="checkbox" name="include_extras" value="1" ${config['include_extras']} />Automatically Include Extras When Adding an Artist</h3>
<i class="smalltext">(EPs, Compilations, Live Albums, Remix Albums and Singles)</i>
<br><br>
<div class="tooltip"><span>(EPs, Compilations, Live Albums, Remix Albums and Singles)</span></div>
<br /><br />
<h3>Interface: <select name="interface"><h3>
%for interface in config['interface_list']:
<%
@@ -315,20 +328,20 @@
<option value="${interface}" ${selected}>${interface}</option>
%endfor
</select>
<br><br>
<h3>Log Directory:</h3><input type="text" name="log_dir" value="${config['log_dir']}" size="50">
<br /><br />
<h3>Log Directory:</h3><input type="text" name="log_dir" value="${config['log_dir']}" size="40">
</td>
</tr>
<tr>
<td>
<h2>Re-Encoding Options:</h2>
<i class="smalltext">Note: this option requires the lame or ffmpeg encoder</i>
<br><br>
<div class="tooltip"><span>Note: this option requires the lame or ffmpeg encoder</span></div>
<br />
<h3><input type="checkbox" name="encode" id="encode" value="1" ${config['encode']}/> Re-encode downloads during postprocessing</h3>
<br>
<br />
<div id="encoderoptions">
<h4><input type="checkbox" name="encoderlossless" value="1" ${config['encoderlossless']}/> Only re-encode lossless files (.flac)</h4>
<br>
<br />
<%
if config['encoder'] == 'lame':
lameselect = 'selected="selected"'
@@ -353,10 +366,10 @@
<option value=${x} ${outputselect}>${x}</option>
%endfor
</select></h4>
<br>
<br />
<h3>Audio Properties:</h3>
<br>
<br />
<h4>VBR/CBR: <select name="encodervbrcbr">
%for x in ['cbr', 'vbr']:
<%
@@ -381,7 +394,7 @@
%endfor
</select></h4>
<br>
<br />
<h4>Bitrate: <select name="bitrate">
%for x in [64, 128, 192, 256, 320]:
<%
@@ -406,23 +419,23 @@
<option value=44100 ${freq44100}>44.1 kHz</option>
<option value=48000 ${freq48000}>48.0 kHz</option>
</select></h4>
<br>
<br>
<br />
<br />
<h3>Advanced Encoding Options:</h3>
<h4>
(ignores audio properties)
</h4>
<input type="text" name="advancedencoder" value="${config['advancedencoder']}" size="43">
<br>
<br />
<h3>Path to Encoder:</h3><input type="text" name="encoderfolder" value="${config['encoderfolder']}" size="43">
</div>
</td>
<td>
<h2>Prowl Notification:</h2><br>
<h3><input type="checkbox" name="prowl_enabled" id="prowl" value="1" ${config['prowl_enabled']} />Enable Prowl Notifications</h3><br>
<h2>Prowl Notification:</h2><br />
<h3><input type="checkbox" name="prowl_enabled" id="prowl" value="1" ${config['prowl_enabled']} />Enable Prowl Notifications</h3><br />
<div id="prowloptions">
<h3>API key:</h3><input type="text" name="prowl_keys" value="${config['prowl_keys']}" size="50"><br><br>
<h3><input type="checkbox" name="prowl_onsnatch" value="1" ${config['prowl_onsnatch']} />Notify on snatch?</h3><br>
<h3>API key:</h3><input type="text" name="prowl_keys" value="${config['prowl_keys']}" size="40"><br /><br />
<h3><input type="checkbox" name="prowl_onsnatch" value="1" ${config['prowl_onsnatch']} />Notify on snatch?</h3><br />
<h3>Priority (-2,-1,0,1 or 2):</h3><input type="text" name="prowl_priority" value="${config['prowl_priority']}" size="2">
</div>
</td>
@@ -447,7 +460,7 @@
</table>
</div>
<p class="center"><input type="submit" value="Save Changes"><br>
<p class="center"><input type="submit" value="Save Changes"><br />
(Web Interface changes require a restart to take effect)</h3>
</form>
</%def>

View File

@@ -19,17 +19,20 @@
<h1>Scan Music Library</h1><br />
<p>
Where do you keep your music?<br /><br />
You can put in any directory, and it will scan for audio files in that folder
(including all subdirectories)<br />
For example: '/Users/name/Music'
<div class="tooltip">
<span>
You can put in any directory, and it will scan for audio files in that folder
(including all subdirectories)<br />
For example: '/Users/name/Music'
</span>
</div>
</p>
<br /><br />
<form action="musicScan" method="GET">
%if headphones.MUSIC_DIR:
<input type="text" value="${headphones.MUSIC_DIR}" name="path" size="70" />
%else:
<input type="text" value="Enter a Music Directory to scan" onfocus="if
(this.value==this.defaultValue) this.value='';" name="path" size="70" />
<input type="text" value="Enter a Music Directory to scan" onfocus="if (this.value==this.defaultValue) this.value='';" name="path" size="70" />
%endif
<br />
<br />
@@ -37,10 +40,15 @@
<br />
<br />
<input type="submit" />
* This process runs in the background.</form>
<div class="tooltip">
<span>
This process runs in the background.
</span>
</div>
</form>
</div>
<div class="table_wrapper_left">
<div class="table_wrapper_half">
<h1>Import Last.FM Artists</h1><br />
Enter the username whose artists you want to import:<br /><br />
<form action="importLastFM" method="GET" align="center">
@@ -50,25 +58,25 @@
else:
lastfmvalue = 'Last.fm Username'
%>
<input type="text" value="${lastfmvalue}" onfocus="if
(this.value==this.defaultValue) this.value='';" name="username" size="18" />
<input type="submit" /></form><br /><br />
<input type="text" value="${lastfmvalue}" onfocus="if (this.value==this.defaultValue) this.value='';" name="username" size="18" /><br />
<input type="submit" />
</form><br /><br />
</div>
<div class="table_wrapper_right">
<div class="table_wrapper_half">
<h1>Placeholder :-)</h1><br />
<br /><br />
<form action="" method="GET" align="center">
<input type="text" value="" onfocus="if
(this.value==this.defaultValue) this.value='';" name="" size="18" />
<input type="submit" /></form><br /><br />
<input type="text" onfocus="if (this.value==this.defaultValue) this.value='';" name="" size="18" /><br />
<input type="submit" />
</form>
</div>
<div class="table_wrapper">
<h1>Force Search</h1><br />
<h3><a href="forceSearch">Force Check for Wanted Albums</a></h3>
<h3><a href="forceUpdate">Force Update Active Artists</a></h3>
<h3><a href="forcePostProcess">Force Post-Process Albums in Download Folder</a></h3><br><br>
<h3><a href="forcePostProcess">Force Post-Process Albums in Download Folder</a></h3><br /><br />
<h3><a href="checkGithub">Check for Headphones Updates</a></h3>
</div>
</%def>

View File

@@ -31,7 +31,16 @@ $(window).resize(function() {
//Update close
$(document).ready(function () {
$("#updatebar").hide();
$("#updatebar").fadeIn("Fast");
$(".btnClose").click(function() {
$("#updatebar").fadeOut("slow");
});
});
});
//Main fadeIn
$(document).ready(function () {
$("#main").hide();
$("#main").fadeIn("slow");
});