-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
595 lines (551 loc) · 30.7 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
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
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
<!DOCTYPE html>
<html>
<head>
<link rel="shortcut icon" href="res/favicon.ico" type="image/x-icon" />
<script src="https://code.jquery.com/jquery-3.4.1.min.js"></script>
<!-- <script src="https://code.jquery.com/ui/1.12.1/jquery-ui.min.js"></script> -->
<!-- <script src="https://cdn.jsdelivr.net/npm/[email protected]/jquery.layout.min.js"></script> -->
<!-- <script src="https://cdnjs.cloudflare.com/ajax/libs/draggable/1.0.0-beta.8/draggable.min.js"></script> -->
<script src="https://cdn.rawgit.com/harvesthq/chosen/gh-pages/chosen.jquery.min.js"></script>
<link href="https://cdn.rawgit.com/harvesthq/chosen/gh-pages/chosen.min.css" rel="stylesheet"/>
<script src="https://www.jsviews.com/download/jsviews.min.js"></script>
<script src="https:////www.jsviews.com/download/sample-tag-controls/jsonview/jsonview.js"></script>
<script src="amazon-cognito-auth.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/lodash.min.js"></script>
<!-- <script src="aws-cognito-sdk.min.js"></script> -->
<script src="oracle.js"></script>
<!-- TODO: dynamic this: -->
<script src="templates/l5r.js"></script>
<script src="templates/lbs.js"></script>
<script src="templates/7thsea.js"></script>
<script src="templates/initiald.js"></script>
<script src="templates/warlord.js"></script>
<script src="templates/dune.js"></script>
<script src="pdfkit.min.js" defer></script>
<script src="blob-stream.min.js" defer></script>
<!-- <link href="https://www.jsviews.com/samples/samples.css" rel="stylesheet" /> -->
<!-- <link rel="stylesheet" href="https://unpkg.com/balloon-css/balloon.min.css"> -->
<link rel="stylesheet" href="balloon.min.css">
<LINK href="oracle.css" rel="stylesheet" type="text/css" />
<style>
label {display: inline-block; margin: 6px 15px 2px 0px;}
</style>
</head>
<body>
<!-- <div class="ui-layout-north"> -->
<div class="menubar" style="position: relative">
<!-- <img src="res/logo-inline.png"> -->
<nav role="navigation">
<ul>
<li class="dropdown menuone"><svg class="feather"><use xlink:href="res/feather-sprite.svg#menu"></svg>
<ul>
<li><span onclick="localStorage.clear(); window.location = window.location.href.substr(0, window.location.href.indexOf('#'));" >Clear Cache <svg class="feather"><use xlink:href="res/feather-sprite.svg#refresh-ccw"></svg></span></li>
<!-- TODO: make this reload a little more friendly with push/pop history state -->
<!-- <li>Settings/whatnot here</li> -->
<!-- <li><a href="." onclick="cache_session('database','l5r');">Legend of the Five Rings</a></li>
<li><a href="." onclick="cache_session('database','lbs');">Legend of the Burning Sands</a></li> -->
</ul>
</li>
<li class="gamechooser pullmenu"><span class="gameinfo-game"></span>
<ul class="dropdown gamelist">
</ul>
</li>
<li class="loginfo right"><span id="loginfo"></span>
<ul class="dropdown menuone">
<li id="userinfo-drop">...</li>
<li onclick="dologout();">Log Out</li>
</ul>
</li>
<li>Formats:</li>
<li class="pullmenu">Search
<ul class="dropdown" id="searchtemplatedropdown">
</ul>
</li>
<li class="pullmenu">Card
<ul class="dropdown" id="cardtemplatedropdown">
</ul>
</li>
<li class="pullmenu">List
<ul class="dropdown" id="listtemplatedropdown">
</ul>
</li>
<li class="right"><span class="button gray" id="loginbutton" onclick="dologin();" style="display: none;">Log In/Register</span></li>
</ul>
</nav>
<div id="logarea"></div>
<!-- <img style="position: absolute; bottom: 3px; right: 11px;" src="res/icon-collapse-up-22x22.png" width="22px" height="12px" onclick="oraclelayout.toggle('north');" /> -->
</div>
<!-- </div> -->
<!-- search area -->
<div id="sidebaropener" onclick="sidebaropener();"><img src="res/a-tabright.png"></div>
<div class="ui-layout-west" id="sidebar">
<div class="searchinput" id="searchinput">
<img id="sidebarcloser" src="res/a-tableft.png" width="21px" height="40px" onclick="sidebarcloser();" />
<a href="/"><div class="logo"> <img width="75" height="58" src="res/logo.png"> </div></a>
<input type="hidden" id="lastsearch" />
<input type="hidden" id="lastsearchquery" />
<input type="hidden" id="lastlistid" />
<input type="hidden" id="lastcardid" />
<input type="hidden" id="lastprintid" />
<form id="searchform" method="POST" onsubmit="dosearch(); return false;" action="">
<dl>
<dt class="notadvanced"></dt><dd class="searchbutton notadvanced"><span class="button gray" id="advancedbutton" onclick="$('dt.advanced').show(); $('dd.advanced').show(); $('dt.notadvanced').hide(); $('dd.notadvanced').hide();">Advanced</span></dd>
<dt class="advanced"></dt><dd class="searchbutton advanced"><span class="button gray" id="basicbutton" onclick="$('dt.advanced').hide(); $('dd.advanced').hide(); $('dt.notadvanced').show(); $('dd.notadvanced').show();">Basic</span></dd>
<dt class="advanced"></dt><dd class="searchbutton"><span class="button gray" id="resetbutton" onclick="$('#searchform')[0].reset(); $('.chosen-select').trigger('chosen:updated');">Reset</span></dd>
<div id="searchtop"><dt>All</dt><dd><input type="text" name="querystring" id="qs" autofocus /></dd></div>
<div id="searchmiddle"></div>
</dl>
<div id="searchbottom">
<span class="gameinfo-gameshort"></span> <span class="gameinfo-gamelogo15"></span><br />
<span class="button gray" onclick="dosearch();">Search<span class="iiconic iyellow"><svg class="feather"><use xlink:href="res/feather-sprite.svg#loader"></svg></span></span>
</div></div>
</form>
<br clear="all" />
<br />
<div id="deckarea">
</div>
<!--
<br>
<style>img#amznBanners_assoc_banner_placement_default_0_img { display: inline-block; }</style>
<div style="text-align: center">
<script type="text/javascript">
amzn_assoc_ad_type = "banner";
amzn_assoc_marketplace = "amazon";
amzn_assoc_region = "US";
amzn_assoc_placement = "assoc_banner_placement_default";
amzn_assoc_campaigns = "toysandgames";
amzn_assoc_banner_type = "category";
amzn_assoc_p = "21";
amzn_assoc_isresponsive = "false";
amzn_assoc_banner_id = "0QERA3S6YE7N02MRZX02";
amzn_assoc_width = "125";
amzn_assoc_height = "125";
amzn_assoc_tracking_id = "ksuquix-20";
amzn_assoc_linkid = "8d85a5d8e3789ce10e7930974c18a550";
</script>
<script src="//z-na.amazon-adsystem.com/widgets/q?ServiceVersion=20070822&Operation=GetScript&ID=OneJS&WS=1"></script>
</div>
-->
<a href="https://www.facebook.com/pg/oracleofthevoid" target="_new">
<img src="res/FindUs-FB-RGB-BRC-Site-500.png" width="125px"> </a>
<br>
<a href="https://discord.gg/3ahYmwn" target="_new">
<img src="res/Discord-Logo+Wordmark-Color.png" width="125px"> </a>
<br>
<a href="https://www.patreon.com/oracleofthevoid" target="_new">
<img src="res/[email protected]" width="125px"> </a>
<br>
<a href="https://github.com/Oracle-of-the-Void/ootv-client/issues" target="_new"><div style="background-color: white; display: inline-block; margin: 3px; height: 32px;">
<svg style="float: left;" class="octicon octicon-mark-github v-align-middle" height="30" viewBox="0 0 16 16" version="1.1" width="30" aria-hidden="true"><path fill-rule="evenodd" d="M8 0C3.58 0 0 3.58 0 8c0 3.54 2.29 6.53 5.47 7.59.4.07.55-.17.55-.38 0-.19-.01-.82-.01-1.49-2.01.37-2.53-.49-2.69-.94-.09-.23-.48-.94-.82-1.13-.28-.15-.68-.52-.01-.53.63-.01 1.08.58 1.23.82.72 1.21 1.87.87 2.33.66.07-.52.28-.87.51-1.07-1.78-.2-3.64-.89-3.64-3.95 0-.87.31-1.59.82-2.15-.08-.2-.36-1.02.08-2.12 0 0 .67-.21 2.2.82.64-.18 1.32-.27 2-.27.68 0 1.36.09 2 .27 1.53-1.04 2.2-.82 2.2-.82.44 1.1.16 1.92.08 2.12.51.56.82 1.27.82 2.15 0 3.07-1.87 3.75-3.65 3.95.29.25.54.73.54 1.48 0 1.07-.01 1.93-.01 2.2 0 .21.15.46.55.38A8.013 8.013 0 0016 8c0-4.42-3.58-8-8-8z"></path></svg>
<!-- <img src="https://avatars2.githubusercontent.com/u/61508750?s=200&v=4" height="30px"> --><span style="line-height: 30px; margin-right: 3px; color: black; text-decoration:none;"> Report Problems</span>
</div></a>
<br>
<a href="https://www.youtube.com/channel/UCBR9rTYdKUYSwEAmShJyjDw" target="_new">
<div style="background-color: white; display: inline-block; margin: 3px; height: 32px;">
<img style="margin-top: 4px; float: left;" src="res/social-youtube-small.png" width="32"><span style="line-height: 30px; margin-right: 3px; color: black; text-decoration: none;"> Youtube</span>
</div>
</a>
<br><br><br><br>
<script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<!-- square -->
<ins class="adsbygoogle"
style="display:block"
data-ad-client="ca-pub-2994105292824681"
data-ad-slot="1657142238"
data-ad-format="auto"
data-full-width-responsive="true"></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>
</div>
</div>
<!-- end search area -->
<!-- <br clear="all" /> -->
<div class="ui-layout-center" id="maincontent"> <!-- main content area -->
<ul id="tabs">
<li><a href="#" name="resultabout">About</a></li>
<li><a href="#" name="resultsearch">Search</a></li>
<li><a href="#" name="resultcard">Card</a></li>
<li><a href="#" name="resultdir">Directory</a></li>
<li><a href="#" name="resultlist">List</a></li>
<li><a href="#" name="resulthelp">Help</a></li>
<li class="r"><span class="numresults"></span></li>
</ul>
<div class="resultcard" id="resultcard"><div class="randarea">No Cards rendered yet, Do a Search and click on a card.</div></div>
<div class="resultdir" id="resultdir">
<div class="listitem directorylistheader">
<div class="listheadmiddle">Id</div>
<div class="listheadmiddle">Name</div>
<div class="listheadmiddle">Type</div>
<div class="listheadmiddle">Count</div>
<div class="listheadmiddle">Created</div>
<div class="listheadmiddle">Modified</div>
<div class="listheadmiddle">Public</div>
<div class="listheadmiddle">Notes</div>
<div class="listheadmiddle"></div>
<div class="listheadmiddle"></div>
<div class="listheadmiddle"></div>
<div class="listheadmiddle"><button aria-label="Create new list" data-balloon-pos="up-right" class="showonlogin iiconic ipositive" onclick="newlist();" style="display:none"><svg class="feather"><use xlink:href="res/feather-sprite.svg#plus-circle"></svg></button></div>
</div>
<div class="hideonlogin directorylistitem out"><div class="randarea">You must be logged in to create/work with lists <span class="button gray" id="loginbutton" onclick="dologin();">Log In/Register</span></div></div>
<div class="directorylistitem out"><div class="randarea">No Lists rendered yet</div></div>
</div>
<div class="resultlist" id="resultlist"><div class="randarea">No list selected, click on Directory</div></div>
<div class="resultsearch" id="resultsearch"><div class="randarea">No Searches performed yet, use the Search area on the left</div></div>
<div class="resultabout" id="resultabout">
<div class="randarea">
<!-- TODO: integrate this documentation into stuff -->
<div class="helloplace"></div>
<br /><div class="infoplace">
Welcome to the L5R Oracle of the Void Database
<br>
<br>
<div class="floatblock">
After Legend of the Five Rings was sold to Fantasy Flight at the end of 2015, Don Eisele (Author of the Oracle of the Void) has continued to fund and run the Oracle of the Void. He is currently working on revamping and coding the Oracle into a serverless cloud architecture on AWS. The new version <strike>will be</strike> <b>is much</b> faster, more resiliant (not running in Don's basement), and supports other games.
</div>
<div class="floatblock">
If you like the Oracle of the Void,<br>please Like our Facebook page: <br>
<a href="https://www.facebook.com/pg/oracleofthevoid" target="_new">
<img src="res/social-facebook.png" width="300px"> </a>
</div>
<div class="floatblock">
Join us on Discord to discuss future plans,<br> or just hang out: <br>
<a href="https://discord.gg/3ahYmwn" target="_new">
<img src="res/social-discord.png" width="300px"> </a>
</div>
<div class="floatblock">
Consider donating to the Oracle's Patreon<br>to support the effort:<br>
<a href="https://www.patreon.com/oracleofthevoid" target="_new">
<img src="res/social-patreon.png" width="300px"> </a>
</div>
<div class="floatblock">
Report issues or request new features on Github issues:<br>
<a href="https://github.com/Oracle-of-the-Void/ootv-client/issues" target="_new">
<img src="https://avatars2.githubusercontent.com/u/61508750?s=200&v=4" width="150px">
</a>
</div>
<div class="floatblock">
Youtube channel with some help videos!<br>
<a href="https://www.youtube.com/channel/UCBR9rTYdKUYSwEAmShJyjDw" target="_new">
<img src="res/social-youtube.jpg" width="300px"> </a>
</div>
<!--
<br><br>
<script type="text/javascript">
amzn_terms = [ 'l5r lcg', 'l5r ccg', '7th sea ccg', 'warlord ccg', 'dune ccg', 'legend of the burning sands ccg', 'strategy board games', 'ccg', 'board game deals', 'board game sales', 'fantasy flight games', 'collectible card game' ];
amzn_assoc_placement = "adunit0";
amzn_assoc_search_bar = "false";
amzn_assoc_tracking_id = "ootv-20";
amzn_assoc_ad_mode = "search";
amzn_assoc_ad_type = "smart";
amzn_assoc_marketplace = "amazon";
amzn_assoc_region = "US";
amzn_assoc_title = "Support the Oracle and get something for yourself, too:";
amzn_assoc_default_search_phrase = amzn_terms[amzn_terms.length * Math.random() | 0];
amzn_assoc_default_category = "Toys";
amzn_assoc_linkid = "2d5eefcc9964a6d5ac179b2e95b28bf9";
amzn_assoc_default_browse_node = "165793011";
</script>
<script src="//z-na.amazon-adsystem.com/widgets/onejs?MarketPlace=US"></script>
-->
<div class="floatblock">
Buying cards from Don also supports the site!<br>(L5R, LBS, SW:CCG, V:TES)<br>
<a href="https://imperialblock.com/store?user=quixote"><img src="https://imperialblock.com/images/banner2-266x60.jpg"></a>
</div>
<br clear="all"><br>
Recent Data Updates for Currently Selected Database:<br>
<div id="updatelog">
</div>
</div>
</div>
</div><!-- resultabout -->
<div class="resulthelp" id="resulthelp">
<div class="randarea">
<div class="infoplace">
<ul>
<li>Not everything is completely set yet, so if you have feedback let me know.
<li>All search boxes are logically AND'ed together.
<li>Title is a "match" field. Individual words are matched against the title.
<li>Keywords is a "match phrase" field. The complete phrase is matched.
<li>The Pull-down fields are self-explanatory
<li>The ALL field is where the true search power is.
<li>Results are agressively cached
<li>Infinite scrolling, loads more on demand (currently 10 items a load for debugging - will be larger in production)
</ul>
<br><br>
Youtube channel with some help videos!<br>
<a href="https://www.youtube.com/channel/UCBR9rTYdKUYSwEAmShJyjDw" target="_new">
<img src="res/social-youtube.jpg" width="300px"> </a>
<br><br>
All: <a target="_blank" href="http://lucene.apache.org/core/3_0_3/queryparsersyntax.html">Lucene search format:</a><br>
<dl>
<dt>Boolean
<dd><code>+keywords:"dark virtue" +text:reaction -title:determination</code> (note: default is ANDing terms)
<dt>English
<dd><code>keywords:"dark virtue" AND text:reaction AND NOT title:determination</code>
<dt>Parenthesis
<dd><code>clan:crab AND (force:10 OR chi:6)</code>
<dt>backslash<dd><code>+ - && || ! ( ) { } [ ] ^ ~ * ? : \ (double-quote)</code>
<dt>fuzzy<dd><code>title:otaku~</code> will also find utaku card titles
<dt>slop<dd><code>title:"oni no"~2</code> will find "oni no" and "no oni" titles
<dt>gt/lt<dd><code>force:>15</code> will find cards greater than 15 force
</dl>
Each card has an entry with different printings nested under "printing"<br>
List of fields:
<pre>
banned
chi
clan
cost
deck
erratum
focus
force
formattedtitle
honor
cardid
keywords
legality
mrp
notes
ph
playtestname
production
startinghonor
story
strength
text
title
type
printingprimary
printing:
artist
artnumber
designer
designernotes
legaldate
number
printedtext
printedwithset
promoquantity
rarity
set
use
printingid
printingchi
printingclan
printingcost
printingflavor
printingfocus
printingforce
printinghonor
printingkeywords
printingnotes
printingpersonalhonor
printingstory
printingtext
printingtitle
printingtype
</pre>
</div>
</div>
</div><!-- resulthelp -->
</div><!-- ui-content-center -->
<div id="all_template">
<!-- modal template for editing a card -->
<script id="template-editcard" type="text/jsrender">
<form id="editform" enctype="multipart/form-data">
<input name="cardid" id="editcardid" type="hidden" value="{{:cardid}}" />
<input name="table" id="editcarddb" type="hidden" value="{{:database}}" />
<input name="printid" id="editcardprint" type="hidden" value="{{:printid}}" />
<textarea id="editcard" name="editcard" rows="50" cols="100">{{:carddata}}</textarea>
<input type="button" id="editcardbutton" value="Update" onclick="editcardtrigger();" />
<div id="editcardbuttonafter"></div>
</form>
</script>
<!-- modal template for importing lists -->
<script id="template-import" type="text/jsrender">
<form id="importform" enctype="multipart/form-data">
<input name="listid" id="importlistid" type="hidden" value="{{:listid}}" />
<input name="table" type="hidden" value="{{:database}}" />
<input name="data" id="importdataval" type="hidden" value="" />
<input name="failed" id="importfailedval" type="hidden" value="" />
<select style="width: 100%" name="fieldlist" data-placeholder="Select input type" class="chosen-select">
<option value=""></option>
<option value="textsnm,puretexttitle,title">Sun and Moon</option>
<option value="puretexttitle,title">Native Oracle</option>
</select><br /><br />
<input name="file" type="file" /><br /><br />
<input type="button" value="Upload" onclick="importlisttrigger();" /></form>
<progress id="importprogress" style="display:none"></progress>
<div id="importstatus"></div>
</script>
<!-- modal template for finalizing import of a list -->
<script id="template-importsuccess" type="text/jsrender">
<div class="numresults">Success</div>
<br /><br />
{{:numresults}} cards imported successfully<br />
{{:numfailed}} cards failed to import<br />
Do you wish to continue loading?
<span class="button gray" onclick="importlistfinalize();">Yes<span class="iiconic ipositive"><svg class="feather"><use xlink:href="res/feather-sprite.svg#check-circle"></svg></span></span>
<span class="button gray" onclick="nomodal();">No<span class="iiconic inegative"><svg class="feather"><use xlink:href="res/feather-sprite.svg#x-circle"></svg></span></span>
{{if failed}}<br /><br />
Failed cards:
<pre>
{{:failed}}
</pre>
{{/if}}
</script>
<!-- template for updatelog entries -->
<script id="template-updatelog" type="text/jsrender">
<div class="updateblock">
{{:timestamp}} {{:operation}} <a href="#game={{:database}},#cardid={{:cardid}}" onclick="if(event.metaKey || event.ctrlKey) {window.open(this.href); } else { docardid(5602,null); } return false;">{{:card.title}}</a> [{{:uname}}]
</div>
</script>
<!-- login hello info displaying login info -->
<script id="template-hello" type="text/x-jsrender">
<div class="helloplace">
<strong>Profile Information</strong>
<dl>
<dt>Joined</dt><dd>{{formatDate:oracle.insert_date}}</dd>
<dt>Uid</dt><dd>{{:oracle.uid}}</dd>
<dt>Emails</dt><dd>{{:oracle.emails.join("<br/>")}}</dd>
<dt></dt><dd>{{if oracle.is_no_email>0}}Email Notifications Disabled{{else}}Email Notifications Enabled{{/if}}</dd>
<dt>Lists</dt><dd>{{:oracle.deckcount}} lists defined</dd>
</dl>
</div>
</script>
<script id="template-listactive" type="text/x-jsrender">
<div class="listblock">
<div><a href="#" onclick="listinfo('{{:listid}}',true); return false;">{{:name}}</a> ({{:type}})
<button class="iiconic inegative" onclick="deactivatelist('{{:listid}}'); return false;"><svg class="feather"><use xlink:href="res/feather-sprite.svg#x-square"></button>
</div>
<div>{{if listdata}}({{:listdata.list.Items[0].distinctcount}}/{{:listdata.list.Items[0].totalcount}} cards){{/if}}</div>
</div>
</script>
<script id="template-lists" type="text/x-jsrender">
<div class="listitem directorylistitem" id="listitem_{{:listid}}">
<div class="listimage" onclick="listinfo('{{:listid}}',true)"; return false;><a aria-label="View List" data-balloon-pos="up-left" href="#" onclick="return false;">{{:listid}}</a></div>
<div class="listmiddle" id="list_name:{{:listid}}" contenteditable="true">{{:name}}</div><div style="display: none;" id="list_prev_name:{{:listid}}">{{:name}}</div>
<div class="listmiddle"><select class="listselect" onchange="listinfoupdate('{{:listid}}','type',this.value);">{{listTypeSelect:type}}</select></div>
<div class="listmiddle">{{if distinctcount>0}}{{:distinctcount}}/{{:totalcount}}{{/if}}</div>
<div class="listmiddle">{{formatDate:createdate}}</div>
<div class="listmiddle" id="list_modified:{{:listid}}">{{formatDate:modified}}</div>
<div class="listmiddle"><select class="listselect" onchange="listinfoupdate('{{:listid}}','public',this.value);"><option value="false"{{if !public}} selected{{/if}}></option><option value="true"{{if public}} selected{{/if}}>Public</option></select></div><!-- TODO figure out how to list public lists -->
<div class="listmiddle" id="list_notes:{{:listid}}" contenteditable="true">{{:notes}}</div><div style="display: none;" id="list_prev_notes:{{:listid}}">{{:notes}}</div>
<div class="listmiddle">
<button aria-label="Activate List to Add cards from search" data-balloon-pos="up-right" class="iiconic idyellow" id="listinactive{{:listid}}" onclick="activatelist('{{:listid}}');"><svg class="feather"><use xlink:href="res/feather-sprite.svg#toggle-left"></svg></button>
<button style="display:none" class="iiconic ipositive" id="listactive{{:listid}}" onclick="deactivatelist('{{:listid}}');"><svg class="feather"><use xlink:href="res/feather-sprite.svg#toggle-right"></svg></button>
</div>
<div aria-label="Delete List" data-balloon-pos="up-right" class="listmiddle"><button class="iiconic inegative" onclick="removelist('{{:listid}}');"><svg class="feather"><use xlink:href="res/feather-sprite.svg#trash-2"></svg></button></div>
<div class="listmiddle"><nav role="download"><ul class="menuone">
<li><button aria-label="Download list" data-balloon-pos="up-right" class="iiconic ipositive"><svg class="feather"><use xlink:href="res/feather-sprite.svg#download"></svg></button>
<ul>
<li onclick="listinfo('{{:listid}}',false,'pdf,filename:ootv_{{filenamecleaner:name}}');"><button class="iiconic inegative"><svg class="feather"><use xlink:href="res/feather-sprite.svg#image"></svg> PDF Print-n-Play</button></li>
<li onclick="listinfo('{{:listid}}',false,'textsnm,filename:ootv_{{filenamecleaner:name}}');"><button class="iiconic idyellow"><svg class="feather"><use xlink:href="res/feather-sprite.svg#sun"></svg> Sun and Moon</button></li>
<li onclick="listinfo('{{:listid}}',false,'texttab,filename:ootv_{{filenamecleaner:name}}');"><button class="iiconic iblue"><svg class="feather"><use xlink:href="res/feather-sprite.svg#columns"></svg> Tab-delimited</button></li>
<!-- <li onclick="listinfo('{{:listid}}',false,'texteopk,filename:ootv_{{filenamecleaner:name}}');"><button class="iiconic iblack"><svg class="feather"><use xlink:href="res/feather-sprite.svg#circle"></svg> Egg of Pan'ku</button></li> -->
<!-- <li onclick="listinfo('{{:listid}}',false,'textlackey,filename:ootv_{{filenamecleaner:name}}');"><button class="iiconic ipurple"><svg class="feather"><use xlink:href="res/feather-sprite.svg#copy"></svg> Lackey CCG</button></li> -->
<li onclick="toggleheaders();"><button class="iiconic ipositive toggleheaderson"><svg class="feather"><use xlink:href="res/feather-sprite.svg#toggle-right"></svg></button><button style="display:none;" class="iiconic inegative toggleheadersoff"><svg class="feather"><use xlink:href="res/feather-sprite.svg#toggle-left"></svg></button> Headers</li>
</ul>
</li></ul></nav></div>
<div class="listmiddle" onclick="importlist('{{:listid}}','{{:name}}');">
<button aria-label="Upload list" data-ballon-pos="up-right" class="iiconic ipositive"><svg class="feather"><use xlink:href="res/feather-sprite.svg#upload"></svg></button>
</div>
</div>
</script> <!-- template-lists -->
<script id="template-card-top" type="text/x-jsrender">
<div class="listitem">
<div class="listimage">
{{for printing ~shorts=#data}}
<div class="printing" data-printingid="{{:printingid}}">
{{if image}}
{{for image ~imagehash=imagehash}}
{{if ~imageclass}}
<img src="{{:~dbinfo.imageuri}}{{:~imagehash}}/{{:#data[~imageclass]}}" /><br />
{{else}}
<img style="max-width: 600px; max-height: 600px" src="{{:~dbinfo.imageuri}}{{:~imagehash}}/{{:details}}" /><br />
{{/if}}
{{/for}}
{{else images}}
{{for images}}
{{if ~imageclass}}
<img src="{{:}}{{:~imageclass}}.jpg" /><br />
{{else}}
<img style="max-width: 600px; max-height: 600px" src="{{:}}details.jpg" /><br />
{{/if}}
{{/for}}
{{else}}
<img src="/res/missing-stamp-rot288.png">
{{/if}}
</div>
{{/for}}
</div>
<div class="listbody">
<input id="printingprimary" type="hidden" name="printingprimary" value="{{:printingprimary}}">
<div class="listheadxl">{{if ~qs}}<a href="" id="cardprev" onclick="cardprev({{:cardid}},'{{addslashes:~qs}}'); return false"><img src="res/symbol-left-one.png"></a>{{/if}} {{if ~qs}}<a href="" id="cardnext" onclick="cardnext({{:cardid}},'{{addslashes:~qs}}'); return false"><img src="res/symbol-right-one.png"></a>{{/if}} {{:formattedtitle?formattedtitle:title}} <a id="cardclose" class="ex gray button" href="" onclick="window.history.back(); return false;">X</a>
</div>
{{if ~groups && (~groups.database || ~groups["*"])}}
<span style="float:right; padding-right: 2px;">
<span class="iiconic iyellow" onclick="editcard({{:cardid}}); return false;"><svg class="feather"><use xlink:href="res/feather-sprite.svg#edit"></span>
<span class="iiconic ipositive" onclick="editcard(''); return false;"><svg class="feather"><use xlink:href="res/feather-sprite.svg#file-plus"></span>
<span class="iiconic inegative" onclick="deletecard({{:cardid}}); return false;"><svg class="feather"><use xlink:href="res/feather-sprite.svg#trash-2"></span>
</span>
{{/if}}
<dl>
</script> <!-- template-card-top -->
<script id="template-card-middle" type="text/x-jsrender">
<dt>Versions</dt><dd>{{for printing ~top=#data}}<a class="printinglink gray button buttonsmall" href="#game={{:~database}},#cardid={{:~top.cardid}},#cnprintingid={{:printingid}}" onclick="if(event.metaKey || event.ctrlKey) {window.open(this.href); } else { changeprinting({{:~top.cardid}},{{:printingid}},'{{addslashes:~qs}}','{{addslashes:~top.formattedtitle?~top.formattedtitle:~top.title}}'); } return false;">({{:printingid}}) {{:setclean}}/{{:rarityclean}}{{if printingid == ~top.printingprimary}} *{{/if}}</a> {{!-- {{if #index+1 < #get("array").data.length}} ● {{/if}} --}} {{/for}}</dd>
{{if ~groups && (~groups.database || ~groups["*"])}}
<span style="float:right; padding-right: 2px;">
<span class="iiconic iyellow" onclick="setprimary({{:cardid}},$('#lastprintid').val()); return false;">*</span>
<span class="iiconic iyellow" onclick="editcard({{:cardid}},$('#lastprintid').val()); return false;"><svg class="feather"><use xlink:href="res/feather-sprite.svg#edit"></span>
<span class="iiconic ipositive" onclick="editcard({{:cardid}},Number.MAX_SAFE_INTEGER); return false;"><svg class="feather"><use xlink:href="res/feather-sprite.svg#file-plus"></span>
<span class="iiconic inegative" onclick="deletecard({{:cardid}},$('#lastprintid').val()); return false;"><svg class="feather"><use xlink:href="res/feather-sprite.svg#file-minus"></span>
</span>
{{/if}}
</script> <!-- template-card-middle -->
<script id="template-card-bottom" type="text/x-jsrender">
</dl>
{{if ~activelists.length > 0}}
<div class="listmanagement">
{{for ~activelists ~cardid=cardid}}
{{:name}}
<span class="iiconic ipositive" onclick="addlistitem('{{:listid}}','{{:~cardid}}',0,1); return false;"><svg class="feather"><use xlink:href="res/feather-sprite.svg#plus-circle"></span>
<span class="iiconic inegative" onclick="addlistitem('{{:listid}}','{{:~cardid}}',0,-1); return false;"><svg class="feather"><use xlink:href="res/feather-sprite.svg#minus-circle"></span>
<span class="iiconic inegative" onclick="addlistitem('{{:listid}}','{{:~cardid}}',0,null); return false;"><svg class="feather"><use xlink:href="res/feather-sprite.svg#trash-2"></span>
<br />
{{/for}}
{{for printing ~cardid=cardid}}
<div>
{{:setclean}}<br />
{{for ~activelists ~printingid=printingid}}
{{:name}}
<span class="iiconic ipositive" onclick="addlistitem('{{:listid}}','{{:~cardid}}',{{:~printingid}},1); return false;"><svg class="feather"><use xlink:href="res/feather-sprite.svg#plus-circle"></span>
<span class="iiconic inegative" onclick="addlistitem('{{:listid}}','{{:~cardid}}',{{:~printingid}},-1); return false;"><svg class="feather"><use xlink:href="res/feather-sprite.svg#minus-circle"></span>
<span class="iiconic inegative" onclick="addlistitem('{{:listid}}','{{:~cardid}}',{{:~printingid}},null); return false;"><svg class="feather"><use xlink:href="res/feather-sprite.svg#trash-2"></span>
<br />
{{/for}}
</div>
{{/for}}
</div>
{{/if}}
{{if updatelogformatted}}
<a href="" onclick="$('#cardupdatesection').toggle(); return false;">Latest Updates: ({{:updatelogformatted[0].timestamp}})+</a><br>
<div id="cardupdatesection">
{{for updatelogformatted}}
<div class="updateblock">{{:timestamp}} {{:op}} {{if newdata}}<div class="updatedetails">New: {{:newdata}}</div> {{/if}}{{if olddata}}<div class="updatedetails">Old: {{:olddata}}</div> {{/if}}[{{:uname}}]</div>
{{/for}}
</div>
{{/if}}
</div>
</div>
<br clear="all" />
</script> <!-- template-card-bottom -->
</div><!-- all_template -->
</div><!-- main content area -->
<div id="modal" class="modal" onclick="generalnomodal(this,event);"><div class="modal-box"><div class="listhead upperhead"><span id="modal-title">Hi</span><button class="iiconic inegative headsetrar" onclick="nomodal();"><svg class="feather"><use xlink:href="res/feather-sprite.svg#x-square"></button></div><div class="modal-content" id="modal-content"></div></div></div>
<div id="modalconfirm" class="modal"><span class="button gray" onclick="CONFIRMYES">Yes<span class="iiconic ipositive"><svg class="feather"><use xlink:href="res/feather-sprite.svg#check-circle"></svg></span></span>
<span class="button gray" onclick="nomodal();">No<span class="iiconic inegative"><svg class="feather"><use xlink:href="res/feather-sprite.svg#x-circle"></svg></span></span></div>
</body>
</html>