diff --git a/functions.php b/functions.php index 24c7278..cb02fb2 100644 --- a/functions.php +++ b/functions.php @@ -36,6 +36,11 @@ add_action( 'after_setup_theme', 'c1024_2026_setup' ); function c1024_2026_assets() { wp_enqueue_style( 'c1024-2026-style', get_stylesheet_uri(), array(), '1.0.0' ); wp_enqueue_script( 'c1024-2026-theme', get_template_directory_uri() . '/assets/js/theme.js', array(), '1.0.0', true ); + + // Core moves and focuses the reply form and sets its parent comment ID. + if ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) { + wp_enqueue_script( 'comment-reply' ); + } } // Load public assets through WordPress so dependencies and plugin integrations remain ordered. add_action( 'wp_enqueue_scripts', 'c1024_2026_assets' );