Merge branch 'develop' of github.com:tainacan/tainacan-theme into develop

This commit is contained in:
Fabiano 2018-06-26 14:28:11 -03:00
commit b3240d21cb
3 changed files with 20 additions and 15 deletions

View File

@ -87,6 +87,7 @@ jQuery(document).ready(function( $ ) {
characterData: true
};
observer.observe(document.getElementById('items-list-area'), config);
if(document.getElementById('items-list-area'))
observer.observe(document.getElementById('items-list-area'), config);
});

View File

@ -6,8 +6,9 @@
.col { flex-grow: 0; }
.tainacan-grid {
padding: 12px 24px 24px 24px;
margin: 12px 16px 24px 16px;
text-align: center;
display: block;
img {
width: 258px;
@ -15,15 +16,22 @@
border-radius: 2px;
}
.metadata-title {
&:hover {
background-color: #e5e5e5;
p.metadata-title { text-decoration: none !important; }
}
p.metadata-title {
flex-shrink: 0;
font-size: 0.875rem;
margin-bottom: 0.875rem;
margin-bottom: 0;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
padding: 0.75rem 1.5rem;
text-align: left;
color: #1d1d1d;
text-decoration: none !important;
}
}

View File

@ -5,20 +5,16 @@
<div class="row no-gutters">
<?php while (have_posts()): the_post(); ?>
<div class="col">
<div class="tainacan-grid">
<?php if ( tainacan_current_view_displays('thumbnail') ): ?>
<a href="<?php the_permalink(); ?>">
<?php the_post_thumbnail('medium'); ?>
</a>
<?php endif; ?>
<a class="tainacan-grid" href="<?php the_permalink(); ?>">
<?php if ( tainacan_current_view_displays('title') ): ?>
<p class="metadata-title">
<a href="<?php the_permalink(); ?>">
<?php the_title(); ?>
</a>
<p class="metadata-title">
<?php the_title(); ?>
</p>
<?php endif; ?>
</div>
<?php if ( tainacan_current_view_displays('thumbnail') ): ?>
<?php the_post_thumbnail('medium'); ?>
<?php endif; ?>
</a>
</div>
<?php endwhile; ?>