mirror of
https://github.com/jlelse/GoBlog
synced 2024-06-27 17:37:35 +00:00
65 lines
3.2 KiB
Plaintext
65 lines
3.2 KiB
Plaintext
{{ define "title" }}
|
|
<link rel="stylesheet" href="{{ asset "css/chroma.css" }}">
|
|
<title>{{ string .Blog.Lang "editor" }} - {{ mdtitle .Blog.Title }}</title>
|
|
{{ end }}
|
|
|
|
{{ define "main" }}
|
|
<main>
|
|
<h1>{{ string .Blog.Lang "editor" }}</h1>
|
|
<h2>{{ string .Blog.Lang "create" }}</h2>
|
|
{{ md (editorpostdesc .BlogString) }}
|
|
<form class="fw p" method="post">
|
|
<input type="hidden" name="h" value="entry">
|
|
<textarea name="content" class="monospace h400p formcache mdpreview" id="create-input" data-preview="post-preview" data-previewws="{{ .Blog.RelativePath "/editor/preview" }}">{{ editortemplate .BlogString }}</textarea>
|
|
<div id="post-preview" class="hide"></div>
|
|
<input type="submit" value="{{ string .Blog.Lang "create" }}">
|
|
</form>
|
|
|
|
{{ if .Data.UpdatePostURL }}
|
|
<h2 id="update">{{ string .Blog.Lang "update" }}</h2>
|
|
<form class="fw p" method="post" action="#update">
|
|
<input type="hidden" name="editoraction" value="updatepost">
|
|
<input type="hidden" name="url" value="{{ .Data.UpdatePostURL }}">
|
|
<textarea name="content" class="monospace h400p mdpreview" data-preview="update-preview" data-previewws="{{ .Blog.RelativePath "/editor/preview" }}">{{ .Data.UpdatePostContent }}</textarea>
|
|
<div id="update-preview" class="hide"></div>
|
|
<input type="submit" value="{{ string .Blog.Lang "update" }}">
|
|
</form>
|
|
{{ end }}
|
|
|
|
<h2>{{ string .Blog.Lang "posts" }}</h2>
|
|
<p><a href="{{ .Blog.RelativePath "/editor/drafts" }}">{{ string .Blog.Lang "drafts" }}</a></p>
|
|
<p><a href="{{ .Blog.RelativePath "/editor/private" }}">{{ string .Blog.Lang "privateposts" }}</a></p>
|
|
<p><a href="{{ .Blog.RelativePath "/editor/unlisted" }}">{{ string .Blog.Lang "unlistedposts" }}</a></p>
|
|
<p><a href="{{ .Blog.RelativePath "/editor/scheduled" }}">{{ string .Blog.Lang "scheduledposts" }}</a></p>
|
|
|
|
<h2>{{ string .Blog.Lang "upload" }}</h2>
|
|
<form class="fw p" method="post" enctype="multipart/form-data">
|
|
<input type="hidden" name="editoraction" value="upload">
|
|
<input type="file" name="file">
|
|
<input type="submit" value="{{ string .Blog.Lang "upload" }}">
|
|
</form>
|
|
<p><a href="{{ .Blog.RelativePath "/editor/files" }}">{{ string .Blog.Lang "mediafiles" }}</a></p>
|
|
|
|
<h2>{{ string .Blog.Lang "location" }}</h2>
|
|
<form class="fw p">
|
|
<input id="geobtn" type="button" value="{{ string .Blog.Lang "locationget" }}" data-failed="{{ string .Blog.Lang "locationfailed" }}" data-notsupported="{{ string .Blog.Lang "locationnotsupported" }}">
|
|
<input id="geostatus" type="text" class="hide" readonly>
|
|
</form>
|
|
|
|
<h2>{{ string .Blog.Lang "gpxhelper" }}</h2>
|
|
<p>{{ string .Blog.Lang "gpxhelperdesc" }}</p>
|
|
<form class="fw p" method="post" enctype="multipart/form-data">
|
|
<input type="hidden" name="editoraction" value="helpgpx">
|
|
<input type="file" name="file">
|
|
<input type="submit" value="{{ string .Blog.Lang "upload" }}">
|
|
</form>
|
|
|
|
<script defer src="{{ asset "js/mdpreview.js" }}"></script>
|
|
<script defer src="{{ asset "js/geohelper.js" }}"></script>
|
|
<script defer src="{{ asset "js/formcache.js" }}"></script>
|
|
</main>
|
|
{{ end }}
|
|
|
|
{{ define "editor" }}
|
|
{{ template "base" . }}
|
|
{{ end }} |