chore(branding): remove leftover upstream theme identifiers

The theme was renamed Zibll/子比 → AKSRT → Jio, but upstream branding
survived the sweeps in CSS classes, the SVG sprite prefix, a persisted
widget field ID, JS events, admin Vue class names, test infrastructure
and docblocks.

Renames:
- zib-widget / zib-widget-wrap / zib-slider → jio-widget-box /
  jio-widget-box-wrap / jio-slider-box (jio-widget is taken by the modern
  widget shell, jio-box-* by the card primitives)
- zib-partners-scroll + zps-* → jio-partners-scroll + jps-*
- zib-combo-info-card + zci-* → jio-combo-info-card + jci-*
- zibsvg- → jiosvg-, including the exported picker helpers and the
  fa-zibsvg- family-prefix guard
- zibpay_type → pay_type; the dual-read fallback in PostQuery collapses
  to a single key
- [zibajax="submit"] dropped (no PHP emitter); zib_ajax.success →
  jio_ajax.success
- aks-* admin Vue classes → jio-*
- zib_palette() → palette()

User-facing vendor traces are gone: the floating "more" button default no
longer ships a zibll.com link or 子比主题 marketing copy, the notice
widget ships no preset promo entries, and the four 官网教程 links are
removed from the post-list admin schema.

Test infrastructure renamed to neutral names (docker-compose.reference.yml,
Caddyfile, article-baseline.json, modern-widgets-contract.test.cjs) with
their DB/volume/env/slug identifiers following.

Kept intentionally, documented in tests/fixtures/README.md: the golden
fixture reference fingerprint (a SHA-256 record of an external directory,
read by validate-widget-golden / generate-widget-golden-fixture /
audit-widget-system), the doesNotMatch guards that prove the old tokens are
gone, and the reference theme's own meta key in the visual fixtures.

No backward-compat or data migration: saved widget configs holding old
icon keys or the old field ID silently lose them, per the project's
rewrite-over-compatibility rule.

Verified: 132/132 node contract tests, php tests/widget-system/run.php
(146 assertions), audit-admin-contracts, audit-psr4-paths and
validate-widget-golden all green; tracked bundles regenerated and in sync.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
kate522andClaude Opus 5 committed 2026-11-02 00:06:54 +08:00
1 parent 42cc64106d
commit 427968a721
188 files changed
+915 -967

No files matched your search

@@ -1,7 +1,7 @@
'use strict';
/**
* 「文章页面」后台设置页契约(对齐参考主题 zibll 1:1):
* 「文章页面」后台设置页契约:
* 1) PHP schema(SchemaPostList.php page section 2.0.0)字段键、顺序、默认值与
* JS schema(assets/admin/src/schema/sections/post-list/page.js)一致;
* 2) 参考主题字段全集存在:三类封面(article_image_cover / article_slide_cover /
@@ -67,14 +67,14 @@ function phpSection(src, sectionKey) {
const pagePhp = phpSection(php, 'page');
// 参考主题 admin-options.php 4934–5249 的字段顺序(含 fieldset 父字段与子字段)。
// page section 字段顺序(含 fieldset 父字段与子字段)。
const PAGE_FIELD_SEQUENCE = [
'article_image_cover',
'article_image_cover_option',
'scale', // article_image_cover_option.scale
'article_slide_cover',
'article_slide_cover_option',
// article_slide_cover_option(CFS_Module::slide 全字段)
// article_slide_cover_option(幻灯片封面全字段)
'direction', 'loop', 'button', 'pagination', 'effect', 'scale_height', 'scale',
'auto_height', 'max_height', 'min_height', 'pc_height', 'm_height',
'spacebetween', 'speed', 'autoplay', 'interval',
@@ -159,7 +159,7 @@ test('PHP page section 默认值对齐参考主题', () => {
assert.match(pagePhp, /'post_related_orderby',\s*'label'\s*=>\s*'排序方式',\s*'type'\s*=>\s*'select',\s*'default'\s*=>\s*'views'/);
});
test('PHP slide fieldset 全字段及嵌套依赖对齐 CFS_Module::slide', () => {
test('PHP slide fieldset 全字段及嵌套依赖齐全', () => {
// 幻灯片默认值(pagination: true, pc_height: 380, m_height: 180 为参考主题默认)。
assert.match(pagePhp, /'direction'\s*=>\s*'horizontal',\s*'loop'\s*=>\s*true,\s*'button'\s*=>\s*false,\s*'pagination'\s*=>\s*true,\s*'effect'\s*=>\s*'slide'/);
assert.match(pagePhp, /'pc_height'\s*=>\s*380,\s*'m_height'\s*=>\s*180,\s*'spacebetween'\s*=>\s*15,\s*'speed'\s*=>\s*0,\s*'autoplay'\s*=>\s*true,\s*'interval'\s*=>\s*4/);
@@ -199,9 +199,10 @@ test('JS schema 与 PHP 字段键一致(ui_only 一言行除外)', () => {
}
assert.ok(!js.includes(`key: 'share_s'`), 'JS page schema 残留 share_s');
assert.ok(!/key:\s*'post_rewards_/.test(js), 'JS page schema 残留 post_rewards_*');
// 参考主题视频封面配置教程链接以 ui_only description 承载。
// 视频封面配置说明以 ui_only description 承载,且不得再指向第三方站点。
assert.match(js, /ui_only:\s*true/);
assert.match(js, /https:\/\/www\.zibll\.com\/1900\.html/);
assert.match(js, /视频封面配置/);
assert.doesNotMatch(js, /zibll\.com/);
});
test('JS schema 默认值与依赖对齐参考主题', () => {
@@ -251,7 +252,7 @@ test('社交分享位于全局功能并使用参考主题唯一键集', () => {
assert.doesNotMatch(shareJs, /share_wechat_s|share_wechat_appid|share_wechat_app_secret|share_only_logo/);
});
test('post_rewards_* 迁移至用户功能页 rewards 组(对齐参考主题 8977 行)', () => {
test('post_rewards_* 迁移至用户功能页 rewards 组', () => {
assert.match(usersPhp, /\['key' => 'rewards', 'title' => '打赏', 'fields' => \[/);
assert.match(usersPhp, /'post_rewards_s', 'label' => '用户打赏功能', 'type' => 'switcher', 'default' => true/);
assert.match(usersPhp, /'post_rewards_text', 'label' => '打赏按钮文案', 'type' => 'input', 'default' => '赞赏'/);
@@ -287,7 +288,7 @@ test('运行时只读取新键并接线封面/缩进/版权/一言', () => {
assert.match(runtime, /max\(20, min\(200, \(int\) \(\$image_cover_option\['scale'\] \?\? 35\)\)\)/);
// 视频封面比例 clamp 0-200(0 = 不固定长宽比例)。
assert.match(runtime, /max\(0, min\(200, \(int\) \(\$video_cover_option\['scale'\] \?\? 0\)\)\)/);
// 幻灯片配置归一化(CFS_Module::slide 全字段)。
// 幻灯片配置归一化(幻灯片封面全字段)。
assert.match(runtime, /normalize_slide_cover_option\(\$slide_option_raw\)/);
for (const key of ['direction', 'loop', 'button', 'pagination', 'effect', 'scale_height', 'scale', 'auto_height', 'max_height', 'min_height', 'pc_height', 'm_height', 'spacebetween', 'speed', 'autoplay', 'interval']) {
assert.ok(runtime.includes(`'${key}'`), `normalize_slide_cover_option 缺少 ${key}`);