From 0b5d7b300e90324d0931837550cac5a9ed348f97 Mon Sep 17 00:00:00 2001 From: rabuzarus <> Date: Mon, 8 Feb 2016 23:15:20 +0100 Subject: [PATCH] contactedit-actions-button: adjust the themes and template polishing --- mod/contacts.php | 9 +- view/global.css | 30 +++- view/templates/contact_edit.tpl | 167 ++++++++---------- view/theme/duepuntozero/style.css | 43 +++-- view/theme/frost-mobile/js/main.js | 1 - view/theme/frost-mobile/style.css | 58 +++++- .../frost-mobile/templates/contact_edit.tpl | 83 +++++---- view/theme/frost/style.css | 64 ++++++- view/theme/frost/templates/contact_edit.tpl | 84 +++++---- view/theme/quattro/dark/style.css | 5 +- view/theme/quattro/green/style.css | 5 +- view/theme/quattro/lilac/style.css | 11 +- view/theme/quattro/quattro.less | 29 +-- view/theme/smoothly/style.css | 48 +++-- view/theme/vier/style.css | 132 +++++++++----- view/theme/vier/templates/contact_edit.tpl | 99 +++++++++++ 16 files changed, 584 insertions(+), 284 deletions(-) create mode 100644 view/theme/vier/templates/contact_edit.tpl diff --git a/mod/contacts.php b/mod/contacts.php index 53fb96c5b..77176f6ca 100644 --- a/mod/contacts.php +++ b/mod/contacts.php @@ -565,6 +565,7 @@ function contacts_content(&$a) { ($contact['rel'] == CONTACT_IS_FOLLOWER)) $follow = $a->get_baseurl(true)."/follow?url=".urlencode($contact["url"]); + // Load contactact related actions like hide, suggest, delete and others $contact_actions = contact_actions($contact); @@ -586,7 +587,7 @@ function contacts_content(&$a) { '$lblcrepair' => t("Repair URL settings"), '$lblrecent' => t('View conversations'), '$lblsuggest' => $lblsuggest, - '$delete' => t('Delete contact'), + //'$delete' => t('Delete contact'), '$nettype' => $nettype, '$poll_interval' => $poll_interval, '$poll_enabled' => $poll_enabled, @@ -627,6 +628,8 @@ function contacts_content(&$a) { '$keywords_label' => t("Tags:"), '$contact_action_button' => t("Actions"), '$contact_actions' => $contact_actions, + '$contact_status' => t("Status"), + '$contact_settings_label' => t('Contact Settings'), )); @@ -970,7 +973,7 @@ function _contact_detail_for_template($rr){ function contact_actions($contact) { $poll_enabled = in_array($contact['network'], array(NETWORK_DFRN, NETWORK_OSTATUS, NETWORK_FEED, NETWORK_MAIL, NETWORK_MAIL2)); - $contact_action_menu = array(); + $contact_action = array(); if($contact['network'] === NETWORK_DFRN) { $contact_actions['suggest'] = array( @@ -1032,5 +1035,5 @@ function contact_actions($contact) { 'id' => 'delete', ); - return $contact_action_menu; + return $contact_actions; } diff --git a/view/global.css b/view/global.css index df001ed36..41af643ec 100644 --- a/view/global.css +++ b/view/global.css @@ -15,12 +15,16 @@ padding: 5px 10px; text-align: center; } +a.btn, a.btn:hover { + text-decoration: none; + color: inherit; +} -ul.menu-popup li.divider { +.menu-popup .divider { height: 1px; margin: 3px 0; overflow: hidden; - background-color: #2d2d2d;; + background-color: #2d2d2d; } /* List of social Networks */ @@ -375,6 +379,24 @@ td.federation-data { } /* contact-edit */ +#contact-edit-status-wrapper { + border: 1px solid; + padding: 10px; +} #contact-edit-actions { - float: right; -} \ No newline at end of file + float: right; + display: inline-block; + position: relative; +} +#contact-edit-actions > .menu-popup { + right: 0; + left: auto; +} + +#contact-edit-settings-label:after { + content: ' ยป'; +} + +#contact-edit-settings { + display: none; +} diff --git a/view/templates/contact_edit.tpl b/view/templates/contact_edit.tpl index 682ebfa36..91ef45127 100644 --- a/view/templates/contact_edit.tpl +++ b/view/templates/contact_edit.tpl @@ -1,110 +1,99 @@ + {{if $header}}