fix: 修复跳转评论按钮无法点击的问题

- 将按钮初始状态从 d-none 改为 fabtn-hidden
- 统一使用 fabtn-hidden 类控制按钮显示/隐藏
- 修复后台设置不生效导致按钮无法显示的问题
- 添加 !important 确保隐藏样式优先级
This commit is contained in:
2026-01-12 16:56:10 +08:00
parent 055df39e30
commit c111edcf4c
2 changed files with 3 additions and 3 deletions

View File

@@ -710,9 +710,9 @@ if (argonConfig.waterflow_columns != "1") {
}) })
if ($("#post_comment").length > 0){ if ($("#post_comment").length > 0){
$("#fabtn_go_to_comment").removeClass("d-none"); $("#fabtn_go_to_comment").removeClass("fabtn-hidden");
}else{ }else{
$("#fabtn_go_to_comment").addClass("d-none"); $("#fabtn_go_to_comment").addClass("fabtn-hidden");
} }
$goToComment.on("click" , function(){ $goToComment.on("click" , function(){
var commentsArea = $("#comments"); var commentsArea = $("#comments");

View File

@@ -1309,7 +1309,7 @@ if (apply_filters('argon_page_background_url', get_option('argon_page_background
</button> </button>
<button id="fabtn_go_to_comment" class="btn btn-icon btn-neutral fabtn shadow-sm d-none" type="button" <?php if (get_option('argon_fab_show_gotocomment_button') != 'true') echo " style='display: none;'";?> aria-label="Comment" tooltip="<?php _e('评论', 'argon'); ?>"> <button id="fabtn_go_to_comment" class="btn btn-icon btn-neutral fabtn shadow-sm fabtn-hidden" type="button" <?php if (get_option('argon_fab_show_gotocomment_button') != 'true') echo " style='display: none !important;'";?> aria-label="Comment" tooltip="<?php _e('评论', 'argon'); ?>">
<span class="btn-inner--icon"><i class="fa fa-comment-o"></i></span> <span class="btn-inner--icon"><i class="fa fa-comment-o"></i></span>