From 807cade64c571929dc19afe3d44787c5abe84f57 Mon Sep 17 00:00:00 2001 From: ArthurHoaro Date: Wed, 31 May 2017 17:50:11 +0200 Subject: [PATCH] Add creation date when editing a link Also, alter the title on edition Fixes #431 --- index.php | 2 +- tpl/default/css/shaarli.css | 8 ++++++++ tpl/default/editlink.html | 9 +++++++-- 3 files changed, 16 insertions(+), 3 deletions(-) diff --git a/index.php b/index.php index 92eb443b..cb0afbd0 100644 --- a/index.php +++ b/index.php @@ -1431,7 +1431,7 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history) 'url' => $url, 'description' => $description, 'tags' => $tags, - 'private' => $private + 'private' => $private, ); } else { $link['linkdate'] = $link['created']->format(LinkDB::LINK_DATE_FORMAT); diff --git a/tpl/default/css/shaarli.css b/tpl/default/css/shaarli.css index 28920648..8b86bce2 100644 --- a/tpl/default/css/shaarli.css +++ b/tpl/default/css/shaarli.css @@ -992,6 +992,14 @@ form[name="linkform"].page-form { color: #3f3f3f; } +/** + * EDIT LINK + */ +#editlinkform .created-date { + color: #767676; + margin-bottom: 10px; +} + /** * LOGIN */ diff --git a/tpl/default/editlink.html b/tpl/default/editlink.html index 354499a4..d03fd72f 100644 --- a/tpl/default/editlink.html +++ b/tpl/default/editlink.html @@ -8,11 +8,15 @@
-

{'Shaare'|t}

+

+ {if="!$link_is_new"}{'Edit'|t}{/if} + {'Shaare'|t} +

{if="isset($link.id)"} {/if} + {if="!$link_is_new"}
{'Created:'|t} {$link.created|format_date}
{/if}
@@ -55,7 +59,8 @@

{'Shaare'|t}

- + {if="!$link_is_new"}