Compare commits

...

46 Commits
7.4 ... 7.6.1

Author SHA1 Message Date
Mario Vavti
2734335869 version 2022-08-07 14:16:56 +02:00
Mario Vavti
0132c4e36e Merge branch 'dev' 2022-08-07 14:16:31 +02:00
Mario Vavti
7dee47183d changelog 2022-08-07 14:16:00 +02:00
Mario Vavti
9c4988c297 Merge branch 'dev' 2022-08-07 14:07:10 +02:00
Mario Vavti
3bfbc70587 check against null 2022-08-07 14:06:08 +02:00
Mario Vavti
34858fce1c Merge branch 'dev' 2022-08-07 12:17:56 +02:00
Mario Vavti
b47dab0ee9 update widget description 2022-08-05 12:45:43 +02:00
Mario Vavti
6eeb033b96 only decode attachment and iconfig for nonresponse activities 2022-08-04 12:42:35 +02:00
Mario Vavti
0679cb8e00 fix wrong attribution in unseen like notifications 2022-08-04 12:13:00 +02:00
Mario
3abc9ee387 fix regression in dark schema
(cherry picked from commit 2e9211cf41)
2022-07-27 09:29:22 +02:00
Mario
2e9211cf41 fix regression in dark schema 2022-07-27 07:27:51 +00:00
Mario
40377796ed Merge branch '7.6RC' 2022-07-26 18:00:00 +00:00
Mario
fedad7f31a version 7.6 2022-07-26 17:59:11 +00:00
Mario
d2a34e0107 Merge branch 'dev' into 7.6RC 2022-07-26 17:20:30 +00:00
Vinzenz Vietzke
769c822568 StartSSL is defunct since 2018
https://www.thesslstore.com/blog/startcom-ssl-shutting-down-2018/
2022-07-26 17:19:16 +00:00
Mario
c452a621fe Merge branch 'remove-dead-startssl' into 'master'
StartSSL is defunct since 2018

See merge request hubzilla/core!2022
2022-07-26 17:18:26 +00:00
Mario
231ab95ef6 update changelog 2022-07-26 17:16:13 +00:00
Mario
7c01b59ffb version 2022-07-26 15:38:57 +00:00
Mario
e79668ddf4 fix lang tests if result is ambigous 2022-07-26 15:37:17 +00:00
Mario
dc6b6fc353 add "falsey" test 2022-07-26 15:22:05 +00:00
Vinzenz Vietzke
34ea58cf38 StartSSL is defunct since 2018
https://www.thesslstore.com/blog/startcom-ssl-shutting-down-2018/
2022-07-25 12:14:43 +00:00
Mario
199168c318 bump dev version 2022-07-19 12:44:46 +00:00
Mario
063d4bbd7d composer autoload 2022-07-19 12:41:53 +00:00
Mario
29fd9b9d64 version and strings 2022-07-19 12:40:08 +00:00
Mario
c301baafb5 check if the webpages app is installed 2022-07-18 17:52:00 +00:00
Mario
4282672201 bump version 2022-07-16 14:52:10 +00:00
Mario
ae705dd865 HQ dashboard - missing files 2022-07-16 14:49:56 +00:00
Mario
f0fa2ce171 bump version 2022-07-15 17:51:01 +00:00
Mario
d6a9a9927c HQ dashboard - initial checkin 2022-07-15 17:50:02 +00:00
Mario
40b4636858 fix vcard-card background for dark schema 2022-07-03 09:49:09 +00:00
Mario
97fe499b63 Merge branch 'redbasic/dark-fixes' into 'dev'
redbasic/dark: make category pills readable.

See merge request hubzilla/core!2021
2022-07-03 09:42:06 +00:00
Mario
e0915cffda es: update plural function 2022-06-23 17:10:35 +00:00
Mario
7602de85c3 make sure the document is loaded 2022-06-23 17:01:43 +00:00
Harald Eilertsen
0787817eb8 redbasic/dark: make category pills readable. 2022-06-21 19:24:21 +02:00
Mario
e030648957 Merge branch 'dev' of https://codeberg.org/hubzilla/hubzilla into dev 2022-06-21 08:57:43 +00:00
hubzilla
b815935fd7 Merge pull request 'Fixing some error in Spanish translation' (#12) from mjfriaza/hubzilla:dev into dev
Reviewed-on: https://codeberg.org/hubzilla/hubzilla/pulls/12
2022-06-21 10:57:12 +02:00
Mario
a5000ba311 Merge branch 'dev' into 'dev'
Fix Opengraph images inside zmg opening tag

See merge request hubzilla/core!2020
2022-06-21 08:52:47 +00:00
Max Kostikov
5e2bb874c8 Fix Opengraph images inside zmg opening tag 2022-06-14 23:19:09 +02:00
mjfriaza
fcb5a7f645 Revert "Fixing some error in Spanish translation"
This reverts commit 1d99c3d3f7.
2022-06-12 18:18:55 +02:00
mjfriaza
b8c6520abb Fix two errors in Spanish translation 2022-06-12 17:21:14 +02:00
mjfriaza
1d99c3d3f7 Fixing some error in Spanish translation 2022-06-05 17:29:44 +02:00
Mario
5e112b395d oembed: implement a max oembed size which defaults to 1MB and do not try to oembed text previews 2022-06-03 08:51:54 +00:00
Mario
d1a8e7813a Revert "composer updates"
This reverts commit 47448b11cd.
2022-06-02 08:00:45 +00:00
Mario
a0582fec12 Revert "composer update"
This reverts commit 2cd3a7b3f0.
2022-06-02 08:00:31 +00:00
Mario
2cd3a7b3f0 composer update 2022-06-02 07:56:13 +00:00
Mario
47448b11cd composer updates 2022-06-02 07:43:33 +00:00
39 changed files with 697 additions and 280 deletions

View File

@@ -1,28 +1,61 @@
Hubzilla 7.4 (2022-06-01)
Updated russian translations
Raise min PHP version to 8.0
Rewrite inbound attachment handling
Move photo flag feature from addon to core
Adjust default production php logging
Update composer libs
Add a hidden config to enable the hs2019 http signature algorithm
Allow starring of pubstream items
Update spanish translations
Add the title in forum post reshares if applicable
Implement inbound pleroma reactions
Add real name info to the navbar template data
Add the updated date to the icon url so that other platforms will pick it up on change
Move wiki from core to addon
Move articles from core to addon
Move cards from core to addon
Hubzilla 7.6.1 (2022-08-07)
Bugfixes
- Fix attachments displayed in visible response activities
- Fix wrong attribution in unseen like notifications
Addons
Rendezvous: add missing default value to sql schema
Wiki: moved from core to addons
Articles: moved from core to addons
Cards: moved from core to addons
Photoflag: moved to core
Sse: fix issue where notifications were emited for created tasks
- Cards: fix widget not implemented via pdl file (requires re-install)
- Articles: fix widget not implemented via pdl file (requires re-install)
- Wiki: fix widget not implemented via pdl file (requires re-install)
Hubzilla 7.6 (2022-07-26)
- Add filter rule to check for false condition
- Implement HQ dashboard to display recently created content for various modules
- Updated spanish translations
- Implement a max oembed size which defaults to 1MB
- Update composer libs
Addons
- Cart: do not attempt oembed
- Cards: implement channel_activities_widget for HQ dashboard
- Articles: implement channel_activities_widget for HQ dashboard
- Wiki: implement channel_activities_widget for HQ dashboard
Bugfixes
- Fix language filter filtering ambigous results
- Fix vcard-card background for dark schema
- Fix contact edit dialog not displayed in chrome browser
- Fix readability of category pills in dark schema
- Fix opengraph images inside zmg opening tag
- Fix oembed attempted for text previews
Hubzilla 7.4 (2022-06-01)
- Updated russian translations
- Raise min PHP version to 8.0
- Rewrite inbound attachment handling
- Move photo flag feature from addon to core
- Adjust default production php logging
- Update composer libs
- Add a hidden config to enable the hs2019 http signature algorithm
- Allow starring of pubstream items
- Update spanish translations
- Add the title in forum post reshares if applicable
- Implement inbound pleroma reactions
- Add real name info to the navbar template data
- Add the updated date to the icon url so that other platforms will pick it up on change
- Move wiki from core to addon
- Move articles from core to addon
- Move cards from core to addon
Addons
- Rendezvous: add missing default value to sql schema
- Wiki: moved from core to addons
- Articles: moved from core to addons
- Cards: moved from core to addons
- Photoflag: moved to core
- Sse: fix issue where notifications were emited for created tasks
Bugfixes
- Fix issue where inbound activitypub items lost image descriptions (issue 1679)

View File

@@ -2417,7 +2417,7 @@ class Activity {
$s['app'] = escape_tags($generator['name']);
}
if (!$response_activity) {
if (is_array($act->obj) && !$response_activity) {
$a = self::decode_taxonomy($act->obj);
if ($a) {
$s['term'] = $a;
@@ -2429,16 +2429,16 @@ class Activity {
}
}
}
}
$a = self::decode_attachment($act->obj);
if ($a) {
$s['attach'] = $a;
}
$a = self::decode_attachment($act->obj);
if ($a) {
$s['attach'] = $a;
}
$a = self::decode_iconfig($act->obj);
if ($a) {
$s['iconfig'] = $a;
$a = self::decode_iconfig($act->obj);
if ($a) {
$s['iconfig'] = $a;
}
}
if (array_key_exists('type', $act->obj)) {

View File

@@ -860,7 +860,7 @@ class Enotify {
// convert this logic into a json array just like the system notifications
$who = (($item['verb'] === ACTIVITY_SHARE) ? 'owner' : 'author');
$body = html2plain(bbcode($item['body'], ['drop_media']), 75, true);
$body = html2plain(bbcode($item['body'], ['drop_media' => true, 'tryoembed' => false]), 75, true);
if ($body) {
$body = htmlentities($body, ENT_QUOTES, 'UTF-8', false);
}

View File

@@ -29,7 +29,19 @@ class MessageFilter {
if (! $word) {
continue;
}
if (substr($word, 0, 1) === '#' && $tags) {
if (isset($lang) && ((strpos($word, 'lang=') === 0) || (strpos($word, 'lang!=') === 0))) {
if (!strlen($lang)) {
// Result is ambiguous. As we are matching deny rules only at this time, continue tests.
// Any matching deny rule concludes testing.
continue;
}
if (strpos($word, 'lang=') === 0 && strcasecmp($lang, trim(substr($word, 5))) == 0) {
return false;
} elseif (strpos($word, 'lang!=') === 0 && strcasecmp($lang, trim(substr($word, 6))) != 0) {
return false;
}
}
elseif (substr($word, 0, 1) === '#' && $tags) {
foreach ($tags as $t) {
if ((($t['ttype'] == TERM_HASHTAG) || ($t['ttype'] == TERM_COMMUNITYTAG)) && (($t['term'] === substr($word, 1)) || (substr($word, 1) === '*'))) {
return false;
@@ -51,10 +63,6 @@ class MessageFilter {
}
} elseif ((strpos($word, '/') === 0) && preg_match($word, $text)) {
return false;
} elseif ((strpos($word, 'lang=') === 0) && ($lang) && (strcasecmp($lang, trim(substr($word, 5))) == 0)) {
return false;
} elseif ((strpos($word, 'lang!=') === 0) && ($lang) && (strcasecmp($lang, trim(substr($word, 6))) != 0)) {
return false;
} elseif (stristr($text, $word) !== false) {
return false;
}
@@ -69,7 +77,19 @@ class MessageFilter {
if (! $word) {
continue;
}
if (substr($word, 0, 1) === '#' && $tags) {
if (isset($lang) && ((strpos($word, 'lang=') === 0) || (strpos($word, 'lang!=') === 0))) {
if (!strlen($lang)) {
// Result is ambiguous. However we are checking allow rules
// and an ambiguous language is always permitted.
return true;
}
if (strpos($word, 'lang=') === 0 && strcasecmp($lang, trim(substr($word, 5))) == 0) {
return true;
} elseif (strpos($word, 'lang!=') === 0 && strcasecmp($lang, trim(substr($word, 6))) != 0) {
return true;
}
}
elseif (substr($word, 0, 1) === '#' && $tags) {
foreach ($tags as $t) {
if ((($t['ttype'] == TERM_HASHTAG) || ($t['ttype'] == TERM_COMMUNITYTAG)) && (($t['term'] === substr($word, 1)) || (substr($word, 1) === '*'))) {
return true;
@@ -91,10 +111,6 @@ class MessageFilter {
}
} elseif ((strpos($word, '/') === 0) && preg_match($word, $text)) {
return true;
} elseif ((strpos($word, 'lang=') === 0) && ($lang) && (strcasecmp($lang, trim(substr($word, 5))) == 0)) {
return true;
} elseif ((strpos($word, 'lang!=') === 0) && ($lang) && (strcasecmp($lang, trim(substr($word, 6))) != 0)) {
return true;
} elseif (stristr($text, $word) !== false) {
return true;
}
@@ -123,7 +139,8 @@ class MessageFilter {
* - ?foo {} baz which will check if 'baz' is an array element in item.foo
* - ?foo {*} baz which will check if 'baz' is an array key in item.foo
* - ?foo which will check for a return of a true condition for item.foo;
*
* - ?!foo which will check for a return of a false condition for item.foo;
*
* The values 0, '', an empty array, and an unset value will all evaluate to false.
*
* @param string $s
@@ -205,6 +222,15 @@ class MessageFilter {
return false;
}
// Ordering of this check (for falsiness) with relation to the following one (check for truthiness) is important.
if (preg_match('/\!(.*?)$/', $s, $matches)) {
$x = ((array_key_exists(trim($matches[1]),$item)) ? $item[trim($matches[1])] : EMPTY_STR);
if (!$x) {
return true;
}
return false;
}
if (preg_match('/(.*?)$/', $s, $matches)) {
$x = ((array_key_exists(trim($matches[1]),$item)) ? $item[trim($matches[1])] : EMPTY_STR);
if ($x) {

View File

@@ -226,7 +226,7 @@ class Display extends \Zotlabs\Web\Controller {
);
}
if(!$r) {
if($r === null) {
$r = q("SELECT item.id AS item_id FROM item
WHERE ((mid = '%s'
AND (((( item.allow_cid = '' AND item.allow_gid = '' AND item.deny_cid = ''
@@ -263,7 +263,7 @@ class Display extends \Zotlabs\Web\Controller {
);
}
if(! $r) {
if($r === null) {
$r = q("SELECT item.id as item_id from item
WHERE ((parent_mid = '%s'
AND (((( item.allow_cid = '' AND item.allow_gid = '' AND item.deny_cid = ''

View File

@@ -49,16 +49,16 @@ class Hq extends \Zotlabs\Web\Controller {
$sql_extra = '';
if(! $item_hash) {
$r = q("SELECT mid FROM item
WHERE uid = %d $item_normal
AND mid = parent_mid
AND item_private IN (0, 1)
ORDER BY created DESC LIMIT 1",
intval(local_channel())
);
if($r[0]['mid']) {
$item_hash = $r[0]['mid'];
}
//$r = q("SELECT mid FROM item
//WHERE uid = %d $item_normal
//AND mid = parent_mid
//AND item_private IN (0, 1)
//ORDER BY created DESC LIMIT 1",
//intval(local_channel())
//);
//if($r[0]['mid']) {
//$item_hash = $r[0]['mid'];
//}
}
if($item_hash) {

View File

@@ -9,42 +9,42 @@ class Page extends \Zotlabs\Web\Controller {
function init() {
// We need this to make sure the channel theme is always loaded.
$which = argv(1);
$profile = 0;
profile_load($which,$profile);
if(\App::$profile['profile_uid'])
head_set_icon(\App::$profile['thumb']);
// load the item here in the init function because we need to extract
// the page layout and initialise the correct theme.
$observer = \App::get_observer();
$ob_hash = (($observer) ? $observer['xchan_hash'] : '');
// perm_is_allowed is denied unconditionally when 'site blocked to unauthenticated members'.
// perm_is_allowed is denied unconditionally when 'site blocked to unauthenticated members'.
// This bypasses that restriction for sys channel (public) content
if((! perm_is_allowed(\App::$profile['profile_uid'],$ob_hash,'view_pages')) && (! is_sys_channel(\App::$profile['profile_uid']))) {
notice( t('Permission denied.') . EOL);
return;
}
if(argc() < 3) {
notice( t('Invalid item.') . EOL);
return;
}
$channel_address = argv(1);
// Always look first for the page name prefixed by the observer language; for instance page/nickname/de/foo
// followed by page/nickname/foo if that is not found.
// If your browser language is de and you want to access the default in this case,
// If your browser language is de and you want to access the default in this case,
// use page/nickname/-/foo to over-ride the language and access only the page with pagelink of 'foo'
$page_name = '';
@@ -63,33 +63,33 @@ class Page extends \Zotlabs\Web\Controller {
// The page link title was stored in a urlencoded format
// php or the browser may/will have decoded it, so re-encode it for our search
$page_id = urlencode($page_name);
$lang_page_id = urlencode(\App::$language . '/' . $page_name);
$u = q("select channel_id from channel where channel_address = '%s' limit 1",
dbesc($channel_address)
);
if(! $u) {
notice( t('Channel not found.') . EOL);
return;
}
if($_REQUEST['rev'])
$revision = " and revision = " . intval($_REQUEST['rev']) . " ";
else
$revision = " order by revision desc ";
require_once('include/security.php');
$sql_options = item_permissions_sql($u[0]['channel_id']);
$r = null;
$r = null;
if(! $ignore_language) {
$r = q("select item.* from item left join iconfig on item.id = iconfig.iid
where item.uid = %d and iconfig.cat = 'system' and iconfig.v = '%s' and item.item_delayed = 0
and iconfig.k = 'WEBPAGE' and item_type = %d
where item.uid = %d and iconfig.cat = 'system' and iconfig.v = '%s' and item.item_delayed = 0
and iconfig.k = 'WEBPAGE' and item_type = %d
$sql_options $revision limit 1",
intval($u[0]['channel_id']),
dbesc($lang_page_id),
@@ -98,8 +98,8 @@ class Page extends \Zotlabs\Web\Controller {
}
if(! $r) {
$r = q("select item.* from item left join iconfig on item.id = iconfig.iid
where item.uid = %d and iconfig.cat = 'system' and iconfig.v = '%s' and item.item_delayed = 0
and iconfig.k = 'WEBPAGE' and item_type = %d
where item.uid = %d and iconfig.cat = 'system' and iconfig.v = '%s' and item.item_delayed = 0
and iconfig.k = 'WEBPAGE' and item_type = %d
$sql_options $revision limit 1",
intval($u[0]['channel_id']),
dbesc($page_id),
@@ -109,7 +109,7 @@ class Page extends \Zotlabs\Web\Controller {
if(! $r) {
// no webpage by that name, but we do allow you to load/preview a layout using this module. Try that.
$r = q("select item.* from item left join iconfig on item.id = iconfig.iid
where item.uid = %d and iconfig.cat = 'system' and iconfig.v = '%s' and item.item_delayed = 0
where item.uid = %d and iconfig.cat = 'system' and iconfig.v = '%s' and item.item_delayed = 0
and iconfig.k = 'PDL' AND item_type = %d $sql_options $revision limit 1",
intval($u[0]['channel_id']),
dbesc($page_id),
@@ -117,17 +117,17 @@ class Page extends \Zotlabs\Web\Controller {
);
}
if(! $r) {
// Check again with no permissions clause to see if it is a permissions issue
$x = q("select item.* from item left join iconfig on item.id = iconfig.iid
where item.uid = %d and iconfig.cat = 'system' and iconfig.v = '%s' and item.item_delayed = 0
where item.uid = %d and iconfig.cat = 'system' and iconfig.v = '%s' and item.item_delayed = 0
and iconfig.k = 'WEBPAGE' and item_type = %d $revision limit 1",
intval($u[0]['channel_id']),
dbesc($page_id),
intval(ITEM_TYPE_WEBPAGE)
);
if($x) {
// Yes, it's there. You just aren't allowed to see it.
notice( t('Permission denied.') . EOL);
@@ -140,7 +140,7 @@ class Page extends \Zotlabs\Web\Controller {
if($r[0]['title'])
\App::$page['title'] = escape_tags($r[0]['title']);
if($r[0]['item_type'] == ITEM_TYPE_PDL) {
\App::$comanche = new \Zotlabs\Render\Comanche();
\App::$comanche->parse($r[0]['body']);
@@ -151,40 +151,41 @@ class Page extends \Zotlabs\Web\Controller {
dbesc($r[0]['layout_mid']),
intval($u[0]['channel_id'])
);
if($l) {
\App::$comanche = new \Zotlabs\Render\Comanche();
\App::$comanche->parse($l[0]['body']);
\App::$pdl = $l[0]['body'];
}
}
\App::$data['webpage'] = $r;
}
function get() {
$r = \App::$data['webpage'];
if(! $r)
return;
if($r[0]['item_type'] == ITEM_TYPE_PDL) {
$r[0]['body'] = t('Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.');
$r[0]['mimetype'] = 'text/plain';
$r[0]['title'] = '';
}
xchan_query($r);
$r = fetch_post_tags($r,true);
if($r[0]['mimetype'] === 'application/x-pdl')
\App::$page['pdl_content'] = true;
$o .= prepare_page($r[0]);
return $o;
}
}

View File

@@ -219,7 +219,8 @@ class Comanche {
* - [if $config.system.foo {} baz] which will check if 'baz' is an array element in get_config('system','foo')
* - [if $config.system.foo {*} baz] which will check if 'baz' is an array key in get_config('system','foo')
* - [if $config.system.foo] which will check for a return of a true condition for get_config('system','foo');
*
* - [if !$config.system.foo] which will check for a return of a false condition for get_config('system','foo');
*
* The values 0, '', an empty array, and an unset value will all evaluate to false.
*
* @param int|string $s
@@ -299,6 +300,15 @@ class Comanche {
return false;
}
// Ordering of this check (for falsiness) with relation to the following one (check for truthiness) is important.
if (preg_match('/[\!\$](.*?)$/', $s, $matches)) {
$x = $this->get_condition_var($matches[1]);
if (!$x) {
return true;
}
return false;
}
if(preg_match('/[\$](.*?)$/',$s,$matches)) {
$x = $this->get_condition_var($matches[1]);
if($x)

View File

@@ -0,0 +1,251 @@
<?php
/**
* * Name: Channel Activity
* * Description: A widget that provides an overview of channels that require your attention and quick links to content that you have recently created or edited
*/
namespace Zotlabs\Widget;
use App;
use Zotlabs\Lib\Apps;
class Channel_activities {
public static $activities = [];
public static $uid = null;
public static $limit = 3;
public static $channel = [];
public static function widget($arr) {
if (!local_channel()) {
return EMPTY_STR;
}
self::$uid = local_channel();
self::$channel = App::get_channel();
$o .= '<div id="channel-activities" class="d-none overflow-hidden">';
$o .= '<h2 class="mb-4">Welcome ' . self::$channel['channel_name'] . '!</h2>';
//$o .= 'Last login date: ' . get_pconfig(self::$uid, 'system', 'stored_login_date') . ' from ' . get_pconfig(self::$uid, 'system', 'stored_login_addr');
self::get_photos_activity();
self::get_files_activity();
self::get_webpages_activity();
self::get_channels_activity();
$hookdata = [
'channel' => self::$channel,
'activities' => self::$activities,
'limit' => self::$limit
];
call_hooks('channel_activities_widget', $hookdata);
if (!$hookdata['activities']) {
$o .= '<h3>No recent activity to display</h3>';
return $o;
}
$keys = array_column($hookdata['activities'], 'date');
array_multisort($keys, SORT_DESC, $hookdata['activities']);
// hz_syslog('activities: ' . print_r($hookdata['activities'], true));
foreach($hookdata['activities'] as $a) {
$o .= replace_macros(get_markup_template($a['tpl']), [
'$url' => $a['url'],
'$icon' => $a['icon'],
'$label' => $a['label'],
'$items' => $a['items']
]);
}
$o .= '</div>';
return $o;
}
private static function get_photos_activity() {
$r = q("SELECT edited, height, width, imgscale, description, filename, resource_id FROM photo WHERE uid = %d
AND photo_usage = 0 AND is_nsfw = 0 AND imgscale = 3
ORDER BY edited DESC LIMIT 6",
intval(self::$uid)
);
if (!$r) {
return;
}
foreach($r as $rr) {
$i[] = [
'url' => z_root() . '/photos/' . self::$channel['channel_address'] . '/image/' . $rr['resource_id'],
'edited' => datetime_convert('UTC', date_default_timezone_get(), $rr['edited']),
'width' => $rr['width'],
'height' => $rr['height'],
'alt' => (($rr['description']) ? $rr['description'] : $rr['filename']),
'src' => z_root() . '/photo/' . $rr['resource_id'] . '-' . $rr['imgscale']
];
}
self::$activities['photos'] = [
'label' => t('Photos'),
'icon' => 'photo',
'url' => z_root() . '/photos/' . self::$channel['channel_address'],
'date' => $r[0]['edited'],
'items' => $i,
'tpl' => 'channel_activities_photos.tpl'
];
}
private static function get_files_activity() {
$r = q("SELECT * FROM attach WHERE uid = %d
AND is_dir = 0 AND is_photo = 0
ORDER BY edited DESC LIMIT %d",
intval(self::$uid),
intval(self::$limit)
);
if (!$r) {
return;
}
foreach($r as $rr) {
$i[] = [
'url' => z_root() . '/cloud/' . self::$channel['channel_address'] . '/' . rtrim($rr['display_path'], $rr['filename']) . '#' . $rr['id'],
'summary' => $rr['filename'],
'footer' => datetime_convert('UTC', date_default_timezone_get(), $rr['edited'])
];
}
self::$activities['files'] = [
'label' => t('Files'),
'icon' => 'folder-open',
'url' => z_root() . '/cloud/' . self::$channel['channel_address'],
'date' => $r[0]['edited'],
'items' => $i,
'tpl' => 'channel_activities.tpl'
];
}
private static function get_webpages_activity() {
if(!Apps::system_app_installed(self::$uid, 'Webpages')) {
return;
}
$r = q("SELECT * FROM iconfig LEFT JOIN item ON iconfig.iid = item.id WHERE item.uid = %d
AND iconfig.cat = 'system' AND iconfig.k = 'WEBPAGE' AND item_type = %d
ORDER BY item.edited DESC LIMIT %d",
intval(self::$uid),
intval(ITEM_TYPE_WEBPAGE),
intval(self::$limit)
);
if (!$r) {
return;
}
foreach($r as $rr) {
$summary = html2plain(purify_html(bbcode($rr['body'], ['drop_media' => true, 'tryoembed' => false])), 85, true);
if ($summary) {
$summary = substr_words(htmlentities($summary, ENT_QUOTES, 'UTF-8', false), 85);
}
$i[] = [
'url' => z_root() . '/page/' . self::$channel['channel_address'] . '/' . $rr['v'],
'title' => $rr['title'],
'summary' => $summary,
'footer' => datetime_convert('UTC', date_default_timezone_get(), $rr['edited'])
];
}
self::$activities['webpages'] = [
'label' => t('Webpages'),
'icon' => 'newspaper-o',
'url' => z_root() . '/webpages/' . self::$channel['channel_address'],
'date' => $r[0]['edited'],
'items' => $i,
'tpl' => 'channel_activities.tpl'
];
}
private static function get_channels_activity() {
$account = App::get_account();
$r = q("SELECT channel_id, channel_name, xchan_photo_s FROM channel
LEFT JOIN xchan ON channel_hash = xchan_hash
WHERE channel_account_id = %d
AND channel_id != %d AND channel_removed = 0",
intval($account['account_id']),
intval(self::$uid)
);
if (!$r) {
return;
}
$channels_activity = 0;
foreach($r as$rr) {
$intros = q("SELECT COUNT(abook_id) AS total FROM abook WHERE abook_channel = %d
AND abook_pending = 1 AND abook_self = 0 AND abook_ignored = 0",
intval($rr['channel_id'])
);
$notices = q("SELECT COUNT(id) AS total FROM notify WHERE uid = %d AND seen = 0",
intval($rr['channel_id'])
);
if (!$intros[0]['total'] && !$notices[0]['total']) {
continue;
}
$footer = '';
if ($intros[0]['total']) {
$footer .= intval($intros[0]['total']) . ' ' . tt('new connection', 'new connections', intval($intros[0]['total']), 'noun');
if ($notices[0]['total']) {
$footer .= ', ';
}
}
if ($notices[0]['total']) {
$footer .= intval($notices[0]['total']) . ' ' . tt('notice', 'notices', intval($notices[0]['total']), 'noun');
}
$i[] = [
'url' => z_root() . '/manage/' . $rr['channel_id'],
'title' => '',
'summary' => '<img src="' . $rr['xchan_photo_s'] . '" class="menu-img-2">' . $rr['channel_name'],
'footer' => $footer
];
$channels_activity++;
}
if(!$channels_activity) {
return;
}
self::$activities['channels'] = [
'label' => t('Channels'),
'icon' => 'home',
'url' => z_root() . '/manage',
'date' => datetime_convert(),
'items' => $i,
'tpl' => 'channel_activities.tpl'
];
}
}

View File

@@ -19,15 +19,13 @@ class Hq_controls {
if (! local_channel())
return;
$entries = [
'toggle_editor' => [
'label' => t('Toggle post editor'),
'href' => '#',
'class' => 'btn jot-toggle',
'type' => 'button',
'icon' => 'pencil',
'extra' => 'data-toggle="button"'
]
$entries['toggle_editor'] = [
'label' => t('Toggle post editor'),
'href' => '#',
'class' => 'btn jot-toggle',
'type' => 'button',
'icon' => 'pencil',
'extra' => 'data-toggle="button"'
];
if(Apps::system_app_installed(local_channel(), 'Notes')) {
@@ -41,6 +39,15 @@ class Hq_controls {
];
}
$entries['toggle_channel_activities'] = [
'label' => t('Channel activities'),
'href' => '#',
'class' => 'btn channel-activities-toggle d-none',
'type' => 'button',
'icon' => 'user-circle-o',
'extra' => 'data-toggle="button"'
];
return replace_macros(get_markup_template('hq_controls.tpl'),
[
'$entries' => $entries,

View File

@@ -113,7 +113,7 @@ class Messages {
}
if (!$summary) {
$summary = html2plain(bbcode($item['body'], ['drop_media' => true]), 75, true);
$summary = html2plain(bbcode($item['body'], ['drop_media' => true, 'tryoembed' => false]), 75, true);
if ($summary) {
$summary = htmlentities($summary, ENT_QUOTES, 'UTF-8', false);
}

View File

@@ -31,7 +31,7 @@ class Notes {
$o = replace_macros($tpl, array(
'$text' => $text,
'$html' => bbcode($text),
'$html' => bbcode($text, ['tryoembed' => false]),
'$app' => ((isset($arr['app'])) ? true : false),
'$hidden' => ((isset($arr['hidden'])) ? true : false),
'$strings' => [

View File

@@ -60,7 +60,7 @@ require_once('include/bbcode.php');
require_once('include/items.php');
define('PLATFORM_NAME', 'hubzilla');
define('STD_VERSION', '7.4');
define('STD_VERSION', '7.6.1');
define('ZOT_REVISION', '6.0');
define('DB_UPDATE_VERSION', 1253);

View File

@@ -2702,10 +2702,11 @@ function attach_move($channel_id, $resource_id, $new_folder_hash, $newname = '',
}
q("update attach set content = '%s', folder = '%s', filename = '%s' where id = %d",
q("update attach set content = '%s', folder = '%s', filename = '%s', edited = '%s' where id = %d",
dbescbin($newstorepath),
dbesc($new_folder_hash),
dbesc($filename),
dbesc(datetime_convert()),
intval($r[0]['id'])
);

View File

@@ -1,6 +1,7 @@
<?php /** @file */
use Zotlabs\Lib\Apps;
use Zotlabs\Lib\Activity;
require_once('include/items.php');
@@ -90,7 +91,6 @@ function item_redir_and_replace_images($body, $images, $cid) {
function localize_item(&$item){
if (activity_match($item['verb'],ACTIVITY_LIKE) || activity_match($item['verb'],ACTIVITY_DISLIKE)){
if(! $item['obj'])
return;
@@ -106,6 +106,8 @@ function localize_item(&$item){
$author_link = get_rel_link($obj['author']['link'],'alternate');
elseif(is_array($obj['actor']) && $obj['actor']['url'])
$author_link = ((is_array($obj['actor']['url'])) ? $obj['actor']['url'][0]['href'] : $obj['actor']['url']);
elseif (is_string($obj['actor']))
$author_link = $obj['actor'];
else
$author_link = '';
@@ -114,6 +116,13 @@ function localize_item(&$item){
if(!$author_name)
$author_name = ((is_array($obj['actor']) && $obj['actor']['name']) ? $obj['actor']['name'] : '');
if(!$author_name && is_string($obj['actor'])) {
$cached_actor = Activity::get_cached_actor($obj['actor']);
if (is_array($cached_actor)) {
$author_name = (($cached_actor['name']) ? $cached_actor['name'] : $cached_actor['preferredUsername']);
}
}
if(is_array($obj['link']))
$item_url = get_rel_link($obj['link'],'alternate');
@@ -1719,12 +1728,14 @@ function prepare_page($item) {
}
$body = prepare_body($item, true, [ 'newwin' => false ]);
$edit_link = (($item['uid'] === local_channel()) ? z_root() . '/editwebpage/' . argv(1) . '/' . $item['id'] : '');
if(App::$page['template'] == 'none') {
$tpl = 'page_display_empty.tpl';
return replace_macros(get_markup_template($tpl), array(
'$body' => $body['html']
'$body' => $body['html'],
'$edit_link' => $edit_link
));
}
@@ -1741,6 +1752,7 @@ function prepare_page($item) {
'$body' => $body['html'],
'$preview' => $preview,
'$link' => $link,
'$edit_link' => $edit_link
));
}

View File

@@ -163,6 +163,25 @@ function oembed_fetch_url($embedurl){
$txt = EMPTY_STR;
if ($action !== 'block') {
$max_oembed_size = get_config('system', 'oembed_max_size', 1 * 1024 * 1024 /* 1MB */);
stream_context_set_default(
[
'http' => [
'method' => 'HEAD',
'timeout' => 5
]
]
);
$headers = get_headers($furl, true);
if (isset($headers['Content-Length']) && $headers['Content-Length'] > $max_oembed_size) {
$action = 'block';
}
}
if ($action !== 'block') {
// try oembed autodiscovery
$redirects = 0;

View File

@@ -21,7 +21,7 @@
$ogtitle = $item['title'];
// find first image if exist
if(preg_match("/\[[zi]mg(=[0-9]+x[0-9]+)?\]([^\[]+)/is", $item['body'], $matches)) {
if (preg_match("/\[[zi]mg(=[0-9]+x[0-9]+)?\]([^\[]+)/is", $item['body'], $matches) || preg_match("/\[[zi]mg(=)([^\]]+)/is", $item['body'], $matches)) {
$ogimage = $matches[2];
$ogimagetype = guess_image_type($ogimage);
}

View File

@@ -57,8 +57,8 @@ follow the browser advice. This is disruptive to the community. That said, we
recognise the issues surrounding the current certificate infrastructure and
agree there are many problems, but that doesn't change the requirement.
Free "browser-valid" certificates are available from providers such as StartSSL
and LetsEncrypt.
Free "browser-valid" certificates are available from providers such as ZeroSSL,
LetsEncrypt and a few others.
If you do NOT use SSL, there may be a delay of up to a minute for the initial
install script - while we check the SSL port to see if anything responds there.

View File

@@ -6,9 +6,9 @@
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: 7.4RC1\n"
"Project-Id-Version: 7.6RC\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-05-25 08:39+0000\n"
"POT-Creation-Date: 2022-07-19 09:43+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -538,12 +538,12 @@ msgid "Page name"
msgstr ""
#: ../../addon/wiki/Widget/Wiki_list.php:20 ../../addon/wiki/Mod_Wiki.php:209
#: ../../include/nav.php:516
#: ../../addon/wiki/wiki.php:75 ../../include/nav.php:516
msgid "Wikis"
msgstr ""
#: ../../addon/wiki/Widget/Wiki_page_history.php:28
#: ../../addon/wiki/Lib/NativeWikiPage.php:580
#: ../../addon/wiki/Lib/NativeWikiPage.php:588
#: ../../addon/wiki/Mod_Wiki.php:221 ../../addon/rendezvous/rendezvous.php:172
#: ../../Zotlabs/Module/Oauth.php:111 ../../Zotlabs/Module/Oauth.php:137
#: ../../Zotlabs/Module/Chat.php:255 ../../Zotlabs/Module/Cdav.php:1372
@@ -555,24 +555,24 @@ msgid "Name"
msgstr ""
#: ../../addon/wiki/Widget/Wiki_page_history.php:29
#: ../../addon/wiki/Lib/NativeWikiPage.php:581
#: ../../addon/wiki/Lib/NativeWikiPage.php:589
msgctxt "wiki_history"
msgid "Message"
msgstr ""
#: ../../addon/wiki/Widget/Wiki_page_history.php:30
#: ../../addon/wiki/Lib/NativeWikiPage.php:582
#: ../../addon/wiki/Lib/NativeWikiPage.php:590
msgid "Date"
msgstr ""
#: ../../addon/wiki/Widget/Wiki_page_history.php:31
#: ../../addon/wiki/Lib/NativeWikiPage.php:583
#: ../../addon/wiki/Lib/NativeWikiPage.php:591
#: ../../addon/wiki/Mod_Wiki.php:370
msgid "Revert"
msgstr ""
#: ../../addon/wiki/Widget/Wiki_page_history.php:32
#: ../../addon/wiki/Lib/NativeWikiPage.php:584
#: ../../addon/wiki/Lib/NativeWikiPage.php:592
msgid "Compare"
msgstr ""
@@ -611,40 +611,40 @@ msgid "Error reading page content"
msgstr ""
#: ../../addon/wiki/Lib/NativeWikiPage.php:367
#: ../../addon/wiki/Lib/NativeWikiPage.php:417
#: ../../addon/wiki/Lib/NativeWikiPage.php:485
#: ../../addon/wiki/Lib/NativeWikiPage.php:526
#: ../../addon/wiki/Lib/NativeWikiPage.php:425
#: ../../addon/wiki/Lib/NativeWikiPage.php:493
#: ../../addon/wiki/Lib/NativeWikiPage.php:534
msgid "Error reading wiki"
msgstr ""
#: ../../addon/wiki/Lib/NativeWikiPage.php:404
#: ../../addon/wiki/Lib/NativeWikiPage.php:411
msgid "Page update failed."
msgstr ""
#: ../../addon/wiki/Lib/NativeWikiPage.php:439
#: ../../addon/wiki/Lib/NativeWikiPage.php:447
msgid "Nothing deleted"
msgstr ""
#: ../../addon/wiki/Lib/NativeWikiPage.php:506
#: ../../addon/wiki/Lib/NativeWikiPage.php:514
msgid "Compare: object not found."
msgstr ""
#: ../../addon/wiki/Lib/NativeWikiPage.php:513
#: ../../addon/wiki/Lib/NativeWikiPage.php:521
msgid "Page updated"
msgstr ""
#: ../../addon/wiki/Lib/NativeWikiPage.php:521
#: ../../addon/wiki/Lib/NativeWikiPage.php:529
msgid "Wiki resource_id required for git commit"
msgstr ""
#: ../../addon/wiki/Lib/NativeWikiPage.php:537 ../../addon/cards/cards.php:103
#: ../../addon/articles/articles.php:103 ../../include/help.php:133
#: ../../addon/wiki/Lib/NativeWikiPage.php:545 ../../addon/cards/cards.php:105
#: ../../addon/articles/articles.php:105 ../../include/help.php:133
#: ../../Zotlabs/Module/Display.php:142 ../../Zotlabs/Module/Page.php:136
#: ../../Zotlabs/Module/Block.php:77 ../../Zotlabs/Web/Router.php:186
msgid "Page not found."
msgstr ""
#: ../../addon/wiki/Lib/NativeWikiPage.php:622 ../../include/bbcode.php:1050
#: ../../addon/wiki/Lib/NativeWikiPage.php:630 ../../include/bbcode.php:1050
#: ../../include/bbcode.php:1235
msgid "Different viewers will see this text differently"
msgstr ""
@@ -746,9 +746,9 @@ msgid "Error downloading wiki: "
msgstr ""
#: ../../addon/wiki/Mod_Wiki.php:214 ../../addon/wiki/Mod_Wiki.php:387
#: ../../addon/cards/Mod_Card_edit.php:99 ../../addon/cards/cards.php:73
#: ../../addon/cards/Mod_Card_edit.php:99 ../../addon/cards/cards.php:75
#: ../../addon/articles/Mod_Article_edit.php:97
#: ../../addon/articles/articles.php:73 ../../include/menu.php:120
#: ../../addon/articles/articles.php:75 ../../include/menu.php:120
#: ../../include/channel.php:1530 ../../include/channel.php:1534
#: ../../Zotlabs/Widget/Cdav.php:142 ../../Zotlabs/Widget/Cdav.php:179
#: ../../Zotlabs/Module/Group.php:245 ../../Zotlabs/Module/Oauth.php:171
@@ -3536,16 +3536,16 @@ msgstr ""
msgid "Delete"
msgstr ""
#: ../../addon/cards/cards.php:47 ../../addon/cards/Mod_Cards.php:209
#: ../../Zotlabs/Lib/Apps.php:330
#: ../../addon/cards/cards.php:49 ../../addon/cards/cards.php:166
#: ../../addon/cards/Mod_Cards.php:209 ../../Zotlabs/Lib/Apps.php:330
msgid "Cards"
msgstr ""
#: ../../addon/cards/cards.php:50
#: ../../addon/cards/cards.php:52
msgid "View Cards"
msgstr ""
#: ../../addon/cards/cards.php:81 ../../addon/articles/articles.php:81
#: ../../addon/cards/cards.php:83 ../../addon/articles/articles.php:83
#: ../../include/conversation.php:842
msgid "View in context"
msgstr ""
@@ -4007,12 +4007,12 @@ msgstr ""
msgid "Edit Article"
msgstr ""
#: ../../addon/articles/articles.php:46
#: ../../addon/articles/articles.php:48 ../../addon/articles/articles.php:165
#: ../../addon/articles/Mod_Articles.php:228 ../../Zotlabs/Lib/Apps.php:329
msgid "Articles"
msgstr ""
#: ../../addon/articles/articles.php:49
#: ../../addon/articles/articles.php:51
msgid "View Articles"
msgstr ""
@@ -4976,6 +4976,7 @@ msgid "Ability to display only posts that you've interacted on"
msgstr ""
#: ../../include/features.php:368 ../../include/nav.php:448
#: ../../Zotlabs/Widget/Channel_activities.php:94
#: ../../Zotlabs/Module/Fbrowser.php:29 ../../Zotlabs/Lib/Apps.php:349
msgid "Photos"
msgstr ""
@@ -5596,7 +5597,8 @@ msgstr ""
msgid "Click to authenticate to your home hub"
msgstr ""
#: ../../include/nav.php:99 ../../Zotlabs/Widget/Admin.php:29
#: ../../include/nav.php:99 ../../Zotlabs/Widget/Channel_activities.php:240
#: ../../Zotlabs/Widget/Admin.php:29
#: ../../Zotlabs/Module/Admin/Channels.php:146
#: ../../Zotlabs/Module/Manage.php:162 ../../Zotlabs/Module/Admin.php:116
msgid "Channels"
@@ -5738,7 +5740,8 @@ msgstr ""
msgid "Profile Details"
msgstr ""
#: ../../include/nav.php:456 ../../Zotlabs/Widget/Notifications.php:107
#: ../../include/nav.php:456 ../../Zotlabs/Widget/Channel_activities.php:126
#: ../../Zotlabs/Widget/Notifications.php:107
#: ../../Zotlabs/Module/Fbrowser.php:85 ../../Zotlabs/Lib/Apps.php:344
#: ../../Zotlabs/Storage/Browser.php:351
msgid "Files"
@@ -5762,8 +5765,8 @@ msgstr ""
msgid "Saved Bookmarks"
msgstr ""
#: ../../include/nav.php:505 ../../Zotlabs/Module/Webpages.php:249
#: ../../Zotlabs/Lib/Apps.php:345
#: ../../include/nav.php:505 ../../Zotlabs/Widget/Channel_activities.php:169
#: ../../Zotlabs/Module/Webpages.php:249 ../../Zotlabs/Lib/Apps.php:345
msgid "Webpages"
msgstr ""
@@ -6194,7 +6197,7 @@ msgstr ""
msgid "Summary (optional)"
msgstr ""
#: ../../include/conversation.php:1775 ../../include/taxonomy.php:670
#: ../../include/conversation.php:1778 ../../include/taxonomy.php:670
#: ../../include/channel.php:1774 ../../Zotlabs/Module/Photos.php:1142
#: ../../Zotlabs/Lib/ThreadItem.php:259
msgctxt "noun"
@@ -6203,7 +6206,7 @@ msgid_plural "Likes"
msgstr[0] ""
msgstr[1] ""
#: ../../include/conversation.php:1778 ../../Zotlabs/Module/Photos.php:1147
#: ../../include/conversation.php:1781 ../../Zotlabs/Module/Photos.php:1147
#: ../../Zotlabs/Lib/ThreadItem.php:264
msgctxt "noun"
msgid "Dislike"
@@ -6211,42 +6214,42 @@ msgid_plural "Dislikes"
msgstr[0] ""
msgstr[1] ""
#: ../../include/conversation.php:1781
#: ../../include/conversation.php:1784
msgctxt "noun"
msgid "Attending"
msgid_plural "Attending"
msgstr[0] ""
msgstr[1] ""
#: ../../include/conversation.php:1784
#: ../../include/conversation.php:1787
msgctxt "noun"
msgid "Not Attending"
msgid_plural "Not Attending"
msgstr[0] ""
msgstr[1] ""
#: ../../include/conversation.php:1787
#: ../../include/conversation.php:1790
msgctxt "noun"
msgid "Undecided"
msgid_plural "Undecided"
msgstr[0] ""
msgstr[1] ""
#: ../../include/conversation.php:1790
#: ../../include/conversation.php:1793
msgctxt "noun"
msgid "Agree"
msgid_plural "Agrees"
msgstr[0] ""
msgstr[1] ""
#: ../../include/conversation.php:1793
#: ../../include/conversation.php:1796
msgctxt "noun"
msgid "Disagree"
msgid_plural "Disagrees"
msgstr[0] ""
msgstr[1] ""
#: ../../include/conversation.php:1796
#: ../../include/conversation.php:1799
msgctxt "noun"
msgid "Abstain"
msgid_plural "Abstains"
@@ -7238,19 +7241,19 @@ msgstr ""
msgid "View PDF"
msgstr ""
#: ../../include/oembed.php:367
#: ../../include/oembed.php:386
msgid " by "
msgstr ""
#: ../../include/oembed.php:368
#: ../../include/oembed.php:387
msgid " on "
msgstr ""
#: ../../include/oembed.php:397
#: ../../include/oembed.php:416
msgid "Embedded content"
msgstr ""
#: ../../include/oembed.php:406
#: ../../include/oembed.php:425
msgid "Embedding disabled"
msgstr ""
@@ -7327,6 +7330,20 @@ msgstr ""
msgid "Chat Members"
msgstr ""
#: ../../Zotlabs/Widget/Channel_activities.php:215
msgctxt "noun"
msgid "new connection"
msgid_plural "new connections"
msgstr[0] ""
msgstr[1] ""
#: ../../Zotlabs/Widget/Channel_activities.php:221
msgctxt "noun"
msgid "notice"
msgid_plural "notices"
msgstr[0] ""
msgstr[1] ""
#: ../../Zotlabs/Widget/Pinned.php:73 ../../Zotlabs/Lib/ThreadItem.php:222
msgid "I will attend"
msgstr ""
@@ -7537,14 +7554,18 @@ msgstr ""
msgid "App Categories"
msgstr ""
#: ../../Zotlabs/Widget/Hq_controls.php:24
#: ../../Zotlabs/Widget/Hq_controls.php:23
msgid "Toggle post editor"
msgstr ""
#: ../../Zotlabs/Widget/Hq_controls.php:35
#: ../../Zotlabs/Widget/Hq_controls.php:33
msgid "Toggle personal notes"
msgstr ""
#: ../../Zotlabs/Widget/Hq_controls.php:43
msgid "Channel activities"
msgstr ""
#: ../../Zotlabs/Widget/Permcats.php:42
msgid "Add new role"
msgstr ""
@@ -12840,7 +12861,7 @@ msgstr ""
msgid "Invalid item."
msgstr ""
#: ../../Zotlabs/Module/Page.php:173
#: ../../Zotlabs/Module/Page.php:174
msgid ""
"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod "
"tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, "

View File

@@ -1721,6 +1721,7 @@ return array(
'Zotlabs\\Widget\\Catcloud_wall' => $baseDir . '/Zotlabs/Widget/Catcloud_wall.php',
'Zotlabs\\Widget\\Categories' => $baseDir . '/Zotlabs/Widget/Categories.php',
'Zotlabs\\Widget\\Cdav' => $baseDir . '/Zotlabs/Widget/Cdav.php',
'Zotlabs\\Widget\\Channel_activities' => $baseDir . '/Zotlabs/Widget/Channel_activities.php',
'Zotlabs\\Widget\\Chatroom_list' => $baseDir . '/Zotlabs/Widget/Chatroom_list.php',
'Zotlabs\\Widget\\Chatroom_members' => $baseDir . '/Zotlabs/Widget/Chatroom_members.php',
'Zotlabs\\Widget\\Clock' => $baseDir . '/Zotlabs/Widget/Clock.php',

View File

@@ -1932,6 +1932,7 @@ class ComposerStaticInit7b34d7e50a62201ec5d5e526a5b8b35d
'Zotlabs\\Widget\\Catcloud_wall' => __DIR__ . '/../..' . '/Zotlabs/Widget/Catcloud_wall.php',
'Zotlabs\\Widget\\Categories' => __DIR__ . '/../..' . '/Zotlabs/Widget/Categories.php',
'Zotlabs\\Widget\\Cdav' => __DIR__ . '/../..' . '/Zotlabs/Widget/Cdav.php',
'Zotlabs\\Widget\\Channel_activities' => __DIR__ . '/../..' . '/Zotlabs/Widget/Channel_activities.php',
'Zotlabs\\Widget\\Chatroom_list' => __DIR__ . '/../..' . '/Zotlabs/Widget/Chatroom_list.php',
'Zotlabs\\Widget\\Chatroom_members' => __DIR__ . '/../..' . '/Zotlabs/Widget/Chatroom_members.php',
'Zotlabs\\Widget\\Clock' => __DIR__ . '/../..' . '/Zotlabs/Widget/Clock.php',

View File

@@ -41,20 +41,6 @@ nav .dropdown-menu {
overflow: auto;
}
#navbar-collapse-2 {
flex-basis: 100%;
max-height: 70vh;
}
#navbar-collapse-2.show {
overflow: auto;
}
#navbar-collapse-2.collapsing .dropdown-header,
#navbar-collapse-2.show .dropdown-header {
padding: 0.5rem 0.1rem;
}
.navbar-dark .navbar-toggler {
color: rgba(255,255,255,1);

View File

@@ -316,14 +316,10 @@ a.wall-item-name-link {
}
code {
font-family: Courier, monospace;
font-size: 1em;
padding: 1em 1.5em;
display: block;
}
code.inline-code {
padding: 0.2em;
display: inline;
}

View File

@@ -1,5 +1,5 @@
#ace-editor {
position: relative;
position: relative;
width: 100%;
height: 500px;
border: 1px solid #ccc;
@@ -47,27 +47,3 @@ td > i {
#wikis-index td:nth-last-child(1){
padding-right: 10px;
}
pre code {
background: #F5F5F5;
font-family: Courier, monospace;
font-size: 1em;
padding: 1em 1.5em;
display: block;
white-space: pre-wrap;
word-break: break-all;
}
code {
background: #F5F5F5;
font-family: Courier, monospace;
font-size: 1em;
display: inline;
padding: 0.2em 0.2em;
white-space: pre-wrap;
word-break: break-all;
}
#wiki-content-container code {
background: #F5F5F5;
}

View File

@@ -7256,7 +7256,7 @@ msgstr "Configuración del canal"
#: ../../Zotlabs/Widget/Settings_menu.php:49
msgid "Privacy settings"
msgstr "Ajustes de peivacidad"
msgstr "Ajustes de privacidad"
#: ../../Zotlabs/Widget/Settings_menu.php:56
msgid "Display settings"
@@ -11807,7 +11807,7 @@ msgstr "Aprobar contacto"
#: ../../Zotlabs/Module/Contactedit.php:431
#: ../../Zotlabs/Module/Connedit.php:717
msgid "Their"
msgstr "Su/Sus"
msgstr "Su"
#: ../../Zotlabs/Module/Contactedit.php:432
#: ../../Zotlabs/Module/Connedit.php:718

View File

@@ -2,7 +2,7 @@
if(! function_exists("string_plural_select_es_es")) {
function string_plural_select_es_es($n){
return ($n != 1);
return ($n != 1 ? 1 : 0);
}}
App::$rtl = 0;
App::$strings["plural_function_code"] = "(n != 1 ? 1 : 0)";
@@ -1619,7 +1619,7 @@ App::$strings["Remove term"] = "Eliminar término";
App::$strings["Suggested Chatrooms"] = "Salas de chat sugeridas";
App::$strings["Account settings"] = "Configuración de la cuenta";
App::$strings["Channel settings"] = "Configuración del canal";
App::$strings["Privacy settings"] = "Ajustes de peivacidad";
App::$strings["Privacy settings"] = "Ajustes de privacidad";
App::$strings["Display settings"] = "Ajustes de visualización";
App::$strings["Manage locations"] = "Gestión de ubicaciones (clones) del canal";
App::$strings["Overview"] = "Resumen";
@@ -2653,7 +2653,7 @@ App::$strings["Custom Filter"] = "Filtro personalizado";
App::$strings["Only import posts with this text"] = "Importar solo entradas que contengan este texto";
App::$strings["Do not import posts with this text"] = "No importar entradas que contengan este texto";
App::$strings["Approve contact"] = "Aprobar contacto";
App::$strings["Their"] = "Su/Sus";
App::$strings["Their"] = "Su";
App::$strings["My"] = "Mi";
App::$strings["Roles"] = "Roles";
App::$strings["Compare permissions"] = "Comparar permisos";

View File

@@ -164,8 +164,8 @@ $(document).ready(function() {
jQuery.timeago.settings.allowFuture = true;
$(document).on('click', '.notification, .message', function(e) {
let b64mid = $(this).data('b64mid');
let notify_id = $(this).data('notify_id');
let b64mid = this.dataset.b64mid;
let notify_id = this.dataset.notify_id;
let path = $(this)[0].pathname.split('/')[1];
let stateObj = { b64mid: b64mid };
let singlethread_modules = ['display', 'hq'];
@@ -882,7 +882,7 @@ function updateInit() {
if($('#live-channel').length) { src = 'channel'; }
if($('#live-pubstream').length) { src = 'pubstream'; }
if($('#live-display').length) { src = 'display'; }
if($('#live-hq').length) { src = 'hq'; }
//if($('#live-hq').length) { src = 'hq'; }
if($('#live-search').length) { src = 'search'; }
// if($('#live-cards').length) { src = 'cards'; }
// if($('#live-articles').length) { src = 'articles'; }

View File

@@ -14,6 +14,11 @@ $(document).ready(function () {
// Per File Tools
// highlight and scroll into view if we got an id via hash
if(window.location.hash) {
$('#cloud-index-' + window.location.hash.substr(1)).addClass('cloud-index-active').get(0).scrollIntoView({block: 'center'});
}
$('.cloud-tool-info-btn').on('click', function (e) {
e.preventDefault();
let id = $(this).data('id');

View File

@@ -1,17 +1,42 @@
$(document).ready(function() {
$(document).on('click', '.jot-toggle', function(e) {
$('.autotime').timeago();
if (bParam_mid) {
src = 'hq';
$('.channel-activities-toggle').removeClass('d-none');
}
else {
$('#channel-activities').removeClass('d-none');
}
$(document).one('click', '.notification, .message', function(e) {
page_load = false;
followUpPageLoad = true;
src = 'hq';
$('#channel-activities').addClass('d-none');
$('.channel-activities-toggle').removeClass('d-none');
});
$(document).on('click', '.channel-activities-toggle', function(e) {
$(window).scrollTop(0);
$(document).trigger('hz:hqControlsClickAction');
$('#channel-activities').toggleClass('d-none');
$(this).toggleClass('active');
});
$(document).on('click', '.jot-toggle', function(e) {
$(document).trigger('hz:hqControlsClickAction');
$('#jot-popup').toggle();
$('#profile-jot-text').focus();
$('#profile-jot-text').focus().get(0).scrollIntoView({block: 'center'});
$(this).toggleClass('active');
});
$(document).on('click', '.notes-toggle', function(e) {
$(window).scrollTop(0);
$(document).trigger('hz:hqControlsClickAction');
$('#personal-notes').toggleClass('d-none');
$('#note-text').focus();
$('#note-text-html').get(0).scrollIntoView({block: 'center'});
$(this).toggleClass('active');
});
});

View File

@@ -6,6 +6,7 @@
[/widget]
[/region]
[region=content]
[widget=channel_activities][/widget]
[widget=notes]
[var=hidden]1[/var]
[var=app]1[/var]

View File

@@ -145,23 +145,6 @@ input[type=text], textarea {
white-space: pre;
}
pre code {
border: none;
padding: 1em 1.5em;
}
code {
background: #ccc;
color: #000;
}
pre {
background: #F5F5F5;
color: #333;
border:1px solid #ccc;
border-radius: $radius;
}
.heart {
color: #FF0000;
}
@@ -209,7 +192,7 @@ nav {
max-height: 50%;
background: $comment_item_colour;
padding: 1rem;
border-bottom: #ccc 1px solid;
border-bottom: #e0e0e0 1px solid;
overflow: auto;
-moz-box-shadow: 0px 3px 3px rgba(0,0,0,0.2);
-webkit-box-shadow: 0px 3px 3px rgba(0,0,0,0.2);
@@ -455,7 +438,7 @@ footer {
.pager-prev,
.pager-next,
.pager_n {
border: 1px solid #ccc;
border: 1px solid #e0e0e0;
background: transparent;
padding: 4px;
}
@@ -706,7 +689,7 @@ nav .acpopup {
*/
.oauthapp {
height: auto; overflow: auto;
border-bottom: 2px solid #cccccc;
border-bottom: 2px solid #e0e0e0;
padding-bottom: 1em;
margin-bottom: 1em;
}
@@ -1086,7 +1069,7 @@ img.mail-conv-sender-photo {
.hide-comments-outer {
background-color: $comment_item_colour;
border-top-color: #ccc;
border-top-color: #e0e0e0;
border-style: solid;
border-top-style: dashed;
border-width: 1px 0px 0px 0px;
@@ -1140,13 +1123,13 @@ img.mail-conv-sender-photo {
.comment-edit-text {
border: 1px solid #ccc;
border: 1px solid #e0e0e0;
border-radius: $radius;
}
.divgrow-showmore {
display: block;
border-top: 1px dashed #ccc;
border-top: 1px dashed #e0e0e0;
text-align: center;
}
@@ -1180,7 +1163,7 @@ img.mail-conv-sender-photo {
}
#datebrowse-sidebar select {
border: 1px solid #ccc;
border: 1px solid #e0e0e0;
border-radius: $radius;
}
@@ -1265,7 +1248,7 @@ img.mail-conv-sender-photo {
}
.generic-content-wrapper {
border: 1px solid rgba(0, 0, 0, .2);
border: 1px solid #e0e0e0;
border-radius: $radius;
margin-bottom: 1.5rem;
}
@@ -1437,7 +1420,7 @@ main.fullscreen .section-content-wrapper-np {
blockquote {
font-size: 1rem;
font-style: italic;
border-left: 3px solid #ccc;
border-left: 3px solid #e0e0e0;
padding: 1em 0px 1em 1.5em;
margin: 0px;
}
@@ -1612,7 +1595,7 @@ dl.bb-dl > dd > li {
.onoffswitch.checkbox > div label {
display: block; overflow: hidden; cursor: pointer;
border: 1px solid #ccc;
border: 1px solid #e0e0e0;
border-radius: 12px;
margin:0px;
-webkit-transition: border-color ease-in-out .15s, -webkit-box-shadow ease-in-out .15s;
@@ -1651,13 +1634,13 @@ dl.bb-dl > dd > li {
.onoffswitch-inner:after {
content: attr(data-off);
padding-left: 21px;
background-color: $item_colour; color: #ccc;
background-color: $item_colour; color: #e0e0e0;
text-align: left;
}
.onoffswitch-switch {
display: block; width: 15px; margin:4px;
background: #ccc;
background: #e0e0e0;
border-radius: 10px;
position: absolute; top: 0; bottom: 0; right: 36px;
-moz-transition: all 0.3s ease-in 0s; -webkit-transition: all 0.3s ease-in 0s;
@@ -1801,3 +1784,7 @@ span.default-highlight {
.bootstrap-tagsinput {
width: 100%;
}
.jg-entry img {
border-radius: $radius;
}

View File

@@ -80,13 +80,13 @@ if (! $nav_active_icon_colour)
if (! $link_colour)
$link_colour = '#0d6efd';
if (! $banner_colour)
$banner_colour = '#fff';
$banner_colour = '#efefef';
if (! $bgcolour)
$bgcolour = 'rgb(254,254,254)';
if (! $background_image)
$background_image ='';
if (! $item_colour)
$item_colour = 'rgb(238,238,238)';
$item_colour = '#f6f6f6';
if (! $comment_item_colour)
$comment_item_colour = 'rgb(255,255,255)';
if (! $item_opacity)

View File

@@ -1,5 +1,6 @@
.generic-content-wrapper {
background-color: transparent;
border: 1px solid #333;
}
textarea, input, select
@@ -40,13 +41,19 @@ option {
color: $link_colour !important;
}
.vcard, #contact-block, .widget {
.vcard,
#contact-block,
.widget {
background-color: transparent;
border: none;
border-bottom: 1px solid #333;
border-radius: 0px
}
.vcard-card {
background-color: transparent;
}
#profile-photo-wrapper {
border: none;
}
@@ -323,10 +330,6 @@ a, a:visited, a:link, .fakelink, .fakelink:visited, .fakelink:link {
background-color: #222;
}
.text-dark {
color: #aaa !important;
}
.group-selected, .fileas-selected, .categories-selected, .search-selected, a.active {
color: #fff !important;
text-decoration: underline !important;
@@ -484,18 +487,18 @@ pre {
/* category badge fix: */
a.text-dark:focus, a.text-dark:hover {
color: #ddd !important;
}
.badge-warning {
/* background-color: #ffc927; */
.bg-warning {
background-color: #e38916;
}
.badge-warning a.text-dark {
color: #333 !important;
.bg-warning:hover, .bg-warning:focus {
background-color: #ffc927 !important;
}
.badge-warning a.text-dark:focus, .badge-warning a.text-dark:hover {
color: red !important;
.bg-warning a.text-dark {
color: #111 !important;
}
.bg-warning a.text-dark:focus, .bg-warning a.text-dark:hover {
color: #bd0000 !important;
text-decoration: none;
}

View File

@@ -0,0 +1,21 @@
<div class="mb-1 text-uppercase">
<a href="{{$url}}"><i class="fa fa-fw fa-{{$icon}} generic-icons-nav"></i>{{$label}}</a>
</div>
<div class="row mb-3">
{{foreach $items as $i}}
<div class="col-sm-4 mb-3">
<div class="card">
<a href="{{$i.url}}" class="text-dark">
<div class="card-body">
{{if $i.title}}
<strong>{{$i.title}}</strong>
<hr>
{{/if}}
{{$i.summary}}
</div>
<div class="card-footer text-muted autotime" title="{{$i.footer}}">{{$i.footer}}</div>
</a>
</div>
</div>
{{/foreach}}
</div>

View File

@@ -0,0 +1,19 @@
<div class="mb-1 text-uppercase">
<a href="{{$url}}"><i class="fa fa-fw fa-{{$icon}} generic-icons-nav"></i>{{$label}}</a>
</div>
<div id="photo-album" class="mb-4">
{{foreach $items as $i}}
<a href="{{$i.url}}" title="{{$i.alt}}">
<img src="{{$i.src}}" width="{{$i.width}}" height="{{$i.height}}" alt="{{$i.alt}}">
<div class='jg-caption autotime' title="{{$i.edited}}"></div>
</a>
{{/foreach}}
</div>
<script>
$('#photo-album').justifiedGallery({
border: 0,
margins: 3,
maxRowsCount: 1,
waitThumbnailsLoad: false
});
</script>

View File

@@ -24,29 +24,24 @@
</div>
</div>
<script>
let poi;
let section = 'roles';
let sub_section;
$('#edit-modal').on('hidden.bs.modal', function (e) {
if (window.location.hash) {
history.replaceState(null, '', 'connections');
}
})
if (window.location.hash) {
poi = window.location.hash.substr(1);
init_contact_edit(poi);
}
window.onhashchange = function() {
$(document).ready(function() {
if (window.location.hash) {
poi = window.location.hash.substr(1);
init_contact_edit(poi);
}
};
window.onhashchange = function() {
if (window.location.hash) {
poi = window.location.hash.substr(1);
init_contact_edit(poi);
}
};
});
$(document).on('click', '.contact-edit', function (e) {
e.preventDefault();
@@ -101,6 +96,12 @@
}
});
$('#edit-modal').on('hidden.bs.modal', function (e) {
if (window.location.hash) {
history.replaceState(null, '', 'connections');
}
});
function init_contact_edit(poi) {
if (!poi)
return;

View File

@@ -69,7 +69,9 @@
$(document).ready(function () {
$('.messages-timeago').timeago();
$('.message[data-b64mid=\'' + bParam_mid + '\']').addClass('active');
if (bParam_mid) {
$('.message[data-b64mid=\'' + bParam_mid + '\']').addClass('active');
}
});
$('#messages-widget').on('scroll', function() {
@@ -130,7 +132,9 @@
else {
$('#messages-empty').show();
}
$('.message[data-b64mid=\'' + bParam_mid + '\']').addClass('active');
if (bParam_mid) {
$('.message[data-b64mid=\'' + bParam_mid + '\']').addClass('active');
}
$('#messages-loading').hide();
$('.messages-timeago').timeago();

View File

@@ -9,6 +9,11 @@
<div class="page-author"><a class="page-author-link" href="{{$auth_url}}">{{$author}}</a></div>
<div class="page-date">{{$date}}</div>
<div class="page-body">{{$body}}</div>
{{if $edit_link}}
<div class="position-fixed bottom-0 end-0 m-3">
<a href="{{$edit_link}}" class="btn btn-lg btn-primary rounded-circle"><i class="fa fa-pencil"></i></a>
</div>
{{/if}}
</div>
</div>
</div>

View File

@@ -1 +1,6 @@
{{$body}}
{{$body}}
{{if $edit_link}}
<div class="position-fixed bottom-0 end-0 m-3">
<a href="{{$edit_link}}" class="btn btn-lg btn-primary rounded-circle"><i class="fa fa-pencil"></i></a>
</div>
{{/if}}