added the hook to change the style of cancel comment reply
This commit is contained in:
parent
f4f37d8f16
commit
ab6b566023
|
@ -43,8 +43,8 @@
|
|||
}
|
||||
}
|
||||
} */
|
||||
button{
|
||||
&#submit{
|
||||
button, a{
|
||||
&#submit, &#cancel-comment-reply-link{
|
||||
@media screen {
|
||||
@media (min-width: 768px){
|
||||
height: 28px;
|
||||
|
@ -52,6 +52,14 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
&#cancel-comment-reply-link{
|
||||
color: #150e38;
|
||||
}
|
||||
&#submit{
|
||||
&:hover{
|
||||
background-color: #25a189 !important;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -54,7 +54,7 @@ if (post_password_required()) {
|
|||
</div>
|
||||
<button id="submit" class="btn btn-info bg-jungle-green align-self-center ml-auto mt-3 float-right" type="submit" name="submit"><?php _e('Send', 'tainacan-theme') ?></button>
|
||||
|
||||
<?php cancel_comment_reply_link('Cancel'); ?>
|
||||
<?php cancel_comment_reply_link(__( 'Cancel', 'tainacan-theme' )); ?>
|
||||
<?php do_action('comment_form', $post->ID); ?>
|
||||
</form>
|
||||
<?php endif; ?>
|
||||
|
|
|
@ -74,4 +74,12 @@ if ( ! function_exists( 'tainacan_post_date' ) ) {
|
|||
echo $time_string;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// define the cancel_comment_reply_link callback
|
||||
function filter_cancel_comment_reply_link( $formatted_link, $link, $text ) {
|
||||
// make filter magic happen here...
|
||||
$formatted_link = '<a rel="nofollow" class="btn btn-info bg-white border-oslo-gray align-self-center mt-3 ml-1" id="cancel-comment-reply-link" href="'.$link.'" style="display:none;">'.$text.'</a>';
|
||||
return $formatted_link;
|
||||
}
|
||||
add_filter( 'cancel_comment_reply_link', 'filter_cancel_comment_reply_link', 10, 3 );
|
Loading…
Reference in New Issue