Redesign comment rendering and styling

This commit is contained in:
2026-07-27 12:11:24 +02:00
parent b3c5f9a482
commit cbcdbc1bb8
3 changed files with 112 additions and 5 deletions
+3 -2
View File
@@ -4,8 +4,9 @@ if ( post_password_required() ) { return; }
?>
<section id="comments" class="comments-area">
<?php if ( have_comments() ) { ?>
<h2 class="comments-title"><?php printf( esc_html( _nx( 'One comment', '%1$s comments', get_comments_number(), 'comments title', 'c1024-2026' ) ), esc_html( number_format_i18n( get_comments_number() ) ) ); ?></h2>
<ol class="comment-list"><?php wp_list_comments( array( 'style' => 'ol', 'short_ping' => true, 'avatar_size' => 48 ) ); ?></ol>
<h2 class="comments-title"><?php echo esc_html( get_comments_number_text() ); ?></h2>
<?php // The custom callback uses an avatar-led, non-numbered discussion layout. ?>
<ol class="comment-list"><?php wp_list_comments( array( 'style' => 'ol', 'short_ping' => true, 'avatar_size' => 44, 'callback' => 'c1024_2026_comment' ) ); ?></ol>
<?php the_comments_navigation(); ?>
<?php } ?>
<?php if ( ! comments_open() && get_comments_number() ) { ?><p><?php esc_html_e( 'Comments are closed.', 'c1024-2026' ); ?></p><?php } ?>