From ada11a2c67f749579eb852d4357ba259335e3662 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jakobus=20Sch=C3=BCrz?= Date: Wed, 15 Mar 2023 04:46:46 +0100 Subject: [PATCH] create factory for dropzones --- mod/photos.php | 2 +- src/Module/Item/Compose.php | 2 +- view/theme/frio/templates/comment_item.tpl | 42 +--------------------- view/theme/frio/templates/head.tpl | 2 ++ 4 files changed, 5 insertions(+), 43 deletions(-) diff --git a/mod/photos.php b/mod/photos.php index d7d806bfc2..06c0d1946a 100644 --- a/mod/photos.php +++ b/mod/photos.php @@ -1141,7 +1141,7 @@ function photos_content(App $a) '$qcomment' => $qcomment, '$rand_num' => Crypto::randomDigits(12), // Dropzone - '$max_imagesize' => floor(Strings::getBytesFromShorthand(DI::config()->get('system', 'maximagesize')) / 1000000), + '$max_imagesize' => floor(\Friendica\Util\Strings::getBytesFromShorthand(DI::config()->get('system', 'maximagesize')) / 1000000), ]); } } diff --git a/src/Module/Item/Compose.php b/src/Module/Item/Compose.php index d1744b9d72..2f60eebc34 100644 --- a/src/Module/Item/Compose.php +++ b/src/Module/Item/Compose.php @@ -242,7 +242,7 @@ class Compose extends BaseModule ]), // Dropzone - '$max_imagesize' => floor(Strings::getBytesFromShorthand(DI::config()->get('system', 'maximagesize')) / 1000000), + '$max_imagesize' => floor(\Friendica\Util\Strings::getBytesFromShorthand(DI::config()->get('system', 'maximagesize')) / 1000000), ]); } } diff --git a/view/theme/frio/templates/comment_item.tpl b/view/theme/frio/templates/comment_item.tpl index 00ca396d11..c4fcb9f627 100644 --- a/view/theme/frio/templates/comment_item.tpl +++ b/view/theme/frio/templates/comment_item.tpl @@ -67,45 +67,5 @@ diff --git a/view/theme/frio/templates/head.tpl b/view/theme/frio/templates/head.tpl index 478f190562..13104aa6a0 100644 --- a/view/theme/frio/templates/head.tpl +++ b/view/theme/frio/templates/head.tpl @@ -140,6 +140,8 @@ {{/if}} + + {{* Include the strings which are needed for some js functions (e.g. translation) They are loaded into the html so that js functions can use them *}} -- 2.39.5