-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathindex.html
93 lines (93 loc) · 2.78 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>ReSpec Preview: Preview documents using a specific ReSpec version</title>
<style>
* {
box-sizing: border-box;
}
body {
margin: 0;
padding: 1em;
font-family: sans-serif;
}
form, header, footer {
max-width: 80ch;
margin: 2em auto;
}
fieldset {
border: none;
padding: 0;
margin: 1em 0;
}
label {
display: block;
margin-bottom: 0.2em;
}
input, button, textarea {
padding: 1em;
font-size: 1.3em;
}
input, textarea {
width: 100%;
font-family: monospace;
}
button {
background: #1a5e9a;
color: #fff;
border: none;
}
button:hover, button:focus {
background: #013d72;
cursor: pointer;
}
button:disabled {
opacity: 0.5;
cursor: not-allowed;
}
footer {
text-align: right;
margin-top: 5em;
}
</style>
</head>
<body>
<header>
<h1>ReSpec Preview</h1>
<p>Preview documents using a specific ReSpec version</p>
</header>
<form action="">
<fieldset>
<label for="spec">Spec URL</label>
<input type="url" name="spec" id="spec"
placeholder="https://w3c.github.io/payment-request/"
required autofocus />
</fieldset>
<fieldset>
<label for="version">ReSpec Script URL</label>
<input type="url" name="version" id="version" list="url-hints"
placeholder="https://unpkg.com/[email protected]/builds/respec-w3c.js"
required />
<datalist id="url-hints">
<option value="https://www.w3.org/Tools/respec/respec-w3c">Latest</option>
<option value="https://unpkg.com/[email protected]/builds/respec-w3c.js">v24.23.0</option>
<option value="https://deploy-preview-3165--respec-pr.netlify.app/respec-w3c.js">PR #3165</option>
</datalist>
</fieldset>
<fieldset>
<label for="respecConfig"><code>respecConfig</code> override script</label>
<textarea name="respecConfig" id="respecConfig" rows="5" placeholder="respecConfig.editors.push({ name: 'Sid Vishnoi' });"></textarea>
</fieldset>
<button type="submit" name="submitButton">Preview</button>
<noscript>
<p>JavaScript is required for this app to work.</p>
</noscript>
</form>
<footer>
<p>Made by <a href="https://github.com/sidvishnoi">Sid Vishnoi</a> | <a href="https://github.com/sidvishnoi/respec-preview">Source Code at GitHub</a></p>
</footer>
<script src="script.js"></script>
</body>
</html>