-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathexample.html
More file actions
59 lines (47 loc) · 1.85 KB
/
example.html
File metadata and controls
59 lines (47 loc) · 1.85 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
<html>
<head>
<title>Spawncamping Octo Name Generator Example</title>
<script src="lib/spawncamping.octo.name.generator.js" type="text/javascript"></script>
<script type="text/javascript">
// This is just a helper function for displaying the output
function appendText(text) {
console.log("Generated: " + text);
document.f.t.value = "" + text + "\n" + document.f.t.value;
}
</script>
<style>
p {margin-left:20px;}
pre {
background-color: #ccc;
padding: 10px;
max-width: 600px;
}
</style>
</head>
<h1>Spawncamping Octo Name Generator</h1>
<p>The name for this library was itself chosen by GitHub's name generator</p>
<form name="f">
<h2>Output</h2>
<textarea name="t" rows="15" cols="40"></textarea>
<p>Default:
<pre>OctoNameGenerator.get()</pre>
<input type="button" onClick="appendText( OctoNameGenerator.get() )" value="generate!">
</p>
<p>Use industrial wordset:
<pre>OctoNameGenerator.get({wordSet:'industrial'})</pre>
<input type="button" onClick="appendText( OctoNameGenerator.get({wordSet:'industrial'}) )" value="generate!">
</p>
<p>Choose word types:
<pre>OctoNameGenerator.get({wordSet:'industrial',wordTypes:['adjectives','nouns']})</pre>
<input type="button" onClick="appendText( OctoNameGenerator.get({wordSet:'industrial',wordTypes:['adjectives','nouns']}) )" value="generate!">
</p>
<p>Choose word types and order:
<pre>OctoNameGenerator.get({wordSet:'industrial',wordTypes:['nouns','verbs']})</pre>
<input type="button" onClick="appendText( OctoNameGenerator.get({wordSet:'industrial',wordTypes:['nouns','verbs']}) )" value="generate!">
</p>
<p>Use geo wordset:
<pre>OctoNameGenerator.get({wordSet:'geo'})</pre>
<input type="button" onClick="appendText( OctoNameGenerator.get({wordSet:'geo'}) )" value="generate!">
</p>
</form>
</html>