-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
executable file
·99 lines (85 loc) · 2.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
<!doctype html>
<html>
<head>
<!-- metadata goes in head -->
<meta charset="UTF-8">
<title>ARK Mod List Generator</title>
<link rel="shortcut icon" href="favicon.ico" type="image/x-icon" />
<link rel="stylesheet" type="text/css" href="style.css">
<link rel="stylesheet" type="text/css" href="lib/ply.css">
<script src="lib/clipboard.min.js"></script>
<script src="lib/Sortable.min.js"></script>
<script src="lib/jquery-3.2.1.min.js"></script>
<script src="lib/Ply.min.js"></script>
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-6R4N862XEQ"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'G-6R4N862XEQ');
</script>
</head>
<body onkeydown="omniTitle(event)" onkeyup="omniTitle(event)">
<div id="content">
<h1>ARK Mod List Generator</h1>
<div id="modListContainer">
<h2>Mods</h2>
<ol id="modList" class="list"></ol>
</div>
<div id="controls">
<p>
<button id="addMod" type="button">Add Mod</button>
<button id="save" type="button">Save</button>
</p>
</div>
<div id="output">
<p><textarea id="display" wrap="off" rows="1" readonly placeholder="Add some Mods!"></textarea></p>
<div class="tooltip">
<button id="omnibutton" type="button">Copy to Clipboard</button>
<span class="tooltiptext"><p>Shift-Click: Download exported list</p><p><span id="importKey">Ctrl</span>-Click: Import list from file</p></span>
</div>
<button id="export" type="button" style="display: none"></button>
<input id="import" type="file" style="display: none">
<button id="clipIt" type="button" style="display: none"></button>
</div>
<a href="https://github.com/Juice805/arkmodadmin" target="_blank"><img id="github" src="img/GitHub-Mark-64px.png"></a>
</div>
</body>
<script type="text/javascript">
var OSName="Unknown OS";
if (navigator.appVersion.indexOf("Win") !== -1) {OSName="Windows";}
if (navigator.appVersion.indexOf("Mac") !== -1) {OSName="MacOS";}
if (navigator.appVersion.indexOf("X11") !== -1) {OSName="UNIX";}
if (navigator.appVersion.indexOf("Linux") !== -1) {OSName="Linux";}
switch(OSName){
case "MacOS":
document.getElementById('importKey').textContent = "Alt";
break;
case "Linux":
case "UNIX":
case "Windows":
document.getElementById('importKey').textContent = "Ctrl";
break;
default:
document.getElementById('importKey').textContent = "Alt";
}
function omniTitle(event) {
var uploadKey = false;
if (document.getElementById('importKey').textContent === "Alt") {
uploadKey = event.altKey;
} else {
uploadKey = event.ctrlKey;
}
var button = document.getElementById('omnibutton');
if (uploadKey) {
button.textContent = "Import List";
} else if (event.shiftKey) {
button.textContent = "Export List";
} else {
button.textContent = "Copy to Clipboard";
}
}
</script>
<script src="index.js"></script>
</html>