-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
85 lines (66 loc) · 3.38 KB
/
index.html
File metadata and controls
85 lines (66 loc) · 3.38 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
85
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<link rel="stylesheet" href="css/degist.css">
<link rel="icon" type="image/png" href="./img/logo.png" />
<title>DeGist | Decentralized Gists</title>
</head>
<body>
<div id="degist-app" class="column grow degist-2 font-1 no-margin">
<!-- header -->
<div class="row degist-1 padding-big vertical-center space-between">
<div class="row grow vertical-center">
<img src="img/logo.png" class="degist-header-logo">
<p class="padding-left-big degist-header-title">
<strong>De</strong>Gist
</p>
</div>
<div class="row grow vertical-center flex-end" v-if="!blockstack.isUserSignedIn()">
<div class="button primary" v-on:click="login()">Log In</div>
</div>
<div class="row grow vertical-center flex-end" v-if="blockstack.isUserSignedIn()">
<div class="button secondary margin-right-small" v-bind:title="newGistText">+</div>
<div class="button primary" v-on:click="logout()">Log Out</div>
</div>
</div>
<!-- content -->
<div class="row grow degist-2">
<div class="colum grow"></div>
<div class="colum grow-1">
<!-- Login -->
<div class="card padding-big column rounded-small" v-if="!blockstack.isUserSignedIn()">
<h2 class="padding-bottom-big">Log In</h2>
<p>If you want to browse or publish DeGists, click Log In!</p>
<div class="row padding-top-big text-center">
<div class="button primary grow margin-right-small" v-on:click="login()">Log In</div>
<div class="button secondary grow margin-left-small" v-on:click="login()">Register</div>
</div>
</div>
<!-- New DeGist -->
<div class="card padding-big column rounded-small" v-if="blockstack.isUserSignedIn()">
<div class="form-group no-padding">
<label class="padding-bottom-small">Title</label>
<input v-model="newDeGistTitleInput" class="no-margin-right" placeholder="DeGist Title">
</div>
<div class="form-group no-padding">
<label class="padding-bottom-small">Content</label>
<textarea v-model="newDeGistInput" class="padding margin-bottom-small no-margin-right" placeholder="console.log('Hello world!');"></textarea>
</div>
<div class="button primary grow" v-on:click="saveDeGists()">Save!</div>
</div>
<!-- All DeGists -->
<div class="card padding-big column rounded-small" v-for="degist in concreteDeGists">
<h3 class="padding-bottom">{{degist.title}}</h3>
<h6 class="padding-bottom-small">{{ new Date(degist.date).toLocaleDateString() }}</h6>
<p>{{degist.content}}</p>
</div>
</div>
<div class="colum grow"></div>
</div>
</div>
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
<script src="js/bundle.js"></script>
<script src="js/degist.js"></script>
</body>
</html>