diff options
| author | Jan-Hendrik Willms <tleilax+studip@gmail.com> | 2026-03-09 09:18:53 +0100 |
|---|---|---|
| committer | Jan-Hendrik Willms <tleilax+studip@gmail.com> | 2026-03-09 09:18:53 +0100 |
| commit | 08da9f257ff4efc98dd058e81984ac9bd6e46639 (patch) | |
| tree | 5e397bb3771fa096b30d435a12bc6ab8687751b2 /templates | |
| parent | ef89c567131c55840192820ed7510497d970f36d (diff) | |
deprecate asSvg in favor of asImg, fixes #6330
Closes #6330
Merge request studip/studip!4802
Diffstat (limited to 'templates')
31 files changed, 64 insertions, 64 deletions
diff --git a/templates/admin/topLinks.php b/templates/admin/topLinks.php index a97ef75..08336b3 100644 --- a/templates/admin/topLinks.php +++ b/templates/admin/topLinks.php @@ -18,7 +18,7 @@ <? if (isset($last_one)) : ?> <div style="float: left;"> <a href="<?= URLHelper::getLink('?#admin_top_links', ['cid' => $adminList[$last_one]['Seminar_id']]) ?>" title="<?= htmlReady($adminList[$last_one]['Name']) ?>"> - <?= Icon::create('arr_1left')->asSvg(['class' => 'text-bottom']) ?> + <?= Icon::create('arr_1left')->asImg(['class' => 'text-bottom']) ?> <?= _("zurück") ?> </a> </div> @@ -27,13 +27,13 @@ <div style="float: right;"> <a href="<?= URLHelper::getLink('?#admin_top_links', ['cid' => $adminList[$next_one]['Seminar_id']]) ?>" title="<?= htmlReady($adminList[$next_one]['Name']) ?>"> <?= _("vor") ?> - <?= Icon::create('arr_1right')->asSvg(['class' => 'text-bottom']) ?> + <?= Icon::create('arr_1right')->asImg(['class' => 'text-bottom']) ?> </a> </div> <? endif ?> <div> <a href="<?= URLHelper::getLink('adminarea_start.php', ['list' => 'TRUE']) ?>"> - <?= Icon::create('arr_1up')->asSvg(['class' => 'text-bottom']) ?> + <?= Icon::create('arr_1up')->asImg(['class' => 'text-bottom']) ?> <?= _("Liste") ?> </a> </div> diff --git a/templates/blubber/coursegroup_context.php b/templates/blubber/coursegroup_context.php index 78c4627..b8c754b 100644 --- a/templates/blubber/coursegroup_context.php +++ b/templates/blubber/coursegroup_context.php @@ -36,7 +36,7 @@ <? $folder = $thread->statusgruppe->getFolder() ?> <div> <a href="<?= URLHelper::getLink('dispatch.php/course/files/index/'.$folder->getId(), ['cid' => $course->getId()]) ?>"> - <?= $folder->getIcon('clickable')->asSvg(25, ['class' => 'text-bottom']) ?> + <?= $folder->getIcon('clickable')->asImg(25, ['class' => 'text-bottom']) ?> <?= htmlReady($folder->name) ?> </a> </div> diff --git a/templates/blubber/disable-notifications.php b/templates/blubber/disable-notifications.php index f7900dd..813da62 100644 --- a/templates/blubber/disable-notifications.php +++ b/templates/blubber/disable-notifications.php @@ -5,8 +5,8 @@ class="followunfollow<?= $unfollowed ? " unfollowed" : "" ?>" title="<?= _('Benachrichtigungen für diese Konversation abstellen.') ?>" data-thread_id="<?= htmlReady($thread->id) ?>"> - <?= Icon::create('decline')->asSvg(['class' => 'follow text-bottom']) ?> - <?= Icon::create('notification2')->asSvg(['class' => 'unfollow text-bottom']) ?> + <?= Icon::create('decline')->asImg(['class' => 'follow text-bottom']) ?> + <?= Icon::create('notification2')->asImg(['class' => 'unfollow text-bottom']) ?> <?= _('Benachrichtigungen aktiviert') ?> </a> </div> diff --git a/templates/blubber/global_context.php b/templates/blubber/global_context.php index e41e0f0..0568782 100644 --- a/templates/blubber/global_context.php +++ b/templates/blubber/global_context.php @@ -10,8 +10,8 @@ aria-pressed="<?= $unfollowed ? 'false' : 'true' ?>" role="button" data-thread_id="global"> - <?= Icon::create('decline')->asSvg(['class' => 'follow text-bottom']) ?> - <?= Icon::create('notification2')->asSvg(['class' => 'unfollow text-bottom']) ?> + <?= Icon::create('decline')->asImg(['class' => 'follow text-bottom']) ?> + <?= Icon::create('notification2')->asImg(['class' => 'unfollow text-bottom']) ?> <?= _('Benachrichtigungen aktiviert') ?> </a> </div> diff --git a/templates/blubber/private_context.php b/templates/blubber/private_context.php index a943ba3..1e7d642 100644 --- a/templates/blubber/private_context.php +++ b/templates/blubber/private_context.php @@ -1,7 +1,7 @@ <div class="blubber_private_info indented"> <div class="icon"> - <?= Icon::create('group3', Icon::ROLE_INFO)->asSvg(50, ['title' => _('Dies ist ein privater Blubber.')]) ?> + <?= Icon::create('group3', Icon::ROLE_INFO)->asImg(50, ['title' => _('Dies ist ein privater Blubber.')]) ?> </div> <ul class="clean members"> @@ -14,7 +14,7 @@ <? if ($user) : ?> <? if ($user->getId() !== $GLOBALS['user']->id && count($mentions) > 2) : ?> <a class="float_right" href="<?= URLHelper::getLink('dispatch.php/blubber/write_to/' . $user->getId()) ?>" data-dialog title="<?= _('Anblubbern') ?>"> - <?= Icon::create('blubber')->asSvg(['class' => 'text-bottom']) ?> + <?= Icon::create('blubber')->asImg(['class' => 'text-bottom']) ?> </a> <? endif ?> <? if ($user->getId() === $GLOBALS['user']->id) : ?> @@ -23,7 +23,7 @@ data-dialog="size=auto" title="<?= _('Gruppe verlassen') ?>" data-confirm="<?= _('Private Konversation wirklich verlassen?') ?>"> - <?= Icon::create('door-leave')->asSvg(['class' => 'text-bottom']) ?> + <?= Icon::create('door-leave')->asImg(['class' => 'text-bottom']) ?> </a> <? endif ?> <a href="<?= URLHelper::getLink('dispatch.php/profile', ['username' => $user['username']]) ?>"> @@ -39,7 +39,7 @@ <? endforeach ?> <li> <a href="<?= URLHelper::getLink('dispatch.php/blubber/add_member_to_private/'.$thread->getId()) ?>" data-dialog="width=600;height=300"> - <?= Icon::create('add')->asSvg(25, ['class' => 'text-bottom']) ?> + <?= Icon::create('add')->asImg(25, ['class' => 'text-bottom']) ?> </a> </li> </ul> diff --git a/templates/blubber/public_context.php b/templates/blubber/public_context.php index ea0f643..5bb3591 100644 --- a/templates/blubber/public_context.php +++ b/templates/blubber/public_context.php @@ -6,7 +6,7 @@ <a href="<?= URLHelper::getLink('dispatch.php/blubber/compose/'.$thread->getId()) ?>" data-dialog title="<?= _('Blubber bearbeiten') ?>"> - <?= Icon::create('edit')->asSvg(30) ?> + <?= Icon::create('edit')->asImg(30) ?> </a> <form action="<?= URLHelper::getLink('dispatch.php/blubber/delete/'.$thread->getId()) ?>" method="post" diff --git a/templates/contact/header-groups.php b/templates/contact/header-groups.php index 48776be..ae7d262 100644 --- a/templates/contact/header-groups.php +++ b/templates/contact/header-groups.php @@ -32,7 +32,7 @@ </a> <? if ($filter == $group_id): ?> <a href="<?= URLHelper::getLink('dispatch.php/messages/write?', compact('group_id')) ?>"> - <?= Icon::create('mail')->asSvg(['title' => _('Nachricht an alle Personen dieser Gruppe schicken')]) ?> + <?= Icon::create('mail')->asImg(['title' => _('Nachricht an alle Personen dieser Gruppe schicken')]) ?> </a> <? endif; ?> </td> diff --git a/templates/contentbar/contentbar.php b/templates/contentbar/contentbar.php index 34dab2a..a4632ca 100644 --- a/templates/contentbar/contentbar.php +++ b/templates/contentbar/contentbar.php @@ -14,10 +14,10 @@ <div class="contentbar-wrapper-left"> <nav class="contentbar-breadcrumb"> <? if ($toc->isActive()): ?> - <?= $icon->asSvg(24, ['class' => 'text-bottom contentbar-icon']) ?> + <?= $icon->asImg(24, ['class' => 'text-bottom contentbar-icon']) ?> <? else: ?> <a href="<?= $toc->getUrl() ?>" title="<?= htmlReady($toc->getTitle()) ?>" class="contentbar-icon"> - <?= $icon->asSvg(24, ['class' => 'text-bottom']) ?> + <?= $icon->asImg(24, ['class' => 'text-bottom']) ?> </a> <? endif ?> <?= $breadcrumbs->render() ?> diff --git a/templates/forms/form.php b/templates/forms/form.php index f2d0eb5..2a53e4e 100644 --- a/templates/forms/form.php +++ b/templates/forms/form.php @@ -55,7 +55,7 @@ $form_id = md5(uniqid()); v-if="STUDIPFORM_REQUIRED.length > 0 || STUDIPFORM_VALIDATIONNOTES.length > 0"> <header> <h1> - <?= Icon::create('info-circle', Icon::ROLE_INFO)->asSvg(['class' => 'text-bottom validation_notes_icon']) ?> + <?= Icon::create('info-circle', Icon::ROLE_INFO)->asImg(['class' => 'text-bottom validation_notes_icon']) ?> <?= _('Hinweise zum Ausfüllen des Formulars') ?> </h1> </header> diff --git a/templates/header-navigation-item.php b/templates/header-navigation-item.php index 511b803..76a3d4c 100644 --- a/templates/header-navigation-item.php +++ b/templates/header-navigation-item.php @@ -17,7 +17,7 @@ $attr_str = arrayToHtmlAttributes($attributes); <li id="nav_<?= $path ?>"<? if ($nav->isActive()) : ?> class="active"<? endif ?>> <a href="<?= URLHelper::getLink($nav->getURL(), $link_params) ?>" <?= $attr_str ?>> - <?= $nav->getImage()->asSvg(32, ['class' => 'headericon original', 'title' => null]) ?> + <?= $nav->getImage()->asImg(32, ['class' => 'headericon original', 'title' => null]) ?> <div class="navtitle"><?= htmlReady($nav->getTitle()) ?></div> </a> </li> diff --git a/templates/header.php b/templates/header.php index c11d973..90f0416 100644 --- a/templates/header.php +++ b/templates/header.php @@ -140,7 +140,7 @@ if ($navigation) { aria-expanded="false" > <span class="count" aria-hidden="true"><?= count($notifications) ?></span> - <?= Icon::create('notification2', Icon::ROLE_INFO)->asSvg() ?> + <?= Icon::create('notification2', Icon::ROLE_INFO)->asImg() ?> </button> <input type="checkbox" id="notification_checkbox"> <div class="list below" id="notification_list"> @@ -175,7 +175,7 @@ if ($navigation) { <li id="responsive-create-shortlink" class="hidden-small-up"> <a href="<?= URLHelper::getLink('dispatch.php/short_urls/create') ?>" id="responsive-create-shortlink-dummy"> - <?= Icon::create('share', Icon::ROLE_INFO_ALT)->asSvg(24) ?> + <?= Icon::create('share', Icon::ROLE_INFO_ALT)->asImg(24) ?> </a> <?= Studip\VueApp::create('short-urls/ShortUrlLink') ->withProps([ @@ -191,13 +191,13 @@ if ($navigation) { <li id="responsive-toggle-fullscreen"> <button class="styleless" id="fullscreen-off" title="<?= _('Kompakte Navigation ausschalten') ?>"> - <?= Icon::create('screen-standard', Icon::ROLE_INFO_ALT)->asSvg(24) ?> + <?= Icon::create('screen-standard', Icon::ROLE_INFO_ALT)->asImg(24) ?> </button> </li> <li id="responsive-toggle-focusmode"> <button class="styleless consuming_mode_trigger" id="focusmode-on" title="<?= _('Vollbild aktivieren') ?>"> - <?= Icon::create('screen-full', Icon::ROLE_INFO_ALT)->asSvg(24) ?> + <?= Icon::create('screen-full', Icon::ROLE_INFO_ALT)->asImg(24) ?> </button> </li> </ul> @@ -220,7 +220,7 @@ if ($navigation) { <input type="checkbox" id="header-sink"> <label for="header-sink"> <a class="canvasready" href="#"> - <?= Icon::create('action', 'navigation')->asSvg(28, [ + <?= Icon::create('action', 'navigation')->asImg(28, [ 'class' => 'headericon original', 'title' => '', 'alt' => '', diff --git a/templates/helpbar/helpbar.php b/templates/helpbar/helpbar.php index 79d4bdf..6f8efbb 100644 --- a/templates/helpbar/helpbar.php +++ b/templates/helpbar/helpbar.php @@ -9,7 +9,7 @@ <a id="helpbar_icon" href="#" class="helpbar-toggler" data-toggles=".helpbar" role="button" title="<?= _('Hilfelasche anzeigen/verstecken') ?>" aria-controls="helpbar-content" aria-expanded="<?= $open ? 'true' : 'false' ?>"> - <?= Icon::create('question-circle')->asSvg(24, ['alt' => '']) ?> + <?= Icon::create('question-circle')->asImg(24, ['alt' => '']) ?> </a> <div class="helpbar" id="helpbar-content" <? if (!$open) echo 'style="display: none"'; ?>> @@ -18,28 +18,28 @@ <a href="#" class="helpbar-toggler" data-toggles=".helpbar" aria-hidden="true" role="button" title="<?= _('Hilfelasche verstecken') ?>" aria-controls="helpbar-content" aria-expanded="<?= $open ? 'true' : 'false' ?>"> - <?= Icon::create('decline-circle', Icon::ROLE_INFO_ALT)->asSvg(24, ['alt' => '']) ?> + <?= Icon::create('decline-circle', Icon::ROLE_INFO_ALT)->asImg(24, ['alt' => '']) ?> </a> </h2> <ul class="helpbar-widgets"> <? foreach ($widgets as $index => $widget): ?> <li> <? if ($widget->icon): ?> - <?= is_string($widget->icon) ? Assets::img($widget->icon, ['class' => 'helpbar-widget-icon']) : $widget->icon->asSvg(['class' => 'helpbar-widget-icon', 'alt' => '']) ?> + <?= is_string($widget->icon) ? Assets::img($widget->icon, ['class' => 'helpbar-widget-icon']) : $widget->icon->asImg(['class' => 'helpbar-widget-icon', 'alt' => '']) ?> <? endif; ?> <?= $widget->render(['base_class' => 'helpbar'])?> <div class="helpbar-widget-admin-icons"> <? if ($widget->edit_link): ?> <a href="<?=$widget->edit_link?>" data-dialog="size=auto;reload-on-close"> - <?= Icon::create('edit', 'info_alt')->asSvg(['title' => _('Hilfe-Text bearbeiten'), 'alt' => '']) ?></a> + <?= Icon::create('edit', 'info_alt')->asImg(['title' => _('Hilfe-Text bearbeiten'), 'alt' => '']) ?></a> <? endif; ?> <? if ($widget->delete_link): ?> <a href="<?=$widget->delete_link?>" data-dialog="size=auto;reload-on-close"> - <?= Icon::create('trash', 'info_alt')->asSvg(['title' => _('Hilfe-Text löschen'), 'alt' => '']) ?></a> + <?= Icon::create('trash', 'info_alt')->asImg(['title' => _('Hilfe-Text löschen'), 'alt' => '']) ?></a> <? endif; ?> <? if ($widget->add_link): ?> <a href="<?=$widget->add_link?>" data-dialog="size=auto;reload-on-close"> - <?= Icon::create('add', 'info_alt')->asSvg(['title' => _('Neuer Hilfe-Text'), 'alt' => '']) ?></a> + <?= Icon::create('add', 'info_alt')->asImg(['title' => _('Neuer Hilfe-Text'), 'alt' => '']) ?></a> <? endif; ?> </div> </li> diff --git a/templates/layouts/base.php b/templates/layouts/base.php index be6b0be..8ae32ce 100644 --- a/templates/layouts/base.php +++ b/templates/layouts/base.php @@ -97,7 +97,7 @@ $lang_attr = str_replace('_', '-', $_SESSION['_language']); <h1 class="sr-only"><?= htmlReady(PageLayout::getTitle()) ?></h1> <? if (PageLayout::isFullscreenModeAllowed()): ?> <button hidden class="fullscreen-toggle unfullscreen" aria-label="<?= _('Vollbildmodus verlassen') ?>" title="<?= _('Vollbildmodus verlassen') ?>"> - <?= Icon::create('zoom-out2')->asSvg(24) ?> + <?= Icon::create('zoom-out2')->asImg(24) ?> </button> <? endif; ?> <?= implode(PageLayout::getMessages(QuestionBox::class)) ?> @@ -113,7 +113,7 @@ $lang_attr = str_replace('_', '-', $_SESSION['_language']); <!-- End main content --> <a id="scroll-to-top" class="hide" tabindex="0" title="<?= _('Zurück zum Seitenanfang') ?>"> - <?= Icon::create('arr_1up', 'info_alt')->asSvg(24, ['class' => '']) ?> + <?= Icon::create('arr_1up', 'info_alt')->asImg(24, ['class' => '']) ?> </a> <?= $this->render_partial('footer', ['link_params' => $header_template->link_params ?? null]); ?> diff --git a/templates/login/_header_contrast.php b/templates/login/_header_contrast.php index d98db07..38f98c3 100644 --- a/templates/login/_header_contrast.php +++ b/templates/login/_header_contrast.php @@ -4,11 +4,11 @@ <input type="hidden" name="page" value="<?= Request::url() ?>"> <div id="contrast"> <? if (!empty($_SESSION['contrast'])): ?> - <?= Icon::create('accessibility', Icon::ROLE_INFO_ALT)->asSvg(24) ?> + <?= Icon::create('accessibility', Icon::ROLE_INFO_ALT)->asImg(24) ?> <button class="as-link" name="unset_contrast"><?= _('Normalen Kontrast aktivieren') ?></button> <?= tooltipIcon(_('Aktiviert standardmäßige, nicht barrierefreie Kontraste.'), false, false, true); ?> <? else: ?> - <?= Icon::create('accessibility', Icon::ROLE_INFO_ALT)->asSvg(24) ?> + <?= Icon::create('accessibility', Icon::ROLE_INFO_ALT)->asImg(24) ?> <button class="as-link" name="set_contrast"><?= _('Hohen Kontrast aktivieren') ?></button> <?= tooltipIcon(_('Aktiviert einen hohen Kontrast gemäß WCAG 2.1. Diese Einstellung wird nach dem Login übernommen. Sie können sie in Ihren persönlichen Einstellungen ändern.'), false, false, true); ?> diff --git a/templates/mail/notification_html.php b/templates/mail/notification_html.php index 2325ca0..81a38f3 100644 --- a/templates/mail/notification_html.php +++ b/templates/mail/notification_html.php @@ -154,7 +154,7 @@ <a href="<?= URLHelper::getLink($module['url'], ['sso' => $sso]) ?>"><?= htmlReady($module['text']) ?></a> </td> <td> - <a href="<?= URLHelper::getLink($module['url'], ['sso' => $sso]) ?>"><?= $module['icon']->asSvg(['title' => $module['text']]) ?></a> + <a href="<?= URLHelper::getLink($module['url'], ['sso' => $sso]) ?>"><?= $module['icon']->asImg(['title' => $module['text']]) ?></a> </td> </tr> <? endforeach ?> diff --git a/templates/multipersonsearch/link.php b/templates/multipersonsearch/link.php index 446c30d..daed91a 100644 --- a/templates/multipersonsearch/link.php +++ b/templates/multipersonsearch/link.php @@ -1,7 +1,7 @@ <a href="<?= URLHelper::getLink('dispatch.php/multipersonsearch/no_js_form/?name=' . $name); ?>" class="multi_person_search_link" data-dialog="width=720;height=490;id=mp-search" data-dialogname="<?= $name; ?>" title="<?= htmlReady($title) ?>" data-js-form="<?= URLHelper::getLink('dispatch.php/multipersonsearch/js_form/' . $name); ?>"> <? if (!empty($linkIconPath)) { - print $linkIconPath->asSvg(20, ['class' => 'action-menu-item-icon']); + print $linkIconPath->asImg(['class' => 'action-menu-item-icon']); } if (!empty($linkIconPath) && !empty($linkText)) { print " "; diff --git a/templates/online/user.php b/templates/online/user.php index 2bba643..89a63ed 100644 --- a/templates/online/user.php +++ b/templates/online/user.php @@ -7,7 +7,7 @@ <? if (!$is_buddy) : ?> <a href="<?= URLHelper::getLink('online.php', ['cmd' => 'add_user', 'add_uname' => $tmp_online_uname]) ?>"> - <?= Icon::create('arr_2left', Icon::ROLE_SORT)->asSvg([ + <?= Icon::create('arr_2left', Icon::ROLE_SORT)->asImg([ 'title' => _('zu den Buddies hinzufügen'), 'style' => 'padding-right: 0.33em;', 'class' => 'middle', @@ -29,7 +29,7 @@ <?= htmlReady($fullname) ?> </a> <? foreach (StudipKing::is_king($tmp_user_id, TRUE) as $type => $text) : ?> - <?= Icon::create('crown', Icon::ROLE_SORT)->asSvg(['title' => $text, 'class' => 'text-bottom']) ?> + <?= Icon::create('crown', Icon::ROLE_SORT)->asImg(['title' => $text, 'class' => 'text-bottom']) ?> <? endforeach ?> </td> @@ -40,14 +40,14 @@ <td width="3%" align="center"> <? if (class_exists('Blubber')) : ?> <a href="<?= URLHelper::getLink('dispatch.php/course/streams/global', ['mention' => $tmp_online_uname]) ?>"> - <?= Icon::create('blubber')->asSvg(['title' => _('Blubber diesen Nutzer an'), 'class' => 'text-bottom']) ?> + <?= Icon::create('blubber')->asImg(['title' => _('Blubber diesen Nutzer an'), 'class' => 'text-bottom']) ?> </a> <? endif ?> </td> <td width="3%" align="center"> <a href="<?= URLHelper::getLink('dispatch.php/messages/write', ['rec_uname' => $tmp_online_uname]) ?>"> - <?= Icon::create('mail')->asSvg(['title' => _('Nachricht an Benutzer verschicken'), 'class' => 'text-bottom']) ?> + <?= Icon::create('mail')->asImg(['title' => _('Nachricht an Benutzer verschicken'), 'class' => 'text-bottom']) ?> </a> </td> @@ -56,7 +56,7 @@ <a href="<?= URLHelper::getLink('online.php', ['cmd' => 'delete_user', 'delete_uname' => $tmp_online_uname]) ?>"> - <?= Icon::create('trash')->asSvg(['title' => _('aus der Buddy-Liste entfernen'), 'class' => 'text-bottom']) ?> + <?= Icon::create('trash')->asImg(['title' => _('aus der Buddy-Liste entfernen'), 'class' => 'text-bottom']) ?> </a> <? else : ?> diff --git a/templates/personal_notifications/notification.php b/templates/personal_notifications/notification.php index 20f1f9d..974823e 100644 --- a/templates/personal_notifications/notification.php +++ b/templates/personal_notifications/notification.php @@ -14,7 +14,7 @@ <?= htmlReady($notification['text']) ?> </a> <button class="options mark_as_read"> - <?= Icon::create('decline')->asSvg(16, ['title' => _('Als gelesen markieren')]) ?> + <?= Icon::create('decline')->asImg(16, ['title' => _('Als gelesen markieren')]) ?> </button> </div> <? if ($notification->more_unseen > 0): ?> diff --git a/templates/shared/action-menu-single.php b/templates/shared/action-menu-single.php index 9fdd5d3..dbe38c1 100644 --- a/templates/shared/action-menu-single.php +++ b/templates/shared/action-menu-single.php @@ -15,7 +15,7 @@ <? if ($action['disabled']): ?> <label class="undecorated action-menu-item-disabled" aria-disabled="true" <?= arrayToHtmlAttributes($action['attributes'] + ['title' => $action['label']]) ?>> <? if ($action['icon']): ?> - <?= $action['icon']->asSvg(['class' => 'action-menu-item-icon']) ?> + <?= $action['icon']->asImg(['class' => 'action-menu-item-icon']) ?> <? else: ?> <?= htmlReady($action['label']) ?> <? endif ?> @@ -23,7 +23,7 @@ <? elseif ($action['type'] === 'link'): ?> <a href="<?= htmlReady($action['link']) ?>" <?= arrayToHtmlAttributes($action['attributes'] + ['title' => $action['label']]) ?>> <? if ($action['icon']): ?> - <?= $action['icon']->asSvg(['class' => 'action-menu-item-icon']) ?> + <?= $action['icon']->asImg(['class' => 'action-menu-item-icon']) ?> <? else: ?> <?= htmlReady($action['label']) ?> <? endif ?> diff --git a/templates/shared/action-menu.php b/templates/shared/action-menu.php index 0119e40..5b105b2 100644 --- a/templates/shared/action-menu.php +++ b/templates/shared/action-menu.php @@ -37,7 +37,7 @@ <? if ($action['disabled']): ?> <label class="undecorated" aria-disabled="true" <?= arrayToHtmlAttributes($action['attributes']) ?>> <? if ($action['icon']): ?> - <?= $action['icon']->asSvg(false, ['class' => 'action-menu-item-icon']) ?> + <?= $action['icon']->asImg(false, ['class' => 'action-menu-item-icon']) ?> <? else: ?> <span class="action-menu-no-icon"></span> <? endif ?> @@ -47,7 +47,7 @@ <? elseif ($action['type'] === 'link'): ?> <a href="<?= htmlReady($action['link']) ?>" <?= arrayToHtmlAttributes($action['attributes']) ?>> <? if ($action['icon']): ?> - <?= $action['icon']->asSvg(false, ['class' => 'action-menu-item-icon']) ?> + <?= $action['icon']->asImg(false, ['class' => 'action-menu-item-icon']) ?> <? else: ?> <span class="action-menu-no-icon"></span> <? endif ?> diff --git a/templates/shared/content_box.php b/templates/shared/content_box.php index 2c5b0f0..c31f467 100644 --- a/templates/shared/content_box.php +++ b/templates/shared/content_box.php @@ -11,7 +11,7 @@ <? if (isset($admin_url)): ?> <nav> <a href="<?= URLHelper::getLink($admin_url) ?>" title="<?= htmlReady($admin_title) ?>"> - <?= Icon::create('admin')->asSvg(tooltip2(htmlReady($admin_title))) ?> + <?= Icon::create('admin')->asImg(tooltip2(htmlReady($admin_title))) ?> </a> </nav> <? endif; ?> diff --git a/templates/shared/index_box.php b/templates/shared/index_box.php index 98ef9c5..92170f4f 100644 --- a/templates/shared/index_box.php +++ b/templates/shared/index_box.php @@ -20,7 +20,7 @@ <td class="table_header_bold" style="text-align: right;"> <? if (isset($admin_url)): ?> <a href="<?= URLHelper::getLink($admin_url) ?>" title="<?= htmlReady($admin_title ?? _('Administration')) ?>"> - <?= Icon::create('admin', Icon::ROLE_INFO_ALT)->asSvg([ + <?= Icon::create('admin', Icon::ROLE_INFO_ALT)->asImg([ 'alt' => $admin_title ?? _('Administration'), ]) ?> </a> diff --git a/templates/sidebar/resource-tree-widget.php b/templates/sidebar/resource-tree-widget.php index e20ee41..890971b 100644 --- a/templates/sidebar/resource-tree-widget.php +++ b/templates/sidebar/resource-tree-widget.php @@ -21,7 +21,7 @@ <? if ($resource_path && !in_array($resource->id, $resource_path)): ?> <a href="<?= $link ?>"> <? endif; ?> - <?= Icon::create('arr_1right')->asSvg([ + <?= Icon::create('arr_1right')->asImg([ 'class' => in_array($resource->id, $resource_path) || (!$resource_path && $resource->level < $max_open_depth) ? 'rotated' : '', @@ -42,7 +42,7 @@ <?= $selected ? 'class="selected-resource"' : '' ?>> - <?= $resource->getIcon($selected ? Icon::ROLE_INFO_ALT : Icon::ROLE_CLICKABLE)->asSvg([ + <?= $resource->getIcon($selected ? Icon::ROLE_INFO_ALT : Icon::ROLE_CLICKABLE)->asImg([ 'class' => 'text-bottom' ]) ?> <?= htmlReady($resource->name) ?> diff --git a/templates/sidebar/room-clipboard-item.php b/templates/sidebar/room-clipboard-item.php index 40b5146..45633a0 100644 --- a/templates/sidebar/room-clipboard-item.php +++ b/templates/sidebar/room-clipboard-item.php @@ -33,13 +33,13 @@ if (!$item) { <td class="item-name"><?= htmlReady($item['name'] ?? '') ?></td> <td class="actions"> <a href="<?= Room::getLinkForAction('show', (!empty($item) ? $item['range_id'] : 'RANGE_ID')) ?>" data-dialog> - <?= Icon::create('info-circle')->asSvg([ + <?= Icon::create('info-circle')->asImg([ 'title' => _('Rauminformationen'), 'class' => 'text-bottom' ])?> </a> <a href="<?= Room::getLinkForAction('semester_plan', (!empty($item) ? $item['range_id'] : 'RANGE_ID')) ?>" target="_blank"> - <?= Icon::create('timetable')->asSvg([ + <?= Icon::create('timetable')->asImg([ 'title' => _('Semesterbelegung'), 'class' => 'text-bottom' ])?> diff --git a/templates/sidebar/room-search-criteria-templates.php b/templates/sidebar/room-search-criteria-templates.php index 09e980b..d084fa4 100644 --- a/templates/sidebar/room-search-criteria-templates.php +++ b/templates/sidebar/room-search-criteria-templates.php @@ -16,7 +16,7 @@ </label> </li> <li class="template invisible" data-template-type="range"> - <?= Icon::create('trash')->asSvg( + <?= Icon::create('trash')->asImg( [ 'class' => 'text-bottom remove-icon', 'aria-label' => _('Kriterium entfernen'), @@ -38,7 +38,7 @@ </label> </li> <li class="template invisible" data-template-type="num"> - <?= Icon::create('trash')->asSvg( + <?= Icon::create('trash')->asImg( [ 'class' => 'text-bottom remove-icon', 'aria-label' => _('Kriterium entfernen'), @@ -51,7 +51,7 @@ </label> </li> <li class="template invisible" data-template-type="select"> - <?= Icon::create('trash')->asSvg(['class' => 'text-bottom remove-icon']) ?> + <?= Icon::create('trash')->asImg(['class' => 'text-bottom remove-icon']) ?> <label class="undecorated"> <span></span> <select class="room-search-widget_criteria-list_input"> @@ -60,7 +60,7 @@ </li> <li class="template invisible" data-template-type="other"> - <?= Icon::create('trash')->asSvg( + <?= Icon::create('trash')->asImg( [ 'class' => 'text-bottom remove-icon', 'aria-label' => _('Kriterium entfernen'), diff --git a/templates/sidebar/room-search-tree-widget.php b/templates/sidebar/room-search-tree-widget.php index 13bd204..008b1bc 100644 --- a/templates/sidebar/room-search-tree-widget.php +++ b/templates/sidebar/room-search-tree-widget.php @@ -8,7 +8,7 @@ <li <?= ((!$resource_path && $resource->level > $max_open_depth) || $hide) ? 'style="display: none;"' : ''; ?> > <? if (count($resource->children)): ?> - <?= Icon::create('arr_1right')->asSvg( + <?= Icon::create('arr_1right')->asImg( [ 'class' => implode( ' ', @@ -38,7 +38,7 @@ <? endif ?> <span id="<?= $search_object; ?>" style="cursor: pointer;"> - <?= $resource->getIcon()->asSvg( + <?= $resource->getIcon()->asImg( [ 'class' => 'text-bottom' ] diff --git a/templates/start/contents.php b/templates/start/contents.php index c0bbcc6..bb5697f 100644 --- a/templates/start/contents.php +++ b/templates/start/contents.php @@ -6,7 +6,7 @@ <a href="<?= URLHelper::getLink($navigation->getURL()) ?>" class="content-item-link"> <div class="content-item-img-wrapper"> <? if ($navigation->getImage()): ?> - <?= $navigation->getImage()->asSvg(32, $navigation->getLinkAttributes()) ?> + <?= $navigation->getImage()->asImg(32, $navigation->getLinkAttributes()) ?> <? endif ?> </div> <div class="content-item-text"> diff --git a/templates/tabs.php b/templates/tabs.php index ae1f409..b53dbf8 100644 --- a/templates/tabs.php +++ b/templates/tabs.php @@ -23,14 +23,14 @@ foreach (Navigation::getItem("/")->getSubNavigation() as $path => $nav) { ?> <a href="<?= URLHelper::getLink($nav->getURL()) ?>" <?= arrayToHtmlAttributes($attr) ?>> <? if ($image = $nav->getImage()) : ?> - <?= $image->asSvg(['class' => "tab-icon", 'title' => $nav->getTitle() ? $nav->getTitle() : $nav->getDescription()]) ?> + <?= $image->asImg(['class' => "tab-icon", 'title' => $nav->getTitle() ? $nav->getTitle() : $nav->getDescription()]) ?> <? endif ?> <span title="<?= $nav->getDescription() ? htmlReady($nav->getDescription()) : htmlReady($nav->getTitle())?>" class="tab-title"><?= htmlReady($nav->getTitle()) ?></span> </a> <? else: ?> <span class="quiet tab-title"> <? if ($image = $nav->getImage()) : ?> - <?= $image->asSvg(['class' => "tab-icon", 'title' => $nav->getTitle()]) ?> + <?= $image->asImg(['class' => "tab-icon", 'title' => $nav->getTitle()]) ?> <? endif ?> <?= htmlReady($nav->getTitle()) ?> </span> @@ -47,7 +47,7 @@ foreach (Navigation::getItem("/")->getSubNavigation() as $path => $nav) { <div id="non-responsive-toggle-fullscreen"> <button class="as-link" id="fullscreen-on" title="<?= _('Kompakte Navigation aktivieren') ?>"> - <?= Icon::create('screen-compact')->asSvg(24) ?> + <?= Icon::create('screen-compact')->asImg(24) ?> </button> </div> <? endif ?> diff --git a/templates/toc/_toc-item-list.php b/templates/toc/_toc-item-list.php index 82cad85..3e2ee0d 100644 --- a/templates/toc/_toc-item-list.php +++ b/templates/toc/_toc-item-list.php @@ -4,7 +4,7 @@ <a class="navigate" href="<?= htmlReady($item->getURL()) ?>"> <? endif ?> <? if ($item->getIcon()) : ?> - <?= $item->getIcon()->copyWithRole(Icon::ROLE_INFO)->asSvg(24) ?> + <?= $item->getIcon()->copyWithRole(Icon::ROLE_INFO)->asImg(24) ?> <? endif ?> <?= htmlReady($item->getTitle()) ?> <? if (!$item->isActive()) : ?> diff --git a/templates/toc/generic-toc-list.php b/templates/toc/generic-toc-list.php index 0894e5f..475ceaa 100644 --- a/templates/toc/generic-toc-list.php +++ b/templates/toc/generic-toc-list.php @@ -3,7 +3,7 @@ <header id="toc_header"> <h1 id="toc_h1"><?= sprintf(_('Inhalt (%u Elemente)'), htmlReady($root->countAllChildren())) ?></h1> <label for="cb-toc" class="check-box enter-accessible" title="<?= _('Schließen')?>" tabindex="0"> - <?= Icon::create('decline')->asSvg(24) ?> + <?= Icon::create('decline')->asImg(24) ?> </label> </header> <section> diff --git a/templates/userfilter/display.php b/templates/userfilter/display.php index 2aba04f..189f6cd 100644 --- a/templates/userfilter/display.php +++ b/templates/userfilter/display.php @@ -17,7 +17,7 @@ if ($filter->show_user_count) { $fieldText .= ' (' . sprintf(ngettext('Eine Person', '%s Personen', $user_count), $user_count); if ($user_count === 0) { $fieldText .= ' ' . Icon::create('exclaim-circle', Icon::ROLE_ATTENTION) - ->asSvg(['title' => _('Niemand erfüllt diese Bedingung.')]); + ->asImg(['title' => _('Niemand erfüllt diese Bedingung.')]); } $fieldText .= ')'; } |
