From c40c61c10689baaa986200b2ac09a78bda268ede Mon Sep 17 00:00:00 2001 From: Michael Vogel Date: Wed, 6 Mar 2013 23:23:04 +0100 Subject: [PATCH 1/8] OStatus conversations: Fixed a bug when a message hadn't got an id. vier: Some more changes to make the side menu static. In the index.php I did a small change to make friendica compatible with the android client for diaspora. --- include/ostatus_conversation.php | 6 ++++++ index.php | 4 ++++ view/theme/vier/style.css | 17 +++++++++++++++-- 3 files changed, 25 insertions(+), 2 deletions(-) diff --git a/include/ostatus_conversation.php b/include/ostatus_conversation.php index ef9e4f179..f430d9e47 100644 --- a/include/ostatus_conversation.php +++ b/include/ostatus_conversation.php @@ -90,6 +90,12 @@ function complete_conversation($itemid, $conversation_url, $only_add_conversatio $items = array_reverse($conv_as->items); foreach ($items as $single_conv) { + if (@!$single_conv->id AND $single_conv->provider->url AND $single_conv->statusnet_notice_info->local_id) + $single_conv->id = $single_conv->provider->url."notice/".$single_conv->statusnet_notice_info->local_id; + + if (@!$single_conv->id) + continue; + if ($first_id == "") { $first_id = $single_conv->id; diff --git a/index.php b/index.php index 40551f388..8e2376e91 100644 --- a/index.php +++ b/index.php @@ -183,6 +183,10 @@ if(strlen($a->module)) { * */ + // Compatibility with the Android Diaspora client + if ($a->module == "stream") + $a->module = "network"; + if(is_array($a->plugins) && in_array($a->module,$a->plugins) && file_exists("addon/{$a->module}/{$a->module}.php")) { include_once("addon/{$a->module}/{$a->module}.php"); if(function_exists($a->module . '_module')) diff --git a/view/theme/vier/style.css b/view/theme/vier/style.css index ebcab5a14..fe9ec459c 100644 --- a/view/theme/vier/style.css +++ b/view/theme/vier/style.css @@ -291,7 +291,7 @@ body { background-color: #F2F2F2; color: #2d2d2d; /* margin: 37px 0px 0px 0px; */ - margin: 32px 0px 0px 0px; + margin: 0px 0px 0px 0px; display: table; /* width: 100% */ } @@ -849,6 +849,7 @@ ul.menu-popup .empty { right_aside { width: 0px; + top: 32px; display: block; } @@ -857,12 +858,20 @@ aside { /* display: table-cell; */ vertical-align: top; width: 185px; - padding: 10px 10px 10px 20px; + padding: 32px 10px 10px 20px; /* border-right: 1px solid #D2D2D2; */ /* background-color: #ECECF2; */ background-color: #F2F2F2; font-size: 13px; /* background: #F1F1F1; */ + top: 0px; + overflow-y: auto; + z-index: 2; + + position: fixed; + /* overflow: auto; */ + height: 100%; + /* overflow: scroll; */ } aside .vcard .fn { font-size: 18px; @@ -1062,6 +1071,7 @@ aside h4 { section { display: table-cell; vertical-align: top; + top: 32px; width: 766px; max-width: 766px; padding: 10px 10px 10px 10px; @@ -1069,6 +1079,9 @@ section { border-bottom: 1px solid lightgray; border-right: 1px solid lightgray; border-left: 1px solid lightgray; + + position: absolute; + left: 215px; } /* wall item */ .tread-wrapper { From 5d3613c8bc057392d3d43986357da6dddf60ce85 Mon Sep 17 00:00:00 2001 From: Michael Vogel Date: Thu, 7 Mar 2013 19:34:54 +0100 Subject: [PATCH 2/8] Vier: The change from blue to black in links is now faded as well. --- include/enotify.php | 3 +-- view/theme/vier/style.css | 15 +++++++++++++++ 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/include/enotify.php b/include/enotify.php index 928d2b4b4..f294a4fc7 100644 --- a/include/enotify.php +++ b/include/enotify.php @@ -214,11 +214,10 @@ function notification($params) { } if($params['type'] == NOTIFY_CONFIRM) { - } if($params['type'] == NOTIFY_SYSTEM) { - + } $h = array( diff --git a/view/theme/vier/style.css b/view/theme/vier/style.css index fe9ec459c..1595499ee 100644 --- a/view/theme/vier/style.css +++ b/view/theme/vier/style.css @@ -240,6 +240,11 @@ div.pager { .shared_header a { color: black; + -webkit-transition: all 0.2s ease-in-out; + -moz-transition: all 0.2s ease-in-out; + -o-transition: all 0.2s ease-in-out; + -ms-transition: all 0.2s ease-in-out; + transition: all 0.2s ease-in-out; } .shared_header a:hover { @@ -1210,6 +1215,11 @@ border-bottom: 1px solid #D2D2D2; .wall-item-container .wall-item-name { color: black; font-weight: bold; + -webkit-transition: all 0.2s ease-in-out; + -moz-transition: all 0.2s ease-in-out; + -o-transition: all 0.2s ease-in-out; + -ms-transition: all 0.2s ease-in-out; + transition: all 0.2s ease-in-out; } .toplevel_item:hover .wall-item-name, @@ -1227,6 +1237,11 @@ border-bottom: 1px solid #D2D2D2; .toplevel_item .fakelink, .wall-item-container .fakelink { color: black; + -webkit-transition: all 0.2s ease-in-out; + -moz-transition: all 0.2s ease-in-out; + -o-transition: all 0.2s ease-in-out; + -ms-transition: all 0.2s ease-in-out; + transition: all 0.2s ease-in-out; /* color: darkblue; */ /* color: #3E3E8C; */ } From 4df162d929c5e6dd397c0ca68bb6a6e5292dbee1 Mon Sep 17 00:00:00 2001 From: Matthew Exon Date: Fri, 8 Mar 2013 08:38:25 +0100 Subject: [PATCH 3/8] Explicitly list protocols that are allowed, rather than using their initials. Also, add cid, which I need for my mailstream plugin to work. --- include/bbcode.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/bbcode.php b/include/bbcode.php index ebed0dbb2..01c8f14df 100644 --- a/include/bbcode.php +++ b/include/bbcode.php @@ -643,7 +643,7 @@ function bbcode($Text,$preserve_nl = false, $tryoembed = true, $simplehtml = fal // fix any escaped ampersands that may have been converted into links $Text = preg_replace("/\<([^>]*?)(src|href)=(.*?)\&\;(.*?)\>/ism",'<$1$2=$3&$4>',$Text); - $Text = preg_replace("/\<([^>]*?)(src|href)=\"[^hfm](.*?)\>/ism",'<$1$2="">',$Text); + $Text = preg_replace("/\<([^>]*?)(src|href)=\"(?!http|ftp|mailto|cid)(.*?)\>/ism",'<$1$2="">',$Text); if($saved_image) $Text = bb_replace_images($Text, $saved_image); From 720a44bb0b64e281b52ea1cf8c77344a5bea31f9 Mon Sep 17 00:00:00 2001 From: Matthew Exon Date: Fri, 8 Mar 2013 03:08:47 +0100 Subject: [PATCH 4/8] The post_remote_end hook was being called with an escaped version of the item, not very useful. This change moves the hook to the end of item_store and gets all data fresh from the database. --- include/items.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/include/items.php b/include/items.php index 29f4d7256..8bd28f788 100755 --- a/include/items.php +++ b/include/items.php @@ -1149,7 +1149,6 @@ function item_store($arr,$force_parent = false) { $arr['deny_gid'] = $deny_gid; $arr['private'] = $private; $arr['deleted'] = $parent_deleted; - call_hooks('post_remote_end',$arr); // update the commented timestamp on the parent @@ -1195,6 +1194,14 @@ function item_store($arr,$force_parent = false) { logger('item_store: put item '.$current_post.' into cachefile '.$cachefile); } + $r = q('SELECT * FROM `item` WHERE id = %d', intval($current_post)); + if (count($r) == 1) { + call_hooks('post_remote_end', $r[0]); + } + else { + logger('item_store: new item not found in DB, id ' . $current_post); + } + return $current_post; } From a2adc03636b1f7d8423e9244b182a47723b95d2b Mon Sep 17 00:00:00 2001 From: pixelroot Date: Mon, 11 Mar 2013 19:19:33 +0100 Subject: [PATCH 5/8] deleted: view/theme/smoothly/login.tpl deleted: view/theme/smoothly/smarty3/login.tpl modified: view/theme/smoothly/style.css modified: view/theme/smoothly/theme.php --- view/theme/smoothly/login.tpl | 36 ----------------------- view/theme/smoothly/smarty3/login.tpl | 41 --------------------------- view/theme/smoothly/style.css | 26 +++++++++-------- view/theme/smoothly/theme.php | 2 +- 4 files changed, 15 insertions(+), 90 deletions(-) delete mode 100644 view/theme/smoothly/login.tpl delete mode 100644 view/theme/smoothly/smarty3/login.tpl diff --git a/view/theme/smoothly/login.tpl b/view/theme/smoothly/login.tpl deleted file mode 100644 index a2c143d39..000000000 --- a/view/theme/smoothly/login.tpl +++ /dev/null @@ -1,36 +0,0 @@ - - - diff --git a/view/theme/smoothly/smarty3/login.tpl b/view/theme/smoothly/smarty3/login.tpl deleted file mode 100644 index e8ade8250..000000000 --- a/view/theme/smoothly/smarty3/login.tpl +++ /dev/null @@ -1,41 +0,0 @@ -{{* - * AUTOMATICALLY GENERATED TEMPLATE - * DO NOT EDIT THIS FILE, CHANGES WILL BE OVERWRITTEN - * - *}} - - - diff --git a/view/theme/smoothly/style.css b/view/theme/smoothly/style.css index 285072d70..1c6f86a20 100644 --- a/view/theme/smoothly/style.css +++ b/view/theme/smoothly/style.css @@ -2,7 +2,7 @@ style.css Smoothly - Created by alex@friendica.pixelbits.de on 2013-02-27 + Created by alex@friendica.pixelbits.de on 2013-03-11 ** Colors ** Blue links - #1873a2 @@ -197,7 +197,7 @@ section { } #login-extra-links { - width: 90px; + width: auto; margin-top: 20px; clear: both; } @@ -210,10 +210,9 @@ section { #login-extra-links a { display: block; - margin: 10px; + margin: 0px; padding: 5px 0px 5px 0px; - text-align: center; - margin-right: 20px; + text-align: left; } #login-extra-filler { @@ -233,12 +232,14 @@ section { #login_openid { width: 300px; - margin-left: 150px; + /*margin-left: 150px;*/ + } #login_standard input, #login_openid input { - width: 240px; + width: 250px; + height: 25px; } #register-link, @@ -258,7 +259,7 @@ section { #login-submit-button, #login-submit-wrapper { margin-top: 10px; - margin-left: 75px; + margin-left: 0px; } #login-submit-button { @@ -2967,7 +2968,7 @@ margin-left: 0px; background: url(images/login-bg.gif) no-repeat; background-position: 0 50%; padding-left: 18px; - width: 250px!important; + width: 260px!important; } .openid:hover { @@ -3648,7 +3649,7 @@ margin-left: 0px; .field { margin-bottom: 10px; - overflow: auto; + /*overflow: auto;*/ padding-bottom: 0px; width: 100%; } @@ -3665,7 +3666,8 @@ margin-left: 0px; .field label { float: left; - width: 200px; + width: auto; + margin-right: 10px; } .field checkbox { @@ -3675,7 +3677,7 @@ margin-left: 0px; .field input, .field textarea { - width: 400px; + width: auto; border: 1px solid #CDCDCD; border-radius: 5px; -moz-border-radius: 5px; diff --git a/view/theme/smoothly/theme.php b/view/theme/smoothly/theme.php index 849ad80a3..6886546d7 100644 --- a/view/theme/smoothly/theme.php +++ b/view/theme/smoothly/theme.php @@ -3,7 +3,7 @@ /* * Name: Smoothly * Description: Like coffee with milk. Theme optimized for iPad[2]. - * Version: Version 2013-02-27.1 + * Version: Version 2013-03-11.1 * Author: Alex * Maintainer: Alex * Screenshot: Screenshot From a65ae04bcc60116d216f83d51504c9def76fc0c6 Mon Sep 17 00:00:00 2001 From: pixelroot Date: Mon, 11 Mar 2013 19:59:49 +0100 Subject: [PATCH 6/8] modified: view/theme/smoothly/style.css --- view/theme/smoothly/style.css | 74 +++++++++++++++-------------------- 1 file changed, 32 insertions(+), 42 deletions(-) diff --git a/view/theme/smoothly/style.css b/view/theme/smoothly/style.css index 1c6f86a20..b95ef677f 100644 --- a/view/theme/smoothly/style.css +++ b/view/theme/smoothly/style.css @@ -204,7 +204,7 @@ section { .login-extra-links { width: 100%; - margin-left: 145px; + margin-left: 0px; clear: both; } @@ -232,14 +232,12 @@ section { #login_openid { width: 300px; - /*margin-left: 150px;*/ - + margin-left: 150px; } #login_standard input, #login_openid input { - width: 250px; - height: 25px; + width: 240px; } #register-link, @@ -258,8 +256,6 @@ section { #login-submit-button, #login-submit-wrapper { - margin-top: 10px; - margin-left: 0px; } #login-submit-button { @@ -635,9 +631,8 @@ aside h4 { .vcard #profile-photo-wrapper { margin: 10px 0px; - padding: 1px; - width: 200px; - height: 200px; + padding: 6px; + width: auto; background: none repeat scroll 0 0 #FFFFFF; border: 1px solid #C5C5C5; box-shadow: 0 0 8px #BDBDBD; @@ -1405,18 +1400,10 @@ ul .sidebar-group-li .icon { width: 100px; } -.wall-item-photo { - width: 81px !important; - height: 81px !important; - border-radius: 5px; - -webkit-border-radius: 5px; - -moz-border-radius: 5px; -} - .wall-item-photo-wrapper { width: 80px; height: 80px; - padding: 1px; + padding: 4px; position: relative; border: 1px solid #dddddd; border-radius: 5px; @@ -1599,13 +1586,14 @@ ul .sidebar-group-li .icon { } .wallwall .wwto { - left: 0px; + left: -10px; + margin: 0; position: absolute; - margin: -1px; - top: 63px; + top: 65px; + width: 30px; z-index: 900; - width: 0px; - height: 0px; + width: 30px; + height: 30px; } .wallwall .wwto img { @@ -1619,8 +1607,8 @@ ul .sidebar-group-li .icon { .wall-item-arrowphoto-wrapper { position: absolute; - left: 30px; - top: 67px; + left: 20px; + top: 70px; z-index: 950; } @@ -1734,8 +1722,8 @@ code { } .wall-item-outside-wrapper.comment .wall-item-photo { - width: 41px!important; - height: 41px!important; + width: 40px!important; + height: 40px!important; } .wall-item-outside-wrapper.comment .wall-item-photo-wrapper { @@ -2022,11 +2010,8 @@ div[id$="wrapper"] br { } .photo { - height: 200px!important; - width: 200px!important; - border-radius: 5px; - -moz-border-radius: 5px; - -webkit-border-radius: 5px; + height: 191px!important; + width: 191px!important; } #side-bar-photos-albums { @@ -2968,7 +2953,7 @@ margin-left: 0px; background: url(images/login-bg.gif) no-repeat; background-position: 0 50%; padding-left: 18px; - width: 260px!important; + width: 250px!important; } .openid:hover { @@ -3649,7 +3634,7 @@ margin-left: 0px; .field { margin-bottom: 10px; - /*overflow: auto;*/ + overflow: auto; padding-bottom: 0px; width: 100%; } @@ -3666,8 +3651,7 @@ margin-left: 0px; .field label { float: left; - width: auto; - margin-right: 10px; + width: 200px; } .field checkbox { @@ -3677,7 +3661,7 @@ margin-left: 0px; .field input, .field textarea { - width: auto; + width: 400px; border: 1px solid #CDCDCD; border-radius: 5px; -moz-border-radius: 5px; @@ -4402,12 +4386,12 @@ div #datebrowse-sidebar.widget { #settings-activity-desc, #settings-notify-desc { - margin:10px 10px 10px 0; + margin: 10px 10px 10px 0; font-weight: bold; } #settings-notifications { - width: 400px; + width: 410px; border: 1px solid #7C7D7B; box-shadow: 0 0 8px #BDBDBD; -moz-box-shadow: 3px 3px 4px #959494; @@ -4415,8 +4399,8 @@ div #datebrowse-sidebar.widget { border-radius: 5px; -moz-border-radius: 5px; -webkit-border-radius: 5px; - padding:10px; - margin:10px 10px 10px 0; + padding: 10px; + margin: 10px 10px 10px 0; } #id_npassword {} @@ -4495,3 +4479,9 @@ div #datebrowse-sidebar.widget { width: 75px; } +#id_remember { + width: auto; +} + +.field.input.openid { +} \ No newline at end of file From bb3e8ad78527e14ec78ee5e5b2ececfa17e9c0aa Mon Sep 17 00:00:00 2001 From: pixelroot Date: Tue, 12 Mar 2013 10:06:19 +0100 Subject: [PATCH 7/8] modified: view/theme/smoothly/style.css modified: view/theme/smoothly/theme.php --- view/theme/smoothly/style.css | 24 +++++++++--------------- view/theme/smoothly/theme.php | 2 +- 2 files changed, 10 insertions(+), 16 deletions(-) diff --git a/view/theme/smoothly/style.css b/view/theme/smoothly/style.css index b95ef677f..5bb78a2ef 100644 --- a/view/theme/smoothly/style.css +++ b/view/theme/smoothly/style.css @@ -2,7 +2,7 @@ style.css Smoothly - Created by alex@friendica.pixelbits.de on 2013-03-11 + Created by alex@friendica.pixelbits.de on 2013-03-12 ** Colors ** Blue links - #1873a2 @@ -208,13 +208,6 @@ section { clear: both; } -#login-extra-links a { - display: block; - margin: 0px; - padding: 5px 0px 5px 0px; - text-align: left; -} - #login-extra-filler { display: none; } @@ -230,9 +223,11 @@ section { margin: 10px 0 0 0; } -#login_openid { - width: 300px; - margin-left: 150px; +#login_openid, +#div_id_remember, +#login-extra-links a { + width: 460px; + float: left; } #login_standard input, @@ -242,9 +237,8 @@ section { #register-link, #lost-password-link { - font-size: 80%; - width: 210px; - margin-left: 5px; + width: 260px; + } #login-name-end, @@ -4484,4 +4478,4 @@ div #datebrowse-sidebar.widget { } .field.input.openid { -} \ No newline at end of file +} diff --git a/view/theme/smoothly/theme.php b/view/theme/smoothly/theme.php index 6886546d7..67f4f7dd7 100644 --- a/view/theme/smoothly/theme.php +++ b/view/theme/smoothly/theme.php @@ -3,7 +3,7 @@ /* * Name: Smoothly * Description: Like coffee with milk. Theme optimized for iPad[2]. - * Version: Version 2013-03-11.1 + * Version: Version 2013-03-12.1 * Author: Alex * Maintainer: Alex * Screenshot: Screenshot From 03f2fa5119c89a91872ac4528445d3f028939305 Mon Sep 17 00:00:00 2001 From: Zach Prezkuta Date: Sat, 16 Mar 2013 10:11:32 -0600 Subject: [PATCH 8/8] prevent infinite redirect on network page for non-existant group --- mod/network.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mod/network.php b/mod/network.php index ba7bff791..51f3d2232 100644 --- a/mod/network.php +++ b/mod/network.php @@ -594,7 +594,7 @@ function network_content(&$a, $update = 0) { if($update) killme(); notice( t('No such group') . EOL ); - goaway($a->get_baseurl(true) . '/network'); + goaway($a->get_baseurl(true) . '/network/0'); // NOTREACHED }