From 531e5d7f3ea82bbbe6b133c530a1a5336aa3c69e Mon Sep 17 00:00:00 2001 From: Hypolite Petovan Date: Sat, 1 May 2021 15:13:39 -0400 Subject: [PATCH 1/3] Add RTL support to profile name and description in the VCard --- view/templates/profile/vcard.tpl | 6 ++-- view/templates/widget/vcard.tpl | 4 +-- .../duepuntozero/templates/profile/vcard.tpl | 6 ++-- view/theme/frio/templates/profile/vcard.tpl | 4 +-- view/theme/frio/templates/widget/vcard.tpl | 6 ++-- .../theme/quattro/templates/profile/vcard.tpl | 30 +++++++++---------- view/theme/vier/templates/profile/vcard.tpl | 6 ++-- 7 files changed, 31 insertions(+), 31 deletions(-) diff --git a/view/templates/profile/vcard.tpl b/view/templates/profile/vcard.tpl index c4e9ea1d1..b989923b7 100644 --- a/view/templates/profile/vcard.tpl +++ b/view/templates/profile/vcard.tpl @@ -1,7 +1,7 @@
-
{{$profile.name}}
+
{{$profile.name}}
{{if $profile.addr}}
{{$profile.addr}}
{{/if}} @@ -13,7 +13,7 @@ {{if $account_type}}{{/if}} {{if $profile.network_link}}
{{$network}}
{{$profile.network_link nofilter}}
{{/if}} {{if $location}} -
+
{{$location}}
{{if $profile.address}}

{{$profile.address nofilter}}

{{/if}} @@ -37,7 +37,7 @@ {{if $homepage}}
{{$homepage}}
{{$profile.homepage}}
{{/if}} - {{if $about}}
{{$about}}
{{$profile.about nofilter}}
{{/if}} + {{if $about}}
{{$about}}
{{$profile.about nofilter}}
{{/if}} {{include file="diaspora_vcard.tpl"}} diff --git a/view/templates/widget/vcard.tpl b/view/templates/widget/vcard.tpl index 1bd0690a2..2cd8d9bb7 100644 --- a/view/templates/widget/vcard.tpl +++ b/view/templates/widget/vcard.tpl @@ -1,8 +1,8 @@
-
{{$name}}
+
{{$name}}
{{if $addr}}
{{$addr}}
{{/if}} - {{if $about}}
{{$about nofilter}}
{{/if}} + {{if $about}}
{{$about nofilter}}
{{/if}} {{if $url}}
{{$name}}
{{else}} diff --git a/view/theme/duepuntozero/templates/profile/vcard.tpl b/view/theme/duepuntozero/templates/profile/vcard.tpl index ed6d52249..cba78da6a 100644 --- a/view/theme/duepuntozero/templates/profile/vcard.tpl +++ b/view/theme/duepuntozero/templates/profile/vcard.tpl @@ -1,7 +1,7 @@
-
{{$profile.name}}
+
{{$profile.name}}
{{if $profile.addr}}
{{$profile.addr}}
{{/if}} @@ -12,7 +12,7 @@ {{if $profile.network_link}}
{{$network}}
{{$profile.network_link nofilter}}
{{/if}} {{if $location}} -
+
{{$location}}
{{if $profile.address}}

{{$profile.address nofilter}}

{{/if}} @@ -21,7 +21,7 @@
{{/if}} - {{if $profile.about}}
{{$profile.about nofilter}}
{{/if}} + {{if $profile.about}}
{{$profile.about nofilter}}
{{/if}} {{if $profile.upubkey}}{{/if}} diff --git a/view/theme/frio/templates/profile/vcard.tpl b/view/theme/frio/templates/profile/vcard.tpl index b1d4ada2d..deecd7543 100644 --- a/view/theme/frio/templates/profile/vcard.tpl +++ b/view/theme/frio/templates/profile/vcard.tpl @@ -37,11 +37,11 @@
-

{{$profile.name}}

+

{{$profile.name}}

{{if $profile.addr}}
{{include file="sub/punct_wrap.tpl" text=$profile.addr}}
{{/if}} - {{if $profile.about}}
{{$profile.about nofilter}}
{{/if}} + {{if $profile.about}}
{{$profile.about nofilter}}
{{/if}} {{if $account_type}}{{/if}}
diff --git a/view/theme/frio/templates/widget/vcard.tpl b/view/theme/frio/templates/widget/vcard.tpl index 210edbe44..9c89ace8c 100644 --- a/view/theme/frio/templates/widget/vcard.tpl +++ b/view/theme/frio/templates/widget/vcard.tpl @@ -16,7 +16,7 @@
-

{{$name}}

+

{{$name}}

{{if $addr}}
{{$addr}}
{{/if}}
@@ -24,13 +24,13 @@
-

{{$name}}

+

{{$name}}

{{if $addr}}
{{$addr}}
{{/if}} {{if $account_type}}{{/if}} - {{if $about}}
{{$about nofilter}}
{{/if}} + {{if $about}}
{{$about nofilter}}
{{/if}} {{if $network_link}}
{{$network}}
{{$network_link nofilter}}
{{/if}}
diff --git a/view/theme/quattro/templates/profile/vcard.tpl b/view/theme/quattro/templates/profile/vcard.tpl index 992700f10..a0f0f2502 100644 --- a/view/theme/quattro/templates/profile/vcard.tpl +++ b/view/theme/quattro/templates/profile/vcard.tpl @@ -1,7 +1,7 @@
-
{{$profile.name}}
+
{{$profile.name}}
{{if $profile.edit}}
{{$profile.edit.1}} @@ -24,23 +24,23 @@ {{if $profile.network_link}}
{{$network}}
{{$profile.network_link nofilter}}
{{/if}} {{if $location}} -
-
{{$location}}
-
- {{if $profile.address}}

{{$profile.address nofilter}}

{{/if}} - {{if $profile.location}}

{{$profile.location}}

{{/if}} -
-
+
+
{{$location}}
+
+ {{if $profile.address}}

{{$profile.address nofilter}}

{{/if}} + {{if $profile.location}}

{{$profile.location}}

{{/if}} +
+
{{/if}} - {{if $about}}
{{$profile.about nofilter}}
{{/if}} + {{if $about}}
{{$profile.about nofilter}}
{{/if}} - {{if $profile.xmpp}} -
-
{{$xmpp}}
-
{{$profile.xmpp}}
-
- {{/if}} + {{if $profile.xmpp}} +
+
{{$xmpp}}
+
{{$profile.xmpp}}
+
+ {{/if}} {{if $profile.upubkey}}{{/if}} diff --git a/view/theme/vier/templates/profile/vcard.tpl b/view/theme/vier/templates/profile/vcard.tpl index 06c7a0235..13e41fcb5 100644 --- a/view/theme/vier/templates/profile/vcard.tpl +++ b/view/theme/vier/templates/profile/vcard.tpl @@ -1,7 +1,7 @@
-
{{$profile.name}}
+
{{$profile.name}}
{{if $profile.edit}}
{{$profile.edit.1}} @@ -20,7 +20,7 @@ {{if $account_type}}{{/if}} {{if $profile.network_link}}
{{$network}}
{{$profile.network_link nofilter}}
{{/if}} {{if $location}} -
+
{{$location}}
{{if $profile.address}}

{{$profile.address nofilter}}

{{/if}} @@ -44,7 +44,7 @@ {{if $homepage}}
{{$homepage}}
{{$profile.homepage}}
{{/if}} - {{if $about}}
{{$about}}
{{$profile.about nofilter}}
{{/if}} + {{if $about}}
{{$about}}
{{$profile.about nofilter}}
{{/if}} {{include file="diaspora_vcard.tpl"}} From c76af275335df1a79a45cb597af4ccce44e59d3c Mon Sep 17 00:00:00 2001 From: Hypolite Petovan Date: Sat, 1 May 2021 15:13:53 -0400 Subject: [PATCH 2/3] Add initial RTL support for post bodies --- view/templates/wall_thread.tpl | 2 +- view/theme/frio/templates/wall_thread.tpl | 2 +- view/theme/quattro/templates/wall_thread.tpl | 2 +- view/theme/smoothly/templates/wall_thread.tpl | 2 +- view/theme/vier/templates/wall_thread.tpl | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/view/templates/wall_thread.tpl b/view/templates/wall_thread.tpl index 0d2561869..1a6a8c071 100644 --- a/view/templates/wall_thread.tpl +++ b/view/templates/wall_thread.tpl @@ -59,7 +59,7 @@
{{$item.title}}
- {{$item.body_html nofilter}} + {{$item.body_html nofilter}}
{{if !$item.suppress_tags}} {{foreach $item.tags as $tag}} diff --git a/view/theme/frio/templates/wall_thread.tpl b/view/theme/frio/templates/wall_thread.tpl index 52a0e7c48..2d9d0a8ab 100644 --- a/view/theme/frio/templates/wall_thread.tpl +++ b/view/theme/frio/templates/wall_thread.tpl @@ -246,7 +246,7 @@ as the value of $top_child_total (this is done at the end of this file)

{{$item.title}}


{{/if}} -
{{$item.body_html nofilter}}
+
{{$item.body_html nofilter}}
diff --git a/view/theme/quattro/templates/wall_thread.tpl b/view/theme/quattro/templates/wall_thread.tpl index e3ed4f26c..870be3207 100644 --- a/view/theme/quattro/templates/wall_thread.tpl +++ b/view/theme/quattro/templates/wall_thread.tpl @@ -54,7 +54,7 @@
{{if $item.title}}

{{$item.title}}

{{/if}} -
{{$item.body_html nofilter}}
+
{{$item.body_html nofilter}}
diff --git a/view/theme/smoothly/templates/wall_thread.tpl b/view/theme/smoothly/templates/wall_thread.tpl index 53f918813..a381722b1 100644 --- a/view/theme/smoothly/templates/wall_thread.tpl +++ b/view/theme/smoothly/templates/wall_thread.tpl @@ -63,7 +63,7 @@
{{$item.title}}
- {{$item.body_html nofilter}} + {{$item.body_html nofilter}}
{{if !$item.suppress_tags}} {{foreach $item.tags as $tag}} diff --git a/view/theme/vier/templates/wall_thread.tpl b/view/theme/vier/templates/wall_thread.tpl index 73997e7c5..f5e13137a 100644 --- a/view/theme/vier/templates/wall_thread.tpl +++ b/view/theme/vier/templates/wall_thread.tpl @@ -74,7 +74,7 @@
{{if $item.title}}

{{$item.title}}

{{/if}} -
{{$item.body_html nofilter}}
+
{{$item.body_html nofilter}}
From 5bca6fe98cc497f95c328bcda298c1f314661f9f Mon Sep 17 00:00:00 2001 From: Hypolite Petovan Date: Sat, 1 May 2021 15:32:17 -0400 Subject: [PATCH 3/3] Add RTL support for display names in mentions --- src/Content/Text/BBCode.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Content/Text/BBCode.php b/src/Content/Text/BBCode.php index 48fda6296..b03100fc9 100644 --- a/src/Content/Text/BBCode.php +++ b/src/Content/Text/BBCode.php @@ -50,7 +50,7 @@ use Friendica\Util\XML; class BBCode { // Update this value to the current date whenever changes are made to BBCode::convert - const VERSION = '2021-04-24'; + const VERSION = '2021-05-01'; const INTERNAL = 0; const API = 2; @@ -1731,7 +1731,7 @@ class BBCode $text); } elseif (!$simple_html) { $text = preg_replace("/([@!])\[url\=(.*?)\](.*?)\[\/url\]/ism", - '$1$3', + '$1$3', $text); }