From 69200db3473588f6df334836c6f249f489575888 Mon Sep 17 00:00:00 2001 From: mariusbaumann Date: Sat, 3 Jan 2015 07:12:50 +0100 Subject: Completely new Design v1 Some bugs heve to be fexed next days --- module/web/templates/default/home.html | 110 +++++++++++++++++++-------------- 1 file changed, 62 insertions(+), 48 deletions(-) (limited to 'module/web/templates/default/home.html') diff --git a/module/web/templates/default/home.html b/module/web/templates/default/home.html index 7359e326c..89074dd26 100644 --- a/module/web/templates/default/home.html +++ b/module/web/templates/default/home.html @@ -77,6 +77,7 @@ var EntryManager = new Class({ } }, this) + }catch(e){ //alert(e) } @@ -105,20 +106,29 @@ var LinkEntry = new Class({ }, insert: function(item){ try{ + + this.elements = { tr: new Element('tr', { 'html': '', 'styles':{ - 'opacity': 0 + 'opacity': 0, } }), + status: new Element('td', { + 'html': ' ', + }), + statusspan: new Element('span', { + 'html': item.statusmsg, + 'class': 'label label-default', + 'styles':{ + + } + }), name: new Element('td', { 'html': item.name }), - status: new Element('td', { - 'html': item.statusmsg - }), info: new Element('td', { 'html': item.info }), @@ -139,20 +149,35 @@ var LinkEntry = new Class({ } }), pgbTr: new Element('tr', { - 'html':'' + 'html':'', + 'styles':{ + 'border-top-color': '#fff', + } + }), + progress: new Element('div', { + 'html':'', + 'class':'progress', + 'styles':{ + 'margin-bottom': '0px', + } }), pgb: new Element('div', { - 'html': ' ', + 'html':'', + 'class':'progress-bar progress-bar-striped active', + 'role':'progress', 'styles':{ - 'height': '4px', 'width': item.percent+'%', 'background-color': '#ddd' } }) + }; - this.elements.tr.adopt(this.elements.name,this.elements.status,this.elements.info,this.elements.bleft,new Element('td').adopt(this.elements.percent,this.elements.remove)); - this.elements.pgbTr.adopt(new Element('td',{'colspan':5}).adopt(this.elements.pgb)); + + this.elements.status.adopt(this.elements.statusspan); + this.elements.progress.adopt(this.elements.pgb); + this.elements.tr.adopt(this.elements.status,this.elements.name,this.elements.info,this.elements.bleft,new Element('td').adopt(this.elements.percent,this.elements.remove)); + this.elements.pgbTr.adopt(new Element('td',{'colspan':5}).adopt(this.elements.progress)); this.initEffects(); }catch(e){ alert(e) @@ -171,15 +196,27 @@ var LinkEntry = new Class({ }, update: function(item){ this.elements.name.set('text', item.name); - this.elements.status.set('text', item.statusmsg); + this.elements.statusspan.set('text', item.statusmsg); this.elements.info.set('text', item.info); this.elements.bleft.set('text', item.format_size); this.elements.percent.set('text', item.percent+ '% / '+ humanFileSize(item.size-item.bleft)); + if (item.statusmsg == "waiting") { + this.elements.statusspan.set('class', 'label label-warning') + } else if (item.statusmsg == "starting") { + this.elements.statusspan.set('class', 'label label-info') + } else if (item.statusmsg == "downloading") { + this.elements.statusspan.set('class', 'label label-success') + } else if (item.stausmsg == "extracting") { + this.elements.statusspan.set('class', 'label label-primary') + } else { + this.elements.statusspan.set('class', 'label label-default') + } if(!operafix) { + this.bar.start({ 'width': item.percent, - 'background-color': [Math.round(120/100*item.percent),100,100].hsbToRgb().rgbToHex() + 'background-color': [Math.round(120/100*item.percent),80,70].hsbToRgb().rgbToHex() }); } else @@ -188,9 +225,10 @@ var LinkEntry = new Class({ 'styles', { 'height': '4px', 'width': item.percent+'%', - 'background-color': [Math.round(120/100*item.percent),100,100].hsbToRgb().rgbToHex(), + 'background-color': [Math.round(50/200*item.percent),0,200].hsbToRgb().rgbToHex(), }); } + }, remove: function(){ this.fade.start('opacity',0).chain(function(){this.elements.tr.dispose();}.bind(this)); @@ -198,57 +236,32 @@ var LinkEntry = new Class({ } }); + + - -{% endblock %} - -{% block subtitle %} -{{_("Active Downloads")}} -{% endblock %} - -{% block menu %} -
  • - {{_("Home")}} -
  • -
  • - {{_("Queue")}} -
  • -
  • - {{_("Collector")}} -
  • -
  • - {{_("Downloads")}} -
  • -{#
  • #} -{# {{_("FileManager")}}#} -{#
  • #} -
  • - {{_("Logs")}} -
  • -
  • - {{_("Config")}} -
  • {% endblock %} +{% block subtitle %}{{_("Active Downloads")}}{% endblock %} {% block content %} - +
    - + +
    {% for link in content %} - - - - + + + +
    {{_("Name")}} {{_("Status")}}{{_("Name")}} {{_("Information")}} {{_("Size")}} {{_("Progress")}}
    -{% endblock %} \ No newline at end of file + +{% endblock %} -- cgit v1.2.3 From a39f74fc46ba59409cd91a772647777bef542e7b Mon Sep 17 00:00:00 2001 From: mariusbaumann Date: Sat, 3 Jan 2015 18:42:30 +0100 Subject: Details changed on info, admin sites Only a few text format changes + Buttons for restart and shutdown styled + Passwort dialog restyled --- module/web/templates/default/home.html | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) (limited to 'module/web/templates/default/home.html') diff --git a/module/web/templates/default/home.html b/module/web/templates/default/home.html index 89074dd26..0cbbca280 100644 --- a/module/web/templates/default/home.html +++ b/module/web/templates/default/home.html @@ -138,15 +138,12 @@ var LinkEntry = new Class({ percent: new Element('span', { 'html': item.percent+ '% / '+ humanFileSize(item.size-item.bleft) }), - remove: new Element('img',{ - 'src': 'media/default/img/control_cancel.png', - 'styles':{ - 'vertical-align': 'middle', - 'margin-right': '-20px', - 'margin-left': '5px', - 'margin-top': '-2px', - 'cursor': 'pointer' - } + remove: new Element('span',{ + 'html': '', + 'class': 'glyphicon glyphicon-remove', + 'styles':{ + 'margin-left': '3px', + } }), pgbTr: new Element('tr', { 'html':'', -- cgit v1.2.3