-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
78 lines (57 loc) · 2.3 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
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Progress Dashboard</title>
<script src="js/js-yaml.min.js"></script>
<!-- <script src="https://cdn.jsdelivr.net/npm/js-yaml@3/dist/js-yaml.min.js"></script> -->
<script src="js/read-yaml.js"></script>
<link rel="stylesheet" href="//md.softreck.dev/reset.css">
<link rel="stylesheet" href="//md.softreck.dev/reveal.css">
<link rel="stylesheet" href="//md.softreck.dev/white.css">
<link rel="stylesheet" href="//md.softreck.dev/docs.css">
<!-- <link rel="stylesheet" href="//md.softreck.dev/github-dark.user.css">-->
</head>
<body>
<h1>Odczyt pliku YAML</h1>
<input type="text" id="yaml-url" value="https://raw.githubusercontent.com/apiunit/www/master/project.yaml" />
<button onclick="loadYAML()">Odczytaj plik</button>
<pre id="yaml-content"></pre>
<script>
function loadYAML() {
var url = document.getElementById('yaml-url').value;
fetch(url)
.then(response => {
if (response.ok) return response.text();
throw new Error('Błąd sieci lub nie znaleziono pliku!');
})
.then(data => {
var yamlContent = jsyaml.load(data);
document.getElementById('yaml-content').textContent = JSON.stringify(yamlContent, null, 2);
})
.catch(error => {
document.getElementById('yaml-content').textContent = error.message;
});
}
</script>
<h1>Project Progress</h1>
<pre id="progress-container"></pre>
<div class="reveal">
<div class="slides">
<!-- Use external markdown resource, separate slides by three newlines; vertical slides by two newlines -->
<section data-markdown="README.md" data-separator="^\n\n\n" data-separator-vertical="^\n\n"></section>
</div>
</div>
<script src="//md.softreck.dev/dist/reveal.js"></script>
<script src="//md.softreck.dev/plugin/markdown/markdown.js"></script>
<script>
Reveal.initialize({
controls: true,
progress: true,
history: true,
center: true,
plugins: [RevealMarkdown]
});
</script>
</body>
</html>