-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathscrbrd.html
46 lines (40 loc) · 1.07 KB
/
scrbrd.html
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
<head>
<title>scrbrd</title>
</head>
<body>
<h1>Welcome to Scrbrd!</h1>
<div><input type="checkbox" class="edit-mode" checked="{{editMode}}" /> Edit</div>
{{> games}}
</body>
<template name="games">
<div>
<form class="new-game">
<input type="text" name="text" placeholder="New Game">
</form>
</div>
{{#each games}}
{{#if editMode}}
<button type='button' class='btn btn-xs btn-danger remove-game'>x</button>
{{/if}}
{{title}}
<div>
{{> players}}
</div>
{{/each}}
</template>
<template name="players">
<form class="new-player">
<input type="text" name="text" placeholder="New Player Name" />
</form>
{{#each players}}
<span>
{{#if editMode}}
<button type='button' class='btn btn-xs btn-danger remove-player'>x</button>
{{/if}}
{{name}} : {{#if editMode}}
<button type='button' class='btn btn-xs btn-warning dec-score'>-</button>
{{/if}}
{{wins}} <button type='button' class='btn btn-xs btn-success inc-score'>+</button>
</span>
{{/each}}
</template>