refactor: rename the theme brand and every identifier from AKSRT to Jio
Full-project rename. `git grep -i aksrt` is now empty apart from the
DBMigrator 3.3.0 changelog note that documents the rename itself.
Code identifiers
- PHP namespace AKSRT\ -> Jio\ (composer PSR-4 + 378 declarations)
- global constants AKSRT_* -> JIO_* (VERSION/DIR/URI, PAY_TYPE_*, CAPTCHA_*)
- procedural functions, hooks, options, meta keys, table names,
cookies, query vars, ajax actions and nonces: aksrt_ -> jio_
- text domain aksrt -> jio; Theme Name -> Jio
- JS globals: aksrtData/aksrtAdminData/... -> jioData/jioAdminData/...,
window.AKSRTCaptcha & friends -> window.JioCaptcha, Aksrt* -> Jio*
- Vue components Aks*.vue -> Jio*.vue (15 files renamed + imports)
- CSS classes/data-attrs/custom properties: aksrt- -> jio-
- REST namespace aksrt/v1 -> jio/v1 (incl. payment gateway callbacks)
Storage layer
- DB tables {prefix}aksrt_* -> {prefix}jio_*; SCHEMA_VERSION 3.2.0 -> 3.3.0
so dbDelta creates the new names on install
- widget id_base aksrt_widget_* -> jio_widget_*
- uninstall.php drop list rebuilt from the actual migrator tables
(dropped 3 stale entries, added the 17 missing ones)
Removed
- hardcoded https://api.aksrt.com/version.json default update endpoint;
get_endpoint() now reads the 「更新端点」 setting and do_check() no-ops
when it is empty
Files renamed: inc/helpers/aksrt-*.php -> jio-*.php (54),
assets/admin/src/components/form/Aks*.vue -> Jio*.vue (15).
Build artifacts regenerated: assets/css/build, assets/js/runtime,
assets/admin/build.
Verified: audit-psr4-paths errors=0, audit-admin-contracts errors=0
(warnings=56, unchanged baseline), 813/813 widget-system tests,
44/44 phpunit, php -l clean across all PHP.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
5b16bc6e15
commit
35bb96e82f
997 files changed
+28216
-28188
No files matched your search
@@ -1,12 +1,12 @@
|
||||
<?php
|
||||
/**
|
||||
* Template Name: AKSRT - 文章导航
|
||||
* Template Name: Jio - 文章导航
|
||||
* Template Post Type: page
|
||||
*
|
||||
* legacy pages/postsnavs.php 1:1 — selected categories with full post lists,
|
||||
* affix TOC sidebar, admin drag-sort settings modal.
|
||||
*
|
||||
* @package AKSRT
|
||||
* @package Jio
|
||||
*/
|
||||
|
||||
defined('ABSPATH') || exit;
|
||||
@@ -51,18 +51,18 @@ get_header();
|
||||
<?php if ($can_admin) : ?>
|
||||
<small>
|
||||
<a style="cursor:pointer" href="javascript:;" data-toggle="modal" data-target="#post-navs-sz">
|
||||
[<?php esc_html_e('设置', 'aksrt'); ?>]
|
||||
[<?php esc_html_e('设置', 'jio'); ?>]
|
||||
</a>
|
||||
</small>
|
||||
<?php endif; ?>
|
||||
</h2>
|
||||
<div class="flex ab jsb hh">
|
||||
<div class="muted-color mr20">
|
||||
<?php echo esc_html($page_desc !== '' ? $page_desc : __('暂无简介内容,请设置', 'aksrt')); ?>
|
||||
<?php echo esc_html($page_desc !== '' ? $page_desc : __('暂无简介内容,请设置', 'jio')); ?>
|
||||
</div>
|
||||
<div class="pull-right page-share mt20">
|
||||
<?php if (function_exists('aksrt_render_share_buttons')) {
|
||||
aksrt_render_share_buttons(['post' => $post_id]);
|
||||
<?php if (function_exists('jio_render_share_buttons')) {
|
||||
jio_render_share_buttons(['post' => $post_id]);
|
||||
} ?>
|
||||
</div>
|
||||
</div>
|
||||
@@ -98,21 +98,21 @@ get_header();
|
||||
echo '<div class="main-bg radius8 main-shadow box-body"><ul class="posts-navs__list">';
|
||||
foreach ($posts as $p) {
|
||||
$time_tip = get_the_time('Y年m月d日 H:i', $p);
|
||||
$time_ago = human_time_diff(get_the_time('U', $p), current_time('timestamp')) . __('前', 'aksrt');
|
||||
$views = function_exists('aksrt_get_post_views') ? (int) aksrt_get_post_views($p->ID) : 0;
|
||||
$time_ago = human_time_diff(get_the_time('U', $p), current_time('timestamp')) . __('前', 'jio');
|
||||
$views = function_exists('jio_get_post_views') ? (int) jio_get_post_views($p->ID) : 0;
|
||||
$likes = (int) get_post_meta($p->ID, 'like', true);
|
||||
if ($likes <= 0) {
|
||||
$likes = (int) get_post_meta($p->ID, 'aksrt_like', true);
|
||||
$likes = (int) get_post_meta($p->ID, 'jio_like', true);
|
||||
}
|
||||
$post_tip = sprintf(
|
||||
/* translators: 1: views 2: likes */
|
||||
__('阅读(%1$s) 点赞(%2$s)', 'aksrt'),
|
||||
__('阅读(%1$s) 点赞(%2$s)', 'jio'),
|
||||
(string) $views,
|
||||
(string) $likes
|
||||
);
|
||||
$subtitle = (string) get_post_meta($p->ID, 'subtitle', true);
|
||||
if ($subtitle === '') {
|
||||
$subtitle = (string) get_post_meta($p->ID, 'aksrt_subtitle', true);
|
||||
$subtitle = (string) get_post_meta($p->ID, 'jio_subtitle', true);
|
||||
}
|
||||
echo '<li class="posts-navs__item">';
|
||||
echo '<div class="text-ellipsis">';
|
||||
@@ -129,11 +129,11 @@ get_header();
|
||||
}
|
||||
} elseif ($can_admin) {
|
||||
echo '<div class="theme-box main-bg radius8 main-shadow box-body">';
|
||||
echo '<p class="muted-2-color">' . esc_html__('尚未选择分类,请点击标题旁「设置」配置要展示的分类。', 'aksrt') . '</p>';
|
||||
echo '<p class="muted-2-color">' . esc_html__('尚未选择分类,请点击标题旁「设置」配置要展示的分类。', 'jio') . '</p>';
|
||||
echo '</div>';
|
||||
} else {
|
||||
echo '<div class="theme-box main-bg radius8 main-shadow box-body">';
|
||||
echo '<p class="muted-2-color">' . esc_html__('暂无导航内容', 'aksrt') . '</p>';
|
||||
echo '<p class="muted-2-color">' . esc_html__('暂无导航内容', 'jio') . '</p>';
|
||||
echo '</div>';
|
||||
}
|
||||
?>
|
||||
@@ -141,7 +141,7 @@ get_header();
|
||||
</div>
|
||||
</div>
|
||||
<div class="sidebar">
|
||||
<div class="posts-nav-box" data-affix="true" data-title="<?php esc_attr_e('导航目录', 'aksrt'); ?>"></div>
|
||||
<div class="posts-nav-box" data-affix="true" data-title="<?php esc_attr_e('导航目录', 'jio'); ?>"></div>
|
||||
</div>
|
||||
</main>
|
||||
|
||||
@@ -149,29 +149,29 @@ get_header();
|
||||
<div class="modal fade" id="post-navs-sz" tabindex="-1" role="dialog" aria-hidden="true">
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content">
|
||||
<form id="aksrt-posts-navs-settings" class="aksrt-posts-navs-settings">
|
||||
<form id="jio-posts-navs-settings" class="jio-posts-navs-settings">
|
||||
<div class="modal-header">
|
||||
<p class="modal-title">
|
||||
<?php esc_html_e('当前页面设置', 'aksrt'); ?>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="<?php esc_attr_e('关闭', 'aksrt'); ?>">
|
||||
<?php esc_html_e('当前页面设置', 'jio'); ?>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="<?php esc_attr_e('关闭', 'jio'); ?>">
|
||||
<i class="fa fas fa-times" aria-hidden="true"></i>
|
||||
</button>
|
||||
</p>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="form-group">
|
||||
<label for="navs_page_name"><?php esc_html_e('标题', 'aksrt'); ?></label>
|
||||
<input type="text" class="form-control" id="navs_page_name" name="navs_page_name" placeholder="<?php esc_attr_e('自定义标题', 'aksrt'); ?>" value="<?php echo esc_attr($page_name); ?>">
|
||||
<label for="navs_page_name"><?php esc_html_e('标题', 'jio'); ?></label>
|
||||
<input type="text" class="form-control" id="navs_page_name" name="navs_page_name" placeholder="<?php esc_attr_e('自定义标题', 'jio'); ?>" value="<?php echo esc_attr($page_name); ?>">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="navs_page_desc"><?php esc_html_e('简介', 'aksrt'); ?></label>
|
||||
<input type="text" class="form-control" id="navs_page_desc" name="navs_page_desc" placeholder="<?php esc_attr_e('自定义简介', 'aksrt'); ?>" value="<?php echo esc_attr($page_desc); ?>">
|
||||
<label for="navs_page_desc"><?php esc_html_e('简介', 'jio'); ?></label>
|
||||
<input type="text" class="form-control" id="navs_page_desc" name="navs_page_desc" placeholder="<?php esc_attr_e('自定义简介', 'jio'); ?>" value="<?php echo esc_attr($page_desc); ?>">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label><?php esc_html_e('请将需要显示的分类拖动到选区并排序', 'aksrt'); ?></label>
|
||||
<label><?php esc_html_e('请将需要显示的分类拖动到选区并排序', 'jio'); ?></label>
|
||||
<div class="row text-center">
|
||||
<div class="col-xs-6 col-sm-6">
|
||||
<p class="text-muted"><?php esc_html_e('未选择的分类', 'aksrt'); ?></p>
|
||||
<p class="text-muted"><?php esc_html_e('未选择的分类', 'jio'); ?></p>
|
||||
<div class="cat-group mini-scrollbar" id="cat-sortable">
|
||||
<?php
|
||||
foreach ($all_cats as $the_cat) {
|
||||
@@ -188,7 +188,7 @@ get_header();
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-xs-6 col-sm-6">
|
||||
<p class="text-muted"><?php esc_html_e('已选择的分类', 'aksrt'); ?></p>
|
||||
<p class="text-muted"><?php esc_html_e('已选择的分类', 'jio'); ?></p>
|
||||
<div class="cat-group mini-scrollbar" id="cat-sortable-ok">
|
||||
<?php
|
||||
foreach ($show_cat_id as $c_id) {
|
||||
@@ -208,10 +208,10 @@ get_header();
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<input type="hidden" name="action" value="aksrt_post_navs_settings">
|
||||
<input type="hidden" name="action" value="jio_post_navs_settings">
|
||||
<input type="hidden" name="page_id" value="<?php echo (int) $post_id; ?>">
|
||||
<?php wp_nonce_field('aksrt_post_navs_settings', '_wpnonce', false); ?>
|
||||
<button type="submit" class="btn btn-primary" evt="action"><?php esc_html_e('确认修改', 'aksrt'); ?></button>
|
||||
<?php wp_nonce_field('jio_post_navs_settings', '_wpnonce', false); ?>
|
||||
<button type="submit" class="btn btn-primary" evt="action"><?php esc_html_e('确认修改', 'jio'); ?></button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
Reference in new issue
Block a user