From 303aef34f0804f9becc10610ae85985835f9d9bf Mon Sep 17 00:00:00 2001 From: Andreas Neustifter Date: Sat, 21 Jul 2018 13:31:05 +0200 Subject: [PATCH] Make frio more consistent by replacing textual links with icons everywhere. (#5415) * Make frio more consistent by replacing textual links with icons everywhere I could find them. * [frio] Move profile add link to icon. --- mod/message.php | 15 ++++++++++ mod/photos.php | 4 +-- view/templates/section_title.tpl | 8 +++-- view/theme/frio/css/style.css | 20 +++++++------ view/theme/frio/templates/events_js.tpl | 10 +++++-- view/theme/frio/templates/group_side.tpl | 12 ++++---- view/theme/frio/templates/mail_head.tpl | 15 ++++++++++ view/theme/frio/templates/mail_list.tpl | 4 ++- view/theme/frio/templates/message_side.tpl | 2 -- view/theme/frio/templates/photo_album.tpl | 28 +++++++++++++----- view/theme/frio/templates/photo_albums.tpl | 29 +++++++++++++++++++ view/theme/frio/templates/photos_recent.tpl | 21 +------------- .../frio/templates/profile_listing_header.tpl | 9 +++--- .../frio/templates/saved_searches_aside.tpl | 2 +- 14 files changed, 121 insertions(+), 58 deletions(-) create mode 100644 view/theme/frio/templates/photo_albums.tpl diff --git a/mod/message.php b/mod/message.php index 61af605302..5cdf0f2334 100644 --- a/mod/message.php +++ b/mod/message.php @@ -109,8 +109,23 @@ function message_content(App $a) $myprofile = System::baseUrl() . '/profile/' . $a->user['nickname']; $tpl = get_markup_template('mail_head.tpl'); + if ($a->argc > 1 && $a->argv[1] == 'new') { + $button = [ + 'label' => L10n::t('Discard'), + 'url' => '/message', + 'sel' => 'close', + ]; + } else { + $button = [ + 'label' => L10n::t('New Message'), + 'url' => '/message/new', + 'sel' => 'new', + 'accesskey' => 'm', + ]; + } $header = replace_macros($tpl, [ '$messages' => L10n::t('Messages'), + '$button' => $button, ]); if (($a->argc == 3) && ($a->argv[1] === 'drop' || $a->argv[1] === 'dropconv')) { diff --git a/mod/photos.php b/mod/photos.php index 8798cbb7a8..07916c5871 100644 --- a/mod/photos.php +++ b/mod/photos.php @@ -1154,9 +1154,9 @@ function photos_content(App $a) } if ($order_field === 'posted') { - $order = [L10n::t('Show Newest First'), 'photos/' . $a->data['user']['nickname'] . '/album/' . bin2hex($album)]; + $order = [L10n::t('Show Newest First'), 'photos/' . $a->data['user']['nickname'] . '/album/' . bin2hex($album), 'oldest']; } else { - $order = [L10n::t('Show Oldest First'), 'photos/' . $a->data['user']['nickname'] . '/album/' . bin2hex($album) . '?f=&order=posted']; + $order = [L10n::t('Show Oldest First'), 'photos/' . $a->data['user']['nickname'] . '/album/' . bin2hex($album) . '?f=&order=posted', 'newest']; } $photos = []; diff --git a/view/templates/section_title.tpl b/view/templates/section_title.tpl index f17dcf7ad4..07685d346b 100644 --- a/view/templates/section_title.tpl +++ b/view/templates/section_title.tpl @@ -1,4 +1,8 @@ -
- {{if $title}}

{{$title}}

{{/if}} +{{if $title}} +
+

{{$title}}

+ {{if ! isset($pullright)}}
+ {{/if}}
+{{/if}} diff --git a/view/theme/frio/css/style.css b/view/theme/frio/css/style.css index 59d8826695..3daa992330 100644 --- a/view/theme/frio/css/style.css +++ b/view/theme/frio/css/style.css @@ -1235,17 +1235,19 @@ div#sidebar-group-list { .group-edit-tool { color: #555; } -aside #group-sidebar .group-edit-tool, -aside #saved-search-list .savedsearchdrop { - opacity: 0.1; - transition: all 0.25s ease-in-out; -} -aside #group-sidebar .group-edit-tool:hover, -aside #saved-search-list .saved-search-li:hover .savedsearchdrop { + +.faded-icon { color: #555; - opacity: 0.8; - transition: all 0.25s ease-in-out; + opacity: 0.3; + transition: all 0.1s ease-in-out; +} +.faded-icon:hover { + opacity: 1; } +.icon-padding { + margin-left: 20px; +} + aside #group-sidebar .sidebar-group-li .group-edit-tool:hover, aside #saved-search-list .saved-search-li .savedsearchdrop:hover { opacity: 1; diff --git a/view/theme/frio/templates/events_js.tpl b/view/theme/frio/templates/events_js.tpl index 76394fe408..cdf1636fe3 100644 --- a/view/theme/frio/templates/events_js.tpl +++ b/view/theme/frio/templates/events_js.tpl @@ -1,12 +1,16 @@
{{$tabs}} - {{include file="section_title.tpl" title=$title}} + {{include file="section_title.tpl" title=$title pullright=1}} {{* The link to create a new event *}} - + {{* We create our own fullcallendar header (with title & calendar view *}} -
+
{{* The dropdown to change the callendar view *}}