aboutsummaryrefslogtreecommitdiffstats
path: root/template/admin/html/post/form.php
diff options
context:
space:
mode:
authorThomas Lange <code@nerdmind.de>2017-05-19 01:05:15 +0200
committerThomas Lange <code@nerdmind.de>2017-05-21 07:54:28 +0200
commiteeddde7ae72d7f68c0a734d1fe7004cde847d1e5 (patch)
tree041aeec3474fdd7169c5b6c235674a15423aceea /template/admin/html/post/form.php
parent6b4faa47d02094d3f9fe637fc83431e7c49004cd (diff)
downloadblog-eeddde7ae72d7f68c0a734d1fe7004cde847d1e5.tar.gz
blog-eeddde7ae72d7f68c0a734d1fe7004cde847d1e5.tar.xz
blog-eeddde7ae72d7f68c0a734d1fe7004cde847d1e5.zip
Several changes have been made to the admin template, which together with the previous commits result in version 2.1.1:v2.1.1
+ Optimization [CSS]: Unused .fa-* classes have been removed. + Optimization [CSS]: Hyphens have been disabled for the text within the content editor. + Optimization [CSS]: Some elements now have a smaller padding value which has benefits if the page is displayed on a mobile device. + Optimization [HTML]: The HTML <section> elements of the formular have been replaced with simple <div> elements because <section> elements should only be used for self-contained areas which have nothing to do with the rest of the content. The using of <section> elements at this place was semantically incorrect. + Implemented [JS]: Tab indents which are made by pressing <tab> can now also be removed by pressing <shift>+<tab>. + Optimization [JS]: The functions "emoticonReplace" and "markdownReplace" has been renamed to "insertEmoticon" and "insertMarkdown" and have been restructured. + Optimization [JS]: The DOMContentLoaded event listeners are not required because the file is included with the "defer" attribute. + Optimization [JS]: A function called "delayed" was added which executes a callback function after an delay of 20 ms (the delayed execution of code is necessary for the "insertEmoticon" and "insertMarkdown" functions because the content editor otherwise will losing focus when clicking outside at the emoticon or markdown buttons while the "onmousedown" event listener is still executing).
Diffstat (limited to 'template/admin/html/post/form.php')
-rw-r--r--template/admin/html/post/form.php60
1 files changed, 30 insertions, 30 deletions
diff --git a/template/admin/html/post/form.php b/template/admin/html/post/form.php
index 3ad4376..14888aa 100644
--- a/template/admin/html/post/form.php
+++ b/template/admin/html/post/form.php
@@ -8,13 +8,13 @@
<input type="hidden" name="token" value="<?=$FORM['TOKEN']?>" />
<?php if($FORM['TYPE'] !== 'DELETE'): ?>
- <section class="flex flex-responsive">
- <section>
+ <div class="flex flex-responsive">
+ <div class="flex-item">
<div class="form-icon-flex"><i class="fa fa-database"></i></div>
<div class="form-label-flex"><label for="form_id">ID</label></div>
<div class="form-field-flex"><input<?=($FORM['TYPE'] === 'UPDATE') ? ' disabled="disabled"' : '';?> id="form_id" name="id" type="number" placeholder="[AUTO_INCREMENT]" value="<?=escapeHTML($FORM['DATA']['ID'])?>" /></div>
- </section>
- <section>
+ </div>
+ <div class="flex-item">
<div class="form-icon-flex"><i class="fa fa-user"></i></div>
<div class="form-label-flex"><label for="form_user"><?=$Language->template('label_user')?></label></div>
<div class="form-field-flex">
@@ -24,46 +24,46 @@
<?php endforeach; ?>
</select>
</div>
- </section>
- </section>
- <section class="flex flex-responsive">
- <section>
+ </div>
+ </div>
+ <div class="flex flex-responsive">
+ <div class="flex-item">
<div class="form-icon-flex"><i class="fa fa-newspaper-o"></i></div>
<div class="form-label-flex"><label for="form_name"><?=$Language->template('label_name')?></label></div>
<div class="form-field-flex"><input id="form_name" name="name" value="<?=escapeHTML($FORM['DATA']['NAME'])?>" /></div>
- </section>
- <section>
+ </div>
+ <div class="flex-item">
<div class="form-icon-flex"><i class="fa fa-link"></i></div>
<div class="form-label-flex"><label for="form_slug"><?=$Language->template('label_slug')?></label></div>
<div class="form-field-flex"><input id="form_slug" name="slug" value="<?=escapeHTML($FORM['DATA']['SLUG'])?>" /></div>
- </section>
- </section>
- <section class="flex flex-responsive">
- <section>
+ </div>
+ </div>
+ <div class="flex flex-responsive">
+ <div class="flex-item">
<div class="form-icon-flex"><i class="fa fa-clock-o"></i></div>
<div class="form-label-flex"><label for="form_time_insert"><?=$Language->template('label_insert')?></label></div>
<div class="form-field-flex"><input id="form_time_insert" name="time_insert" placeholder="[YYYY-MM-DD HH:II:SS]" value="<?=escapeHTML($FORM['DATA']['TIME_INSERT'])?>" /></div>
- </section>
- <section>
+ </div>
+ <div class="flex-item">
<div class="form-icon-flex"><i class="fa fa-clock-o"></i></div>
<div class="form-label-flex"><label for="form_time_update"><?=$Language->template('label_update')?></label></div>
<div class="form-field-flex"><input id="form_time_update" name="time_update" placeholder="<?=escapeHTML($FORM['DATA']['TIME_UPDATE'] ? $FORM['DATA']['TIME_UPDATE'] : '[CURRENT_TIMESTAMP]')?>" value="" /></div>
- </section>
- </section>
- <section class="flex flex-padding">
+ </div>
+ </div>
+ <div class="flex flex-padding">
<textarea id="content-editor" name="body" placeholder="[…]"><?=escapeHTML($FORM['DATA']['BODY'])?></textarea>
- </section>
- <section class="flex flex-padding background flex-arguments">
+ </div>
+ <div class="flex flex-padding background flex-arguments">
<input id="form_argv" name="argv" maxlength="100" placeholder="[ARGUMENT_FOO=one|ARGUMENT_BAR=two …]" value="<?=escapeHTML($FORM['DATA']['ARGV'])?>" />
- </section>
- <section class="flex flex-padding background flex-emoticons">
+ </div>
+ <div class="flex flex-padding background flex-emoticons">
<ul id="emoticon-list" class="button-list emoticons">
<?php foreach(getEmoticons() as $emoticon => $data):?>
<li data-emoticon="<?=$emoticon?>" title="<?=$data[1]?>"><?=$data[0]?></li>
<?php endforeach; ?>
</ul>
- </section>
- <section class="flex flex-padding background">
+ </div>
+ <div class="flex flex-padding background">
<ul id="markdown-list" class="button-list markdown">
<li data-markdown="bold" class="fa fa-bold" title="<?=$Language->template('markdown_bold')?>"></li>
<li data-markdown="italic" class="fa fa-italic" title="<?=$Language->template('markdown_italic')?>"></li>
@@ -75,14 +75,14 @@
<li data-markdown="list_ul" class="fa fa-list-ul" title="<?=$Language->template('markdown_list_ul')?>"></li>
<li data-markdown="list_ol" class="fa fa-list-ol" title="<?=$Language->template('markdown_list_ol')?>"></li>
</ul>
- </section>
+ </div>
<?php else: ?>
- <section class="flex flex-padding background flex-direction-column">
+ <div class="flex flex-padding background flex-direction-column">
<?=$HTML?>
- </section>
+ </div>
<?php endif; ?>
- <section class="flex flex-padding background">
+ <div class="flex flex-padding background">
<?php if($FORM['TYPE'] === 'INSERT'): ?>
<input type="submit" name="insert" value="<?=$Language->text('insert')?>" />
<?php elseif($FORM['TYPE'] === 'UPDATE'): ?>
@@ -90,5 +90,5 @@
<?php elseif($FORM['TYPE'] === 'DELETE'): ?>
<input type="submit" name="delete" value="<?=$Language->text('delete')?>" id="delete-button" data-text="<?=$Language->template('sure')?>" />
<?php endif; ?>
- </section>
+ </div>
</form> \ No newline at end of file