-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
213 lines (162 loc) · 9.95 KB
/
index.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
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
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
<!DOCTYPE html>
<html>
<head>
<title>Airline Sample</title>
<meta charset="UTF-8" />
<link href="jquery-mobile/jquery.mobile-1.3.1.min.css" rel="stylesheet" type="text/css" />
<!-- uncoment viewport meta tag, if targeting Android 4.x.x devices -->
<!-- <meta name="viewport" content="width=device-width, initial-scale=1"> -->
<script src="cordova.js" type="text/javascript"></script>
<script src="jquery-mobile/jquery.min.js" type="text/javascript"></script>
<script src="jquery-mobile/jquery.mobile-1.3.1.min.js" type="text/javascript"></script>
<script>
$(function() {
$.mobile.defaultHomeScroll = 0;
});
</script>
<script src="scripts/main.js" type="text/javascript"></script>
<!-- Default Stylesheet -->
<link rel="stylesheet" href="styles/main.css" />
<!-- Phone 320x480 High DPI (aka Retina) -->
<!--<link rel="stylesheet" media="only screen and (min-device-width: 320px) and (max-device-width: 480px) and (-webkit-device-pixel-ratio:2)" href="styles/phone-480.css" type="text/css" />-->
<!--<!– Phone 480x800 Medium DPI (aka Samsung Galaxy S II Skyrocket) –>-->
<!--<link rel="stylesheet" media="only screen and (min-device-width: 320px) and (max-device-width: 508px) and (-webkit-device-pixel-ratio:1.5)" href="styles/phone-800.css" type="text/css" />-->
<!--<!– Tablet 768x1024 Low DPI (aka iPad 1 & 2") –>-->
<!--<link rel="stylesheet" media="only screen and (min-device-width: 768px) and (max-device-width: 1024px) and (-webkit-device-pixel-ratio:1)" href="styles/tablet-1024-ldpi.css" type="text/css" />-->
<!--<!– Phone 720x1280 High DPI (aka Google Nexus) –>-->
<!--<link rel="stylesheet" media="only screen and (min-device-width: 720px) and (max-device-width: 1280px) and (-webkit-device-pixel-ratio:2)" href="styles/phone-1280.css" type="text/css" />-->
<style>
.plus {
width:55px;
}
.minus {
width:40px;
}
.countervalue {
width:35px;
}
.full-width-slider .ui-slider-track {
width: 100px;
}
input {
font-size: 16px;
width: 40px;
float:left;
}
.good_score {
color: green;
}
.bad_score {
color: red;
}
.ui-btn-inner {
padding-left: 15px;
}
</style>
</head>
<body>
<!-- home page -->
<div id="home" data-role="page" data-mini="true">
<div data-role="header" data-position="fixed" data-tap-toggle="false">
<h1>Tot It Up</h1>
</div>
<div data-role="content">
<div class="ui-grid-solo">
<label for="potential" class="range_label">Max possible score</label>
<input type="slider" name="potential" id="potential" value="300" min="100" max="500" step="10" data-type="range">
</div>
<div class="ui-grid-solo">
<label for="half" class="range_label">Half Marks</label>
<input type="slider" name="half" id="half" value="0" min="0" max="25" step="0.5" data-type="range">
</div>
<div class="ui-grid-a">
<div class="ui-block-a">
<div class="score_widget" id="score_1" data-role="controlgroup" data-type="horizontal" data-multiplier="1" data-count="0">
<a href="" class="action plus" data-role="button" data-icon="plus" data-counter="1" data-action="1">1</a>
<a href="" class="countervalue" data-role="button" id="count_1" >0</a>
<a href="" class="action minus" data-role="button" data-icon="minus" data-counter="1" data-action="-1"> </a>
</div>
<div class="score_widget" id="score_2" data-role="controlgroup" data-type="horizontal" data-multiplier="2" data-count="0" >
<a href="" class="action plus" data-role="button" data-icon="plus" data-counter="2" data-action="1">2</a>
<a href="" class="countervalue" data-role="button" id="count_2" >0</a>
<a href="" class="action minus" data-role="button" data-icon="minus" data-counter="2" data-action="-1"> </a>
</div>
<div class="score_widget" id="score_3" data-role="controlgroup" data-type="horizontal" data-multiplier="3" data-count="0">
<a href="" class="action plus" data-role="button" data-icon="plus" data-counter="3" data-action="1">3</a>
<a href="" class="countervalue" data-role="button" id="count_3" >0</a>
<a href="" class="action minus" data-role="button" data-icon="minus" data-counter="3" data-action="-1"> </a>
</div>
<div class="score_widget" id="score_4" data-role="controlgroup" data-type="horizontal" data-multiplier="4" data-count="0" >
<a href="" class="action plus" data-role="button" data-icon="plus" data-counter="4" data-action="1">4</a>
<a href="" class="countervalue" data-role="button" id="count_4" >0</a>
<a href="" class="action minus" data-role="button" data-icon="minus" data-counter="4" data-action="-1"> </a>
</div>
<div class="score_widget" id="score_5" data-role="controlgroup" data-type="horizontal" data-multiplier="5" data-count="0" >
<a href="" class="action plus" data-role="button" data-icon="plus" data-counter="5" data-action="1">5</a>
<a href="" class="countervalue" data-role="button" id="count_5" >0</a>
<a href="" class="action minus" data-role="button" data-icon="minus" data-counter="5" data-action="-1"> </a>
</div>
<div class="score_widget" id="score_6" data-role="controlgroup" data-type="horizontal" data-multiplier="6" data-count="0">
<a href="" class="action plus" data-role="button" data-icon="plus" data-counter="6" data-action="1">6</a>
<a href="" class="countervalue" data-role="button" id="count_6" >0</a>
<a href="" class="action minus" data-role="button" data-icon="minus" data-counter="6" data-action="-1"> </a>
</div>
<div class="score_widget" id="score_7" data-role="controlgroup" data-type="horizontal" data-multiplier="7" data-count="0" >
<a href="" class="action plus" data-role="button" data-icon="plus" data-counter="7" data-action="1">7</a>
<a href="" class="countervalue" data-role="button" id="count_7" >0</a>
<a href="" class="action minus" data-role="button" data-icon="minus" data-counter="7" data-action="-1"> </a>
</div>
<div class="score_widget" id="score_8" data-role="controlgroup" data-type="horizontal" data-multiplier="8" data-count="0">
<a href="" class="action plus" data-role="button" data-icon="plus" data-counter="8" data-action="1">8</a>
<a href="" class="countervalue" data-role="button" id="count_8" >0</a>
<a href="" class="action minus" data-role="button" data-icon="minus" data-counter="8" data-action="-1"> </a>
</div>
<div class="score_widget" id="score_9" data-role="controlgroup" data-type="horizontal" data-multiplier="9" data-count="0" >
<a href="" class="action plus" data-role="button" data-icon="plus" data-counter="9" data-action="1">9</a>
<a href="" class="countervalue" data-role="button" id="count_9" >0</a>
<a href="" class="action minus" data-role="button" data-icon="minus" data-counter="9" data-action="-1"> </a>
</div>
<div class="score_widget" id="score_10" data-role="controlgroup" data-type="horizontal" data-multiplier="10" data-count="0" >
<a href="" class="action plus" data-role="button" data-icon="plus" data-counter="10" data-action="1">10</a>
<a href="" class="countervalue" data-role="button" id="count_10" >0</a>
<a href="" class="action minus" data-role="button" data-icon="minus" data-counter="10" data-action="-1"> </a>
</div>
</div>
<div class="ui-block-b">
<h3 id="scores">Scores <span id="score_count"></span> of <span id="num_scores"></span> </h3>
<h3>Subtotal <span id="totalscore"></span></h3>
<div data-role="fieldcontain" id="num_penalties" data-value="0">
<fieldset data-role="controlgroup" data-type="horizontal" >
<legend>Penalties:</legend>
<input type="radio" name="penalties" id="penalties1" value="0" checked="checked" />
<label for="penalties1">0</label>
<input type="radio" name="penalties" id="penalties2" value="2" />
<label for="penalties2">2</label>
<input type="radio" name="penalties" id="penalties4" value="4" />
<label for="penalties4">4</label>
</fieldset>
</div>
<h3>Total <span id="total"></span></h3>
<h1>Final Score <span id="percentage"></span>%</h1>
<button id="clear" class="btn" >Clear</button>
</div>
</div>
</div>
</div>
<!--Settings page-->
<div id="settings" data-role="page" data-add-back-btn="true">
<div data-role="header" data-position="fixed" data-tap-toggle="false">
<h1>Settings</h1>
</div>
<div data-role="content">
<ul data-role="listview" id="Ul4" data-inset="true" data-theme="d">
<li>Come on, this is just a sample!</li>
</ul>
</div>
</div>
<script>
var app = new tottyApp();
app.run();
</script>
</body>
</html>