Publish approved compact advertisements and synchronize related project sources
32
AGENTS.md
@ -1,12 +1,38 @@
|
|||||||
# FNA_V3维护入口
|
# FNA_V3 项目维护入口
|
||||||
|
|
||||||
|
项目工作先读 GemDocs AI版项目总览、维护协议及 `/Users/hellcat/Documents/GemDocs/AI版/10-项目/fna_v3.md`。线上事务优先经白色机 SSH;网页与订阅 HTTP 访问须符合 GemDocs 的反代规则。
|
||||||
|
|
||||||
|
订阅检测已独立为 SubCheck,入口见 [SubCheck](/Users/hellcat/Documents/GemCodes/subcheck/AGENTS.md);cfn来源适配与调查见 [CFN.md](/Users/hellcat/Documents/GemCodes/subcheck/docs/CFN.md)。fnb不再保存检测实现。代码、凭据、业务数据及并行修改按当前任务授权处理。
|
||||||
|
|
||||||
|
## FNA_V3 本地副本维护
|
||||||
|
|
||||||
|
CFN页头SVG猫和两行品牌文字的维护与回退见[品牌标志](docs/maintenance/BRANDING.md),已于2026-10-31发布,见[界面发布记录](docs/maintenance/UI_RELEASE_2026-10-31.md)。
|
||||||
|
|
||||||
|
本目录为独立 FNA_V3 副本,身份与环境以 GemDocs AI版 `10-项目/fna_v3.md` 为准;上述 FN_B 入口保留来源背景,不代表授权修改 FN_B。文章广告实现、配置与验收见 [广告维护说明](docs/maintenance/ADVERTISING.md)。统一机场推荐数据、正文替换和教程末尾展示见[机场推荐维护](docs/maintenance/AIRPORT_RECOMMENDATIONS.md),已于2026-10-31发布,见[界面发布记录](docs/maintenance/UI_RELEASE_2026-10-31.md)。免费节点详情页的只读结构化渲染、订阅保护与回退见[内容页重设计](docs/maintenance/FREENODE_ARTICLE_LAYOUT.md)。
|
||||||
|
|
||||||
|
SEO 的只读审计、优化顺序与逐项验收统一维护在 [SEO 优化建议与执行清单](docs/maintenance/SEO_PLAN.md),2026-10-22 建立。清单中的建议不代表已实施,后续按用户指定项目推进并更新本文件所链接的唯一正文。
|
||||||
|
|
||||||
|
## CFN系绘图接手
|
||||||
|
|
||||||
|
2026-10-23用户明确将此前由张天承担的绘图工作交给“画师【CFN系】”(personnel-position:cd029d9db8454ec68172b221ff35e6f6)。FNA_V3主程继续开发工作,后续绘图由该画师岗位承接,避免重复制作。本记录仅转交绘图范围,不改变开发或上线权限;未向原聊天发送消息。
|
||||||
|
|
||||||
|
风格已从原聊天最近作品及本地成图核实:现代主义剪纸拼贴、哑光色块、轻微丝网印刷颗粒、成熟动物比例、非对称构图和大块留白。参考文件在本项目output/imagegen/:freenode-dog-dalmatian-20261023.png、freenode-dog-dachshund-20261023.png、freenode-dogs-dance-20261023.png;同名txt保存完整提示词。延续视觉语言,每张更换主题或构图,不照搬布局。
|
||||||
|
|
||||||
|
接手首张试画及提示词:/Users/hellcat/Documents/Codex/2026-10-23/cfn/outputs/cfn-tuxedo-cat-20261023.png 和同名txt。用户已认可风格并继续扩充;2026-10-26按授权与后续猫狗作品一起归档到Resource V2,并接入本地FNA_V3,未发布到线上。归档和栏目配图的唯一维护入口见[本地插画资源与配图](docs/maintenance/ILLUSTRATIONS.md)。
|
||||||
|
|
||||||
|
教程栏目现为“入门教程”(/client)和“综合教程”(/advanced,原进阶教程)。栏目改名、首篇重写、DNS进阶文章及内容回退见[教程栏目维护](docs/maintenance/TUTORIALS.md)。原七篇旧教程均已处理:迁移文归进阶,其余按Android、iOS、Mac和Linux重写;另有Windows纯入门与DNS进阶文章。正文、图解和关联已本地验收,本地内容不代表线上发布。
|
||||||
|
|
||||||
## FNA 静态配图副本
|
## FNA 静态配图副本
|
||||||
|
|
||||||
2026-10-30起Resource保留原稿、图池和固定分配,FNA保存按内容去重的公开展示副本,由本站Nginx直接提供。同步、创建时校验、撤回、缓存与部署验收唯一正文见[静态配图副本](docs/maintenance/LOCAL_ILLUSTRATIONS.md)。用户访问图片不调用Resource、不执行PHP修复。
|
2026-10-30起Resource保留原稿、图池和固定分配,FNA保存按内容去重的公开展示副本,由本站Nginx直接提供。同步、创建时校验、撤回、缓存与部署验收唯一正文见[静态配图副本](docs/maintenance/LOCAL_ILLUSTRATIONS.md)。用户访问图片不调用Resource、不执行PHP修复。2026-10-31明确源端删除/停用不影响FNA独立副本或已有文章关联,修复与恢复原图记录见[独立副本保留修复](docs/maintenance/INDEPENDENT_ILLUSTRATIONS_FIX_2026-10-31.md)。
|
||||||
|
|
||||||
## AI 文章写作(必读)
|
## AI 文章写作(必读)
|
||||||
|
|
||||||
文章写作和发布先读docs/content/WRITING.md及docs/maintenance/EDITORIAL_API.md。项目身份和访问边界先读GemDocs AI版项目总览、维护协议及10-项目/fna_v3.md。
|
后续为 FNA_V3 选题、写作、重写、调整分类或撤下文章时,必须先读[AI写作与文章关联索引](docs/content/WRITING.md)。它是文章用途、稳定地址和正文关系的唯一登记入口。公开文章禁止出现“核对范围”“未实测”等内部核验/验收说明,具体禁止项与发布前检查按该写作规范执行;相关事实只留项目维护记录。写作时复用相关的下载、入门、进阶和排错内容,自然设置内链,并检查相关旧文是否需要补入口;完成后同步正文源、运行数据库和该索引,验收真实目标与锚点。未创建的文章不能编造链接,本地生效不能写成已上线;不自动开展全站重写或发布。
|
||||||
|
|
||||||
|
## 独立文章发布 API
|
||||||
|
|
||||||
|
用户已明确文章直接发布到 FNA_V3,不经过 ATOM。实现、调用契约、凭据边界及验收见[独立文章 API](docs/maintenance/EDITORIAL_API.md)。后续写稿使用本站草稿→签名预览→按hash发布→回执核对流程;相关旧文内链修改可同批提交。不要再用临时SQL脚本发布普通编辑文章。旧文首次接管必须显式指定原文章ID并保留URL;发布结果未知先查原请求UUID。代码已于2026-10-29随正式切换部署,生产临时编辑密钥在教程迁移后删除、接口默认关闭;后续按明确写作/发布任务临时启用并在完成后关闭,不扩大线上访问或发布范围。正式部署、备份、Git SHA及验收统一见[发布记录](docs/maintenance/RELEASE_PREFLIGHT_2026-10-28.md#正式切换2026-10-29)。
|
||||||
|
|
||||||
插画完成后按[自动交付](docs/maintenance/ILLUSTRATION_DELIVERY.md)提交批准批次;不要再手工上传发布/编辑图池或把保存草稿当作上线完成。
|
插画完成后按[自动交付](docs/maintenance/ILLUSTRATION_DELIVERY.md)提交批准批次;不要再手工上传发布/编辑图池或把保存草稿当作上线完成。
|
||||||
|
|
||||||
|
|||||||
@ -1,10 +1,16 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
return [
|
return [
|
||||||
'dpl' => ['enabled' => env('DPL_AD_ENABLED', true), 'url' => env('DPL_AD_URL', 'https://dp-link.net/')],
|
'dpl' => [
|
||||||
'fuc' => ['enabled' => env('FUC_AD_ENABLED', true), 'url' => env('FUC_AD_URL', 'https://xn--123-9i9dj97q.com/')],
|
'enabled' => env('DPL_AD_ENABLED', true),
|
||||||
|
'url' => 'https://dp-link.net/',
|
||||||
|
],
|
||||||
'hn' => [
|
'hn' => [
|
||||||
'enabled' => env('HN_AD_ENABLED', true),
|
'enabled' => env('HN_AD_ENABLED', true),
|
||||||
'url' => env('HN_AD_URL', 'https://hardnerd.net/'),
|
'url' => env('HN_AD_URL', env('APP_ENV', 'production') === 'local' ? 'http://hn.loc/' : 'https://hardnerd.net/'),
|
||||||
|
],
|
||||||
|
'fuc' => [
|
||||||
|
'enabled' => env('FUC_AD_ENABLED', true),
|
||||||
|
'url' => env('FUC_AD_URL', 'https://xn--123-9i9dj97q.com/'),
|
||||||
],
|
],
|
||||||
];
|
];
|
||||||
|
|||||||
5
docs/assets/advertising/20261031/README.md
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
# 2026-10-31矮版广告素材
|
||||||
|
|
||||||
|
李响制作、用户确认的三张最终素材及完整提示词。正式展示只使用assets.json登记的最终PNG;本地中间迭代图不作为生产候选。
|
||||||
|
|
||||||
|
固定广告位3.675:1、cover取景,福云center 40%。每次打开随机选一张,候选在template中,活动DOM只加载选中的一张;没有新增接口或轮播。原旧图保留用于恢复,不在同页叠加。
|
||||||
20
docs/assets/advertising/20261031/assets.json
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
{
|
||||||
|
"dpl": {
|
||||||
|
"path": "public/images/ads/dpl-ad-compact-wordmark-20261031.png",
|
||||||
|
"width": 2169,
|
||||||
|
"height": 725,
|
||||||
|
"sha256": "c0742c8f7102ea2ebb70feea5caa9113ef032df54e2ab9d9097d797a5a12e92b"
|
||||||
|
},
|
||||||
|
"hn": {
|
||||||
|
"path": "public/images/ads/hn-ad-compact-lowercase-20261031.png",
|
||||||
|
"width": 2021,
|
||||||
|
"height": 778,
|
||||||
|
"sha256": "6b1d981d4fe461d5f7a00f3f0ad79cad3ea92b767ddb13b5fd4acb1c9cb022ff"
|
||||||
|
},
|
||||||
|
"fuc": {
|
||||||
|
"path": "public/images/ads/fuc-ad-compact-five-years-20261031.png",
|
||||||
|
"width": 2141,
|
||||||
|
"height": 734,
|
||||||
|
"sha256": "48e26721e3d05f9e7ebedf8e08d182aad2b0f5f8e656f2d8a09122053692f045"
|
||||||
|
}
|
||||||
|
}
|
||||||
1
docs/assets/advertising/20261031/dpl-prompt.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
Use case: ads-marketing, identity-preserving redesign. Reference image: existing approved DPL advertisement, brand identity/style reference only. Create a NEW COMPOSITION for an EXTRA WIDE SHORT horizontal banner, exact target 1962x534 pixels, aspect ratio 3.674:1. This is NOT a smaller copy of the tall original and NOT original art centered with empty side gutters. Design natively to fill every edge of this short wide canvas. Preserve exact blue rounded DPL mark with white layered signal lines and DPL letters, dark navy blue grid background, blue/purple cyan gradient headline, subtle orbital network globe. Redesign layout: small DPL brand upper left, readable medium large headline below and a restrained short supporting line, compact blue CTA integrated lower left. Right half: simplified three slim floating network region cards with tiny flags and bars, arranged laterally in a shallow diagonal, not vertically stacked tall. Text EXACT: "DPL", "畅连全球网络", "日常访问 · 远程办公 · 在线娱乐", "查看套餐", and on cards "美国 · US", "日本 · JP", "香港 · HK". Tiny gray "广告" upper right. No numeric promises or extra text. Refined visual hierarchy: main headline about66px at1962wide; secondary32px; CTA32px. Strong whitespace without huge logo or giant headline. All elements comfortably within534pxheight, no cropping, no stretching, no mockup frame. Full-bleed native wide banner with well-balanced optical composition.
|
||||||
1
docs/assets/advertising/20261031/dpl-wordmark-prompt.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
Use case: text-localization. Edit the provided existing DPL compact horizontal advertisement. Change ONLY the small white brand wordmark beside the blue logo in the upper left from "DPL" to EXACT uppercase "DP-LINK.NET". Keep its height and clean sans serif font weight similar to the existing DPL text; extend the wordmark naturally to the right with refined tight optical kerning and balanced icon-to-text gap. Preserve the blue logo icon EXACTLY. Preserve every other pixel/compositional element as closely as possible: wide aspect ratio, dark navy grid, globe, region cards, gradients, headline "畅连全球网络", subtitle "日常访问 · 远程办公 · 在线娱乐", button "查看套餐", tiny 广告. No other wording changes. Do not redesign, enlarge, move or crop anything else. The replacement wordmark must read D P hyphen L I N K dot N E T: "DP-LINK.NET".
|
||||||
1
docs/assets/advertising/20261031/fuc-copy-prompt.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
Use case: text-localization. Edit the supplied existing FUC purple rocket advertisement. Replace ONLY the large white headline "全球网络中继服务" with EXACT "全球网络加速". Replace ONLY the smaller lavender subtitle "随时随处,尽情使用" with EXACT "五年稳定运营". Keep headline and subtitle left aligned with the same existing left edge, approximately same font size and weight as their respective old lines, retaining natural refined character spacing instead of stretching the shorter phrases to fill the previous width. Preserve existing logo and 福云 wordmark EXACTLY, deep purple starry background, rocket, planets, orbital curves, white 开始使用 button with arrow, tiny 广告 top-right, all positions and original wide canvas. No other wording or visual changes. Exact Chinese text is mandatory: 全球网络加速 / 五年稳定运营.
|
||||||
1
docs/assets/advertising/20261031/fuc-prompt.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
Use case: ads-marketing. Input1: CURRENT FUC homepage screenshot, visual-style reference ONLY, not a composition to crop or reuse. Input2: current official FUC continuous-cloud purple logo, brand mark reference, reproduce its distinctive exact loop/cloud shape; no giant 福 character. Design a NEW polished short extra-wide FUC display advertisement, target1962x534px, aspect3.674:1. Full-bleed deep royal purple #3e269d background, restrained violet/magenta orbital curves and sparse tiny stars, inspired by CURRENT homepage. Left quarter: tasteful official purple cloud mark paired with WHITE Chinese wordmark "福云" at restrained size, enough contrast. Middle-left/main area: readable bold WHITE exact headline "全球网络中继服务"; below smaller muted lavender exact subtitle "随时随处,尽情使用". Lower-left small refined white rounded pill CTA with purple exact text "开始使用" and a small right arrow. Right third: sophisticated minimal purple rocket/orbital illustration with soft magenta planet glow and flowing curved paths, not childish clipart, modest supporting scale. Allow strong clean negative space. Tiny light lavender "广告" upper right. Do NOT use old huge 福 glyph, white/lilac background, Netflix/video stills, platform trademarks, UI navbar or page chrome. No pricing, speed claims, numbers or extra text. Careful typography and compact horizontal hierarchy that belongs to a534px tall canvas. Not a scaled down tall ad, no side padding gutters or outer borders. Native full-width short banner.
|
||||||
1
docs/assets/advertising/20261031/hn-lowercase-prompt.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
Use case: text-localization and typography refinement. Edit this existing compact HN advertisement. Preserve exact H/lime-glasses icon, dark charcoal background, teal and violet glows, wide canvas and all Chinese wording. Change brand wordmark to EXACT all lowercase "hardnerd" (lowercase h, not capital H). Enlarge this gradient brand WORDMARK by about18 percent compared with current, keeping icon roughly current size and optically aligned beside wordmark; brand group centered. Shrink lower white Chinese tagline by about20 percent: exact "硬核架构,品质专线,全球网络畅通无阻". Increase clear vertical gap between brand row and tagline from current roughly50px to about95px at original2021px width. Put brand row around y300, tagline around y475; center the overall two-row composition. Refined restrained natural letter spacing, tagline on one line, no exaggerated tracking. Preserve plenty of safe space within central2021x550 visible banner crop; all main content stays within y180..570. Keep tiny gray 广告 upper right, no other text or graphics. Do not change the icon design. No CTA. Main requested changes only: brand larger and lowercase, tagline smaller, more space between rows.
|
||||||
1
docs/assets/advertising/20261031/hn-prompt.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
Use case: ads-marketing, identity-preserving redesign. Reference image: current Hardnerd advertisement, brand style/logo/text reference only. Create a NEW native extra-wide short banner 1962x534px, aspect ratio3.674:1. Do not scale down the tall old advertisement or letterbox it. Fill full canvas edge-to-edge with charcoal black, restrained teal glow left and violet glow right. Preserve EXACT H lime-glasses icon and gradient wordmark "Hardnerd" with capital H, original brand forms. Recompose using generous horizontal room: cohesive brand group centered around x981 y210, width about650px, icon balanced approximately95pxheight, wordmark about88px high. Below at y350 put the exact white tagline on one line "硬核架构,品质专线,全球网络畅通无阻", around42px font with subtle restrained natural tracking, not exaggerated wide character spacing. Tiny understated gray "广告" upper right. Keep whole group visually centered with balanced top/bottom margins, enough gap between brand and tagline. Only these texts. No green footer, no button or CTA, no shine or overly dramatic effects, no frame. Mature premium quiet typography designed for this exact short wide canvas, crisp legible Chinese and consistent brand proportions.
|
||||||
@ -8,6 +8,8 @@ # AI 写作与文章关联索引
|
|||||||
|
|
||||||
本文是写作流程、文章用途及文章关系的唯一维护入口。文章正文保存在各自源文件,数据库是页面实际读取的内容;栏目实现、渲染与备份方法见[教程维护](../maintenance/TUTORIALS.md),SEO项目状态见[SEO清单](../maintenance/SEO_PLAN.md)。不要在这些文档中再复制一份持续更新的文章关系表。
|
本文是写作流程、文章用途及文章关系的唯一维护入口。文章正文保存在各自源文件,数据库是页面实际读取的内容;栏目实现、渲染与备份方法见[教程维护](../maintenance/TUTORIALS.md),SEO项目状态见[SEO清单](../maintenance/SEO_PLAN.md)。不要在这些文档中再复制一份持续更新的文章关系表。
|
||||||
|
|
||||||
|
2026-10-31新增[统一机场推荐模块](../maintenance/AIRPORT_RECOMMENDATIONS.md):入门/综合教程自动在末尾展示,综合教程由展示层补入文内跳转;不要在正文源重复维护机场价格、地址和优惠码,也不要创建同名airport-recommendations锚点。已随[界面发布](../maintenance/UI_RELEASE_2026-10-31.md)上线。
|
||||||
|
|
||||||
## 1 写作前先确定读者要完成的任务
|
## 1 写作前先确定读者要完成的任务
|
||||||
|
|
||||||
- 入门教程:以第一次使用为前提,讲准备、下载、安装、配置、使用和基本排错。不要把客户端迁移作为普通入门教程的主线。
|
- 入门教程:以第一次使用为前提,讲准备、下载、安装、配置、使用和基本排错。不要把客户端迁移作为普通入门教程的主线。
|
||||||
@ -65,6 +67,9 @@ ## 2 当前文章登记
|
|||||||
| cfw-mac-legacy | 210 / Mac | Clash Verge Rev 使用教程:Mac 安装、订阅与系统代理 | `/a/m173.html` | [verge-mac.md](tutorials/verge-mac.md);本地API版本2 | Mac操作入口;#install DMG安装,#import 订阅,系统代理与退出排错;无设备联网实测 |
|
| cfw-mac-legacy | 210 / Mac | Clash Verge Rev 使用教程:Mac 安装、订阅与系统代理 | `/a/m173.html` | [verge-mac.md](tutorials/verge-mac.md);本地API版本2 | Mac操作入口;#install DMG安装,#import 订阅,系统代理与退出排错;无设备联网实测 |
|
||||||
| cfw-linux-legacy | 211 / Linux | Clash Verge Rev 使用教程:Linux 安装、订阅与代理设置 | `/a/m174.html` | [verge-linux.md](tutorials/verge-linux.md);本地API版本5 | Linux桌面入门;#install 包格式与架构,#import 订阅,#terminal 单条curl代理验证;不适用于无桌面的服务器 |
|
| cfw-linux-legacy | 211 / Linux | Clash Verge Rev 使用教程:Linux 安装、订阅与代理设置 | `/a/m174.html` | [verge-linux.md](tutorials/verge-linux.md);本地API版本5 | Linux桌面入门;#install 包格式与架构,#import 订阅,#terminal 单条curl代理验证;不适用于无桌面的服务器 |
|
||||||
| system-proxy-vs-tun | 365 / 综合教程 | 系统代理和 TUN 有什么区别?接管范围、使用选择与排错 | `/a/system-proxy-vs-tun.html` | [system-proxy-tun.md](tutorials/system-proxy-tun.md);本地API版本1 | 桌面代理接管与出口选择;`#choose` 场景选择、`#switch` 切换检查、`#troubleshoot` 排错;三张流程图 |
|
| system-proxy-vs-tun | 365 / 综合教程 | 系统代理和 TUN 有什么区别?接管范围、使用选择与排错 | `/a/system-proxy-vs-tun.html` | [system-proxy-tun.md](tutorials/system-proxy-tun.md);本地API版本1 | 桌面代理接管与出口选择;`#choose` 场景选择、`#switch` 切换检查、`#troubleshoot` 排错;三张流程图 |
|
||||||
|
| clash-routing-modes | 366 / 综合教程 | Clash 规则、全局和直连怎么选?代理组与分流排错教程 | `/a/clash-rule-global-direct.html` | [clash-routing-modes.md](tutorials/clash-routing-modes.md);2026-10-31本地ID366/版本1,正式ID382/版本1已发布 | 模式选择与代理组分流;`#groups` 组内选择、`#custom` 添加规则、`#verify` 验证新连接 |
|
||||||
|
|
||||||
|
2026-10-31新教程正式ID382/版本1、本地ID366/版本1已发表;系统代理/TUN正文补入口后两环境均为API版本2(正式ID376、本地ID365)。正式发布时间14:58:28北京时间,IndexNow由VPS-003提交返回200,服务器HTTP与图哈希/锚点验收通过。唯一状态与恢复记录见[规则模式教程发布记录](../maintenance/ROUTING_MODES_2026-10-31.md)。
|
||||||
|
|
||||||
这里只登记长期编辑内容及值得复用的稳定资源说明,不逐条收录日更节点或账号文章。稳定入口为 `/`(当前免费节点)、`/freenode`(历史分享归档)、`/client`(入门)、`/advanced`(综合教程);平台入口和名称修改另按项目路由核对,不从名称自行拼接。
|
这里只登记长期编辑内容及值得复用的稳定资源说明,不逐条收录日更节点或账号文章。稳定入口为 `/`(当前免费节点)、`/freenode`(历史分享归档)、`/client`(入门)、`/advanced`(综合教程);平台入口和名称修改另按项目路由核对,不从名称自行拼接。
|
||||||
|
|
||||||
@ -107,6 +112,10 @@ ## 3 已有文章关系
|
|||||||
| system-proxy-vs-tun | cfw-mac-legacy `#enable` | 切换前完成 Mac 基本连接 | 已在本地正文实现 |
|
| system-proxy-vs-tun | cfw-mac-legacy `#enable` | 切换前完成 Mac 基本连接 | 已在本地正文实现 |
|
||||||
| system-proxy-vs-tun | cfw-linux-legacy `#connect` / `#terminal` | Linux 基础连接及单条命令显式代理 | 已在本地正文实现 |
|
| system-proxy-vs-tun | cfw-linux-legacy `#connect` / `#terminal` | Linux 基础连接及单条命令显式代理 | 已在本地正文实现 |
|
||||||
| system-proxy-vs-tun | mihomo-dns `#dns-2` | 继续检查 DNS 接管、加密和出口 | 已在本地正文实现 |
|
| system-proxy-vs-tun | mihomo-dns `#dns-2` | 继续检查 DNS 接管、加密和出口 | 已在本地正文实现 |
|
||||||
|
| system-proxy-vs-tun | clash-routing-modes `#groups` | 已接管但走错出口时检查规则和代理组;放在场景选择之前 | 2026-10-31本地与正式已发布 |
|
||||||
|
| clash-routing-modes | verge-windows-start `#enable` / cfw-mac-legacy `#enable` | 尚未完成基本连接时返回对应平台操作 | 2026-10-31本地与正式已发布 |
|
||||||
|
| clash-routing-modes | system-proxy-vs-tun `#routing` / `#troubleshoot` | 解释接管和分流的区别,以及看不到连接时排错 | 2026-10-31本地与正式已发布 |
|
||||||
|
| clash-routing-modes | mihomo-dns `#dns-2` | 出口正确但域名解析仍异常时继续查DNS | 2026-10-31本地与正式已发布 |
|
||||||
|
|
||||||
两篇Android教程通过订阅格式段落互链;Mac下载指南与操作教程互链,Linux从下载指南和真实Linux栏目获得入口,iOS沿用真实iOS栏目入口。系统代理与TUN专题由Windows和DNS正文提供入口,并指向三平台的基础操作及DNS专题。目录、标签、导航和热门榜不算正文关联;正文内链及锚点已经本地HTTP验证。
|
两篇Android教程通过订阅格式段落互链;Mac下载指南与操作教程互链,Linux从下载指南和真实Linux栏目获得入口,iOS沿用真实iOS栏目入口。系统代理与TUN专题由Windows和DNS正文提供入口,并指向三平台的基础操作及DNS专题。目录、标签、导航和热门榜不算正文关联;正文内链及锚点已经本地HTTP验证。
|
||||||
|
|
||||||
|
|||||||
@ -0,0 +1,9 @@
|
|||||||
|
# 规则、全局与直连配图
|
||||||
|
|
||||||
|
原生 SVG 为可编辑源,PNG 为文章 API 上传用图;未使用外部截图。封面沿用 system-proxy-tun-cover.svg 的现有样式;正文两图分别表达路由模式与代理组选择路径。
|
||||||
|
|
||||||
|
- `cover.svg` / `cover.png`:960×540。
|
||||||
|
- `modes.svg` / `modes.png`:1000×670。
|
||||||
|
- `groups.svg` / `groups.png`:1000×610。
|
||||||
|
|
||||||
|
正文源:../../clash-routing-modes.md。技术图使用本机 Chrome 在禁网页面渲染,正式展示副本通过文章资产 API 发布。制作/发布记录见 ../../../../maintenance/ROUTING_MODES_2026-10-31.md。
|
||||||
BIN
docs/content/tutorials/assets/clash-routing-modes/cover.png
Normal file
|
After Width: | Height: | Size: 26 KiB |
@ -0,0 +1 @@
|
|||||||
|
<svg xmlns="http://www.w3.org/2000/svg" width="960" height="540" viewBox="0 0 960 540"><rect width="960" height="540" fill="#eaf2f7"/><rect x="55" y="62" width="6" height="412" fill="#347c99"/><g font-family="Arial, PingFang SC, Microsoft YaHei, sans-serif"><text x="97" y="130" font-size="24" fill="#47748a" letter-spacing="3">代理设置 · 综合教程</text><text x="97" y="265" font-size="51" fill="#18394d" font-weight="700">规则、全局与直连</text><text x="100" y="327" font-size="30" fill="#547084">分流模式 · 代理组 · 连接验证</text><path d="M100 403H725" stroke="#92b6c9" stroke-width="3"/><circle cx="100" cy="403" r="9" fill="#347c99"/><circle cx="410" cy="403" r="9" fill="#347c99"/><circle cx="725" cy="403" r="9" fill="#347c99"/></g></svg>
|
||||||
|
After Width: | Height: | Size: 775 B |
BIN
docs/content/tutorials/assets/clash-routing-modes/groups.png
Normal file
|
After Width: | Height: | Size: 84 KiB |
@ -0,0 +1 @@
|
|||||||
|
<svg xmlns="http://www.w3.org/2000/svg" width="1000" height="610" viewBox="0 0 1000 610"><rect width="1000" height="610" rx="20" fill="#f0f5f7"/><g font-family="PingFang SC, Microsoft YaHei, sans-serif"><text x="45" y="64" font-size="34" fill="#264658" font-weight="600">同一条影音规则,两种不同的组内选择</text><text x="45" y="115" font-size="29" fill="#264658" font-weight="600">情况一:影音组直接选择节点甲</text><rect x="45" y="145" width="275" height="95" rx="14" fill="#fff" stroke="#bed0d9"/><text x="69" y="204" font-size="30" fill="#264658" font-weight="600">影音规则</text><text x="326" y="204" font-size="29" fill="#264658" font-weight="400">→</text><rect x="363" y="145" width="275" height="95" rx="14" fill="#fff" stroke="#bed0d9"/><text x="387" y="204" font-size="30" fill="#264658" font-weight="600">影音组</text><text x="644" y="204" font-size="29" fill="#264658" font-weight="400">→</text><rect x="681" y="145" width="275" height="95" rx="14" fill="#e3edf3" stroke="#bed0d9"/><text x="705" y="204" font-size="30" fill="#264658" font-weight="600">节点甲</text><text x="45" y="285" font-size="26" fill="#5d7380" font-weight="400">调整“节点选择”不会改变上面这条选择路径。</text><text x="45" y="345" font-size="29" fill="#264658" font-weight="600">情况二:影音组选择另一个代理组</text><rect x="45" y="375" width="195" height="95" rx="14" fill="#fff" stroke="#bed0d9"/><text x="69" y="434" font-size="30" fill="#264658" font-weight="600">影音规则</text><text x="246" y="434" font-size="29" fill="#264658" font-weight="400">→</text><rect x="283" y="375" width="195" height="95" rx="14" fill="#fff" stroke="#bed0d9"/><text x="307" y="434" font-size="30" fill="#264658" font-weight="600">影音组</text><text x="484" y="434" font-size="29" fill="#264658" font-weight="400">→</text><rect x="521" y="375" width="195" height="95" rx="14" fill="#fff" stroke="#bed0d9"/><text x="545" y="434" font-size="30" fill="#264658" font-weight="600">节点选择</text><text x="722" y="434" font-size="29" fill="#264658" font-weight="400">→</text><rect x="759" y="375" width="195" height="95" rx="14" fill="#e3edf3" stroke="#bed0d9"/><text x="783" y="434" font-size="30" fill="#264658" font-weight="600">节点乙</text><text x="45" y="515" font-size="26" fill="#5d7380" font-weight="400">此时调整“节点选择”,才会影响影音连接的后续出口。</text><text x="45" y="571" font-size="26" fill="#5d7380" font-weight="400">示意组名:请以自己的配置与新连接详情为准。</text></g></svg>
|
||||||
|
After Width: | Height: | Size: 2.5 KiB |
BIN
docs/content/tutorials/assets/clash-routing-modes/modes.png
Normal file
|
After Width: | Height: | Size: 75 KiB |
@ -0,0 +1 @@
|
|||||||
|
<svg xmlns="http://www.w3.org/2000/svg" width="1000" height="670" viewBox="0 0 1000 670"><rect width="1000" height="670" rx="20" fill="#f0f5f7"/><g font-family="PingFang SC, Microsoft YaHei, sans-serif"><text x="45" y="64" font-size="34" fill="#264658" font-weight="600">模式决定:已进入客户端的连接怎样出去</text><rect x="45" y="105" width="910" height="86" rx="14" fill="#fff" stroke="#bed0d9"/><text x="75" y="159" font-size="32" fill="#264658" font-weight="600">请求已进入 Mihomo</text><rect x="45" y="245" width="154" height="100" rx="14" fill="#e1ece8" stroke="#bed0d9"/><text x="87" y="306" font-size="32" fill="#264658" font-weight="600">规则</text><text x="214" y="306" font-size="32" fill="#264658" font-weight="400">→</text><rect x="265" y="245" width="330" height="100" rx="14" fill="#fff" stroke="#bed0d9"/><text x="290" y="305" font-size="29" fill="#264658" font-weight="400">匹配当前规则</text><text x="612" y="306" font-size="32" fill="#264658" font-weight="400">→</text><rect x="665" y="245" width="290" height="100" rx="14" fill="#fff" stroke="#bed0d9"/><text x="685" y="305" font-size="26" fill="#264658" font-weight="400">代理组 / 直连 / 拒绝</text><rect x="45" y="375" width="154" height="100" rx="14" fill="#e1eaf3" stroke="#bed0d9"/><text x="87" y="436" font-size="32" fill="#264658" font-weight="600">全局</text><text x="214" y="436" font-size="32" fill="#264658" font-weight="400">→</text><rect x="265" y="375" width="330" height="100" rx="14" fill="#fff" stroke="#bed0d9"/><text x="290" y="435" font-size="29" fill="#264658" font-weight="400">使用 GLOBAL 当前选择</text><text x="612" y="436" font-size="32" fill="#264658" font-weight="400">→</text><rect x="665" y="375" width="290" height="100" rx="14" fill="#fff" stroke="#bed0d9"/><text x="685" y="435" font-size="26" fill="#264658" font-weight="400">选中的节点或策略</text><rect x="45" y="505" width="154" height="100" rx="14" fill="#efe9df" stroke="#bed0d9"/><text x="87" y="566" font-size="32" fill="#264658" font-weight="600">直连</text><text x="214" y="566" font-size="32" fill="#264658" font-weight="400">→</text><rect x="265" y="505" width="330" height="100" rx="14" fill="#fff" stroke="#bed0d9"/><text x="290" y="565" font-size="29" fill="#264658" font-weight="400">使用本地网络</text><text x="612" y="566" font-size="32" fill="#264658" font-weight="400">→</text><rect x="665" y="505" width="290" height="100" rx="14" fill="#fff" stroke="#bed0d9"/><text x="685" y="565" font-size="26" fill="#264658" font-weight="400">直接连接目标</text><text x="45" y="645" font-size="26" fill="#5d7380" font-weight="400">未进入客户端的连接,不会仅因切换模式而被接管。</text></g></svg>
|
||||||
|
After Width: | Height: | Size: 2.7 KiB |
1
docs/content/tutorials/clash-routing-modes.html
Normal file
98
docs/content/tutorials/clash-routing-modes.md
Normal file
@ -0,0 +1,98 @@
|
|||||||
|
同一个网站,规则模式打不开,切成全局却正常;明明选了新节点,连接记录里还是另一个名字。遇到这类问题,先看这条连接实际走了哪条规则、哪个代理组,再决定要改什么。
|
||||||
|
|
||||||
|
本文以 Clash Verge Rev 和 Mihomo 为例,讲清规则、全局、直连三个模式,并完成一次“只让指定网站走指定出口”的配置。还没有完成导入和首次连接,可以先看 [Windows 入门教程](/a/clash-verge-rev-windows.html#enable);Mac 用户可以从[对应操作步骤](/a/m173.html#enable)开始。
|
||||||
|
|
||||||
|
<nav class="guide-toc" aria-label="文章目录"><strong>阅读路线</strong><a href="#modes">三个模式怎么选</a><a href="#groups">为什么换节点没效果</a><a href="#order">规则先后顺序</a><a href="#custom">添加一条网站规则</a><a href="#verify">从连接记录验证</a><a href="#troubleshoot">按现象排查</a></nav>
|
||||||
|
|
||||||
|
<h2 id="modes">01 三个模式,改变的是出口选择</h2>
|
||||||
|
|
||||||
|
先确定前提:请求已经进入了客户端。系统代理、应用自身代理设置和 TUN 负责把流量送进来,下面三个模式负责决定进去以后怎样处理。未被接管的应用,不会因为切到全局就自动经过客户端;接管方式见[系统代理与 TUN 的区别](/a/system-proxy-vs-tun.html#routing)。
|
||||||
|
|
||||||
|
<div class="table-wrap">
|
||||||
|
|
||||||
|
| 模式 | 进入客户端后的普通业务连接 | 适合什么时候用 |
|
||||||
|
| --- | --- | --- |
|
||||||
|
| 规则(Rule) | 按当前配置匹配规则,选择直连、代理组或其他策略 | 日常分流:不同网站使用不同出口 |
|
||||||
|
| 全局(Global) | 使用 GLOBAL 组当前选择的节点或策略 | 临时对比:判断问题是否与分流结果有关 |
|
||||||
|
| 直连(Direct) | 由本地网络直接连接目标 | 临时检查本地网络,或不需要代理出口时 |
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
这三个模式是路由选择,不是速度档位。全局也要检查 GLOBAL 组究竟选了什么:如果选的是 DIRECT,结果仍然是直连;如果选的是另一个代理组,还要继续看那个组的选择。[Mihomo 运行模式说明](https://wiki.metacubex.one/config/general/)
|
||||||
|
|
||||||
|
直连模式也不等于退出客户端:系统代理、TUN 等入口可能仍开启。要停用接管,需要处理对应开关,不能只把模式改成“直连”。[Clash Verge Rev 名词解释](https://www.clashverge.dev/guide/term.html)
|
||||||
|
|
||||||
|
<figure class="guide-figure"><img src="/images/editorial/98a43bdd771dd4c6c5ec6b87bb5f0ebf679fa2b228dddbb764adecf50b0374e9.png" alt="请求进入客户端后,规则模式按规则分流,全局模式使用 GLOBAL 选择,直连模式使用本地网络" width="1000" height="670"><figcaption>图 1:模式作用于已进入客户端的连接;切模式不会补上接管范围的缺口。</figcaption></figure>
|
||||||
|
|
||||||
|
<h2 id="groups">02 换了节点没效果,可能换错了组</h2>
|
||||||
|
|
||||||
|
代理页里有“节点选择”“流媒体”“自动选择”等分组时,不要把它们当成一排作用相同的开关。规则通常先指向一个组,组再选节点,也可能继续选另一个组。
|
||||||
|
|
||||||
|
例如,一份配置把视频网站分给“影音”,普通网页交给“节点选择”。你在“节点选择”里换成节点乙,但“影音”仍直接选着节点甲,视频连接就可能继续走甲。只有“影音”选择了“节点选择”这个组,它才会沿着这条选择关系继续向下找出口。
|
||||||
|
|
||||||
|
<figure class="guide-figure"><img src="/images/editorial/417b203a4af30200b6ed3b37d0b0e823a9b47db49e2d743b1110b35329cc5de8.png" alt="规则命中影音组后,该组直接选择节点甲时不经过节点选择组;选择节点选择组时才跟随其中的节点乙" width="1000" height="610"><figcaption>图 2:两种配置的差别在于“影音”组的选择。组名只是配置中的名称,实际关系要查看当前选择。</figcaption></figure>
|
||||||
|
|
||||||
|
手动选择组(`select`)由你决定使用哪个选项;如果它选择的是自动选择组(`url-test`),后者仍会按自己的测速配置选择节点。想固定到具体节点,就检查整条选择路径,而不是只看最外层的组名。[手动选择组](https://wiki.metacubex.one/config/proxy-groups/select/)与[自动选择组](https://wiki.metacubex.one/config/proxy-groups/url-test/)
|
||||||
|
|
||||||
|
实际排查时,可以在连接详情里找策略、代理链或类似字段。不同界面展示顺序可能不同,重点是认出“命中了哪个组”和“最终使用哪个节点”。
|
||||||
|
|
||||||
|
<h2 id="order">03 先看顺序,再看规则写得对不对</h2>
|
||||||
|
|
||||||
|
Mihomo 的路由规则从上往下匹配。通常前面命中的规则就决定了后续策略,因此“更精确”不会自动获得更高优先级;精确规则如果排在已经覆盖它的规则之后,仍可能用不上。涉及 UDP 等条件时,还要注意目标策略是否具备相应支持。[路由规则与优先级](https://wiki.metacubex.one/config/rules/)
|
||||||
|
|
||||||
|
下面是用来理解顺序的片段,不是可以替换整个订阅的完整配置。`example.com` 是示例域名,“节点选择”必须换成你配置中真实存在的组名:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
rules:
|
||||||
|
- DOMAIN,video.example.com,节点选择
|
||||||
|
- DOMAIN-SUFFIX,example.com,DIRECT
|
||||||
|
- MATCH,节点选择
|
||||||
|
```
|
||||||
|
|
||||||
|
在这个例子里,访问 `video.example.com` 先命中第一条,交给“节点选择”;访问 `docs.example.com` 则命中第二条,使用直连。如果把前两条交换,`video.example.com` 也会先被域名后缀规则接住。
|
||||||
|
|
||||||
|
`DOMAIN` 对应完整域名;`DOMAIN-SUFFIX` 对应该域名及其子域名。末尾的 `MATCH` 用于接住前面没有匹配到的连接。不要为了让某个网站使用节点,就在前面塞一条覆盖所有连接的 MATCH:那会让后面的分流规则失去机会。
|
||||||
|
|
||||||
|
<h2 id="custom">04 在 Verge Rev 里给一个网站添加规则</h2>
|
||||||
|
|
||||||
|
先选一个你确实需要调整的网站。例如,某个域名在当前网络下直连不通,而你已有能访问它的节点。只改这一项,验证后再扩展范围。
|
||||||
|
|
||||||
|
1. 在“订阅”页面找到**正在使用的配置**,右键选择“编辑规则”。这里维护的是该订阅的自定义规则,可以保留在后续订阅更新中。
|
||||||
|
2. 新增规则,类型先选 `DOMAIN`,内容填写连接记录里的完整主机名,例如 `video.example.com`。不要填 `https://`、路径或整个网页地址。
|
||||||
|
3. 代理策略选择当前配置中实际存在的代理组;需要直连时选 DIRECT,需要使用节点时选相应的组,并确认组内选择。
|
||||||
|
4. 需要覆盖订阅中已有的分流结果时,放入**前置规则**,同时检查前面是否还有会先命中的自定义项。不要把它追加在已兜底的 MATCH 后面。
|
||||||
|
5. 保存并确认没有配置错误,保持规则模式,然后让目标应用重新发起连接。
|
||||||
|
|
||||||
|
界面入口与前置/后置规则的含义可参考 [Verge Rev 自定义规则](https://www.clashverge.dev/guide/rules.html)。这与直接改下载下来的订阅正文不同;后者可能被下一次更新覆盖。
|
||||||
|
|
||||||
|
一个网页可能同时访问登录、图片、视频和接口等多个域名。添加主站域名后页面只恢复了一部分,先查看失败连接,再补真正需要的域名。不要因为一个资源加载失败,就直接扩大成整类域名、全部应用或全部流量。
|
||||||
|
|
||||||
|
<h2 id="verify">05 改完以后,检查一条新连接</h2>
|
||||||
|
|
||||||
|
验证时保持订阅、模式和接管方式稳定,只调整刚才那条规则或对应组的选择。打开“连接”页面,清除筛选,重新访问目标内容,找到刚建立的连接,逐项检查:
|
||||||
|
|
||||||
|
- **目标是否相同:** 看实际域名或 IP,而不是只认浏览器标签页上的网站名。
|
||||||
|
- **规则是否符合预期:** 有没有命中新加的规则,还是先被另一条规则或规则集处理。
|
||||||
|
- **策略是否正确:** 命中的组是否是你刚才修改的组,组内有没有继续指向其他组或 DIRECT。
|
||||||
|
- **应用是否恢复:** 出口符合预期以后,再验证原先失败的操作,例如播放、登录或下载。
|
||||||
|
|
||||||
|
已有长连接不适合作为换规则、换节点后的唯一观察对象。可优先重连目标应用,或只关闭相关连接后重新测试;直接清空所有连接会影响其他正在使用的程序。
|
||||||
|
|
||||||
|
如果仍无法区分,可以做一次有控制的对比:记录当前设置,在全局模式中选择**同一个明确的节点**,重新建立目标连接。全局可用、规则模式不可用,提示你继续查分流和代理组;它并不能单独证明某一条规则错误,因为模式变化也可能影响其他配置行为。对比后切回规则模式,修正具体目标。
|
||||||
|
|
||||||
|
<h2 id="troubleshoot">06 几种常见现象,对应查哪里</h2>
|
||||||
|
|
||||||
|
<div class="table-wrap">
|
||||||
|
|
||||||
|
| 现象 | 下一步检查 |
|
||||||
|
| --- | --- |
|
||||||
|
| 换了节点,目标连接仍走旧节点 | 是否改错代理组、组里还有嵌套选择,以及观察的是否为旧连接 |
|
||||||
|
| 明明加了代理规则,却显示 DIRECT | 当前模式、规则顺序、实际域名,以及命中组是否选了 DIRECT |
|
||||||
|
| 全局能用,规则不能用 | 对比同一目标的新连接,确认规则模式的最终出口是否与全局相同 |
|
||||||
|
| 网页文字出现了,图片或视频失败 | 找失败资源的域名与连接,逐项判断,不只给主站加规则 |
|
||||||
|
| 完全找不到应用的连接记录 | 清除筛选、查看日志,再检查应用代理或 TUN 接管;规则还没到发挥作用的阶段 |
|
||||||
|
| 订阅更新后又不对了 | 是否改了会被覆盖的订阅正文、当前配置是否切换、原代理组是否还存在 |
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
如果连接已经走了预期节点,但仍出现域名解析异常,继续检查 [DNS 接管、加密和出口](/a/mihomo-dns-leak.html#dns-2)。如果客户端根本看不到目标流量,则回到[系统代理与 TUN 的排查步骤](/a/system-proxy-vs-tun.html#troubleshoot)。先根据连接记录确定问题发生在哪一步,再动对应设置,通常比不断切换三个模式更有效。
|
||||||
@ -43,6 +43,8 @@
|
|||||||
|
|
||||||
一个具体例子:浏览器和下载工具访问同一域名,浏览器连接记录里显示了节点,下载工具却没有记录。此时应优先检查下载工具的代理设置或接管方式;反复切换全局,通常没有解决前面的缺口。
|
一个具体例子:浏览器和下载工具访问同一域名,浏览器连接记录里显示了节点,下载工具却没有记录。此时应优先检查下载工具的代理设置或接管方式;反复切换全局,通常没有解决前面的缺口。
|
||||||
|
|
||||||
|
如果流量已经进入客户端,却仍走错节点,可以继续看[规则模式、代理组与实际出口的检查方法](/a/clash-rule-global-direct.html#groups),分清应该改哪一个组。
|
||||||
|
|
||||||
<h2 id="choose">04 按应用需求选择,不必一开始全部打开</h2>
|
<h2 id="choose">04 按应用需求选择,不必一开始全部打开</h2>
|
||||||
|
|
||||||
| 你要完成的事 | 可以先这样做 |
|
| 你要完成的事 | 可以先这样做 |
|
||||||
|
|||||||
@ -45,3 +45,7 @@ ## 状态与恢复
|
|||||||
IndexNow的结果、环境开关及服务器延时重试见[教程SEO通知](EDITORIAL_INDEXNOW.md)。通知pending只重试后处理,不再次发表正文。
|
IndexNow的结果、环境开关及服务器延时重试见[教程SEO通知](EDITORIAL_INDEXNOW.md)。通知pending只重试后处理,不再次发表正文。
|
||||||
|
|
||||||
2026-10-31编辑发布已接入[IndexNow通知与重试](EDITORIAL_INDEXNOW.md),复用发布回执effects;通知pending不表示正文未发布,禁止为通知重发正文。
|
2026-10-31编辑发布已接入[IndexNow通知与重试](EDITORIAL_INDEXNOW.md),复用发布回执effects;通知pending不表示正文未发布,禁止为通知重发正文。
|
||||||
|
|
||||||
|
## 图片发布目录
|
||||||
|
|
||||||
|
2026-10-31首篇真实上传配图时发现正式 `public/images/editorial` 缺失。用户明确批准创建该专用目录并设为nginx所有、0755;已实施并完成真实文章发布。上级public/images权限未改变。以后部署预检该目录存在且执行身份nginx可写,禁止临时以root执行文章发布来绕过。回执见[首篇周期教程](ROUTING_MODES_2026-10-31.md)。
|
||||||
|
|||||||
@ -9,3 +9,9 @@ # 插画交付接收
|
|||||||
回退先停fna-illustration-delivery.timer和service、关闭开关;静态副本和旧配图保留。原同步/静态展示维护见[静态配图](LOCAL_ILLUSTRATIONS.md)。批次验收与具体SHA由Resource发布记录维护。
|
回退先停fna-illustration-delivery.timer和service、关闭开关;静态副本和旧配图保留。原同步/静态展示维护见[静态配图](LOCAL_ILLUSTRATIONS.md)。批次验收与具体SHA由Resource发布记录维护。
|
||||||
|
|
||||||
当前已上线,真实自动回执与既有停用图片的验收差异见[发布记录](/Users/hellcat/Documents/GemCodes/resource.loc/v2/docs/ILLUSTRATION_DELIVERY_RELEASE.md)。
|
当前已上线,真实自动回执与既有停用图片的验收差异见[发布记录](/Users/hellcat/Documents/GemCodes/resource.loc/v2/docs/ILLUSTRATION_DELIVERY_RELEASE.md)。
|
||||||
|
|
||||||
|
## 2026-10-30 乔治002—011交付
|
||||||
|
|
||||||
|
用户明确批准发布后,通过唯一交付工具提交10张新画:002—006猫图至freenode,007—011狗图至shadowrocketids。批次`06025e43-7a07-5922-a60a-1b694398c28d`经received、awaiting_sync到completed,Resource处理1次、无错误,完成时间2026-10-30 11:09:41 UTC(北京时间19:09:41)。回执包含10项资产;completed表示FNA已核对本批静态副本及SHA并完成ACK,Resource再次确认发布、授权和图池成员。
|
||||||
|
|
||||||
|
私有交付目录为`storage/app/private/illustration-deliveries/20261030-george-002-011/`,含原图、完整提示词、delivery.json及receipt.json;原来源文件保留。画师只执行check、submit和status,后续由服务器自动处理,没有手工修改图池、分配旧文章或执行全量同步。本次无代码部署;已完成服务器侧自动交付验收,未做线上页面验收。
|
||||||
|
|||||||
@ -132,3 +132,12 @@ ## 文章点赞增量发布(2026-10-29)
|
|||||||
## 静态配图副本增量发布(2026-10-30)
|
## 静态配图副本增量发布(2026-10-30)
|
||||||
|
|
||||||
功能提交`ce27dbdd1eb206a9b7e7ac9b5a1c77778ed75e03`已推送并部署test和正式,基于最新正式f315215保留年度点赞及并行生成模板;未发布广告。Resource保留素材/图池/分配,FNA保存按SHA去重的公开副本,Nginx直接提供。37份文件覆盖正式176篇、test174篇;35项/277断言自动测试、test283项及正式246项服务器检查均通过。正文/原始字段和年度点赞参数摘要不变,未新增后台任务或Resource权限。机制、恢复点和退役边界见[静态配图维护](LOCAL_ILLUSTRATIONS.md),逐项回执见[验收JSON](STATIC_ILLUSTRATIONS_RELEASE_2026-10-30.json)。已完成服务器侧验收,未做线上页面验收。
|
功能提交`ce27dbdd1eb206a9b7e7ac9b5a1c77778ed75e03`已推送并部署test和正式,基于最新正式f315215保留年度点赞及并行生成模板;未发布广告。Resource保留素材/图池/分配,FNA保存按SHA去重的公开副本,Nginx直接提供。37份文件覆盖正式176篇、test174篇;35项/277断言自动测试、test283项及正式246项服务器检查均通过。正文/原始字段和年度点赞参数摘要不变,未新增后台任务或Resource权限。机制、恢复点和退役边界见[静态配图维护](LOCAL_ILLUSTRATIONS.md),逐项回执见[验收JSON](STATIC_ILLUSTRATIONS_RELEASE_2026-10-30.json)。已完成服务器侧验收,未做线上页面验收。
|
||||||
|
|
||||||
|
## test退役(2026-10-30)
|
||||||
|
|
||||||
|
用户明确要求正式切换后取消test,已撤销test DNS及测试应用/资源公开入口、停用专属证书续期;保留410拒绝旧DNS缓存请求,正式站不变。测试数据仅保留离线恢复用途,详情与验证见[test下线记录](TEST_RETIREMENT_2026-10-30.md)。此前“test继续在线”均为历史状态。
|
||||||
|
|
||||||
|
|
||||||
|
## Resource独立后续管理升级(2026-10-30)
|
||||||
|
|
||||||
|
Resource图片V2已在0d9e71a图池基线上独立发布ATOM管理增量,当前运行SHA以[Resource管理正式发布](/Users/hellcat/Documents/GemCodes/resource.loc/v2/docs/MANAGEMENT.md#正式发布与服务器验收2026-10-30)为准;本页0d9e71a是FNA正式切换时的历史基线,不能据其覆盖当前资源服务。旧图片、37图池素材/引用及FNA消费者凭据保持,本次未改FNA代码/数据库/静态副本。
|
||||||
|
|||||||
173
docs/maintenance/ROUTING_MODES_2026-10-31.json
Normal file
@ -0,0 +1,173 @@
|
|||||||
|
{
|
||||||
|
"release_id": "daabedf9-a81c-49ca-995b-7b6832dd2254",
|
||||||
|
"published_at": "2026-10-31T06:58:28+00:00",
|
||||||
|
"phase": "complete",
|
||||||
|
"receipt": {
|
||||||
|
"publication_id": "c7f9be21-3914-43f1-b7e5-9e7b49ef224d",
|
||||||
|
"status": "published",
|
||||||
|
"articles": [
|
||||||
|
{
|
||||||
|
"content_key": "clash-routing-modes",
|
||||||
|
"article_id": 382,
|
||||||
|
"revision": 1,
|
||||||
|
"content_changed": true,
|
||||||
|
"url": "https://clashfreenode.com/a/clash-rule-global-direct.html"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"content_key": "system-proxy-vs-tun",
|
||||||
|
"article_id": 376,
|
||||||
|
"revision": 2,
|
||||||
|
"content_changed": true,
|
||||||
|
"url": "https://clashfreenode.com/a/system-proxy-vs-tun.html"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"effects": {
|
||||||
|
"indexnow": {
|
||||||
|
"status": "done",
|
||||||
|
"attempts": 1,
|
||||||
|
"http_status": 200,
|
||||||
|
"urls": [
|
||||||
|
"https://clashfreenode.com/a/clash-rule-global-direct.html",
|
||||||
|
"https://clashfreenode.com/a/system-proxy-vs-tun.html"
|
||||||
|
],
|
||||||
|
"submitted_at": "2026-10-31T06:58:29+00:00",
|
||||||
|
"result": "received"
|
||||||
|
},
|
||||||
|
"cache": {
|
||||||
|
"status": "done"
|
||||||
|
},
|
||||||
|
"search": {
|
||||||
|
"status": "done",
|
||||||
|
"method": "meilisearch",
|
||||||
|
"index": "cfn_articles_v3",
|
||||||
|
"documents": 2
|
||||||
|
},
|
||||||
|
"sitemap": {
|
||||||
|
"status": "done",
|
||||||
|
"method": "database-driven"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"readback": [
|
||||||
|
{
|
||||||
|
"content_key": "clash-routing-modes",
|
||||||
|
"article_id": 382,
|
||||||
|
"revision_matches": true,
|
||||||
|
"content_matches": true,
|
||||||
|
"body_sha256": "b9986ade5893115611f8a02070f5e98ba2fb8b7d9a100dff39e11ff60876c5c2",
|
||||||
|
"like_growth": {
|
||||||
|
"seven_day_remaining": 29,
|
||||||
|
"yearly": 50,
|
||||||
|
"one_year_target": 241,
|
||||||
|
"one_year_added": 0,
|
||||||
|
"one_year_started_at": "2026-10-31 06:58:28"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"content_key": "system-proxy-vs-tun",
|
||||||
|
"article_id": 376,
|
||||||
|
"revision_matches": true,
|
||||||
|
"content_matches": true,
|
||||||
|
"body_sha256": "255db797e5e1403ee779e960e2129558e160badf0fe53f1822250b8d45e0ddb3",
|
||||||
|
"like_growth": {
|
||||||
|
"seven_day_remaining": 0,
|
||||||
|
"yearly": 50,
|
||||||
|
"one_year_target": 106,
|
||||||
|
"one_year_added": 0,
|
||||||
|
"one_year_started_at": "2026-10-29 13:30:35"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"display_published_at_utc": "2026-10-31 02:10:28",
|
||||||
|
"http": {
|
||||||
|
"new_page": 200,
|
||||||
|
"chapter_anchors": [
|
||||||
|
"custom",
|
||||||
|
"groups",
|
||||||
|
"modes",
|
||||||
|
"order",
|
||||||
|
"troubleshoot",
|
||||||
|
"verify"
|
||||||
|
],
|
||||||
|
"images": [
|
||||||
|
{
|
||||||
|
"path": "/images/editorial/417b203a4af30200b6ed3b37d0b0e823a9b47db49e2d743b1110b35329cc5de8.png",
|
||||||
|
"status": 200,
|
||||||
|
"sha256_matches": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "/images/editorial/98a43bdd771dd4c6c5ec6b87bb5f0ebf679fa2b228dddbb764adecf50b0374e9.png",
|
||||||
|
"status": 200,
|
||||||
|
"sha256_matches": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"links": [
|
||||||
|
{
|
||||||
|
"target": "/a/clash-verge-rev-windows.html#enable",
|
||||||
|
"status": 200,
|
||||||
|
"anchor_exists": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"target": "/a/m173.html#enable",
|
||||||
|
"status": 200,
|
||||||
|
"anchor_exists": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"target": "/a/mihomo-dns-leak.html#dns-2",
|
||||||
|
"status": 200,
|
||||||
|
"anchor_exists": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"target": "/a/system-proxy-vs-tun.html#routing",
|
||||||
|
"status": 200,
|
||||||
|
"anchor_exists": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"target": "/a/system-proxy-vs-tun.html#troubleshoot",
|
||||||
|
"status": 200,
|
||||||
|
"anchor_exists": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"incoming_link": true,
|
||||||
|
"directory": {
|
||||||
|
"owner": "nginx",
|
||||||
|
"mode": "0o755"
|
||||||
|
},
|
||||||
|
"head": "77f9b09c58b46ef2bbe0882ec89194bf25aa82cd"
|
||||||
|
},
|
||||||
|
"local_browser": {
|
||||||
|
"checks": [
|
||||||
|
{
|
||||||
|
"width": 1360,
|
||||||
|
"scroll": 1360,
|
||||||
|
"headings": [
|
||||||
|
"01 三个模式,改变的是出口选择",
|
||||||
|
"02 换了节点没效果,可能换错了组",
|
||||||
|
"03 先看顺序,再看规则写得对不对",
|
||||||
|
"04 在 Verge Rev 里给一个网站添加规则",
|
||||||
|
"05 改完以后,检查一条新连接",
|
||||||
|
"06 几种常见现象,对应查哪里"
|
||||||
|
],
|
||||||
|
"brokenImages": [],
|
||||||
|
"tables": 2,
|
||||||
|
"images": 2
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"width": 390,
|
||||||
|
"scroll": 390,
|
||||||
|
"headings": [
|
||||||
|
"01 三个模式,改变的是出口选择",
|
||||||
|
"02 换了节点没效果,可能换错了组",
|
||||||
|
"03 先看顺序,再看规则写得对不对",
|
||||||
|
"04 在 Verge Rev 里给一个网站添加规则",
|
||||||
|
"05 改完以后,检查一条新连接",
|
||||||
|
"06 几种常见现象,对应查哪里"
|
||||||
|
],
|
||||||
|
"brokenImages": [],
|
||||||
|
"tables": 2,
|
||||||
|
"images": 2
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"blockedOrigins": []
|
||||||
|
}
|
||||||
|
}
|
||||||
36
docs/maintenance/ROUTING_MODES_2026-10-31.md
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
# 规则、全局与直连教程 · 2026-10-31
|
||||||
|
|
||||||
|
## 本次授权与范围
|
||||||
|
|
||||||
|
用户要求“现在就来一篇,当检测触发了”。本次作为提前的人工触发登记到2026-10-26周的 `2026-10-26-manual-1` 槽位,不改变2026-11-02起的每周三篇计划。本篇已按真实发布回执计入当周额度。
|
||||||
|
|
||||||
|
新文内容键 `clash-routing-modes`,路径 `/a/clash-rule-global-direct.html`,栏目综合教程。两张解释图、一张沿用现有样式的封面。系统代理/TUN文章只在 `#choose` 前补一个新文 `#groups` 入口,其余内容不改。新文链接Windows入门 `#enable`、Mac入门 `#enable`、TUN `#routing` / `#troubleshoot`、DNS `#dns-2`。
|
||||||
|
|
||||||
|
## 资料与质量检查
|
||||||
|
|
||||||
|
2026-10-31阅读 Mihomo 官方运行模式、路由规则、手动/自动代理组文档,以及 Clash Verge Rev 名词解释、自定义规则文档。准确链接保留在正文。原创示例使用example.com,不把配置片段写成完整可直接导入的订阅。未开展客户端真机联网实测,此边界只留维护记录。
|
||||||
|
|
||||||
|
本地实际模板桌面1360和手机390检查:均无横向溢出、2张正文图无破图、2张表格正常渲染、6个章节锚点存在。浏览器请求先按本地origin白名单拦截;没有本机线上页面访问。初次检查发现本地Vite未运行,启动原5187开发服务后复检通过,未改样式。正式签名预览由VPS-003内部Kernel渲染,未在本机打开其线上资源。
|
||||||
|
|
||||||
|
## 发布与恢复
|
||||||
|
|
||||||
|
- release_id:`daabedf9-a81c-49ca-995b-7b6832dd2254`
|
||||||
|
- publication_request_id:`c7f9be21-3914-43f1-b7e5-9e7b49ef224d`
|
||||||
|
- draft hash:`6ebc848487be507cd71e61016bf1232f1fc7c28b4042f019ff63654c8e29c486`
|
||||||
|
- 正式冻结默认值:i7like 29,i365like 50,一次性年度目标241;显示偏移17280秒。旧文设置不变。
|
||||||
|
- 本地已通过API发表:新文ID366/版本1,TUN ID365/版本2;本地IndexNow禁用并返回skipped。
|
||||||
|
- 正式首次publish失败;原ID status确认尚无发表回执,草稿仍draft。VPS-003错误为ContentRenderer.php:83 mkdir Permission denied;公开图片目录 `public/images/editorial` 不存在,上级root:root0755,API运行身份nginx无法创建。私有资产上传目录nginx:nginx0700正常。
|
||||||
|
- 创建该专用目录并设nginx:nginx0755的操作被自动审批拒绝(持久生产权限变更);用户随后明确批准“允许,仅创建这个专用目录并继续发布”,已按该范围创建并验证;其他目录所有权与权限未改。沿原release恢复,未另起发布请求。
|
||||||
|
- 私有工作文件:本机 `/private/tmp/fna-modes-20261031/`;服务器原release台账位于 `storage/app/private/editorial-releases/daabedf9-a81c-49ca-995b-7b6832dd2254.json`。
|
||||||
|
|
||||||
|
## 最终验收
|
||||||
|
|
||||||
|
正式发布完成:2026-10-31 14:58:28北京时间(服务器回执06:58:28 UTC),新文ID382/版本1,TUN ID376/版本2。展示时间比实际时间提前17280秒(4小时48分);点赞29/50/241已回读,旧文106年度目标及起点保留。新文全文与冻结版、两文版本、三张上传图片文件SHA由发布封装回读一致。
|
||||||
|
|
||||||
|
IndexNow由VPS-003在14:58:29北京时间提交新文和旧文更新两条URL,HTTP200、attempts1;白色机仅转发SSH。缓存、Meilisearch与sitemap均done,phase complete。此结果表示通知接收,不表示搜索引擎已收录。
|
||||||
|
|
||||||
|
服务器侧真实HTTP:新文200,2张正文图200且SHA一致;5条正文关联链接200且锚点存在,TUN旧文入向链接存在,6个章节锚点齐全。目录nginx所有/0755回读通过。已完成服务器侧验收,未做线上页面验收。本机浏览器只验收本地实际模板。
|
||||||
|
|
||||||
|
周期台账已用原release回执record到2026-10-26-manual-1,实际发表时间用于计数;2026-11-02当周三个计划未改。正文、图源、PNG、渲染HTML、关系索引同步保存,机器可读回执见[发布证据](ROUTING_MODES_2026-10-31.json)。
|
||||||
|
|
||||||
|
如需回退,旧文可从API版本1创建回退草稿,新文保留同URL通过API修订;不直接SQL修改,也不为撤回图片删除共享内容寻址资源。专用图片目录是API后续发文必需部署项,新增部署前应检查该目录归属与nginx写入能力。
|
||||||
45
docs/maintenance/TEST_RETIREMENT_2026-10-30.json
Normal file
@ -0,0 +1,45 @@
|
|||||||
|
{
|
||||||
|
"retired_at": "2026-10-30T04:36:51Z",
|
||||||
|
"checks": [
|
||||||
|
{
|
||||||
|
"url": "http://test.clashfreenode.com/",
|
||||||
|
"status": 410
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"url": "https://test.clashfreenode.com/",
|
||||||
|
"status": 410
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"url": "https://test.clashfreenode.com/resource-v2/",
|
||||||
|
"status": 410
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"url": "https://test.clashfreenode.com/images/illustrations/0000000000000000000000000000000000000000000000000000000000000000.png",
|
||||||
|
"status": 410
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"production_http": 200,
|
||||||
|
"production_nginx_unchanged": true,
|
||||||
|
"test_renewal_disabled": true,
|
||||||
|
"test_data_retained_offline": true,
|
||||||
|
"dns": {
|
||||||
|
"cloudflare_test_A_removed": true,
|
||||||
|
"authoritative": [
|
||||||
|
{
|
||||||
|
"ns": "bradley.ns.cloudflare.com.",
|
||||||
|
"status": "NXDOMAIN"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"ns": "jewel.ns.cloudflare.com.",
|
||||||
|
"status": "NXDOMAIN"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"prior_record": {
|
||||||
|
"type": "A",
|
||||||
|
"name": "test.clashfreenode.com",
|
||||||
|
"content": "45.153.247.44",
|
||||||
|
"proxied": false,
|
||||||
|
"ttl": "auto"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
11
docs/maintenance/TEST_RETIREMENT_2026-10-30.md
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
# test 预览下线(2026-10-30)
|
||||||
|
|
||||||
|
用户明确要求切正式后取消test。当前唯一公开业务站为https://clashfreenode.com/;test.clashfreenode.com已撤销Cloudflare单条A记录(原45.153.247.44、DNS-only、自动TTL)。主域名、www、邮件等其余10条记录保留。DNS界面证据见[截图](TEST_DNS_RETIRED_2026-10-30.png)。
|
||||||
|
|
||||||
|
经白色机SSH在VPS-003下线test网页及/resource-v2/入口,原虚拟主机不再指向测试代码或PHP;保留同名HTTP/HTTPS 410拒绝规则,避免尚有DNS缓存的客户端落入其他虚拟主机。关闭仅test的Certbot续期配置,现有证书只供缓存客户端返回410;未撤销或修改共享证书、PHP-FPM、Resource生产服务。Nginx配置验证/reload通过,正式站HTTP200且正式Nginx配置摘要未变。
|
||||||
|
|
||||||
|
测试代码、独立MySQL库和测试Resource SQLite/资产保留为离线恢复资料,不再提供公开访问;没有执行数据库删除、素材删除或撤销正式凭据。后续不得把test作为仍在线验收入口,也不自动重新开放。
|
||||||
|
|
||||||
|
VPS-003恢复点:`/root/backups/cfn-test-retirement-20261030/`,包含原test Nginx、原续期配置及退役回执。恢复须重新授权:恢复原test虚拟主机和续期配置,nginx -t后reload,再按原值重建精确test A记录并验证。不得用旧部署脚本擅自恢复。
|
||||||
|
|
||||||
|
已完成服务器侧验收,未做线上页面验收。
|
||||||
@ -1,6 +1,6 @@
|
|||||||
# 综合教程周期写作
|
# 综合教程周期写作
|
||||||
|
|
||||||
2026-10-31用户最终规则:每周三篇,每天北京时间15:00检查;文章展示时间随机往前0~6小时,精确到秒。原每周两篇、早晚两个窗口的规则已替换。Codex heartbeat `fna`,名称“FNA 综合教程|每周三篇”,ACTIVE,绑定本聊天,自2026-11-02当周开始。调度已修改,首轮实际写作尚未执行。
|
2026-10-31用户最终规则:每周三篇,每天北京时间15:00检查;文章展示时间随机往前0~6小时,精确到秒。原每周两篇、早晚两个窗口的规则已替换。Codex heartbeat `fna`,名称“FNA 综合教程|每周三篇”,ACTIVE,绑定本聊天,自2026-11-02当周开始。调度已修改;2026-10-31用户提前手动触发一篇已正式发布并计入当周台账,2026-11-02当周的三次计划保持不变。详见[首篇记录](ROUTING_MODES_2026-10-31.md)。
|
||||||
|
|
||||||
## 执行入口
|
## 执行入口
|
||||||
|
|
||||||
|
|||||||
@ -1,8 +1,11 @@
|
|||||||
.random-article-ad { position: relative; min-width: 0; aspect-ratio: 3.675; margin: 20px 0; overflow: hidden; border-radius: 12px; background: #181b1e; }
|
.random-article-ad { position: relative; min-width: 0; aspect-ratio: 3.675; margin: 20px 0; overflow: hidden; border-radius: 12px; background: #181b1e; }
|
||||||
.random-article-ad[hidden] { display: none !important; }
|
.random-article-ad[hidden] { display: none !important; }
|
||||||
.random-article-ad > a { display: block; position: absolute; inset: 0; }
|
.random-article-ad > a { display: block; position: absolute; inset: 0; }
|
||||||
.random-article-ad img { display: block; width: 100%; height: 100%; object-fit: contain; }
|
.random-article-ad img { display: block; width: 100%; height: 100%; object-fit: cover; }
|
||||||
.random-article-ad > a:focus-visible { outline: 3px solid #8ab4ff; outline-offset: -4px; }
|
.random-article-ad > a:focus-visible { outline: 3px solid #8ab4ff; outline-offset: -4px; }
|
||||||
|
|
||||||
.random-article-ad[data-ad-selected="dpl"] { background: #0a0f1a; }
|
.random-article-ad[data-ad-selected="dpl"] { background: #0a0f1a; }
|
||||||
.random-article-ad[data-ad-selected="fuc"] { background: #f8f8fc; }
|
.random-article-ad[data-ad-selected="fuc"] { background: #f8f8fc; }
|
||||||
|
|
||||||
|
.random-article-ad__disclosure { position: absolute; z-index: 1; top: 8px; right: 12px; font-size: 9px; line-height: 1; color: #a9acb8; pointer-events: none; }
|
||||||
|
.random-article-ad[data-ad-selected="fuc"] img { object-position: center 40%; }
|
||||||
|
|||||||
BIN
public/images/ads/dpl-ad-compact-wordmark-20261031.png
Normal file
|
After Width: | Height: | Size: 1.7 MiB |
BIN
public/images/ads/fuc-ad-compact-five-years-20261031.png
Normal file
|
After Width: | Height: | Size: 1.5 MiB |
BIN
public/images/ads/hn-ad-compact-lowercase-20261031.png
Normal file
|
After Width: | Height: | Size: 1.4 MiB |
@ -1,8 +1,8 @@
|
|||||||
@php
|
@php
|
||||||
$adChoices = collect([
|
$adChoices = collect([
|
||||||
['key' => 'dpl', 'file' => 'dpl-ad-site-style-20261028.png', 'width' => 1962, 'height' => 801, 'alt' => 'DPL:畅连全球网络。日常访问、远程办公、在线娱乐,查看套餐。'],
|
['key' => 'dpl', 'file' => 'dpl-ad-compact-wordmark-20261031.png', 'width' => 2169, 'height' => 725, 'alt' => 'DP-LINK.NET:畅连全球网络。日常访问、远程办公、在线娱乐,查看套餐。'],
|
||||||
['key' => 'hn', 'file' => 'hn-ad-refined-20261031.png', 'width' => 1964, 'height' => 801, 'alt' => 'Hardnerd:硬核架构,品质专线,全球网络畅通无阻。'],
|
['key' => 'hn', 'file' => 'hn-ad-compact-lowercase-20261031.png', 'width' => 2021, 'height' => 778, 'alt' => 'hardnerd:硬核架构,品质专线,全球网络畅通无阻。'],
|
||||||
['key' => 'fuc', 'file' => 'fuc-ad-site-style-20261028.png', 'width' => 1962, 'height' => 801, 'alt' => '福云:全球网络中继服务。随时随处,尽情使用。了解福云。'],
|
['key' => 'fuc', 'file' => 'fuc-ad-compact-five-years-20261031.png', 'width' => 2141, 'height' => 734, 'alt' => '福云:全球网络加速。五年稳定运营。开始使用。'],
|
||||||
])->filter(fn ($ad) => config('advertising.'.$ad['key'].'.enabled')
|
])->filter(fn ($ad) => config('advertising.'.$ad['key'].'.enabled')
|
||||||
&& config('advertising.'.$ad['key'].'.url')
|
&& config('advertising.'.$ad['key'].'.url')
|
||||||
&& is_file(public_path('images/ads/'.$ad['file'])))->values();
|
&& is_file(public_path('images/ads/'.$ad['file'])))->values();
|
||||||
@ -17,6 +17,7 @@
|
|||||||
@foreach ($adChoices as $ad)
|
@foreach ($adChoices as $ad)
|
||||||
<template data-ad-choice="{{ $ad['key'] }}">
|
<template data-ad-choice="{{ $ad['key'] }}">
|
||||||
<a href="{{ config('advertising.'.$ad['key'].'.url') }}" target="_blank" rel="sponsored noopener noreferrer" aria-label="广告:{{ $ad['alt'] }}(新窗口打开)">
|
<a href="{{ config('advertising.'.$ad['key'].'.url') }}" target="_blank" rel="sponsored noopener noreferrer" aria-label="广告:{{ $ad['alt'] }}(新窗口打开)">
|
||||||
|
<span class="random-article-ad__disclosure" aria-hidden="true">广告</span>
|
||||||
<img src="/images/ads/{{ $ad['file'] }}?v={{ filemtime(public_path('images/ads/'.$ad['file'])) }}" alt="{{ $ad['alt'] }}" width="{{ $ad['width'] }}" height="{{ $ad['height'] }}" decoding="async">
|
<img src="/images/ads/{{ $ad['file'] }}?v={{ filemtime(public_path('images/ads/'.$ad['file'])) }}" alt="{{ $ad['alt'] }}" width="{{ $ad['width'] }}" height="{{ $ad['height'] }}" decoding="async">
|
||||||
</a>
|
</a>
|
||||||
</template>
|
</template>
|
||||||
@ -26,6 +27,7 @@
|
|||||||
@php($ad = $adChoices->first())
|
@php($ad = $adChoices->first())
|
||||||
<aside class="random-article-ad" aria-label="网络服务广告">
|
<aside class="random-article-ad" aria-label="网络服务广告">
|
||||||
<a href="{{ config('advertising.'.$ad['key'].'.url') }}" target="_blank" rel="sponsored noopener noreferrer">
|
<a href="{{ config('advertising.'.$ad['key'].'.url') }}" target="_blank" rel="sponsored noopener noreferrer">
|
||||||
|
<span class="random-article-ad__disclosure" aria-hidden="true">广告</span>
|
||||||
<img src="/images/ads/{{ $ad['file'] }}?v={{ filemtime(public_path('images/ads/'.$ad['file'])) }}" alt="{{ $ad['alt'] }}" width="{{ $ad['width'] }}" height="{{ $ad['height'] }}">
|
<img src="/images/ads/{{ $ad['file'] }}?v={{ filemtime(public_path('images/ads/'.$ad['file'])) }}" alt="{{ $ad['alt'] }}" width="{{ $ad['width'] }}" height="{{ $ad['height'] }}">
|
||||||
</a>
|
</a>
|
||||||
</aside>
|
</aside>
|
||||||
|
|||||||
@ -71,7 +71,6 @@
|
|||||||
<div class="sidebar col-lg-4 d-none d-lg-block ms-lg-auto">
|
<div class="sidebar col-lg-4 d-none d-lg-block ms-lg-auto">
|
||||||
@include('components.order-likes')
|
@include('components.order-likes')
|
||||||
<!-- @include('components.generated-tags-cloud') -->
|
<!-- @include('components.generated-tags-cloud') -->
|
||||||
@include('components.banners')
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@ -142,7 +142,6 @@ class="post-like-button btn btn-light btn-w-md btn-rounded me-2"
|
|||||||
@include('components.order-likes')
|
@include('components.order-likes')
|
||||||
@endunless
|
@endunless
|
||||||
<!-- @include('components.generated-tags-cloud') -->
|
<!-- @include('components.generated-tags-cloud') -->
|
||||||
@include('components.banners')
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
26
tests/Unit/ResourceArticlePresentationTest.php
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace Tests\Unit;
|
||||||
|
|
||||||
|
use App\Services\ResourceArticlePresentation;
|
||||||
|
use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
|
final class ResourceArticlePresentationTest extends TestCase
|
||||||
|
{
|
||||||
|
public function test_daily_resource_prompts_are_removed_without_changing_resource_markup(): void
|
||||||
|
{
|
||||||
|
$prompts = '<p><b><a href="https://t.me/clashfreenode">👉 点击加入我们的tg频道,每日获取最新节点与苹果账号。</a></b></p><p></p>'
|
||||||
|
.'<p><b><a href="https://github.com/example">👉 点击关注我们的github仓库,永不失联。</a></b></p><p></p>';
|
||||||
|
$resource = '<p><a data-clipboard-text="fixture-subscription">复制订阅</a></p><p>App Store 使用说明</p>';
|
||||||
|
foreach (['freenode', 'shadowrocketids'] as $category) {
|
||||||
|
self::assertSame($resource, ResourceArticlePresentation::body($prompts.$resource, $category));
|
||||||
|
}
|
||||||
|
self::assertSame($prompts.$resource, ResourceArticlePresentation::body($prompts.$resource, 'advanced'));
|
||||||
|
}
|
||||||
|
|
||||||
|
public function test_unrelated_github_and_telegram_links_are_kept(): void
|
||||||
|
{
|
||||||
|
$body = '<p>在 <a href="https://github.com/example">GitHub</a> 下载客户端。</p><p>Telegram 客户端教程</p>';
|
||||||
|
self::assertSame($body, ResourceArticlePresentation::body($body, 'freenode'));
|
||||||
|
}
|
||||||
|
}
|
||||||