From a41ce7656c9aa981e46a708a7cc39c3c2d9f2c5d Mon Sep 17 00:00:00 2001 From: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com> Date: Fri, 4 Sep 2026 14:29:29 +0800 Subject: [PATCH] fix(skill): simplify agent install prompt Signed-off-by: XiaoSeS <87064762+XiaoSeS@users.noreply.github.com> --- web/e2e/public-skill-detail-anonymous.spec.ts | 4 ++-- web/src/i18n/landing-quick-start-locale.test.ts | 3 ++- web/src/i18n/locales/en.json | 2 +- web/src/i18n/locales/ru.json | 2 +- web/src/i18n/locales/zh.json | 2 +- 5 files changed, 7 insertions(+), 6 deletions(-) diff --git a/web/e2e/public-skill-detail-anonymous.spec.ts b/web/e2e/public-skill-detail-anonymous.spec.ts index b23ba6e4..cda39714 100644 --- a/web/e2e/public-skill-detail-anonymous.spec.ts +++ b/web/e2e/public-skill-detail-anonymous.spec.ts @@ -67,8 +67,8 @@ test.describe('Public Skill Detail Anonymous Access (Real API)', () => { expect(agentPrompt).toContain(`${registryUrl}/install/skillhub.md`) expect(agentPrompt).toContain(skillhubCoordinate) expect(agentPrompt).toContain(current.skill.version) - expect(agentPrompt).toContain('explain why and stop') - expect(agentPrompt).toContain('do not use another source') + expect(agentPrompt).not.toContain('explain why and stop') + expect(agentPrompt).not.toContain('do not use another source') expect(agentPrompt).not.toContain('fallback') await page.getByRole('tab', { name: 'ClawHub CLI' }).click() diff --git a/web/src/i18n/landing-quick-start-locale.test.ts b/web/src/i18n/landing-quick-start-locale.test.ts index 9627ade6..0fefeb7f 100644 --- a/web/src/i18n/landing-quick-start-locale.test.ts +++ b/web/src/i18n/landing-quick-start-locale.test.ts @@ -32,7 +32,8 @@ describe('landing quick start locales', () => { expect(prompt).toContain('{{version}}') expect(prompt).not.toContain('fallback') expect(prompt).not.toContain('备用公共') - expect(prompt).toMatch(/不要改用其他来源|do not use another source|не используйте другой источник/) + expect(prompt).not.toMatch(/若无法安装|If installation fails|Если установка не удалась/) + expect(prompt).not.toMatch(/不要改用其他来源|do not use another source|не используйте другой источник/) } }) diff --git a/web/src/i18n/locales/en.json b/web/src/i18n/locales/en.json index 1e77208d..5cae8447 100644 --- a/web/src/i18n/locales/en.json +++ b/web/src/i18n/locales/en.json @@ -1051,7 +1051,7 @@ "installForAgent": { "button": "Install for Agent", "copied": "Agent prompt copied", - "prompt": "Follow {{guideUrl}} to connect SkillHub and install {{skill}} version {{version}} from this SkillHub. If installation fails, explain why and stop; do not use another source." + "prompt": "Follow {{guideUrl}} to connect SkillHub and install {{skill}} version {{version}} from this SkillHub." } }, "skillCompare": { diff --git a/web/src/i18n/locales/ru.json b/web/src/i18n/locales/ru.json index 18e35a15..fc2299c6 100644 --- a/web/src/i18n/locales/ru.json +++ b/web/src/i18n/locales/ru.json @@ -1116,7 +1116,7 @@ "installForAgent": { "button": "Установить для агента", "copied": "Инструкция скопирована", - "prompt": "Следуйте инструкции {{guideUrl}}, чтобы подключить SkillHub и установить {{skill}} версии {{version}} из этого SkillHub. Если установка не удалась, объясните причину и остановитесь; не используйте другой источник." + "prompt": "Следуйте инструкции {{guideUrl}}, чтобы подключить SkillHub и установить {{skill}} версии {{version}} из этого SkillHub." } }, "skillCompare": { diff --git a/web/src/i18n/locales/zh.json b/web/src/i18n/locales/zh.json index 722f7992..a49969b8 100644 --- a/web/src/i18n/locales/zh.json +++ b/web/src/i18n/locales/zh.json @@ -1051,7 +1051,7 @@ "installForAgent": { "button": "安装到 Agent", "copied": "安装指令已复制", - "prompt": "请根据 {{guideUrl}} 接入 SkillHub,并从该 SkillHub 安装 {{skill}} 的 {{version}} 版本。若无法安装,请说明原因并停止,不要改用其他来源。" + "prompt": "请根据 {{guideUrl}} 接入 SkillHub,并从该 SkillHub 安装 {{skill}} 的 {{version}} 版本。" } }, "skillCompare": {