-
Notifications
You must be signed in to change notification settings - Fork 2
/
demo.html
92 lines (73 loc) · 2.96 KB
/
demo.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
<!DOCTYPE html>
<html lang="de">
<head>
<meta charset="utf-8" />
<title>
</title>
<link rel="stylesheet" href="iiif2pdf.css">
<link rel="stylesheet" href="https://cdn.rawgit.com/noelboss/featherlight/1.7.13/release/featherlight.min.css">
<style>
body {
font-family: sans-serif;
font-size: 16px;
line-height: 32px;
text-align: center;
}
button {
font-family: sans-serif;
font-size: 16px;
margin: 16px;
padding:4px;
}
</style>
<script src="https://code.jquery.com/jquery-latest.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jspdf/1.3.5/jspdf.debug.js" integrity="sha384-CchuzHs077vGtfhGYl9Qtc7Vx64rXBXdIAZIPbItbNyWIRTdG0oYAqki3Ry13Yzu" crossorigin="anonymous"></script>
<script src="https://cdn.rawgit.com/noelboss/featherlight/1.7.13/release/featherlight.min.js" type="text/javascript" charset="utf-8"></script>
<script src="iiif2pdf.js"></script>
</head>
<body>
<!--
Example 1: a Range
"manifest":"https://iiif.ub.uni-leipzig.de/0000002636/manifest.json",
"uri":"https://iiif.ub.uni-leipzig.de/0000002636/range/0-2-15",
Example 2: a Sequence
"manifest":"https://iiif.ub.uni-leipzig.de/0000009359/manifest.json",
"uri":"https://iiif.ub.uni-leipzig.de/0000009359/sequence/1",
Example 3: a CORS Error :-)
"manifest":"https://digi.vatlib.it/iiif/MSS_Vat.lat.3225/manifest.json",
"uri":"https://digi.vatlib.it/iiif/MSS_Vat.lat.3225/range/r0-0",
Example 4: a CORS Error :-)
"manifest":"https://digi.vatlib.it/iiif/MSS_Vat.gr.1209/manifest.json",
"uri":"https://digi.vatlib.it/iiif/MSS_Vat.gr.1209/range/r0-9",
"manifest":"https://api.digitale-sammlungen.de/iiif/presentation/v2/bsb00032719/manifest",
"uri":"https://api.digitale-sammlungen.de/iiif/presentation/v2/bsb00032719/sequences/normal",
"manifest":"https://api.digitale-sammlungen.de/iiif/presentation/v2/bsb00014488/manifest",
"uri":"https://api.digitale-sammlungen.de/iiif/presentation/v2/bsb00014488/sequences/normal",
"manifest":"https://iiif.lib.harvard.edu/manifests/drs:46909368",
"uri":"https://iiif.lib.harvard.edu/manifests/drs:46909368/range/range-1.json",
"manifest":"https://media.nga.gov/public/manifests/nga_highlights.json",
"uri":"https://media.nga.gov/public/manifests/canvas/46159.json",
"uri":"https://media.nga.gov/public/manifests/sequence/normal.json",
-->
<script>
function launch_iiif2pdf() {
$.featherlight('<div id="demo"></div>',null);
var in_man=document.getElementById("in_man").value;
var in_uri=document.getElementById("in_uri").value;
var myWidget = new iiif2pdf({
"id":"demo",
"manifest":in_man,
"uri":in_uri,
"resolution":"1024"
})
}
</script>
<label for="in_mf">Manifest:</label>
<input type="text" size="40" id="in_man" value="https://iiif.ub.uni-leipzig.de/0000002636/manifest.json"/>
<br />
<label for="in_mf">URI:</label>
<input type="text" size="40" id="in_uri" value="https://iiif.ub.uni-leipzig.de/0000002636/range/LOG_0004"/>
<br />
<button id="launch" href="#" onclick="launch_iiif2pdf();">Launch iiif2pdf</button>
</body>
</html>