forked from open-indy/Koa11y
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.htm
378 lines (298 loc) · 16.1 KB
/
index.htm
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
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
<!DOCTYPE html>
<html>
<head>
<!-- Automatically updated by your package.json file. -->
<title class="applicationTitle">Koa11y</title>
<link rel="icon" type="image/x-icon" href="_img/fav.ico">
<link rel="stylesheet" href="_style/ven.bootstrap.css">
<!-- Change this next line from cerulean to whatever swatch you pick. -->
<link rel="stylesheet" href="_style/ven.bootswatch/flatly.min.css" data-swatch="swapper">
<link rel="stylesheet" href="_style/ugui-devtools.css">
<link rel="stylesheet" href="_style/style.css">
<!-- UGUI requires jQuery 1.9.1 or above. -->
<script type="text/javascript" src="_scripts/ven.jquery-2.1.1.min.js"></script>
<script type="text/javascript" src="_scripts/ven.bootstrap-3.2.0.min.js"></script>
<script type="text/javascript" src="_scripts/ven.dropdowns-enhancement.js"></script>
<script type="text/javascript" src="_scripts/ven.bootstrap-slider.min.js"></script>
<script type="text/javascript" src="_scripts/ven.simple-donut.js"></script>
<script type="text/javascript" src="_scripts/ugui.js"></script>
<script type="text/javascript" src="_scripts/app.js"></script>
<!--
/////////////////////////////////////////////////////////////////
// //
// COMMAND LINE ARGUMENT UI BINDINGS //
// //
/////////////////////////////////////////////////////////////////
// The order of these arguments controls the order they will //
// be sent out to the command line. If you place a name inside //
// double parenthesis like ((cows)) it will automatically be //
// replaced by the value of the element in the #argsForm with //
// a matching data-argName="cows". //
// //
// Input tags with a type of "file" will also automatically be //
// parsed into several sub-arguments for your ease of use such //
// as path, name, ext, size, lastModifiedDate, etc. //
// //
// If you need the value of an element parsed for you supply a //
// definition. Consult the UGUI documentation for detailed //
// information and instructions on how this feature works. //
/////////////////////////////////////////////////////////////////
-->
<cmd executable="pa11y">
<!--
<arg>((url))</arg>
<arg>((output))</arg>
<arg>((outputcsv))</arg>
<arg>((outputhtml))</arg>
<arg>((outputjson))</arg>
<arg>((outputmd))</arg>
<arg>((standardsection))</arg>
<arg>((standardwcaga))</arg>
<arg>((standardwcagaa))</arg>
<arg>((standardwcagaaa))</arg>
<arg>((folderPicker))</arg>
-->
</cmd>
</head>
<!-- Change the class form dev to prod when you're ready to distribute your application. -->
<body role="document" class="prod">
<!--
/////////////////////////////////////////////////////////////////
// //
// NAVIGATION //
// //
/////////////////////////////////////////////////////////////////
// Top bar navigation. Some parts are only visible when in dev //
// mode. Be sure to change the body class to prod before you //
// distribute your app. //
/////////////////////////////////////////////////////////////////
-->
<nav class="navbar navbar-inverse navbar-fixed-top" role="navigation">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target=".navbar-collapse">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand">
<img src="_img/logo.png" alt="Logo" />
<span class="applicationTitle">Koa11y</span>
</a>
</div>
<div class="navbar-collapse collapse">
<ul class="nav navbar-nav">
<li><a href="#about">About</a></li>
<li><a href="#exit">Exit</a></li>
<!--
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">File <span class="caret"></span></a>
<ul class="dropdown-menu" role="menu">
<li><a href="#save" class="save-ugui-settings">Save Settings</a></li>
<li><a href="#load" class="load-ugui-settings">Load Settings</a></li>
</ul>
</li>
<li class="dropdown devNav">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">View <span class="caret"></span></a>
<ul class="dropdown-menu" role="menu">
<li><a href="#fullscreen">Fullscreen</a></li>
<li class="devNav"><a href="#console">Console</a></li>
<li class="divider"></li>
<li class="devNav"><a href="#cmdoutput">Command Line Output</a></li>
</ul>
</li>
<li class="dropdown navHelp">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Help <span class="caret"></span></a>
<ul class="dropdown-menu" role="menu">
</ul>
</li> -->
</ul>
</div><!--/.nav-collapse -->
</div>
</nav>
<!--
/////////////////////////////////////////////////////////////////
// //
// APPLICATION NAME AND DESCRIPTION //
// //
/////////////////////////////////////////////////////////////////
// This is automatically replaced by the content in your //
// package.json file. //
/////////////////////////////////////////////////////////////////
-->
<div class="container" role="main">
<header>
<h3>
<!--
<span class="applicationTitle">Koa11y</span>
<small class="applicationDescription">A GUI for running Pa11y.</small>
-->
</h3>
</header>
<!--
/////////////////////////////////////////////////////////////////
// //
// CLI FORM ELEMENTS //
// //
/////////////////////////////////////////////////////////////////
// All form elements used to send commands to your executable //
// must be placed in the argsForm below. //
/////////////////////////////////////////////////////////////////
-->
<section>
<form id="pa11y" role="form-inline">
<div class="row">
<div class="col-xs-12 col-s-12 col-md-12 col-l-12">
<label for="url">URL:</label>
<input id="url" type="text" class="form-control" data-argName="url" required="required" />
<input type="hidden" data-argName="version" value="2.0.0" />
</div>
</div>
<div class="row">
<div class="col-xs-12 col-s-12 col-md-12 col-l-12 form-group">
<label for="output">Filename (will overwrite existing files):</label>
<div class="input-group">
<input id="output" type="text" class="form-control" data-argName="output" required="required" />
<div id="output-btn" class="input-group-addon btn-group">
<button id="outputtype" class="btn btn-success dropdown-toggle" type="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">HTML<span class="caret"></span></button>
<ul class="dropdown-menu" aria-labelledby="outputtype">
<li><input type="radio" name="outputtype" data-argName="outputhtml" value="html" id="html" /><label for="html" >HTML</label></li>
<li><input type="radio" name="outputtype" data-argName="outputcsv" value="csv" id="csv" /><label for="csv" >CSV</label></li>
<li><input type="radio" name="outputtype" data-argName="outputjson" value="json" id="json" /><label for="json" >JSON</label></li>
<li><input type="radio" name="outputtype" data-argName="outputmd" value="md" id="md" /><label for="md" >Markdown</label></li>
<li><input type="radio" name="outputtype" data-argName="outputxml" value="xml" id="xml" /><label for="xml" >XML</label></li>
</ul>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-xs-6 col-s-6 col-md-6 col-l-6">
<label>Standards Format:</label><br />
<button data-toggle="dropdown" class="btn btn-success dropdown-toggle">WCAG2AA <span class="caret"></span></button>
<ul id="standard" class="dropdown-menu">
<li><input type="radio" name="standard" data-argName="standardsection" value="section" id="section" /><label for="section" >Section508</label></li>
<li><input type="radio" name="standard" data-argName="standardwcaga" value="wcaga" id="wcaga" /><label for="wcaga" >WCAG2A</label></li>
<li><input type="radio" name="standard" data-argName="standardwcagaa" value="wcagaa" id="wcagaa" checked="checked" /><label for="wcagaa" >WCAG2AA (default)</label></li>
<li><input type="radio" name="standard" data-argName="standardwcagaaa" value="wcagaaa" id="wcagaaa" /><label for="wcagaaa" >WCAG2AAA</label></li>
</ul>
</div>
<div class="col-xs-6 col-s-6 col-md-6 col-l-6">
<label for="folderPicker">Output Folder:</label>
<input id="folderPicker" type="text" class="form-control" data-argName="folderPicker" required="required" />
<span id="outputFolderIcon" class="glyphicon glyphicon-folder-open pull-right" title="Browse"></span>
<input type="file" id="outputFolderBrowse" nwdirectory="nwdirectory" nwworkingdir="..." class="hide" />
</div>
</div>
<div class="row" id="imageAltsSection">
<div class="col-xs-12 col-s-12 col-md-12 col-l-12">
<label for="imagealts">Image Accessibility:</label>
<p><button id="clipboard" class="btn btn-sm btn-primary">Copy the console code</button> Paste this code in your browser's console and press enter. It will give you code you can paste into the box below, then click "Run".</p>
<textarea id="imagealts" class="form-control"></textarea>
</div>
</div>
<div class="row" id="button-row">
<div class="col-xs-12 col-s-12 col-md-12 col-l-12 text-left" style="vertical-align: middle">
<span id="button-badges">
<button class="btn btn-sm btn-danger" type="button" value="true" data-argName="badgeError">
Errors <span class="badge">0</span>
</button>
<button class="btn btn-sm btn-warning" type="button" value="true" data-argName="badgeWarning">
Warnings <span class="badge">0</span>
</button>
<button class="btn btn-sm btn-primary" type="button" value="true" data-argName="badgeNotice">
Notices <span class="badge">0</span>
</button>
</span>
<button type="submit" id="run" class="btn btn-primary pull-right">Run!</button>
</div>
</div>
</form>
<hr />
<div id="results" class="row"></div>
</section>
<!--
/////////////////////////////////////////////////////////////////
// //
// ABOUT MODAL //
// //
/////////////////////////////////////////////////////////////////
// This content is displayed when the user clicks Help in the //
// top navigation, then About. Some parts of the about modal //
// are automatically replaced by the content defined in your //
// package.json file, such as Application Name and Version. //
/////////////////////////////////////////////////////////////////
-->
<div id="aboutModal" class="modal">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<span class="glyphicon glyphicon-remove pull-right" data-dismiss="modal" aria-hidden="true"></span>
<h4>About</h4>
</div>
<div class="modal-body">
<div class="panel panel-primary">
<div class="panel-heading">
<span class="pull-right versionApp" title="Version">V2.0.0</span>
<h3 class="panel-title">About <span class="applicationTitle">Koa11y</span></h3>
</div>
<div class="panel-body">
<p class="well well-sm">
This program will load an invisible (headless) browser and go to the URL you've supplied to test the page for accessibility issues. Then it outputs any issues to a file.
</p>
<p>
<span class="applicationTitle">Koa11y</span> was created by The Jared Wilcurt.<br />
Koa11y uses Pa11y under the hood to automate checking your page for issues. For more information visit: <a href="http://pa11y.org" class="external-link">Pa11y.org</a>.<br />
Koala Logo designed by <a href="mailto:[email protected]" title="[email protected]" class="external-link">Charlotte Schmidt</a>.<br /><br />
<div class="text-center">
<a href="http://thejaredwilcurt.github.io/Koa11y" class="external-link">Visit the Koa11y website.</a>
</div>
</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div id="spinner" style="display: none;">
<div class="stage">
<div class="cube">
<div class="side side1"></div>
<div class="side side2"></div>
<div class="side side3"></div>
<div class="side side4"></div>
</div>
</div>
</div>
<div id="imageAltsModal" class="modal">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<span class="glyphicon glyphicon-remove pull-right" data-dismiss="modal" aria-hidden="true"></span>
<h4>Image Alts</h4>
</div>
<div class="modal-body">
<div id="imageAltsThumbs"></div>
<div id="imageAltsDonut" class="donut-size">
<div class="pie-wrapper">
<span class="label">
<span class="num">0</span><span class="smaller">%</span>
</span>
<div class="pie">
<div class="left-side half-circle"></div>
<div class="right-side half-circle"></div>
</div>
<div class="shadow"></div>
</div>
</div>
</div>
<div class="modal-footer">
<button class="btn btn-success pull-right disabled">Continue</button>
</div>
</div>
</div>
</div>
</div> <!-- end container -->
</body>
</html>