更多资料新增元信息

This commit is contained in:
2026-08-23 13:12:41 +08:00
parent 32cda220f7
commit 1c5c6d86bb
+2 -7
View File
@@ -195,13 +195,8 @@ $pm_url = ($pm_enabled && $messages_url !== '')
<button type="button" class="aksrt-profile-details-modal__close" data-aksrt-modal-close aria-label="<?php esc_attr_e('关闭', 'aksrt'); ?>">&times;</button>
<h2 id="aksrt-profile-details-title"><?php esc_html_e('更多资料', 'aksrt'); ?></h2>
<dl>
<?php
$verify_state = is_array($dashboard['verify_state'] ?? null) ? $dashboard['verify_state'] : [];
$verify_state_value = (string) ($verify_state['state'] ?? '');
$verify_tones = ['none' => 'neutral', 'personal' => 'success', 'enterprise' => 'warning'];
$verify_icons = ['none' => '', 'personal' => 'fa-user-check', 'enterprise' => 'fa-building'];
?>
<?php if ($verify_state_value !== '' && ($verify_state['label'] ?? '') !== '') : ?><div><dt><?php esc_html_e('认证', 'aksrt'); ?></dt><dd><span class="badg badg-sm aksrt-identity-chip aksrt-identity-chip--<?php echo esc_attr($verify_tones[$verify_state_value]); ?>"><?php if ($verify_icons[$verify_state_value] !== '') : ?><i class="fa fas <?php echo esc_attr($verify_icons[$verify_state_value]); ?>" aria-hidden="true"></i> <?php endif; ?><?php echo esc_html((string) $verify_state['label']); ?></span></dd></div><?php endif; ?>
<?php $verify_state = is_array($dashboard['verify_state'] ?? null) ? $dashboard['verify_state'] : []; ?>
<?php if (($verify_state['state'] ?? '') !== '' && ($verify_state['label'] ?? '') !== '') : ?><div><dt><?php esc_html_e('认证', 'aksrt'); ?></dt><dd><?php echo esc_html((string) $verify_state['label']); ?></dd></div><?php endif; ?>
<?php if (!empty($profile_details['gender'])) : ?><div><dt><?php esc_html_e('性别', 'aksrt'); ?></dt><dd><?php echo esc_html($profile_details['gender'] === 'male' ? __('男', 'aksrt') : __('女', 'aksrt')); ?></dd></div><?php endif; ?>
<?php if (!empty($profile_details['website'])) : ?><div><dt><?php esc_html_e('个人网站', 'aksrt'); ?></dt><dd><a href="<?php echo esc_url($profile_details['website']); ?>" target="_blank" rel="noopener noreferrer"><?php echo esc_html($profile_details['website']); ?></a></dd></div><?php endif; ?>
<?php if (!empty($profile_details['github'])) : ?><div><dt>GitHub</dt><dd><a href="<?php echo esc_url($profile_details['github']); ?>" target="_blank" rel="noopener noreferrer"><?php echo esc_html($profile_details['github']); ?></a></dd></div><?php endif; ?>