summaryrefslogtreecommitdiffstats
path: root/web
diff options
context:
space:
mode:
authorraylu <raylu@gridium.com>2013-10-21 23:53:44 -0700
committerraylu <raylu@gridium.com>2013-10-22 00:36:28 -0700
commita9f844c3da365dc777002037262355e7c0b50265 (patch)
tree951526c81de2b538c7af4632798349a8558a4750 /web
parent0761480db9c0a83662ca31662ddb88214750cece (diff)
downloadykill-a9f844c3da365dc777002037262355e7c0b50265.tar.xz
differentiate final blow and other attackers
Diffstat (limited to 'web')
-rw-r--r--web/static/css/kill.ccss24
-rw-r--r--web/static/js/kill.js14
-rw-r--r--web/templates/kill.html9
3 files changed, 37 insertions, 10 deletions
diff --git a/web/static/css/kill.ccss b/web/static/css/kill.ccss
index 6ef779c..6a97f32 100644
--- a/web/static/css/kill.ccss
+++ b/web/static/css/kill.ccss
@@ -76,24 +76,36 @@ table#attackers:
width: 336px
margin-top: 10px
+ th:
+ &:nth-child(1):
+ width: 33px
+ &:nth-child(2):
+ width: 200px
+ &:nth-child(3):
+ width: 33px
+ &:nth-child(4):
+ width: 70px
+
td:
height: 64px
&:nth-child(1):
- width: 33px
white-space: normal
line-height: 0
&:nth-child(2):
- width: 200px
padding-left: 5px
&:nth-child(3):
- width: 33px
white-space: normal
line-height: 0
&:nth-child(4):
- width: 70px
text-align: right
padding-right: 8px
+ td.attacker_type:
+ height: auto
+ line-height: normal
+ background-color: #222
+ padding: 2px 8px
+
tr:nth-child(even):
background-color: #181818
@@ -113,7 +125,7 @@ table#items:
background-color: #222
padding: 2px 8px
- tr:nth-child(odd):
+ tr:nth-child(even):
background-color: #181818
td:nth-child(1):not(.slot):
@@ -123,6 +135,6 @@ table#items:
font-weight: bold
padding-right: 8px
.dropped:
- background-color: #050
+ background-color: #041
.destroyed:
color: #a22
diff --git a/web/static/js/kill.js b/web/static/js/kill.js
index 2c12d2d..a37c30c 100644
--- a/web/static/js/kill.js
+++ b/web/static/js/kill.js
@@ -79,10 +79,18 @@ window.addEvent('domready', function() {
});
table = $('attackers');
+ table.grab(new Element('tr').grab(
+ new Element('td', {'class': 'attacker_type', 'colspan': 4, 'html': 'final blow'})
+ ));
show_attacker(table, data['final_blow']);
- data['attackers'].each(function(char) {
- show_attacker(table, char);
- });
+ if (data['attackers'].length) {
+ table.grab(new Element('tr').grab(
+ new Element('td', {'class': 'attacker_type', 'colspan': 4, 'html': 'attackers'})
+ ));
+ data['attackers'].each(function(char) {
+ show_attacker(table, char);
+ });
+ }
table = $('items');
var slots = ['subsystem', 'high', 'medium', 'low', 'rig', 'drone bay', 'cargo', 'special hold', 'implant', '???'];
diff --git a/web/templates/kill.html b/web/templates/kill.html
index 818529e..99a4039 100644
--- a/web/templates/kill.html
+++ b/web/templates/kill.html
@@ -55,7 +55,14 @@
<table id="victim"></table>
<div class="clear"></div>
-<table id="attackers"></table>
+<table id="attackers">
+ <thead><tr>
+ <th></th>
+ <th></th>
+ <th></th>
+ <th></th>
+ </tr></thead>
+</table>
<table id="items">
<thead><tr>