/
index.html
187 lines (154 loc) · 5.32 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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
<!DOCTYPE html>
<html manifest="cwtches.mf">
<head>
<meta charset="utf-8">
<title>Cwtches | Notes for you</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
<link rel="apple-touch-icon-precomposed" href="apple-touch-icon-precomposed.png">
<!-- build:css css/main.min.css -->
<link rel="stylesheet" href="css/main.css">
<!-- endbuild -->
</head>
<body>
<section id="main" class="main-content">
<header class="header--app">
<a href="/#note" class="header__icon detail-link">
<span class="icon icon--write"></span>
<span class="invisible">Write</span>
</a>
<a href="/" class="header__icon">
<span class="icon icon--menu"></span>
<span class="invisible">View all</span>
</a>
</header>
<!-- /.header app -->
<div id="app" class="content"></div>
<!-- /#app -->
<footer class="footer--app">
<p>© 2014 |
A side project by <a href="http://matthew-jackson.com">matthewbeta</a>
</p>
<p>
<a href="http://github.com/matthewbeta/backboneNote" class="social-link">
<span class="icon icon--github"></span>
<span class="invisible">Github</span>
</a>
<a href="http://twitter.com/matthewbeta" class="social-link">
<span class="icon icon--twitter"></span>
<span class="invisible">Twitter</span>
</a>
</p>
</footer>
</section>
<!-- /.main-content -->
<script id="noteSnippet" type="text/template">
<header class="note__header">
<a href="#" class="detail-link">
<h2 class="heading--detail"><%= title %></h2>
</a>
<% if (editDate === "") { %>
<p class="heading--byline">
<span class="create-date--detail">Created:
<%= moment(createDate).fromNow() %>
</span>
</p>
<% } else { %>
<p class="heading--byline">
<span class="create-date--detail">Created:
<%= moment(createDate).fromNow() %>
</span> |
<span class="edit-date--detail">Last updated:
<%= moment(editDate).fromNow() %>
</span>
</p>
<% } %>
</header>
<div class="action--inline">
<a href="#" class="btn detail-link"><span class="icon icon--file"></span> Read</a>
<a href="#" class="btn edit-link">
<span class="icon icon--write"></span>Edit</a>
</div>
</script>
<script id="note" type="text/template">
<div class="note-snippet">
<header class="note__header">
<h2 class="heading--detail"><%= title %></h2>
<p class="heading--byline">
<span class="create-date--detail">Created:
<%= moment(createDate).fromNow() %></span>
<% if (editDate !== "") { %> |
<span class="edit-date--detail">Last updated:
<%= moment(editDate).fromNow() %>
</span>
<% } %>
</p>
</header>
<div class="action--inline">
<div class="btn-group">
<a href="#" class="btn btn--edit">
<span class="icon icon--write"></span> Edit</a>
<a href="#" class="btn btn--delete">
<span class="icon icon--trash"></span> Delete</a>
</div>
</div>
</div>
<div class="detail--content">
<% var converter = new Showdown.converter(); %>
<%= converter.makeHtml(content) %>
</div>
<div class="action">
<div class="btn-group">
<a href="#" class="btn btn--edit">
<span class="icon icon--write"></span> Edit</a>
<a href="#" class="btn btn--delete">
<span class="icon icon--trash"></span> Delete</a>
</div>
</div>
</script>
<script id="noteEdit" type="text/template">
<form action="submit">
<div class="note__input">
<label for="noteContent" class="label heading--byline">Write</label>
<textarea id="noteContent" class="input--textarea" autofocus="autofocus"><%= content %></textarea>
</div>
<div class="action">
<div class="note__title">
<label for="noteTitle" class="label heading--byline">Title</label>
<input type="text" id="noteTitle" class="input--txt" value="<%= title %>" placeholder="Give it a title">
</div>
<div class="btn-group">
<button type="submit" class=" btn btn--save">
<span class="icon icon--save"></span> Save
</button>
<% if (typeof(id) != "undefined") { %>
<button type="button" class=" btn btn--delete">
<span class="icon icon--trash"></span> Delete
</button>
<% } %>
</div>
</div>
</form>
</script>
<!-- build:js js/main.min.js -->
<script src="js/lib/jquery.min.js"></script>
<script src="js/lib/underscore-min.js"></script>
<script src="js/lib/backbone-min.js"></script>
<script src="js/lib/backbone.localStorage-min.js"></script>
<script src="js/lib/moment.min.js"></script>
<script src="js/lib/showdown.min.js"></script>
<script src="js/lib/jquery.flexibleArea.js"></script>
<script src="js/models/note.js"></script>
<script src="js/collections/notes.js"></script>
<script src="js/views/note-list.js"></script>
<script src="js/views/note-snippet.js"></script>
<script src="js/views/note.js"></script>
<script src="js/views/note-edit.js"></script>
<script src="js/routers/router.js"></script>
<script src="js/app.js"></script>
<!-- endbuild -->
</body>
</html>