-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
61 lines (52 loc) · 1.98 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" name="viewport" content="width=device-width, initial-scale=1.0">
<title>Daniil Chalov</title>
<link rel="shortcut icon" type="image/x-icon" href="favicon.ico">
<style>
html,
body {
margin: 0;
padding: 0;
height: 100%;
overflow: hidden;
}
.pdfobject-container {
width: 100%;
height: 100%;
border: none;
display: block;
}
</style>
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfobject/2.3.0/pdfobject.min.js"
integrity="sha512-Nr6NV16pWOefJbWJiT8SrmZwOomToo/84CNd0MN6DxhP5yk8UAoPUjNuBj9KyRYVpESUb14RTef7FKxLVA4WGQ=="
crossorigin="anonymous">
</script>
<!-- No integrity check is possible since tailwind's custom CDN doesn't support CORS headers :( -->
<script src="https://cdn.tailwindcss.com/3.4.15"></script>
</head>
<body>
<script>
const resumeUrl = 'dist/resume.pdf'
const fallbackUi = `
<div class="flex items-center justify-center min-h-screen px-4">
<div class="bg-white p-6 rounded-lg shadow-lg text-center w-full max-w-md">
<p class="mb-4">Looks like your browser may not support viewing PDF files.</p>
<p class="mb-4">
Please reopen the link using desktop versions of either Google Chrome, Mozilla Firefox,Microsoft Edge,
Safari, or Opera.
</p>
<p class="mb-4">Alternatively, feel fre to simply download the resume.</p>
<br>
<a download href="${resumeUrl}"
class="bg-blue-500 text-white py-2 px-4 rounded hover:bg-blue-700 w-full sm:w-auto">
Download Daniil's resume
</a>
</div>
</div>
`
PDFObject.embed(resumeUrl, "body", { fallbackLink: fallbackUi })
</script>
</body>
</html>