-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
44 lines (38 loc) · 1.8 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Colour Palette Maker</title>
<link rel="stylesheet" href="/node_modules/@shoelace-style/shoelace/dist/themes/light.css" />
<script type="module" src="node_modules/@shoelace-style/shoelace/dist/shoelace.js"></script>
<link rel="stylesheet" href="/src/index.css" />
<script type="module" src="/src/index.ts"></script>
</head>
<body>
<script type="module">
import { registerIconLibrary } from '/node_modules/@shoelace-style/shoelace/dist/utilities/icon-library.js';
registerIconLibrary('my-icons', {
resolver: name => `/assets/custom-icons/${name}.svg`,
mutator: svg => svg.setAttribute('fill', 'currentColor')
});
</script>
<cp-app></cp-app>
<small id="opendialog">© Diana Broeders - 2024</small>
<sl-dialog label="Contact" class="dialog-overview">
<p>Scan this code to visit the colour palette maker app!</p>
<sl-qr-code value="https://colour-palette-maker.netlify.app/" label="Scan this code to visit the colour palette maker app!"></sl-qr-code>
<p>Scan this to send me an email:</p>
<sl-qr-code value="mailto:[email protected]" label="Scan this code to send me an email"></sl-qr-code>
<sl-button slot="footer" variant="primary">Close</sl-button>
</sl-dialog>
<script>
const dialog = document.querySelector('.dialog-overview');
const openButton = document.querySelector('#opendialog');
const closeButton = dialog.querySelector('sl-button[slot="footer"]');
openButton.addEventListener('click', () => dialog.show());
closeButton.addEventListener('click', () => dialog.hide());
</script>
</body>
</html>