Commit f4506811 authored by Evonne's avatar Evonne Committed by Robert Lyon
Browse files

Bug 1857401 Consolidating list-group outer-links in theme



Taking out a bunch of outer-links when there are secondary inner-links
within. Aligned the format of attachment files so that they are
consistent.

behatnotneeded

Change-Id: Iaa35a3ac41cbf738ecd94288bec05fe2e597a0b0
Signed-off-by: default avatarEvonne <evonne@catalyst.net.nz>
parent 92229b13
......@@ -39,19 +39,20 @@
displayiconsonly=true}
{/if}
<div class="list-group-item">
<a class="outer-link collapsed" data-toggle="collapse" href="#recent_post_{$post->id}" aria-expanded="false">
<span class="sr-only">{$post->title}</span>
</a>
<h4 class="list-group-item-heading">
{if !($editing)}
<a class="modal_link inner-link text-left" data-toggle="modal-docked" data-target="#configureblock" href="#" data-blockid="{$blockid}" data-artefactid="{$post->id}">
<a class="modal_link text-left" data-toggle="modal-docked" data-target="#configureblock" href="#" data-blockid="{$blockid}" data-artefactid="{$post->id}">
{$post->title}
</a>
{else}
<span class="list-group-item-heading no-link">{$post->title}</span>
{/if}
</h4>
<span class="icon icon-chevron-up collapse-indicator float-right" role="presentation" aria-hidden="true"></span>
<a class="collapsed" data-toggle="collapse" href="#recent_post_{$post->id}" aria-expanded="false">
<span class="sr-only">{$post->title}</span>
<span class="icon icon-chevron-down collapse-indicator float-right" role="presentation" aria-hidden="true"></span>
</a>
<div>
<span class="text-small">
{str tag='postedin' section='blocktype.blog/recentposts'}
......
......@@ -59,7 +59,7 @@
<div class="post list-group-item flush">
<h4 class="title">
{if !($editing)}
<a class="modal_link inner-link" data-toggle="modal-docked" data-target="#configureblock" href="#" data-blockid="{$blockid}" data-artefactid="{$post->id}">
<a class="modal_link" data-toggle="modal-docked" data-target="#configureblock" href="#" data-blockid="{$blockid}" data-artefactid="{$post->id}">
{$post->title}
</a>
{else}
......@@ -103,19 +103,21 @@
displayiconsonly=true}
{/if}
<div class="list-group-item">
<a class="outer-link collapsed" data-toggle="collapse" href="#tagged_post_{$post->id}" aria-expanded="false">
<span class="sr-only">{$post->title}</span>
</a>
<h4 class="list-group-item-heading">
{if !($editing)}
<a class="modal_link inner-link list-group-item-heading" data-toggle="modal-docked" data-target="#configureblock" href="#" data-blockid="{$blockid}" data-artefactid="{$post->id}">
<a class="modal_link list-group-item-heading" data-toggle="modal-docked" data-target="#configureblock" href="#" data-blockid="{$blockid}" data-artefactid="{$post->id}">
{$post->title}
</a>
{else}
<span class="list-group-item-heading no-link">{$post->title}</span>
{/if}
</h4>
<span class="icon icon-chevron-up collapse-indicator float-right" role="presentation" aria-hidden="true"></span>
<a class="collapsed" data-toggle="collapse" href="#tagged_post_{$post->id}" aria-expanded="false">
<span class="sr-only">{$post->title}</span>
<span class="icon icon-chevron-down collapse-indicator float-right" role="presentation" aria-hidden="true"></span>
</a>
<div>
<span class="metadata">
{str tag='postedon' section='blocktype.blog/taggedposts'}
......
......@@ -13,28 +13,21 @@
<ul class="list-unstyled list-group">
{foreach from=$attachments item=item}
<li class="list-group-item">
<a href="{$item->downloadpath}" class="outer-link icon-on-hover" {if $item->description} title="{$item->description}" data-toggle="tooltip"{/if}>
<span class="sr-only">
{str tag=Download section=artefact.file} {$item->title}
</span>
</a>
{if $item->iconpath}
{if $item->iconpath}
<img class="file-icon" src="{$item->iconpath}" alt="">
{else}
{else}
<span class="icon icon-{$item->artefacttype} icon-lg text-default left" role="presentation" aria-hidden="true"></span>
{/if}
{/if}
<span class="title">
<span class="inner-link text-small">
{$item->title}
</span>
<span class="metadata"> -
[{$item->size|display_size}]
</span>
<span class="text-small">{$item->title}</span>
<span class="metadata"> [{$item->size|display_size}]</span>
</span>
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
<a href="{$item->downloadpath}" {if $item->description}title="{$item->description}" data-toggle="tooltip"{/if}>
<span class="sr-only">{str tag=Download section=artefact.file} {$item->title}</span>
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
</a>
</li>
{/foreach}
</ul>
......
......@@ -61,23 +61,20 @@
<ul class="list-group list-unstyled">
{foreach from=$post->files item=file}
<li class="list-group-item">
<a href="{$WWWROOT}artefact/file/download.php?file={$file->attachment}&amp;view={$options.viewid}" class="outer-link icon-on-hover">
<span class="sr-only">
{str tag=Download section=artefact.file} {$file->title}
</span>
</a>
{if $file->icon}
{if $file->icon}
<img class="file-icon" src="{$file->icon}" alt="">
{else}
{else}
<span class="icon icon-{$file->artefacttype} icon-lg text-default left" role="presentation" aria-hidden="true"></span>
{/if}
{/if}
<span class="title">
<span class="text-small">{$file->title}</span>
<span class="metadata"> -
[{$file->size|display_size}]
</span>
<span class="metadata"> [{$file->size|display_size}]</span>
</span>
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
<a href="{$WWWROOT}artefact/file/download.php?file={$file->attachment}&amp;view={$options.viewid}">
<span class="sr-only">{str tag=Download section=artefact.file} {$file->title}</span>
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
</a>
</li>
{/foreach}
</ul>
......
......@@ -5,12 +5,12 @@
<div class="usericon-heading">
<span class="user-icon user-icon-30 float-left" role="presentation" aria-hidden="true">
{if $item->author && !$item->author->deleted}
<img src="{profile_icon_url user=$item->author maxheight=30 maxwidth=30}" valign="middle" alt="{str tag=profileimagetext arg1=$item->author|display_default_name}"/>
<a href="{$item->author->profileurl}"><img src="{profile_icon_url user=$item->author maxheight=30 maxwidth=30}" valign="middle" alt="{str tag=profileimagetext arg1=$item->author|display_default_name}"/></a>
{else}
<img src="{profile_icon_url user=null maxheight=30 maxwidth=30}" valign="middle" alt="{str tag=profileimagetextanonymous}"/>
{/if}
</span>
<h5 class="float-left list-group-item-heading">
<h4 class="float-left list-group-item-heading">
{if $item->author && !$item->author->deleted}
<a href="{$item->author->profileurl}">
<span>{$item->author|display_name}</span>
......@@ -38,7 +38,7 @@
{/for}
</span>
{/if}
</h5>
</h4>
<!-- The "comment-item-buttons" class is used as an identifier by Javascript -->
<div class="btn-group btn-group-top comment-item-buttons">
{if !$onview}
......@@ -105,20 +105,17 @@
</a>
</h4>
<div id="attachments_{$item->id}" class="collapse" aria-expanded="false">
<ul class=" list-group list-group-unbordered">
<ul class="list-unstyled list-group">
{strip}
{foreach $item->attachments item=a name=attachments}
<li class="list-group-item">
<a href="{$WWWROOT}artefact/file/download.php?file={$a->attachid}&comment={$item->id}&view={$viewid}" class="outer-link icon-on-hover">
<span class="sr-only">{$a->attachtitle}</span>
</a>
<span class="title">
{$a->attachtitle}
<span class="attachsize metadata">
[{$a->attachsize}]
</span>
<span class="text-small">{$a->attachtitle}</span>
<span class="metadata"> [{$a->attachsize}]</span>
</span>
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
<a href="{$WWWROOT}artefact/file/download.php?file={$a->attachid}&comment={$item->id}&view={$viewid}">
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
</a>
</li>
{/foreach}
{/strip}
......
......@@ -13,53 +13,35 @@
justdetails=$justdetails
displayiconsonly = true}
<li class="filedownload-item list-group-item">
<a href="{$file.downloadurl}" class="outer-link icon-on-hover">
<span class="sr-only">
{str tag=Download section=artefact.file} {$file.title}
</span>
</a>
<a class="modal_link" data-toggle="modal-docked" data-target="#configureblock" href="#" data-artefactid="{$file.id}" data-blockid="{$blockid}" title="{$file.title}">
{if $file.iconsrc}
<img src="{$file.iconsrc}" alt="" class="file-icon text-inline" />
{else}
<span class="icon icon-{$file.artefacttype} icon-lg left" role="presentation" aria-hidden="true"></span>
{/if}
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
</a>
<h4 class="title list-group-item-heading">
{if !$editing}
<a class="modal_link inner-link"
data-toggle="modal-docked"
data-target="#configureblock"
href="#"
data-artefactid="{$file.id}"
data-blockid="{$blockid}"
title="{$file.title}">
{$file.title}
<span class="sr-only">
{str tag=Details section=artefact.file}
</span>
</a>
{else}
{if !$editing}
<a class="modal_link" data-toggle="modal-docked" data-target="#configureblock" href="#" data-artefactid="{$file.id}" data-blockid="{$blockid}" title="{$file.title}">
{$file.title}
<span class="sr-only">
{str tag=Details section=artefact.file}
</span>
{/if}
<span class="sr-only">{str tag=Details section=artefact.file}</span>
</a>
{else}
{$file.title}
{/if}
</h4>
<br />
<span class="text-small text-midtone">
<a href="{$file.downloadurl}">
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
<span class="sr-only">{str tag=Download section=artefact.file} {$file.title}</span>
</a>
<div class="text-small text-midtone">
{$file.ctime|format_date:'strftimedaydate'}
[{$file.size|display_size}]
</span>
</div>
{if $file.description}
<div class="file-description">
<p class="text-small">
{$file.description|safe|clean_html}
</p>
<div class="file-description text-small">
{$file.description|safe|clean_html}
</div>
<script>
jQuery("div.file-description a").addClass('inner-link');
</script>
{/if}
</li>
{/foreach}
......
......@@ -21,40 +21,33 @@
<ul class="list-group">
{foreach from=$children item=child}
<li class="filedownload-item list-group-item">
{if $child->artefacttype != 'folder'}
<a href="{$WWWROOT}artefact/file/download.php?file={$child->id}&amp;view={$viewid}" class="outer-link icon-on-hover">
<span class="sr-only">
{str tag=Details section=artefact.file}
{$child->title}
</span>
</a>
{/if}
<a class="modal_link" title="{$child->hovertitle}" data-toggle="modal-docked" data-target="#configureblock" href="#" data-blockid="{$blockid}" data-artefactid="{$child->id}">
{if $child->iconsrc}
<img src="{$child->iconsrc}" alt="{$child->artefacttype}" class="file-icon text-inline {if $modal}file-icon-render-in-modal{/if}">
{else}
<span class="icon icon-{$child->artefacttype} icon-lg left {if $modal}file-icon-render-in-modal{/if}" role="presentation" aria-hidden="true"></span>
{/if}
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
<h4 class="title list-group-item-heading text-inline">
<a class="modal_link inner-link" title="{$child->hovertitle}" data-toggle="modal-docked" data-target="#configureblock" href="#" data-blockid="{$blockid}" data-artefactid="{$child->id}">
</a>
<h4 class="title list-group-item-heading">
<a class="modal_link" title="{$child->hovertitle}" data-toggle="modal-docked" data-target="#configureblock" href="#" data-blockid="{$blockid}" data-artefactid="{$child->id}">
{$child->title}
</a>
{if !$simpledisplay}
<span class="filedate metadata">
{$child->date}
</span>
{/if}
</h4>
{if $child->artefacttype != 'folder'}
<a href="{$WWWROOT}artefact/file/download.php?file={$child->id}&amp;view={$viewid}">
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
<span class="sr-only">{str tag=Details section=artefact.file}
{$child->title}
</span>
</a>
{if !$simpledisplay}
<div class="filedate metadata">
{$child->date}
</div>
{/if}
{if $child->description}
<p class="file-description text-small text-midtone">
<div class="file-description text-small text-midtone">
{$child->description|safe|clean_html}
</p>
<script>
jQuery(".file-description a").addClass('inner-link');
</script>
</div>
{/if}
</li>
{/foreach}
......
......@@ -32,15 +32,6 @@
justdetails=$justdetails
displayiconsonly=true}
<li class="filedownload-item list-group-item">
{if $child->artefacttype != 'folder'}
<a href="{$WWWROOT}artefact/file/download.php?file={$child->id}&amp;view={$viewid}" class="outer-link icon-on-hover">
<span class="sr-only">
{str tag=Details section=artefact.file}
{$child->title}
</span>
</a>
{/if}
{if $child->iconsrc}
<img src="{$child->iconsrc}" alt="{$child->artefacttype}" class="file-icon text-inline">
{else}
......@@ -61,7 +52,13 @@
{/if}
</h4>
{if $child->artefacttype != 'folder'}
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
<a href="{$WWWROOT}artefact/file/download.php?file={$child->id}&amp;view={$viewid}">
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
<span class="sr-only">
{str tag=Details section=artefact.file}
{$child->title}
</span>
</a>
{/if}
{if $child->description}
<p class="file-description text-small text-midtone">
......
......@@ -25,30 +25,34 @@
<ul class="list-unstyled list-group">
{foreach from=$attachments item=item}
<li class="list-group-item">
<a href="{$item->downloadpath}" class="outer-link icon-on-hover">
<span class="sr-only">
{str tag=Download section=artefact.file} {$item->title}
</span>
</a>
{if !$editing}
<a class="modal_link" data-toggle="modal-docked" data-target="#configureblock" href="#" data-blockid="{$blockid}" data-artefactid="{$item->id}">
{/if}
{if $item->iconpath}
<img class="file-icon" src="{$item->iconpath}" alt="">
<img class="file-icon" src="{$item->iconpath}" alt="">
{else}
<span class="icon icon-{$item->artefacttype} left icon-lg text-default" role="presentation" aria-hidden="true"></span>
<span class="icon icon-{$item->artefacttype} left icon-lg text-default" role="presentation" aria-hidden="true"></span>
{/if}
{if !$editing}
</a>
{/if}
<span class="title list-group-item-heading text-inline">
{if !$editing}
<a class="modal_link inner-link" data-toggle="modal-docked" data-target="#configureblock" href="#" data-blockid="{$blockid}" data-artefactid="{$item->id}">
{$item->title}
<span class="title">
{if !$editing}
<a class="modal_link" data-toggle="modal-docked" data-target="#configureblock" href="#" data-blockid="{$blockid}" data-artefactid="{$item->id}">
<span class="text-small">{$item->title}</span>
</a>
{else}
<span class="inner-link">{$item->title}</span>
{/if}
<span class="metadata"> -
[{$item->size|display_size}]
</span>
{else}
<span class="text-small">{$item->title}</span>
{/if}
<span class="metadata"> [{$item->size|display_size}]</span>
</span>
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
<a href="{$item->downloadpath}">
<span class="sr-only">{str tag=Download section=artefact.file} {$item->title}</span>
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
</a>
</li>
{/foreach}
</ul>
......
......@@ -7,16 +7,17 @@
<a class="btn btn-secondary btn-sm" href="{$WWWROOT}artefact/plans/task/delete.php?id={$task->id}{if $view}&view={$view}{/if}" title="{str tag='deletethistask' section='artefact.plans' arg1=$task->title}"><span class="icon icon-trash-alt text-danger"></span></a>
</div>
{/if}
{if $task->description || $task->tags}
<a class="outer-link collapsed" href="#expand-task-{$task->id}{if $block}-{$block}{/if}{if $versioning}-{$versioning->version}{/if}" data-toggle="collapse" aria-expanded="false" aria-controls="expand-task-{$task->id}{if $block}-{$block}{/if}{if $versioning}-{$versioning->version}{/if}">
<span class="sr-only">{$task->title}</span>
<span class="icon icon-chevron-down right collapse-indicator float-right" role="presentation" aria-hidden="true"></span>
</a>
{/if}
<span class="overdue-task">
<span class="icon icon-times text-danger icon-lg left task{$task->id}{if $editing || $canedit} plan-task-icon{/if}" role="presentation" aria-hidden="true" data-task="{$task->id}"></span>
<div class="plan-task-heading">
<span class="text-danger">{$task->title}</span>
{if $task->description || $task->tags}
<a class="collapsed" href="#expand-task-{$task->id}{if $block}-{$block}{/if}{if $versioning}-{$versioning->version}{/if}" data-toggle="collapse" aria-expanded="false" aria-controls="expand-task-{$task->id}{if $block}-{$block}{/if}{if $versioning}-{$versioning->version}{/if}">
{/if}
<span class="text-danger">{$task->title}</span>
{if $task->description || $task->tags}
<span class="icon icon-chevron-down collapse-indicator float-right" role="presentation" aria-hidden="true"></span>
</a>
{/if}
{if $task->completiondate}
<br />
<span class="text-small text-midtone">
......@@ -47,12 +48,6 @@
<a class="btn btn-secondary btn-sm" href="{$WWWROOT}artefact/plans/task/delete.php?id={$task->id}{if $view}&view={$view}{/if}" title="{str tag='deletethistask' section='artefact.plans' arg1=$task->title}"><span class="icon icon-trash-alt text-danger"></span></a>
</div>
{/if}
{if $task->description || $task->tags}
<a class="outer-link collapsed" href="#expand-task-{$task->id}{if $block}-{$block}{/if}{if $versioning}-{$versioning->version}{/if}" data-toggle="collapse" aria-expanded="false" aria-controls="expand-task-{$task->id}{if $block}-{$block}{/if}{if $versioning}-{$versioning->version}{/if}">
<span class="sr-only">{$task->title}</span>
<span class="icon icon-chevron-down right collapse-indicator float-right" role="presentation" aria-hidden="true"></span>
</a>
{/if}
<span class="complete-task">
{if $task->completed == 1}
<span class="icon icon-regular icon-check-square icon-lg text-success left task{$task->id}{if $editing || $canedit} plan-task-icon{/if}" role="presentation" aria-hidden="true" data-task="{$task->id}"></span>
......@@ -62,7 +57,14 @@
<span class="sr-only">{str tag=incomplete section=artefact.plans}</span>
{/if}
<div class="plan-task-heading">
{if $task->description || $task->tags}
<a class="collapsed" href="#expand-task-{$task->id}{if $block}-{$block}{/if}{if $versioning}-{$versioning->version}{/if}" data-toggle="collapse" aria-expanded="false" aria-controls="expand-task-{$task->id}{if $block}-{$block}{/if}{if $versioning}-{$versioning->version}{/if}">
{/if}
<span class="text-default">{$task->title}</span>
{if $task->description || $task->tags}
<span class="icon icon-chevron-down collapse-indicator float-right" role="presentation" aria-hidden="true"></span>
</a>
{/if}
{if $task->completiondate}
<br />
<span class="text-midtone text-small">
......
......@@ -53,28 +53,23 @@
<div id="booklist{$suffix}" class="list-group list-group-lite">
{foreach from=$rows item=row}
<div class="list-group-item">
<h5 class="list-group-item-heading">
{if $row->description || $row->attachments || $row->url}
<h5 class="list-group-item-heading">
<a href="#book-content-{$row->id}{if $artefactid}-{$artefactid}{/if}" class="text-left collapsed collapsible" aria-expanded="false" data-toggle="collapse">
{$row->title}
<span class="icon icon-chevron-down float-right collapse-indicator" role="presentation" aria-hidden="true"></span>
<br />
{if $row->date}
<span class="text-small text-muted">
{$row->date}
</span>
{/if}
</a>
</h5>
{else}
{$row->title}
<br />
{if $row->date}
<span class="text-small text-muted">
{$row->date}
</span>
{/if}
<h5 class="list-group-item-heading">
{$row->title}
</h5>
{/if}
{if $row->date}
<span class="text-small text-muted">
{$row->date}
</span>
{/if}
</h5>
<div id="book-content-{$row->id}{if $artefactid}-{$artefactid}{/if}" class="collapse resume-content">
{if $row->description}
......@@ -109,30 +104,30 @@
justdetails=$justdetails
displayiconsonly = true}
<li class="list-group-item">
<a href="{$item->downloadpath}" class="outer-link icon-on-hover">
<span class="sr-only">{str tag=Download section=artefact.file} {$item->title}</span>
</a>
{if !$editing}
<a class="modal_link text-small" data-toggle="modal-docked" data-target="#configureblock" href="#" data-artefactid="{$item->id}">
{/if}
{if $item->iconpath}
<img class="file-icon" src="{$item->iconpath}" alt="">
<img class="file-icon" src="{$item->iconpath}" alt="">
{else}
<span class="icon icon-{$item->artefacttype} left icon-lg text-default" role="presentation" aria-hidden="true"></span>
<span class="icon icon-{$item->artefacttype} left icon-lg text-default" role="presentation" aria-hidden="true"></span>
{/if}
{if !$editing}
</a>
{/if}
<span class="title">
{if !$editing}
<a class="modal_link text-small inner-link" data-toggle="modal-docked" data-target="#configureblock" href="#" data-artefactid="{$item->id}">
{$item->title}
</a>
{else}
<span class="text-small inner-link">{$item->title}</span>
{/if}
<span class="metadata"> -
[{$item->size}]
</span>
{if !$editing}
<a class="modal_link text-small" data-toggle="modal-docked" data-target="#configureblock" href="#" data-artefactid="{$item->id}">{$item->title}</a>
{else}
<span class="text-small">{$item->title}</span>
{/if}
<span class="metadata"> [{$item->size}]</span>
</span>
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
<a href="{$item->downloadpath}">
<span class="sr-only">{str tag=Download section=artefact.file} {$item->title}</span>
<span class="icon icon-download icon-lg float-right text-watermark icon-action" role="presentation" aria-hidden="true"></span>
</a>
</li>