This repository has been archived by the owner on Dec 22, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
62 lines (58 loc) · 2.15 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
<html>
<head>
<meta charset="UTF-8">
<title>Jodel AMA Viewer</title>
<meta name="viewport" content="width=device-width, height=device-height, initial-scale=1">
<link rel="stylesheet" type="text/css" href="./style.css">
</head>
<body>
<script type="text/x-template" id="state-template">
<div id="state">
<div v-if="state.pinned" class="back-box" @click="back"><span class="back">Back</span></div>
<div v-else-if="state.filter" class="filter-box" @click="back()">
<div class="filter">
<span class="oj">{{ state.filter }}</span>
</div>
</div>
<h3 v-if="state.name">{{state.name}}</h3>
</div>
</script>
<script type="text/x-template" id="post-template">
<div class="post-box" @click="thread($event)">
<div class="meta">
<span class="oj" @click="filterOj" title="filter by this jodler">{{ post.ojId }}</span>
<span class="time">{{ post.time }}</span>
</div>
<div class="post" v-html="post.message"></div>
</div>
</script>
<script type="text/x-template" id="reference-post-template">
<div v-if="post" id="reference-post" class="post-box">
<div class="meta">
<span class="oj">{{ post.ojId }}</span>
<span class="time">{{ post.time }}</span>
</div>
<div class="post" v-html="post.message"></div>
</div>
</script>
<div id="app">
<header>
<h1><img src="./logo.png">AMA Viewer <a target="_blank" class="help" href="https://github.com/ocjojo/jodel-ama-viewer">?</a></h1>
</header>
<state v-bind:state="currentState"></state>
<reference-post :class="{ answer: currentState.refIsAnswer }" v-bind:post="currentState.pinned"></reference-post>
<div class="post-container">
<post
v-for="post in posts()"
v-bind:post="post"
v-bind:key="post.id">
</post>
<div v-show="showLoadMore" class="load-more">There might be more answers, <span @click="loadMore">try loading</span></div>
<div v-show="loading" class="loader">Loading ...</div>
</div>
</div>
<script type="text/javascript" src="https://lib.local.dev/jquery/jquery.min.js"></script>
<script type="text/javascript" src="https://lib.local.dev/vue/vue.js"></script>
<script type="text/javascript" src="./script.js"></script>
</body>
</html>