interface tweaks
This commit is contained in:
parent
85aea63307
commit
f931bb3ed0
|
@ -12,7 +12,7 @@ header {
|
||||||
height: 3em;
|
height: 3em;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
background-color: #263238;
|
background-color: #263238;
|
||||||
padding: 0 2em;
|
padding: 0 1em;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
z-index: 999;
|
z-index: 999;
|
||||||
color: #eee;
|
color: #eee;
|
||||||
|
@ -60,50 +60,12 @@ header nav ul li a:hover {
|
||||||
}
|
}
|
||||||
|
|
||||||
main {
|
main {
|
||||||
|
position: fixed;
|
||||||
top: 3em;
|
top: 3em;
|
||||||
left: 0;
|
left: 0;
|
||||||
position: fixed;
|
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: calc(100% - 3em);
|
||||||
overflow: inherit;
|
|
||||||
}
|
|
||||||
|
|
||||||
.container {
|
|
||||||
box-sizing: border-box;
|
|
||||||
top: 3em;
|
|
||||||
height: auto;
|
|
||||||
max-height: 100%;
|
|
||||||
bottom: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.container.left {
|
|
||||||
position: fixed;
|
|
||||||
left: 0;
|
|
||||||
width: 25%;
|
|
||||||
background-color: #37474F;
|
|
||||||
overflow: auto;
|
overflow: auto;
|
||||||
color: #eee;
|
|
||||||
padding: 1.5em 1.5em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.container.main {
|
|
||||||
position: fixed;
|
|
||||||
right: 0;
|
|
||||||
width: 75%;
|
|
||||||
overflow: auto;
|
|
||||||
padding: 0;
|
|
||||||
margin-bottom: 3em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.container *:first-child {
|
|
||||||
margin-top: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.container.main textarea {
|
|
||||||
height: 100%;
|
|
||||||
width: 100%;
|
|
||||||
padding: 2em 5em;
|
|
||||||
box-sizing: border-box;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.content {
|
.content {
|
||||||
|
@ -112,17 +74,87 @@ main {
|
||||||
max-width: 800px;
|
max-width: 800px;
|
||||||
}
|
}
|
||||||
|
|
||||||
textarea {
|
|
||||||
|
/* EDITOR STYLE */
|
||||||
|
|
||||||
|
.editor .sidebar {
|
||||||
|
position: fixed;
|
||||||
|
left: 0;
|
||||||
|
top: 3em;
|
||||||
|
overflow-y: auto;
|
||||||
|
overflow-x: hidden;
|
||||||
|
height: calc(100% - 3em);
|
||||||
|
width: 25%;
|
||||||
|
background-color: #37474F;
|
||||||
|
color: #fff;
|
||||||
|
box-sizing: border-box;
|
||||||
|
padding: 1.5em 1em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.editor .container {
|
||||||
|
position: fixed;
|
||||||
|
top: 3em;
|
||||||
|
right: 0;
|
||||||
|
overflow: hidden;
|
||||||
|
height: calc(100% - 6em);
|
||||||
|
width: 75%;
|
||||||
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
|
||||||
|
.editor .sidebar *:first-child {
|
||||||
|
margin-top: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.editor textarea {
|
||||||
|
box-sizing: border-box;
|
||||||
|
height: 100%;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
min-height: 50em;
|
resize: none;
|
||||||
border: 0;
|
border: 0;
|
||||||
resize: vertical;
|
padding: 1.5em 11em;
|
||||||
box-sizing: content-box;
|
font-family: monospace;
|
||||||
font-family: inherit;
|
font-size: 1.05em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.editor input {
|
||||||
|
width: 100%;
|
||||||
|
background-color: #fff;
|
||||||
|
border-radius: 5px;
|
||||||
|
padding: .5em 1em;
|
||||||
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
|
||||||
|
.editor input:focus {
|
||||||
|
border: 1px solid #ddd;
|
||||||
|
}
|
||||||
|
|
||||||
|
.editor legend {
|
||||||
|
font-size: 1em;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
.action-bar {
|
||||||
|
position: fixed;
|
||||||
|
bottom: 0;
|
||||||
|
right: 0;
|
||||||
|
width: 75%;
|
||||||
|
background-color: #455A64;
|
||||||
|
height: 3em;
|
||||||
|
display: flex;
|
||||||
|
padding: 0.5em 1em;
|
||||||
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
|
||||||
|
.action-bar .left {
|
||||||
|
margin-right: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.action-bar *:last-child {
|
||||||
|
margin-left: 1em;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* FORMS */
|
/* FORMS ELEMENTS */
|
||||||
|
|
||||||
form input {
|
form input {
|
||||||
color: rgba(0, 0, 0, 0.41);
|
color: rgba(0, 0, 0, 0.41);
|
||||||
|
@ -155,45 +187,6 @@ form legend {
|
||||||
font-size: 1.5em;
|
font-size: 1.5em;
|
||||||
}
|
}
|
||||||
|
|
||||||
form .container.left input {
|
|
||||||
width: 100%;
|
|
||||||
background-color: #fff;
|
|
||||||
border-radius: 5px;
|
|
||||||
padding: .5em 1em;
|
|
||||||
box-sizing: border-box;
|
|
||||||
}
|
|
||||||
|
|
||||||
form .container.left input:focus {
|
|
||||||
border: 1px solid #ddd;
|
|
||||||
}
|
|
||||||
|
|
||||||
form .container.left label {}
|
|
||||||
|
|
||||||
form .container.left legend {
|
|
||||||
font-size: 1em;
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
.action-bar {
|
|
||||||
position: fixed;
|
|
||||||
bottom: 0;
|
|
||||||
right: 0;
|
|
||||||
width: 75%;
|
|
||||||
background-color: #455A64;
|
|
||||||
height: 3em;
|
|
||||||
display: flex;
|
|
||||||
padding: 0.5em 1em;
|
|
||||||
box-sizing: border-box;
|
|
||||||
}
|
|
||||||
|
|
||||||
.action-bar .left {
|
|
||||||
margin-right: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
.action-bar *:last-child {
|
|
||||||
margin-left: 1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
button, input[type="submit"] {
|
button, input[type="submit"] {
|
||||||
border: 0;
|
border: 0;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
$('.scroll').perfectScrollbar();
|
$('.scroll').perfectScrollbar();
|
||||||
|
|
||||||
|
|
||||||
$('form').submit(function(event) {
|
$('form').submit(function(event) {
|
||||||
var data = JSON.stringify($(this).serializeField())
|
var data = JSON.stringify($(this).serializeField())
|
||||||
var url = $(this).attr('action')
|
var url = $(this).attr('action')
|
||||||
|
|
|
@ -32,11 +32,8 @@
|
||||||
</ul>
|
</ul>
|
||||||
</nav>
|
</nav>
|
||||||
</header>
|
</header>
|
||||||
<main>
|
{{ template "content" . }}
|
||||||
{{ template "content" . }}
|
|
||||||
</main>
|
|
||||||
<footer>
|
<footer>
|
||||||
|
|
||||||
</footer>
|
</footer>
|
||||||
</body>
|
</body>
|
||||||
|
|
||||||
|
|
|
@ -1,24 +1,24 @@
|
||||||
{{ define "content" }} {{ with .Body }}
|
{{ define "content" }} {{ with .Body }}
|
||||||
|
|
||||||
<form method="POST" action="">
|
<main class="editor">
|
||||||
|
<form method="POST" action="_self">
|
||||||
|
<div class="sidebar scroll">
|
||||||
|
<h2>Metadata</h2>
|
||||||
|
{{ template "frontmatter" .FrontMatter }}
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="container left scroll">
|
<div class="container">
|
||||||
<h2>Metadata</h2>
|
<textarea name="content" class="scroll">
|
||||||
{{ template "frontmatter" .FrontMatter }}
|
{{ .Content }}
|
||||||
</div>
|
</textarea>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="container main">
|
<div class="action-bar">
|
||||||
<textarea name="content" class="scroll">
|
<button id="preview" class="left">Preview</button>
|
||||||
{{ .Content }}
|
<input type="submit" value="Save">
|
||||||
</textarea>
|
<input type="submit" class="default" value="Publish">
|
||||||
</div>
|
</div>
|
||||||
|
</form>
|
||||||
<div class="action-bar">
|
</main>
|
||||||
<button id="preview" class="left">Preview</button>
|
|
||||||
<input type="submit" value="Save">
|
|
||||||
<input type="submit" class="default" value="Publish">
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</form>
|
|
||||||
|
|
||||||
{{ end }} {{ end }}
|
{{ end }} {{ end }}
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
{{ define "content" }}
|
{{ define "content" }}
|
||||||
|
<main>
|
||||||
{{ with .Body }}
|
{{ with .Body }}
|
||||||
<div class="content">
|
<div class="content">
|
||||||
<h1>Settings</h1>
|
<h1>Settings</h1>
|
||||||
|
@ -9,5 +9,6 @@
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
</main>
|
||||||
|
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
Loading…
Reference in New Issue