Snippets: WooCommerce Click to Toggle Review Form

/* Add this CSS to the site to hide the form and make the comment title look more like a button */
.woocommerce #review_form #commentform {
    display: none;
}

.woocommerce #review_form .comment-reply-title {
    display: inline-block;
    background: #000;
    color: #fff;
    padding: 10px 20px;
    font-size: 12px;
    cursor: pointer;
}

/* Add this to your functions.php file for the javascript needed for the toggle affect */
add_action( 'wp_footer', function() { ?>
	<script>
		( function( $ ) {
			'use strict';
			$( '.woocommerce #review_form .comment-reply-title' ).click( function() {
				$( '.woocommerce #review_form #commentform' ).toggle();
			} );
		} ( jQuery ) );
	</script>
<?php } );
All PHP snippets should be added via a child theme's functions.php file.