feat(badges): medal info remote modal + grant notification

Add zibll-like badge list/single AJAX modals, Message notify on grant,
author-home/user-center entry points, and front wear handler.
This commit is contained in:
2026-07-19 02:17:53 +08:00
parent 5fa902304b
commit 9f90d54821
5 changed files with 273 additions and 1 deletions
+10
View File
@@ -102,6 +102,16 @@ $pm_url = ($pm_enabled && $messages_url !== '')
</h1>
<?php endif; ?>
<?php
// Badge detail remote-modal (zibll user medal info).
if (class_exists('\AKSRT\User\Badges') && \AKSRT\User\Badges::enabled() && \AKSRT\User\Badges::public_display()) {
$badge_link = \AKSRT\User\Badges::get_info_link($user_id, 'but but-sm jb-blue mt6', __('徽章明细', 'aksrt'));
if ($badge_link !== '') {
echo '<div class="aksrt-author-hero__badges">' . $badge_link . '</div>'; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
}
}
?>
<?php if ($show_desc && $user->description) : ?>
<p class="aksrt-author-hero__desc"><?php echo esc_html($user->description); ?></p>
<?php endif; ?>