-
Notifications
You must be signed in to change notification settings - Fork 1
/
storage.html
92 lines (89 loc) · 2.7 KB
/
storage.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
<html>
<head>
<script src="http://code.jquery.com/jquery-1.10.1.min.js"></script>
<script src="storage.js"></script>
<style>
.status {
white-space: pre;
font-family: monospace;
font-size: 12pt;
}
</style>
<link href="storage.css" rel="stylesheet" type="text/css">
</head>
<body>
<div class="dialog" id="storagedialog">
<h1 class="save">Save <span class="basename"></span>…</h1>
<h1 class="open">Restore <span class="basename"></span>…</h1>
<div class="local option">
<h2 class="save">…on this browser</h2>
<h2 class="open">…from this browser</h2>
<input class="save" type="text" placeholder="New file"/>
<div class="hasfiles">
<select>
<option value="" class="null save">New file</option>
<optgroup label="Existing files">
</optgroup>
</select>
</div>
<button>
<span class="save">Save</span>
<span class="open">Restore</span>
</button>
</div>
<div class="file option">
<h2 class="save">…on this computer</h2>
<h2 class="open">…from this computer</h2>
<div class="save">
<a download="save.sav" class="downloadlink" href="">Download <span class="basename"></span>…</a>
</div>
<div class="open">
<input type="file"/>
<button>
<span class="save">Save</span>
<span class="open">Restore</span>
</button>
</div>
</div>
<div class="drive option">
<h2 class="save">…on Google Drive</h2>
<h2 class="open">…from Google Drive</h2>
<div class="signedin">
<input class="save" type="text" placeholder="New file"/>
<div class="hasfiles">
<select>
<option value="" class="null save">New file</option>
<optgroup label="Existing files">
</optgroup>
</select>
</div>
<button>
<span class="save">Save</span>
<span class="open">Restore</span>
</button>
</div>
<div class="signedout">
</div>
</div>
<div class="server option open">
<h2 class="open">…from server.</h2>
<div class="signedin">
<select id="serveroldname">
</select>
<button>
<span class="save">Save</span>
<span class="open">Restore</span>
</button>
</div>
<div class="signedout">
</div>
</div>
</div>
<script>
s=Storage();
s.save({ local: 'jszipSaves', data: '0000', pattern: '.+\.sav' });
//s.open({ local: 'jszipSaves', pattern: '\.sav$',callback: function(d) { console.log(d)} });
//s.save({});
</script>
</body>
</html>