fix(pagination): align AJAX load-more loading state with reference

Loading indication now matches the reference theme's post_ajax() contract:

- Stop overwriting the 加载更多 button label with 正在加载...; the button
  keeps its own text and the .post_ajax_loader skeleton carries the busy
  state instead.
- Add the reference fallback loader (.loading ring + 加载中...) when no
  skeleton exists in the DOM, and reinsert the skeleton after the last
  card on every page load like beforeSend does.
- Retext the loader string to 加载中... (zib__('loading')) and make the
  ajax_trigger default a translatable string.
- Route ajax-list.js / comments.js / widgets frontend.js through the
  .is-loading class instead of inline display, which outranked the class
  rule and could freeze the skeleton shut.
- Drop the search.php inline display:none that defeated .is-loading, and
  remove the unproduced .post-ajax-loader / [data-aksrt-ajax-loader] shims.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
2026-10-03 17:23:44 +08:00
co-authored by Claude Fable 5
parent e506309434
commit b5f37d6d46
10 changed files with 59 additions and 49 deletions
+8 -7
View File
@@ -257,17 +257,18 @@ body.aksrt-modal-runtime-open {
min-height: 80px;
}
/* 骨架默认收起,由 pagination.js 的 showSkeleton() 加 .is-loading 展开。
这里不依赖 .ajaxpager 祖先:首页 tab pane、归档流、评论列表的 loader
层级各不相同,统一按类名自身控制。 */
.post_ajax_loader,
.post-ajax-loader {
/* 骨架默认收起,由 JS 加 .is-loading 展开(参考主题 post_ajax 的 beforeSend
remove + fadeIn / success .hide() 语义等价物)。
这里不依赖 .ajaxpager 祖先:首页 tab pane、归档流、评论列表的 loader 层级各不
相同,而且并非每个 loader 都在 bootstrap 的 .tab-pane 里(bootstrap 只负责
隐藏 tab-pane 内的骨架),统一按类名自身控制。 */
.post_ajax_loader {
display: none;
}
.post_ajax_loader.is-loading,
.post-ajax-loader.is-loading {
.post_ajax_loader.is-loading {
display: block;
animation: aksrtFadeIn 0.2s ease both;
}
.ajax-item.is-fading {