<?php
/**
 * The template for displaying Comments.
 *
 * The area of the page that contains comments and the comment form.
 *
 * @package WordPress
 * @subpackage Twenty_Thirteen
 * @since Twenty Thirteen 1.0
 */
/*
 * If the current post is protected by a password and the visitor has not yet
 * entered the password we will return early without loading the comments.
 */
if ( post_password_required() )
	return;
?>
<div itemscope itemtype="http://schema.org/Comment" id="comments" class="post-comments comments-area clearfix">
	<?php if ( have_comments() ) : ?>
    <div class="comments-area">
		<div class="group-title"><h2><?php comments_number();?></h2></div>
		<!-- comments -->
		<div class="th-comment-list">
			<?php
                wp_list_comments( array(
                    'style'       => 'ul',
                    'short_ping'  => true,
                    'avatar_size' => 100,
                    'callback'=>'tycheproperty_list_comments'
                ) );
            ?>
		</div>
		
		<?php
			
			if ( get_comment_pages_count() > 1 && get_option( 'page_comments' ) ) :
		?>
		<nav class="navigation comment-navigation" role="navigation">
			<h1 class="screen-reader-text section-heading"><?php esc_html_e( 'Comment navigation', 'tycheproperty' ); ?></h1>
			<div class="nav-previous"><?php previous_comments_link( esc_html__( '&larr; Older Comments', 'tycheproperty' ) ); ?></div>
			<div class="nav-next"><?php next_comments_link( esc_html__( 'Newer Comments &rarr;', 'tycheproperty' ) ); ?></div>
		</nav><!-- .comment-navigation -->
		<?php endif; // Check for comment navigation ?>
		<?php if ( ! comments_open() && get_comments_number() ) : ?>
		<p class="no-comments"><?php esc_html_e( 'Comments are closed.' , 'tycheproperty' ); ?></p>
		<?php endif; ?>
    </div>
	<?php endif; // have_comments() ?>
    
    <!-- Add Your Comments -->
    <div class="comment-form wow fadeInUp" data-wow-delay="200ms" data-wow-duration="1500ms">
        <!-- Heading -->
       <?php if ( comments_open()) : ?>
        
            <div class="group-title"><h2><?php esc_html_e('Leave Your Comments', 'tycheproperty');?></h2></div>
            
       <?php endif; ?>	
        
        <?php tycheproperty_comment_form(); ?>
    </div>    
</div><!-- #comments -->
