|
|
|
extends frame
|
|
|
|
block main-content
|
|
|
|
|
|
|
|
-var post_title = ''
|
|
|
|
-var post_plaintext = ''
|
|
|
|
-var post_feature = 'null'
|
|
|
|
-var post_tags = ''
|
|
|
|
-var post_id = ''
|
|
|
|
-var post_date = 'NOW'
|
|
|
|
|
|
|
|
if(edit)
|
|
|
|
-post_title = post.title
|
|
|
|
-post_plaintext = post.entry_plaintext
|
|
|
|
-post_feature = feature
|
|
|
|
-post_tags = post.tags
|
|
|
|
-post_date = date
|
|
|
|
|
|
|
|
#entries-edit-index
|
|
|
|
#entries-edit-index-wrapper
|
|
|
|
//h2 EDIT
|
|
|
|
=post_title
|
|
|
|
#entry-header.columns
|
|
|
|
#entry-title.column
|
|
|
|
textarea(id="entry_title" type='text', name='entry_title' class='post-edit', placeholder='title', required, autofocus)
|
|
|
|
=post_title
|
|
|
|
#entry-meta.column
|
|
|
|
textarea(id='entry_tags' type='text', name='entry_tags' class='form-control', placeholder='tags [comma seperated]', autofocus)
|
|
|
|
=post_tags
|
|
|
|
label Date Posted
|
|
|
|
input(id="entry-date" type="text" value=post_date)
|
|
|
|
br
|
|
|
|
input(id="featured-click" type="file" name="featured-click")
|
|
|
|
input(id="post-image" type="file" name="post-image")
|
|
|
|
|
|
|
|
#entry-feature
|
|
|
|
//label FEATURE IMAGE
|
|
|
|
if(post_feature == 'null')
|
|
|
|
#featured-image-drop
|
|
|
|
| DRAG AND DROP IMAGE OR
|
|
|
|
label(for="featured-click") CLICK TO CHOOSE
|
|
|
|
|
|
|
|
else
|
|
|
|
#featured-new-image-btn
|
|
|
|
button#new-upload-link
|
|
|
|
svg#new-upload-link(viewBox="0 0 20 20" class="icons")
|
|
|
|
use(xlink:href='/dash/assets/images/sprite.svg#entypo-image-inverted')
|
|
|
|
#featured-image-drop
|
|
|
|
img(src=post_feature)
|
|
|
|
#edit-content
|
|
|
|
#edit-control
|
|
|
|
button#option-bold.content-editor-btn-text.editor-button(title="bold")
|
|
|
|
| B
|
|
|
|
button#option-italic.content-editor-btn-text.editor-button(title="italics")
|
|
|
|
| I
|
|
|
|
button#option-strikethrough.content-editor-btn-text.editor-button(title="strikethrough")
|
|
|
|
| S
|
|
|
|
button#option-link.content-editor-btn-icon.editor-button(title="insert link")
|
|
|
|
svg#option-link(viewBox="0 0 20 20" class="icons")
|
|
|
|
use(xlink:href='/dash/assets/images/sprite.svg#entypo-link')
|
|
|
|
button#option-header1.content-editor-btn-text.editor-button(title="header 1")
|
|
|
|
| H1
|
|
|
|
button#option-header2.content-editor-btn-text.editor-button(title="header 2")
|
|
|
|
| H2
|
|
|
|
button#option-header3.content-editor-btn-text.editor-button(title="header 3")
|
|
|
|
| H3
|
|
|
|
button#option-image.content-editor-btn-icon(for="post-image" title='insert image')
|
|
|
|
svg#option-link(viewBox="0 0 20 20" class="icons")
|
|
|
|
use(xlink:href='/dash/assets/images/sprite.svg#entypo-image')
|
|
|
|
|
|
|
|
if(edit)
|
|
|
|
button#post-sumbit-btn.post-sumbit-btn.submit-start(data-action='blog-update' data-id=post.id type='submit')
|
|
|
|
svg#submit-save(viewBox="0 0 20 20" class="icons")
|
|
|
|
use(xlink:href='/dash/assets/images/sprite.svg#entypo-save' data-action='blog-update' data-id=post.id)
|
|
|
|
svg#submit-good.icon-hide(viewBox="0 0 20 20" class="icons")
|
|
|
|
use(xlink:href='/dash/assets/images/sprite.svg#entypo-thumbs-up')
|
|
|
|
svg#submit-error.icon-hide(viewBox="0 0 20 20" class="icons")
|
|
|
|
use(xlink:href='/dash/assets/images/sprite.svg#entypo-thumbs-down')
|
|
|
|
else
|
|
|
|
button#post-sumbit-btn.post-sumbit-btn(data-action='blog-add' type='submit') ADD POST
|
|
|
|
|
|
|
|
#edit-content-wrapper
|
|
|
|
pre
|
|
|
|
code#edit-text-code(contenteditable="true") !{colored}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|