possibly first working draft
This commit is contained in:
@ -1,3 +1,4 @@
|
||||
{{ define "base" }}
|
||||
<!doctype html>
|
||||
<html class="no-js" lang="en">
|
||||
<head>
|
||||
@ -9,4 +10,5 @@
|
||||
<body>
|
||||
{{ template "content" . }}
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
{{ end }}
|
||||
@ -3,6 +3,6 @@
|
||||
{{ template "noteList" . }}
|
||||
{{/* Markdown notes rendering area */}}
|
||||
<main>
|
||||
{{ .Note }}
|
||||
{{ .RenderedNote }}
|
||||
</main>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
@ -24,15 +24,15 @@
|
||||
{{ define "renderSearch" }}
|
||||
{{ if ne .SearchTerm "" }}<h2>Matching results for query '{{ .SearchTerm }}'</h2>{{ end }}
|
||||
<ul class="search-results">
|
||||
{{ range .Nodes }}
|
||||
{{ if .IsEnd }}
|
||||
<li {{ if eq .Hash $.LastActive }}class="active-note"{{ end }}>
|
||||
<input type="checkbox"/>
|
||||
<a href="/notes/{{ .Hash }}" data-hash="{{ .Hash }}">{{ .Title }}</a>
|
||||
<span class="last-modified">{{ .LastModified }}</span>
|
||||
</li>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ range .Notes }}
|
||||
<li {{ if eq .ID $.LastActive }}class="active-note"{{ end }}>
|
||||
<div class="note-title">
|
||||
<input type="checkbox"/>
|
||||
<a href="/notes/{{ .ID }}" data-hash="{{ .ID }}">{{ if ge (len .Title) 30 }}{{printf "%.30s" .Title }}[...]{{ else }} {{ .Title }}{{ end }}</a>
|
||||
</div>
|
||||
<span class="last-modified">{{ .GetUpdateDateRep }}</span>
|
||||
</li>
|
||||
{{ end }}
|
||||
</ul>
|
||||
{{ end }}
|
||||
|
||||
@ -52,4 +52,4 @@
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</ul>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
Reference in New Issue
Block a user