Skip to content

Commit

Permalink
Fix the vertical alignment of the pages without link
Browse files Browse the repository at this point in the history
  • Loading branch information
leofeyer committed Oct 1, 2021
1 parent 1497a59 commit 572b29c
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 2 deletions.
4 changes: 4 additions & 0 deletions core-bundle/src/Resources/contao/classes/Backend.php
Original file line number Diff line number Diff line change
Expand Up @@ -953,6 +953,10 @@ public static function addPageIcon($row, $label, DataContainer $dc=null, $imageA
{
$label = '<a href="' . self::addToUrl('pn=' . $row['id']) . '" title="' . StringUtil::specialchars($GLOBALS['TL_LANG']['MSC']['selectNode']) . '">' . $label . '</a>';
}
else
{
$label = '<span>' . $label . '</span>';
}

// Return the image
return '<a href="contao/preview.php?page=' . $row['id'] . '" title="' . StringUtil::specialchars($GLOBALS['TL_LANG']['MSC']['view']) . '" target="_blank">' . Image::getHtml($image, '', $imageAttribute) . '</a> ' . $label;
Expand Down
8 changes: 7 additions & 1 deletion core-bundle/src/Resources/contao/themes/flexible/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -1193,9 +1193,15 @@ table.tl_listing {
.tl_tree_xtnd .tl_file .tl_left img {
margin-right:2px;
}
.tl_left > a:last-of-type {
.tl_left > * {
vertical-align:middle;
}
@media not all and (min-resolution:.001dpcm) { @supports (-webkit-appearance:none) {
.tl_left > *:last-of-type {
position:relative;
top:1px;
}
}}
.tl_file_manager .tl_file .tl_left > a:first-child {
vertical-align:1px;
}
Expand Down

0 comments on commit 572b29c

Please sign in to comment.