-
Notifications
You must be signed in to change notification settings - Fork 399
Expand file tree
/
Copy pathindex.html
More file actions
84 lines (78 loc) · 2.37 KB
/
index.html
File metadata and controls
84 lines (78 loc) · 2.37 KB
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
<!DOCTYPE html>
<html class="pl-c-html" lang="en">
<head>
<title id="title">Pattern Lab</title>
<meta charset="UTF-8" />
<meta
name="viewport"
content="initial-scale=1, width=device-width, viewport-fit=cover"
/>
<meta name="theme-color" content="#ababab" />
<link rel="stylesheet" href="styleguide/css/pattern-lab.css" media="all" />
<link
rel="prefetch"
as="image"
href="styleguide/images/pattern-lab-logo--on-dark.svg"
/>
<link
rel="prefetch"
as="image"
href="styleguide/images/pattern-lab-logo--on-light.svg"
/>
</head>
<body class="pl-c-body">
<pl-layout></pl-layout>
<!-- the template for the modal slider -->
<script type="text/x-handlebars-template" class="pl-js-panel-template-base">
${require('./partials/base-template.html') }
</script>
<script src="styleguide/data/patternlab-data.js" defer></script>
<script src="annotations/annotations.js" defer></script>
<script
src="styleguide/js/patternlab-viewer.modern.js"
type="module"
crossorigin
></script>
<script>
// https://gist.github.com/samthor/64b114e4a4f539915a95b91ffd340acc
(function () {
var check = document.createElement('script');
if (!('noModule' in check) && 'onbeforeload' in check) {
var support = false;
document.addEventListener(
'beforeload',
function (e) {
if (e.target === check) {
support = true;
} else if (!e.target.hasAttribute('nomodule') || !support) {
return;
}
e.preventDefault();
},
true
);
check.type = 'module';
check.src = '.';
document.head.appendChild(check);
check.remove();
}
})();
</script>
<script
src="styleguide/js/patternlab-viewer.js"
defer
nomodule
crossorigin
></script>
<script>
// Check that service workers are registered
// @todo: uncomment once cache-busting strategy is in place
// if ('serviceWorker' in navigator) {
// // Use the window load event to keep the page load performant
// window.addEventListener('load', () => {
// navigator.serviceWorker.register('/sw.js');
// });
// }
</script>
</body>
</html>