Skip to content

Commit

Permalink
feat(widgets): Add Bootstrap 5 sr-only equiv
Browse files Browse the repository at this point in the history
  • Loading branch information
zooley committed Apr 2, 2024
1 parent b508fc8 commit ddba270
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 12 deletions.
12 changes: 6 additions & 6 deletions app/Widgets/Coffeehours/views/index.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@
$events[] = $slot;
?>
<section id="coffee{{ $event->id }}" class="dialog dialog-event" title="{{ $event->headline }}" aria-labelledby="coffee{{ $event->id }}-title">
<h3 id="coffee{{ $event->id }}-title" class="sr-only"><span class="sr-only">Article #{{ $event->id }}:</span> {{ $event->headline }}</h3>
<h3 id="coffee{{ $event->id }}-title" class="sr-only visually-hidden"><span class="sr-only visually-hidden">Article #{{ $event->id }}:</span> {{ $event->headline }}</h3>

<ul class="news-meta text-muted">
<li>
Expand Down Expand Up @@ -160,12 +160,12 @@
<li>
<span class="fa fa-fw fa-calendar" aria-hidden="true"></span>
<a target="_blank" class="calendar calendar-subscribe" href="{{ $event->subscribeCalendarLink }}"><!--
-->Subscribe<span class="sr-only"> to event #{{ $event->id }} at {!! $event->formatDate($event->datetimenews, $event->datetimenewsend) !!}</span><!--
-->Subscribe<span class="sr-only visually-hidden"> to event #{{ $event->id }} at {!! $event->formatDate($event->datetimenews, $event->datetimenewsend) !!}</span><!--
--></a>
&nbsp;|&nbsp;
<span class="fa fa-fw fa-download" aria-hidden="true"></span>
<a target="_blank" class="calendar calendar-download" href="{{ $event->downloadCalendarLink }}"><!--
-->Download<span class="sr-only"> event #{{ $event->id }} at {!! $event->formatDate($event->datetimenews, $event->datetimenewsend) !!}</span><!--
-->Download<span class="sr-only visually-hidden"> event #{{ $event->id }} at {!! $event->formatDate($event->datetimenews, $event->datetimenewsend) !!}</span><!--
--></a>
</li>
<?php
Expand All @@ -180,7 +180,7 @@
@endif
@endif

<div class="sr-only">{!! $event->toHtml() !!}</div>
<div class="sr-only visually-hidden">{!! $event->toHtml() !!}</div>

<div class="dialog-footer newsattend">

Expand Down Expand Up @@ -286,11 +286,11 @@
<div class="col-md-6 text-right">
<a class="edit tip" href="{{ route('site.news.manage', ['id' => $event->id]) }}&edit" title="{{ trans('global.edit') }}"><!--
--><span class="fa fa-fw fa-pencil" aria-hidden="true"></span><!--
--><span class="sr-only">{{ trans('global.button.edit') }}</span><!--
--><span class="sr-only visually-hidden">{{ trans('global.button.edit') }}</span><!--
--></a>
<a href="#coffee{{ $event->id }}" class="delete-news tip text-danger ml-3" data-confirm="Are you sure you want to delete this event?" data-api="{{ route('api.news.delete', ['id' => $event->id]) }}" title="{{ trans('global.button.delete') }}"><!--
--><span class="fa fa-fw fa-trash" aria-hidden="true"></span><!--
--><span class="sr-only">{{ trans('global.button.delete') }}</span><!--
--><span class="sr-only visually-hidden">{{ trans('global.button.delete') }}</span><!--
--></a>
</div>
</div>
Expand Down
4 changes: 2 additions & 2 deletions app/Widgets/Gallery/views/carousel.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@
</div>
<button class="btn carousel-control-prev" type="button" data-target="#wdgt-{{ $widget->id }}-carousel" data-slide="prev">
<span class="carousel-control-prev-icon" aria-hidden="true"></span>
<span class="sr-only">Previous</span>
<span class="sr-only visually-hidden">Previous</span>
</button>
<button class="btn carousel-control-next" type="button" data-target="#wdgt-{{ $widget->id }}-carousel" data-slide="next">
<span class="carousel-control-next-icon" aria-hidden="true"></span>
<span class="sr-only">Next</span>
<span class="sr-only visually-hidden">Next</span>
</button>
</div>
2 changes: 1 addition & 1 deletion app/Widgets/Gallery/views/list.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<div class="media-files media-list" id="media-list">
<div class="media-list">
<table class="table">
<caption class="sr-only">{{ trans('media::media.files') }}</caption>
<caption class="sr-only visually-hidden">{{ trans('media::media.files') }}</caption>
<thead>
<tr>
<th scope="col">{{ trans('media::media.list.name') }}</th>
Expand Down
2 changes: 1 addition & 1 deletion app/Widgets/Groups/views/index.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
@endif

<table class="table table-hover">
<caption class="sr-only">{{ trans('widget.groups::groups.recent') }}</caption>
<caption class="sr-only visually-hidden">{{ trans('widget.groups::groups.recent') }}</caption>
<thead>
<tr>
<th scope="col">{{ trans('widget.groups::groups.name') }}</th>
Expand Down
2 changes: 1 addition & 1 deletion app/Widgets/Productlist/lang/en/productlist.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// Misc.
'hidden' => 'HIDDEN',
'login to see pricing' => 'Login to see pricing options.',
'purchase now' => 'Purchase <span class="sr-only">:name </span>Now</a>',
'purchase now' => 'Purchase <span class="sr-only visually-hidden">:name </span>Now</a>',
'no articles found' => 'No articles found.',
'params' => [
'category desc' => 'Select Articles from a specific Category. If no selection, it will show all categories by default.',
Expand Down
2 changes: 1 addition & 1 deletion app/Widgets/UserList/lang/en/userlist.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
'staff directory' => 'Staff Directory',
'email' => 'Email',
'users profile photo' => ':name\'s Profile Photo',
'full profile for' => 'Full profile <span class="sr-only">for :name</span>',
'full profile for' => 'Full profile <span class="sr-only visually-hidden">for :name</span>',
// Misc.
'no articles found' => 'No articles found.',
'params' => [
Expand Down

0 comments on commit ddba270

Please sign in to comment.