From 6cee5147e677eec5eb209fb93c6cd6327efdcb60 Mon Sep 17 00:00:00 2001 From: blackcoder87 Date: Sun, 12 Jan 2025 12:49:05 +0100 Subject: [PATCH] CKEditor and more: Use ck-content class for displaying content + other bugfixes (#1152) * Added the "ck-content" class for the content that was created in the CKEditor. * ilch.css: set "overflow: auto" for ck-content or otherwise it would affect everything after the "ck-content" div. * Contact: Removed required attribute for the textarea used by CKEditor as it doesn't work with CKEditor 5. * Rule: Fix "Invalid argument supplied for foreach() in application/modules/rule/views/admin/index/treat.php:52". * Newsletter: Remove unsubscribe link from show action. * Newsletter: Remove email from unreadable link. * Teams: Fix error with no leader or coleader. * War: Fix invalid group image error. * War: Fix error when trying to add a map. * War: The matchtype couldn't be entered when trying to add a war. * HTMLPurifier: Added a unit test for "Wrap text: Left aligned image". --- application/libraries/Ilch/Comments.php | 12 +++-- .../modules/admin/layouts/maintenance.php | 3 +- .../modules/article/views/index/index.php | 4 +- .../modules/article/views/index/show.php | 2 +- .../modules/calendar/views/events/show.php | 2 +- .../modules/checkoutbasic/config/config.php | 2 +- .../checkoutbasic/views/index/index.php | 2 +- .../contact/views/admin/settings/index.php | 3 +- .../modules/contact/views/index/index.php | 2 +- .../modules/events/views/show/event.php | 2 +- application/modules/faq/config/config.php | 2 +- application/modules/faq/views/index/show.php | 2 +- application/modules/forum/config/config.php | 2 +- .../modules/forum/views/showposts/index.php | 4 +- .../modules/guestbook/config/config.php | 2 +- .../modules/guestbook/views/index/index.php | 2 +- application/modules/history/config/config.php | 2 +- .../history/views/admin/index/index.php | 2 +- .../modules/history/views/index/index.php | 2 +- .../modules/imprint/views/index/index.php | 2 +- application/modules/jobs/config/config.php | 2 +- .../modules/jobs/views/index/index.php | 8 ++-- application/modules/jobs/views/index/show.php | 8 ++-- .../modules/newsletter/config/config.php | 2 +- .../newsletter/controllers/admin/Index.php | 2 +- .../modules/newsletter/layouts/show.php | 3 -- .../modules/newsletter/translations/de.php | 2 +- .../modules/newsletter/translations/en.php | 2 +- .../newsletter/views/admin/index/show.php | 47 ++++++++++--------- .../modules/newsletter/views/index/show.php | 2 +- .../modules/privacy/views/index/index.php | 2 +- application/modules/rule/config/config.php | 2 +- .../modules/rule/views/admin/index/index.php | 2 +- .../modules/rule/views/admin/index/treat.php | 2 +- .../modules/rule/views/index/index.php | 2 +- application/modules/shop/config/config.php | 2 +- application/modules/shop/views/index/agb.php | 2 +- application/modules/shop/views/index/show.php | 4 +- application/modules/teams/config/config.php | 2 +- .../teams/views/admin/applications/show.php | 2 +- .../views/admin/applicationshistory/show.php | 2 +- .../modules/teams/views/index/team.php | 2 +- .../modules/training/config/config.php | 2 +- .../modules/training/views/index/show.php | 4 +- .../modules/user/views/regist/index.php | 2 +- application/modules/war/config/config.php | 2 +- .../modules/war/controllers/admin/Group.php | 2 +- .../modules/war/views/admin/index/treat.php | 2 +- .../modules/war/views/admin/maps/treat.php | 4 +- application/modules/war/views/index/show.php | 2 +- static/css/ilch.css | 6 ++- .../libraries/ilch/Design/BasePurifyTest.php | 21 +++++++++ 52 files changed, 121 insertions(+), 86 deletions(-) diff --git a/application/libraries/Ilch/Comments.php b/application/libraries/Ilch/Comments.php index 4a78bd865..64ec2656b 100644 --- a/application/libraries/Ilch/Comments.php +++ b/application/libraries/Ilch/Comments.php @@ -85,9 +85,11 @@ private function rec(int $id, int $commentId, int $uid, int $req, Base $obj): st
' . $user_rep->getName() . '
- ' + +
' . nl2br($obj->alwaysPurify($fk_comment->getText())) . - '
'; + '
+
'; if ($obj->getUser() && !in_array($obj->getUser()->getId(), $voted)) { $commentsHtml .= '
@@ -293,9 +295,11 @@ public function getComments(string $key, $object, Base $layout): string

' . $commentDate->format('d.m.Y - H:i', true) . '

-
' +
+
' . nl2br($layout->alwaysPurify($comment->getText())) . - '
'; + '
+
'; if ($layout->getUser() && !in_array($layout->getUser()->getId(), $voted)) { $commentsHtml .= ' diff --git a/application/modules/admin/layouts/maintenance.php b/application/modules/admin/layouts/maintenance.php index 77e734a8e..63bea56ce 100644 --- a/application/modules/admin/layouts/maintenance.php +++ b/application/modules/admin/layouts/maintenance.php @@ -25,6 +25,7 @@ + @@ -96,7 +97,7 @@ style="width: get('maintenance_status') ?>%;">
-
+
get('maintenance_text') ?>
diff --git a/application/modules/article/views/index/index.php b/application/modules/article/views/index/index.php index 8ced4c821..33d217ddb 100755 --- a/application/modules/article/views/index/index.php +++ b/application/modules/article/views/index/index.php @@ -36,11 +36,11 @@ - purify(reset($contentParts)) ?> +
purify(reset($contentParts)) ?>

getTrans('readMore') ?> - purify($content) ?> +
purify($content) ?>

diff --git a/application/modules/article/views/index/show.php b/application/modules/article/views/index/show.php index 752c800d1..9a7fac0a2 100755 --- a/application/modules/article/views/index/show.php +++ b/application/modules/article/views/index/show.php @@ -33,7 +33,7 @@ - purify($content) ?> +
purify($content) ?>

getTrans('description') ?>
getText()) : ?> - purify($calendar->getText()) ?> +
purify($calendar->getText()) ?>
getTrans('noDescription') ?> diff --git a/application/modules/checkoutbasic/config/config.php b/application/modules/checkoutbasic/config/config.php index 4c97d6bca..9791894ba 100644 --- a/application/modules/checkoutbasic/config/config.php +++ b/application/modules/checkoutbasic/config/config.php @@ -11,7 +11,7 @@ class Config extends \Ilch\Config\Install { public $config = [ 'key' => 'checkoutbasic', - 'version' => '1.6.0', + 'version' => '1.6.1', 'icon_small' => 'fa-regular fa-credit-card', 'author' => 'Stantin, Thomas', 'link' => 'https://ilch.de', diff --git a/application/modules/checkoutbasic/views/index/index.php b/application/modules/checkoutbasic/views/index/index.php index adc878d1d..b7e2291f8 100644 --- a/application/modules/checkoutbasic/views/index/index.php +++ b/application/modules/checkoutbasic/views/index/index.php @@ -9,7 +9,7 @@ ?>

getTrans('accountdata') ?>

-get('checkout_contact') != '') ? $this->purify($this->get('checkout_contact')) : '' ?> +get('checkout_contact') != '') ? '
' . $this->purify($this->get('checkout_contact')) . '
' : '' ?>

getTrans('bankbalance') ?>

diff --git a/application/modules/contact/views/admin/settings/index.php b/application/modules/contact/views/admin/settings/index.php index f59fd0d4b..fa0f167aa 100644 --- a/application/modules/contact/views/admin/settings/index.php +++ b/application/modules/contact/views/admin/settings/index.php @@ -9,8 +9,7 @@ + toolbar="ilch_html">escape($this->get('welcomeMessage')) != '') ? $this->escape($this->get('welcomeMessage')) : $this->escape($this->originalInput('welcomeMessage')) ?>
getSaveBar() ?> diff --git a/application/modules/contact/views/index/index.php b/application/modules/contact/views/index/index.php index ce4276170..88967e02a 100644 --- a/application/modules/contact/views/index/index.php +++ b/application/modules/contact/views/index/index.php @@ -1,7 +1,7 @@

getTrans('menuContact') ?>

get('welcomeMessage'))) : ?>
-
alwaysPurify($this->get('welcomeMessage')) ?>
+
alwaysPurify($this->get('welcomeMessage')) ?>
get('receivers') != ''): ?> diff --git a/application/modules/events/views/show/event.php b/application/modules/events/views/show/event.php index 6bee9fe95..6a33c5664 100644 --- a/application/modules/events/views/show/event.php +++ b/application/modules/events/views/show/event.php @@ -227,7 +227,7 @@
getTrans('description') ?>
-
+
alwaysPurify($event->getText()) ?>
diff --git a/application/modules/faq/config/config.php b/application/modules/faq/config/config.php index e54d19857..125e99aa3 100644 --- a/application/modules/faq/config/config.php +++ b/application/modules/faq/config/config.php @@ -11,7 +11,7 @@ class Config extends \Ilch\Config\Install { public $config = [ 'key' => 'faq', - 'version' => '1.10.1', + 'version' => '1.10.2', 'icon_small' => 'fa-regular fa-circle-question', 'author' => 'Veldscholten, Kevin', 'link' => 'https://ilch.de', diff --git a/application/modules/faq/views/index/show.php b/application/modules/faq/views/index/show.php index 6aeb7e4ab..177a4bb0b 100644 --- a/application/modules/faq/views/index/show.php +++ b/application/modules/faq/views/index/show.php @@ -7,4 +7,4 @@ ?>

escape($faq->getQuestion()) ?>

-getAnswer() ?> +
getAnswer() ?>
diff --git a/application/modules/forum/config/config.php b/application/modules/forum/config/config.php index 92b8b188f..eee4902d1 100644 --- a/application/modules/forum/config/config.php +++ b/application/modules/forum/config/config.php @@ -11,7 +11,7 @@ class Config extends \Ilch\Config\Install { public $config = [ 'key' => 'forum', - 'version' => '1.35.3', + 'version' => '1.35.4', 'icon_small' => 'fa-solid fa-list', 'author' => 'Stantin Thomas', 'link' => 'https://ilch.de', diff --git a/application/modules/forum/views/showposts/index.php b/application/modules/forum/views/showposts/index.php index c1c5abce9..39accbc39 100644 --- a/application/modules/forum/views/showposts/index.php +++ b/application/modules/forum/views/showposts/index.php @@ -142,13 +142,13 @@

-
+
alwaysPurify($post->getText()) ?>
getAutor()->getSignature()) : ?>
- alwaysPurify($post->getAutor()->getSignature()) ?> +
alwaysPurify($post->getAutor()->getSignature()) ?>
diff --git a/application/modules/guestbook/config/config.php b/application/modules/guestbook/config/config.php index b0c285d1b..ef0292ce9 100644 --- a/application/modules/guestbook/config/config.php +++ b/application/modules/guestbook/config/config.php @@ -13,7 +13,7 @@ class Config extends \Ilch\Config\Install { public $config = [ 'key' => 'guestbook', - 'version' => '1.14.1', + 'version' => '1.14.2', 'icon_small' => 'fa-solid fa-book', 'author' => 'Stantin, Thomas', 'link' => 'https://ilch.de', diff --git a/application/modules/guestbook/views/index/index.php b/application/modules/guestbook/views/index/index.php index 0bb5d5c74..6ebe8eee9 100644 --- a/application/modules/guestbook/views/index/index.php +++ b/application/modules/guestbook/views/index/index.php @@ -43,7 +43,7 @@
-
+
alwaysPurify($entry->getText()) ?>
diff --git a/application/modules/history/config/config.php b/application/modules/history/config/config.php index ddba07e06..922e563a0 100644 --- a/application/modules/history/config/config.php +++ b/application/modules/history/config/config.php @@ -11,7 +11,7 @@ class Config extends \Ilch\Config\Install { public $config = [ 'key' => 'history', - 'version' => '1.10.0', + 'version' => '1.10.1', 'icon_small' => 'fa-solid fa-clock-rotate-left', 'author' => 'Veldscholten, Kevin', 'link' => 'https://ilch.de', diff --git a/application/modules/history/views/admin/index/index.php b/application/modules/history/views/admin/index/index.php index a5fcba067..c943d2c5c 100644 --- a/application/modules/history/views/admin/index/index.php +++ b/application/modules/history/views/admin/index/index.php @@ -38,7 +38,7 @@ getDeleteIcon(['action' => 'del', 'id' => $entry->getId()]) ?> format('d.m.Y', true) ?> escape($entry->getTitle()) ?> - purify($entry->getText()) ?> + purify($entry->getText()) ?> diff --git a/application/modules/history/views/index/index.php b/application/modules/history/views/index/index.php index 3c2bae614..b1cd0e69c 100644 --- a/application/modules/history/views/index/index.php +++ b/application/modules/history/views/index/index.php @@ -18,7 +18,7 @@

escape($history->getTitle()) ?>

- purify($history->getText()) ?> +
purify($history->getText()) ?>
getDate()); ?> format('d. ', true) . $this->getTrans($getDate->format('F', true)) . $getDate->format(' Y', true) ?>
diff --git a/application/modules/imprint/views/index/index.php b/application/modules/imprint/views/index/index.php index 8cb1c394f..c915a6e59 100644 --- a/application/modules/imprint/views/index/index.php +++ b/application/modules/imprint/views/index/index.php @@ -6,4 +6,4 @@ $imprint = $this->get('imprint'); ?>

getTrans('menuImprint') ?>

-purify($imprint->getImprint()) ?> +
purify($imprint->getImprint()) ?>
diff --git a/application/modules/jobs/config/config.php b/application/modules/jobs/config/config.php index c2813ad1b..ce2afa608 100644 --- a/application/modules/jobs/config/config.php +++ b/application/modules/jobs/config/config.php @@ -11,7 +11,7 @@ class Config extends \Ilch\Config\Install { public $config = [ 'key' => 'jobs', - 'version' => '1.7.0', + 'version' => '1.7.1', 'icon_small' => 'fa-solid fa-briefcase', 'author' => 'Veldscholten, Kevin', 'link' => 'https://ilch.de', diff --git a/application/modules/jobs/views/index/index.php b/application/modules/jobs/views/index/index.php index b4312ee0f..8aab6a46b 100644 --- a/application/modules/jobs/views/index/index.php +++ b/application/modules/jobs/views/index/index.php @@ -16,16 +16,18 @@
-
+
-
+

escape($job->getTitle()) ?>

- purify($job->getText()) ?> +
+ purify($job->getText()) ?> +
getUser()) : ?>
diff --git a/application/modules/jobs/views/index/show.php b/application/modules/jobs/views/index/show.php index 78f990a9a..aaf657bf1 100644 --- a/application/modules/jobs/views/index/show.php +++ b/application/modules/jobs/views/index/show.php @@ -15,12 +15,14 @@

getTrans('menuJob') ?>

-
+
-
+

escape($job->getTitle()) ?>

- purify($job->getText()) ?> +
+ purify($job->getText()) ?> +
diff --git a/application/modules/newsletter/config/config.php b/application/modules/newsletter/config/config.php index b49ebe967..c25f84cd0 100644 --- a/application/modules/newsletter/config/config.php +++ b/application/modules/newsletter/config/config.php @@ -13,7 +13,7 @@ class Config extends Install { public $config = [ 'key' => 'newsletter', - 'version' => '1.8.1', + 'version' => '1.8.2', 'icon_small' => 'fa-regular fa-newspaper', 'author' => 'Veldscholten, Kevin', 'link' => 'https://ilch.de', diff --git a/application/modules/newsletter/controllers/admin/Index.php b/application/modules/newsletter/controllers/admin/Index.php index 81dcf9f74..7bf0d4231 100644 --- a/application/modules/newsletter/controllers/admin/Index.php +++ b/application/modules/newsletter/controllers/admin/Index.php @@ -170,7 +170,7 @@ public function treatAction() '{sitetitle}' => $this->getLayout()->escape($this->getConfig()->get('page_title')), '{date}' => $date->format('l, d. F Y', true), '{footer}' => $this->getTranslator()->trans('noReplyMailFooter'), - '{unreadable}' => $this->getTranslator()->trans('mailUnreadable', $newsletterMapper->getLastId(), $email->getEmail()), + '{unreadable}' => $this->getTranslator()->trans('mailUnreadable', $newsletterMapper->getLastId()), '{unsubscribe}' => $this->getTranslator()->trans('mailUnsubscribe', $email->getSelector(), $email->getConfirmCode()), ]; $message = str_replace(array_keys($messageReplace), array_values($messageReplace), $messageTemplate); diff --git a/application/modules/newsletter/layouts/show.php b/application/modules/newsletter/layouts/show.php index 5bab1fbbe..8fd6e8b24 100644 --- a/application/modules/newsletter/layouts/show.php +++ b/application/modules/newsletter/layouts/show.php @@ -4,8 +4,6 @@ use Ilch\Translator; $config = Registry::get('config'); -$subscriberMapper = new Modules\Newsletter\Mappers\Subscriber(); -$subscriber = $subscriberMapper->getSubscriberByEMail($this->getRequest()->getParam('email')); $translator = new Translator(); $translator->load(APPLICATION_PATH . '/modules/newsletter/translations/'); ?> @@ -223,7 +221,6 @@

trans('noReplyMailFooter') ?>

-

trans('mailUnsubscribe', $subscriber->getSelector(), $subscriber->getConfirmCode()) ?>

diff --git a/application/modules/newsletter/translations/de.php b/application/modules/newsletter/translations/de.php index 4f35319c8..f3cf0dd2c 100644 --- a/application/modules/newsletter/translations/de.php +++ b/application/modules/newsletter/translations/de.php @@ -23,7 +23,7 @@ 'unsubscribeSuccess' => 'E-Mail wurde erfolgreich ausgetragen.', 'subscribeFailed' => 'Eintragen fehlgeschlagen.', 'noReplyMailFooter' => 'Bitte antworten Sie nicht auf diese E-Mail. Dieses Postfach wird nicht überwacht, deshalb werden Sie keine Antwort erhalten.', - 'mailUnreadable' => 'Falls Sie keine HTML E-Mail lesen können klicken Sie hier.', + 'mailUnreadable' => 'Falls Sie keine HTML E-Mail lesen können klicken Sie hier.', 'mailUnsubscribe' => 'Wenn Sie keine Newsletter von uns erhalten wollen, können Sie diese jederzeit hier abmelden.', 'incompleteUnsubscribeUrl' => 'Die Adresse zum Austragen aus dem Newsletter ist ungültig.', 'incompleteDoubleOptInUrl' => 'Die Adresse zur Bestätigung der Registrierung für den Newsletter ist ungültig.', diff --git a/application/modules/newsletter/translations/en.php b/application/modules/newsletter/translations/en.php index 301985986..0461c803c 100644 --- a/application/modules/newsletter/translations/en.php +++ b/application/modules/newsletter/translations/en.php @@ -23,7 +23,7 @@ 'unsubscribeSuccess' => 'E-Mail has been successfully removed.', 'subscribeFailed' => 'Subscribing failed.', 'noReplyMailFooter' => 'Please do not reply to this email. This mailbox is not monitored, so you will not receive a response.', - 'mailUnreadable' => 'If you can not read HTML E-Mail click here.', + 'mailUnreadable' => 'If you can not read HTML E-Mail click here.', 'mailUnsubscribe' => 'If you do not wish to receive newsletters from us, you can cancel these at any time here.', 'incompleteUnsubscribeUrl' => 'The url to unsubscribe from the newsletter is invalid.', 'incompleteDoubleOptInUrl' => 'The url to confirm the subscription to the newsletter is invalid.', diff --git a/application/modules/newsletter/views/admin/index/show.php b/application/modules/newsletter/views/admin/index/show.php index d3197bcba..927bb56cd 100644 --- a/application/modules/newsletter/views/admin/index/show.php +++ b/application/modules/newsletter/views/admin/index/show.php @@ -9,31 +9,34 @@ ?>

getTrans('show') ?>

-
- getTokenField() ?> -
-
- getTrans('date') ?>: -
-
format('d.m.Y H:i', true) ?>
+
+
+ getTrans('date') ?>: +
+
format('d.m.Y H:i', true) ?>
+
+
+
+ getTrans('from') ?>:
- +
+
+ getTrans('subject') ?>:
-
-
- getTrans('subject') ?>: -
-
escape($newsletter->getSubject()) ?>
+
escape($newsletter->getSubject()) ?>
+
+
+
+ getTrans('text') ?>:
-
-
- getTrans('text') ?>: -
-
purify($newsletter->getText()) ?>
+
+ purify($newsletter->getText()) ?>
+
+ + + getTokenField() ?> getSaveBar('delete') ?> diff --git a/application/modules/newsletter/views/index/show.php b/application/modules/newsletter/views/index/show.php index 0e1dc132e..dba17e46e 100644 --- a/application/modules/newsletter/views/index/show.php +++ b/application/modules/newsletter/views/index/show.php @@ -9,4 +9,4 @@

format('l, d. F Y', true) ?>

 

getSubject() ?>

-

getText() ?>

+
purify($newsletter->getText()) ?>
diff --git a/application/modules/privacy/views/index/index.php b/application/modules/privacy/views/index/index.php index 2e1732d37..dc064c380 100644 --- a/application/modules/privacy/views/index/index.php +++ b/application/modules/privacy/views/index/index.php @@ -15,7 +15,7 @@ } ?>

escape($privacy->getTitle()) ?>

-

purify($privacy->getText()) ?>

+
purify($privacy->getText()) ?>

0) : ?> getTrans('source') ?>: diff --git a/application/modules/rule/config/config.php b/application/modules/rule/config/config.php index 84f1fd92f..54a62d3ed 100644 --- a/application/modules/rule/config/config.php +++ b/application/modules/rule/config/config.php @@ -11,7 +11,7 @@ class Config extends \Ilch\Config\Install { public $config = [ 'key' => 'rule', - 'version' => '1.9.1', + 'version' => '1.9.2', 'icon_small' => 'fa-solid fa-gavel', 'author' => 'Veldscholten, Kevin', 'link' => 'https://ilch.de', diff --git a/application/modules/rule/views/admin/index/index.php b/application/modules/rule/views/admin/index/index.php index f25b705c3..cc3b6b949 100644 --- a/application/modules/rule/views/admin/index/index.php +++ b/application/modules/rule/views/admin/index/index.php @@ -50,7 +50,7 @@ escape($rulesparent->getParagraph()) . ' / ' : '') ?>escape($rule->getParagraph()) ?> escape($rule->getTitle()) ?> escape($rule->getParentTitle()) ?> - purify($rule->getText()) ?> + purify($rule->getText()) ?> diff --git a/application/modules/rule/views/admin/index/treat.php b/application/modules/rule/views/admin/index/treat.php index 961012cc8..46821b545 100644 --- a/application/modules/rule/views/admin/index/treat.php +++ b/application/modules/rule/views/admin/index/treat.php @@ -49,7 +49,7 @@ class="form-control"
diff --git a/application/modules/rule/views/index/index.php b/application/modules/rule/views/index/index.php index 0514dd987..4c47f0b0a 100644 --- a/application/modules/rule/views/index/index.php +++ b/application/modules/rule/views/index/index.php @@ -52,7 +52,7 @@ function rec(\Modules\Rule\Models\Rule $item, \Ilch\View $obj) - + ' . $obj->purify($item->getText()) . ' '; diff --git a/application/modules/shop/config/config.php b/application/modules/shop/config/config.php index 85ff5b0c6..1e60acc44 100644 --- a/application/modules/shop/config/config.php +++ b/application/modules/shop/config/config.php @@ -14,7 +14,7 @@ class Config extends Install { public $config = [ 'key' => 'shop', - 'version' => '1.3.3', + 'version' => '1.3.4', 'icon_small' => 'fa-solid fa-cart-shopping', 'author' => 'blackcoder & LordSchirmer', 'link' => 'https://ilch.de', diff --git a/application/modules/shop/views/index/agb.php b/application/modules/shop/views/index/agb.php index 5b25b7ecd..8a2990271 100644 --- a/application/modules/shop/views/index/agb.php +++ b/application/modules/shop/views/index/agb.php @@ -18,7 +18,7 @@ -
+
purify($shopAGB) ?>
getTrans('noAGB') ?> diff --git a/application/modules/shop/views/index/show.php b/application/modules/shop/views/index/show.php index b8d8cb356..2d83d149b 100644 --- a/application/modules/shop/views/index/show.php +++ b/application/modules/shop/views/index/show.php @@ -168,7 +168,7 @@ getTrans('approx') ?> escape($shopItem->getShippingTime()) ?> getTrans('days') ?> - getTrans('shortInfo') ?>

getInfo() ?> + getTrans('shortInfo') ?>

purify($shopItem->getInfo()) ?> @@ -210,7 +210,7 @@
- diff --git a/application/modules/teams/config/config.php b/application/modules/teams/config/config.php index 9bc2af743..0f3e3dacb 100644 --- a/application/modules/teams/config/config.php +++ b/application/modules/teams/config/config.php @@ -13,7 +13,7 @@ class Config extends \Ilch\Config\Install { public $config = [ 'key' => 'teams', - 'version' => '1.24.2', + 'version' => '1.24.3', 'icon_small' => 'fa-solid fa-users', 'author' => 'Veldscholten, Kevin', 'link' => 'https://ilch.de', diff --git a/application/modules/teams/views/admin/applications/show.php b/application/modules/teams/views/admin/applications/show.php index 0c44205d6..971954f5a 100644 --- a/application/modules/teams/views/admin/applications/show.php +++ b/application/modules/teams/views/admin/applications/show.php @@ -107,7 +107,7 @@ -
+
alwaysPurify($join->getText()) ?>
diff --git a/application/modules/teams/views/admin/applicationshistory/show.php b/application/modules/teams/views/admin/applicationshistory/show.php index 457a5ed31..d3d146200 100644 --- a/application/modules/teams/views/admin/applicationshistory/show.php +++ b/application/modules/teams/views/admin/applicationshistory/show.php @@ -104,7 +104,7 @@ -
+
alwaysPurify($join->getText()) ?>
diff --git a/application/modules/teams/views/index/team.php b/application/modules/teams/views/index/team.php index 8560ef84b..2f063aaed 100644 --- a/application/modules/teams/views/index/team.php +++ b/application/modules/teams/views/index/team.php @@ -32,7 +32,7 @@ $groupList = $groupMapper->getUsersForGroup($team->getGroupId()); $leaderIds = explode(',', $team->getLeader()); $coLeaderIds = explode(',', $team->getCoLeader()); - $groupList = array_unique(array_merge($leaderIds, $coLeaderIds, $groupList)); + $groupList = array_unique(array_filter(array_merge($leaderIds, $coLeaderIds, $groupList))); ?>
+ getDesc() ?>
diff --git a/application/modules/training/config/config.php b/application/modules/training/config/config.php index 8b8d881ea..ef3db843f 100644 --- a/application/modules/training/config/config.php +++ b/application/modules/training/config/config.php @@ -13,7 +13,7 @@ class Config extends \Ilch\Config\Install { public array $config = [ 'key' => 'training', - 'version' => '1.10.0', + 'version' => '1.10.1', 'icon_small' => 'fa-solid fa-graduation-cap', 'author' => 'Veldscholten, Kevin', 'link' => 'https://ilch.de', diff --git a/application/modules/training/views/index/show.php b/application/modules/training/views/index/show.php index d62208ebb..294ff5634 100644 --- a/application/modules/training/views/index/show.php +++ b/application/modules/training/views/index/show.php @@ -166,7 +166,9 @@
getText() != '') : ?> - purify($training->getText()) ?> +
+ purify($training->getText()) ?> +
getTrans('noOtherInfo') ?> diff --git a/application/modules/user/views/regist/index.php b/application/modules/user/views/regist/index.php index 405ce14eb..0a749ce3a 100644 --- a/application/modules/user/views/regist/index.php +++ b/application/modules/user/views/regist/index.php @@ -6,7 +6,7 @@
getTrans('rules') ?>
-
+
get('regist_rules') ?>
- getId()) ? $this->getSaveBar('updateButton') : $this->getSaveBar('addButton') ?> + getId()) ? $this->getSaveBar('updateButton') : $this->getSaveBar('addButton') ?> diff --git a/application/modules/war/views/index/show.php b/application/modules/war/views/index/show.php index 24e5da5d1..ae8123ca1 100644 --- a/application/modules/war/views/index/show.php +++ b/application/modules/war/views/index/show.php @@ -223,7 +223,7 @@
getTrans('warReport') ?>
-
+
purify($war->getWarReport()) ?>
diff --git a/static/css/ilch.css b/static/css/ilch.css index 2339ee6df..1a0770bfc 100644 --- a/static/css/ilch.css +++ b/static/css/ilch.css @@ -221,4 +221,8 @@ div.input-group.filter input:not(:placeholder-shown) { font-weight: bold; color: #a94442; background: #f2dede; -} \ No newline at end of file +} + +.ck-content { + overflow: auto; +} diff --git a/tests/libraries/ilch/Design/BasePurifyTest.php b/tests/libraries/ilch/Design/BasePurifyTest.php index b663aaf49..85d5971ad 100644 --- a/tests/libraries/ilch/Design/BasePurifyTest.php +++ b/tests/libraries/ilch/Design/BasePurifyTest.php @@ -484,15 +484,36 @@ public function testPurifyLocalVideoNotAllowedURLCK5() self::assertEquals('
', $output); } + /** + * Embedded Google Maps + * + * @return void + */ public function testPurifyGoogleMaps() { $output = $this->view->purify('
'); self::assertEquals('
', $output); } + /** + * Another variant of how google maps can be embedded. + * + * @return void + */ public function testPurifyGoogleMapsVariant() { $output = $this->view->purify(''); self::assertEquals('', $output); } + + /** + * Wrap text: Left aligned image (CKEditor 5) + * + * @return void + */ + public function testPurifyWrapTextLeftAlignCK5() + { + $output = $this->view->purify('
test
captionA

Test

'); + self::assertEquals('
test
captionA

Test

', $output); + } }