-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathpopup.html
More file actions
100 lines (87 loc) · 2.91 KB
/
popup.html
File metadata and controls
100 lines (87 loc) · 2.91 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
<!doctype html>
<html>
<head>
<title>Divs Count</title>
<style>
body {
overflow: hidden;
margin: 0px;
padding: 0px;
background: white;
}
.card-type {
width: 32px;
}
.card-played {
visibility: collapse;
}
.status {
width: 16px;
height: 16px;
background-color: red;
display: inline-block;
}
.code-injected {
background-color: green;
}
.cards tr:nth-child(even) {
background: #CCC
}
.cards tr:nth-child(odd) {
background: #c7d09a
}
.cards td {
padding: 5px;
}
.cards {
border-spacing: 0px;
}
.card-in-hand{
background-color:#50b72f;
}
</style>
<script src="./dist/popup.js"></script>
</head>
<body ng-app="CardsCounter" ng-controller="MainController as ctrl">
<button ng-click="ctrl.clearCards()">clear</button>
<button ng-if="!ctrl.codeInjected" ng-click="ctrl.injectCardsCounter()">inject</button>
<button ng-if="ctrl.codeInjected" ng-click="ctrl.deleteCardsWatcher()">Delete</button>
<label class="status" ng-class="{'code-injected':ctrl.codeInjected}"></label>
<table class="cards">
<tbody>
<tr>
<th>
<img class="card-type" src="images/heart.png" />
</th>
<td ng-class="{'card-in-hand':card.inHand}" ng-repeat="card in ctrl.cards.heart ">
<span ng-class="{'card-played':card.played}"> {{card.name | clearCard}}</span>
</td>
</tr>
<tr>
<th>
<img class="card-type" src="images/club.png" />
</th>
<td ng-class="{'card-in-hand':card.inHand}" ng-repeat="card in ctrl.cards.spade ">
<span ng-class="{'card-played':card.played}"> {{card.name | clearCard}}</span>
</td>
</tr>
<tr>
<th>
<img class="card-type" src="images/spade.png" />
</th>
<td ng-class="{'card-in-hand':card.inHand}" ng-repeat="card in ctrl.cards.club ">
<span ng-class="{'card-played':card.played}"> {{card.name | clearCard}}</span>
</td>
</tr>
<tr>
<th>
<img class="card-type" src="images/diamond.png" />
</th>
<td ng-class="{'card-in-hand':card.inHand}" ng-repeat="card in ctrl.cards.diamond ">
<span ng-class="{'card-played':card.played}"> {{card.name | clearCard}}</span>
</td>
</tr>
</tbody>
</table>
</body>
</html>