Skip to content
Snippets Groups Projects
Commit 13ff3d95 authored by Viola Elsenhans's avatar Viola Elsenhans Committed by Mathias Maaß
Browse files

refs #24014 [finc] unification of items in menu.phtml

parent ce95baab
Branches
Tags
No related merge requests found
...@@ -283,6 +283,8 @@ ...@@ -283,6 +283,8 @@
// and in newer myaccount menu items // and in newer myaccount menu items
.badge { .badge {
font-size: $sidebar-facet-badge-font-size; font-size: $sidebar-facet-badge-font-size;
// use same height for all badges
height: 20px;
// remove right padding to align with accordion arrows // remove right padding to align with accordion arrows
padding-right: $sidebar-facet-badge-padding-right; padding-right: $sidebar-facet-badge-padding-right;
......
...@@ -43,6 +43,7 @@ ...@@ -43,6 +43,7 @@
<?php /* finc needs to add .facet-group class and classes on sub items for borders - CK */ ?> <?php /* finc needs to add .facet-group class and classes on sub items for borders - CK */ ?>
<?php /* finc: myresearch menu as list #19734 and wraps it in '<nav>' container, CK */ ?> <?php /* finc: myresearch menu as list #19734 and wraps it in '<nav>' container, CK */ ?>
<?php /* finc: specify current page menu entry in following elements #19941 */ ?> <?php /* finc: specify current page menu entry in following elements #19941 */ ?>
<?php /* finc: use <span class="flex-col"> around all <i> and class "flex" for all <a> #24014 */ ?>
<nav class="myresearch-menu"> <nav class="myresearch-menu">
<ul class="account-menu facet-group"> <ul class="account-menu facet-group">
<?php if ($ilsOnline && $this->ils()->checkCapability('getMyTransactions', $capabilityParams)): ?> <?php if ($ilsOnline && $this->ils()->checkCapability('getMyTransactions', $capabilityParams)): ?>
...@@ -58,7 +59,7 @@ ...@@ -58,7 +59,7 @@
<?php /* finc: adds media ready to pickup */ ?> <?php /* finc: adds media ready to pickup */ ?>
<?php if ($ilsOnline && $this->ils()->checkCapability('getMyMediaReadyToPickup', $capabilityParams) && $routeExists('myresearch-mediareadytopickup')): ?> <?php if ($ilsOnline && $this->ils()->checkCapability('getMyMediaReadyToPickup', $capabilityParams) && $routeExists('myresearch-mediareadytopickup')): ?>
<li class="facet"> <li class="facet">
<a href="<?=$this->url('myresearch-mediareadytopickup')?>" class="flex <?=$this->active == 'mediareadytopickup' ? ' active' : ''?>" <a href="<?=$this->url('myresearch-mediareadytopickup')?>" class="flex<?=$this->active == 'mediareadytopickup' ? ' active' : ''?>"
<?=$this->active == 'mediareadytopickup' ? ' aria-current="page"' : ''?> <?=$this->active == 'mediareadytopickup' ? ' aria-current="page"' : ''?>
> >
<span class="flex-col"><i class="fa fa-fw fa-book" aria-hidden="true"></i>&nbsp;<?=$this->transEsc('Ready For Collection')?></span> <span class="flex-col"><i class="fa fa-fw fa-book" aria-hidden="true"></i>&nbsp;<?=$this->transEsc('Ready For Collection')?></span>
...@@ -69,7 +70,7 @@ ...@@ -69,7 +70,7 @@
<?php /* finc: adds permanent loans */ ?> <?php /* finc: adds permanent loans */ ?>
<?php if ($ilsOnline && $this->ils()->checkCapability('getMyPermanentLoans', $capabilityParams) && $routeExists('myresearch-permanentloans')): ?> <?php if ($ilsOnline && $this->ils()->checkCapability('getMyPermanentLoans', $capabilityParams) && $routeExists('myresearch-permanentloans')): ?>
<li class="facet"> <li class="facet">
<a href="<?=$this->url('myresearch-permanentloans')?>" class="flex <?=$this->active == 'permanentloans' ? ' active' : ''?>" <a href="<?=$this->url('myresearch-permanentloans')?>" class="flex<?=$this->active == 'permanentloans' ? ' active' : ''?>"
<?=$this->active == 'permanent' ? ' aria-current="page"' : ''?> <?=$this->active == 'permanent' ? ' aria-current="page"' : ''?>
> >
<span class="flex-col"><i class="fa fa-fw fa-book" aria-hidden="true"></i>&nbsp;<?=$this->transEsc('Permanent Checked Out Items')?></span> <span class="flex-col"><i class="fa fa-fw fa-book" aria-hidden="true"></i>&nbsp;<?=$this->transEsc('Permanent Checked Out Items')?></span>
...@@ -131,15 +132,19 @@ ...@@ -131,15 +132,19 @@
<?php endif; ?> <?php endif; ?>
<?php if ($this->overdrive()->showMyContentLink()):?> <?php if ($this->overdrive()->showMyContentLink()):?>
<li class="facet"> <li class="facet">
<a href="<?=$this->url('overdrive-mycontent')?>"<?=$this->active == 'dgcontent' ? ' class="active"' : ''?>> <a href="<?=$this->url('overdrive-mycontent')?>" class="flex<?=$this->active == 'dgcontent' ? ' active' : ''?>"
<i class="fa fa-fw fa-download" aria-hidden="true"></i> <?=$this->transEsc('Overdrive Content')?> <?=$this->active == 'dgcontent' ? ' aria-current="page"' : ''?>
>
<span class="flex-col"><i class="fa fa-fw fa-download" aria-hidden="true"></i> <?=$this->transEsc('Overdrive Content')?></span>
</a> </a>
</li> </li>
<?php endif; ?> <?php endif; ?>
<?php if ($this->accountCapabilities()->getSavedSearchSetting() === 'enabled'): ?> <?php if ($this->accountCapabilities()->getSavedSearchSetting() === 'enabled'): ?>
<li class="facet"> <li class="facet">
<a href="<?=$this->url('search-history')?>?require_login"<?=$this->active == 'history' ? ' class="active" aria-current="page"' : ''?>> <a href="<?=$this->url('search-history')?>?require_login" class="flex<?=$this->active == 'history' ? ' active' : ''?>"
<i class="fa fa-fw fa-search" aria-hidden="true"></i> <?=$this->transEsc('history_saved_searches')?> <?=$this->active == 'history' ? ' aria-current="page"' : ''?>
>
<span class="flex-col"><i class="fa fa-fw fa-search" aria-hidden="true"></i> <?=$this->transEsc('history_saved_searches')?></span>
</a> </a>
</li> </li>
<?php endif; ?> <?php endif; ?>
...@@ -152,27 +157,33 @@ ...@@ -152,27 +157,33 @@
<nav class="myresearch-menu"> <nav class="myresearch-menu">
<ul class="account-menu facet-group"> <ul class="account-menu facet-group">
<li class="facet"> <li class="facet">
<a href="<?=$this->url('myresearch-profile')?>"<?=$this->active == 'profile' ? ' class="active" aria-current="page"' : ''?>> <a href="<?=$this->url('myresearch-profile')?>" class="flex<?=$this->active == 'profile' ? ' active' : ''?>"
<i class="fa fa-fw fa-user" aria-hidden="true"></i> <?=$this->transEsc('Profile')?> <?=$this->active == 'profile' ? ' aria-current="page"' : ''?>
>
<span class="flex-col"><i class="fa fa-fw fa-user" aria-hidden="true"></i> <?=$this->transEsc('Profile')?></span>
</a> </a>
</li> </li>
<?php if ($this->auth()->getManager()->supportsPasswordChange() && $routeExists('myresearch-changepassword')): ?> <?php if ($this->auth()->getManager()->supportsPasswordChange() && $routeExists('myresearch-changepassword')): ?>
<li class="facet"> <li class="facet">
<a href="<?=$this->url('myresearch-changepassword')?>" class="text<?=$this->active == 'newpassword' ? ' active' : ''?>"> <a href="<?=$this->url('myresearch-changepassword')?>" class="flex<?=$this->active == 'newpassword' ? ' active' : ''?>"
<i class="fa fa-fw fa-lock" aria-hidden="true"></i> <?=$this->transEsc('Change Password')?> <?=$this->active == 'newpassword' ? ' aria-current="page"' : ''?>
>
<span class="flex-col"><i class="fa fa-fw fa-lock" aria-hidden="true"></i> <?=$this->transEsc('Change Password')?></span>
</a> </a>
</li> </li>
<?php endif; ?> <?php endif; ?>
<?php if ($this->ils()->checkCapability('changeUserPin') && $routeExists('myresearch-setpin')): ?> <?php if ($this->ils()->checkCapability('changeUserPin') && $routeExists('myresearch-setpin')): ?>
<li class="facet"> <li class="facet">
<a href="<?=$this->url('myresearch-setpin')?>" class="text<?=$this->active == 'setpin' ? ' active' : ''?>"> <a href="<?=$this->url('myresearch-setpin')?>" class="flex<?=$this->active == 'setpin' ? ' active' : ''?>"
<i class="fa fa-fw fa-key" aria-hidden="true"></i> <?=$this->transEsc('LiberoAccount::change_user_pin')?> <?=$this->active == 'setpin' ? ' aria-current="page"' : ''?>
>
<span class="flex-col"><i class="fa fa-fw fa-key" aria-hidden="true"></i> <?=$this->transEsc('LiberoAccount::change_user_pin')?></span>
</a> </a>
</li> </li>
<?php endif; ?> <?php endif; ?>
<li class="facet"> <li class="facet">
<a href="<?=$this->url('myresearch-logout')?>" class="text action"> <a href="<?=$this->url('myresearch-logout')?>" class="action flex">
<i class="fa fa-fw fa-sign-out" aria-hidden="true"></i> <?=$this->transEsc("Log Out")?> <span class="flex-col"><i class="fa fa-fw fa-sign-out" aria-hidden="true"></i> <?=$this->transEsc("Log Out")?></span>
</a> </a>
</li> </li>
</ul> </ul>
...@@ -187,27 +198,30 @@ ...@@ -187,27 +198,30 @@
<ul class="facet-group"> <ul class="facet-group">
<li class="facet"> <li class="facet">
<?php /* finc adds aria-current */ ?> <?php /* finc adds aria-current */ ?>
<a href="<?=$this->url('myresearch-favorites')?>"<?=$this->active == 'favorites' ? ' class="active"' : ''?> <a href="<?=$this->url('myresearch-favorites')?>" class="flex <?=$this->active == 'favorites' ? ' active' : ''?>"
<?=$this->active == 'favorites' ? ' aria-current="page"' : ''?> <?=$this->active == 'favorites' ? ' aria-current="page"' : ''?>
> >
<i class="fa fa-fw fa-star" aria-hidden="true"></i> <?=$this->transEsc('Your Favorites')?> <span class="flex-col"><i class="fa fa-fw fa-star" aria-hidden="true"></i> <?=$this->transEsc('Your Favorites')?></span>
</a> </a>
</li> </li>
<?php $lists = $user->getLists() ?> <?php $lists = $user->getLists() ?>
<?php foreach ($lists as $list): ?> <?php foreach ($lists as $list): ?>
<li class="facet"> <li class="facet">
<a href="<?=$this->url('userList', ['id' => $list['id']])?>"<?=$this->active == 'list' . $list['id'] ? ' class="active"' : ''?> <a href="<?=$this->url('userList', ['id' => $list['id']])?>" class="flex<?=$this->active == 'list' . $list['id'] ? ' active' : ''?>"
<?=$this->active == 'list' . $list['id'] ? ' aria-current="page"' : ''?> <?=$this->active == 'list' . $list['id'] ? ' aria-current="page"' : ''?>
> >
<?=$this->escapeHtml($list['title'])?> <?php /* finc: add fa-star for all lists */ ?>
<?php /* adds '.lists' class to favorites badges for correct styling */ ?> <span class="flex-col"><i class="fa fa-fw fa-star" aria-hidden="true"></i> <?=$this->escapeHtml($list['title'])?></span>
<?php /* finc: adds '.lists' class to favorites badges for correct styling */ ?>
<span class="badge lists"><?=$list->cnt ?></span> <span class="badge lists"><?=$list->cnt ?></span>
</a> </a>
</li> </li>
<?php endforeach; ?> <?php endforeach; ?>
<li class="facet"> <li class="facet">
<a href="<?=$this->url('editList', ['id' => 'NEW'])?>" <?=$this->active == 'editlist/NEW' ? ' aria-current="page"' : ''?>> <a href="<?=$this->url('editList', ['id' => 'NEW'])?>" class="flex<?=$this->active == 'editlist/NEW' ? ' active' : ''?>"
<i class="fa fa-fw fa-plus" aria-hidden="true"></i> <?=$this->transEsc('Create a List') ?> <?=$this->active == 'editlist/NEW' ? ' aria-current="page"' : ''?>
>
<span class="flex-col"><i class="fa fa-fw fa-plus" aria-hidden="true"></i> <?=$this->transEsc('Create a List') ?></span>
</a> </a>
</li> </li>
</ul> </ul>
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment