@prettier-ai/dsh-client-ui-skill 0.1.2-alpha.5 → 0.1.3-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.i18n.yaml +2 -2
- package/README.md +1 -1
- package/README.zh.md +1 -1
- package/lib/client.js +2 -2
- package/package.json +13 -13
package/README.i18n.yaml
CHANGED
|
@@ -2,5 +2,5 @@
|
|
|
2
2
|
# side as of the last confirmed-consistent state. Both languages carry equal authority;
|
|
3
3
|
# after editing either side, bring the other along and re-record with:
|
|
4
4
|
# pnpm run verify-translation-pairing --write packages/client/ui-skill/README.md
|
|
5
|
-
README.md:
|
|
6
|
-
README.zh.md:
|
|
5
|
+
README.md: a98194f7e590eb8a68bd329495896e9f2df1b506
|
|
6
|
+
README.zh.md: c4f444f1c749f0697e8883166a0f4ea8ca2009ba
|
package/README.md
CHANGED
|
@@ -29,7 +29,7 @@ Type `/` in the composer and pick a skill from the suggestions, or type `/name`
|
|
|
29
29
|
|
|
30
30
|
### What the source offers
|
|
31
31
|
|
|
32
|
-
Ordinary-session candidates come from the `skills/list` Remote; the host serves every user-invocable skill, and a `modelInvocable: false` entry (a `disable-model-invocation` skill, whose only entry point is this path) wears the user-only marker as a description prefix in the active language. Results
|
|
32
|
+
Ordinary-session candidates come from the `skills/list` Remote; the host serves every user-invocable skill, and a `modelInvocable: false` entry (a `disable-model-invocation` skill, whose only entry point is this path) wears the user-only marker as a description prefix in the active language. Results rank through the `/` menu's shared name ranker, `rankByName` from ui-primitives: the query matches a case-insensitive ordered subsequence of the skill name, prefix hits rank first, and ties keep the host order ([ranking decision](../../../.agents/notes/implemented/feature/2026-08-04-web-slash-command-fuzzy-discovery.md)). A failed `skills/list` call is logged and folded into a silent menu-group drop — the menu shows only pending/ready states.
|
|
33
33
|
|
|
34
34
|
### The skill tool row
|
|
35
35
|
|
package/README.zh.md
CHANGED
|
@@ -29,7 +29,7 @@ kind: "package-reference"
|
|
|
29
29
|
|
|
30
30
|
### source 提供什么
|
|
31
31
|
|
|
32
|
-
普通会话的候选来自 `skills/list` Remote;宿主提供每一个用户可调用的 skill,`modelInvocable: false` 的条目(即 `disable-model-invocation` skill
|
|
32
|
+
普通会话的候选来自 `skills/list` Remote;宿主提供每一个用户可调用的 skill,`modelInvocable: false` 的条目(即 `disable-model-invocation` skill,此路径是其唯一入口)会以当前语言把仅限用户标记作为描述前缀带上。结果经 `/` 菜单共享的名字排序器(ui-primitives 的 `rankByName`)排名:查询作为不区分大小写的有序子序列匹配 skill 名,前缀命中排最前,同分保持宿主顺序([排名决策](../../../.agents/notes/implemented/feature/2026-08-04-web-slash-command-fuzzy-discovery.zh.md))。`skills/list` 调用失败时会被记录并静默丢弃该菜单组——菜单只显示 pending/ready 状态。
|
|
33
33
|
|
|
34
34
|
### skill 工具行
|
|
35
35
|
|
package/lib/client.js
CHANGED
|
@@ -4,9 +4,9 @@ window.__ModuleLoader__.load({
|
|
|
4
4
|
var module = { exports: {} };
|
|
5
5
|
var exports = module.exports;
|
|
6
6
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
7
|
+
let _prettier_ai_dsh_client_ui_primitives = require("@prettier-ai/dsh-client-ui-primitives");
|
|
7
8
|
let react_jsx_runtime = require("react/jsx-runtime");
|
|
8
9
|
let react = require("react");
|
|
9
|
-
let _prettier_ai_dsh_client_ui_primitives = require("@prettier-ai/dsh-client-ui-primitives");
|
|
10
10
|
//#region \0dsh-css:/home/runner/work/dsh-publisher/dsh-publisher/upstream/packages/client/ui-skill/src/client/SkillRow.module.css.mjs
|
|
11
11
|
const css = ".NHJAaW_card{flex-direction:column;display:flex}.NHJAaW_row{align-items:center;min-width:0;height:24px;display:flex;position:relative;overflow:hidden}.NHJAaW_row[data-expandable]{cursor:pointer}.NHJAaW_card[data-state=running] .NHJAaW_row:after{content:\"\";background:linear-gradient(90deg, transparent 0%, color-mix(in srgb, var(--dsw-alias-bg-base) 60%, transparent) 55%, transparent 100%);pointer-events:none;width:300px;animation:2.6s ease-out infinite NHJAaW_dsh-skill-row-sweep;position:absolute;inset:0 auto 0 0}@keyframes NHJAaW_dsh-skill-row-sweep{0%{left:-300px}90%,to{left:100%}}.NHJAaW_leading{width:16px;height:16px;color:var(--dsw-alias-label-tertiary);flex:none;justify-content:center;align-items:center;margin-right:6px;display:inline-flex;position:relative}.NHJAaW_chevron{color:var(--dsw-alias-label-secondary)}.NHJAaW_iconIdle{opacity:1;transition:opacity .1s;display:inline-flex}.NHJAaW_chevronHover{opacity:0;margin:auto;transition:opacity .1s;position:absolute;inset:0}.NHJAaW_row:hover .NHJAaW_iconIdle{opacity:0}.NHJAaW_row:hover .NHJAaW_chevronHover{opacity:1}.NHJAaW_title{color:var(--dsw-alias-label-secondary);flex:none;font-size:14px;line-height:24px}.NHJAaW_separator{background:var(--dsw-alias-label-caption);border-radius:1px;flex:none;width:2px;height:2px;margin:0 8px}.NHJAaW_summary{text-overflow:ellipsis;white-space:nowrap;min-width:0;color:var(--dsw-alias-label-tertiary);flex:auto;font-size:14px;line-height:24px;overflow:hidden}.NHJAaW_errorSummary{color:var(--dsw-alias-state-error-primary)}.NHJAaW_bodyWrap{flex-direction:column;display:flex}.NHJAaW_instructionsCard{border:.5px solid var(--dsw-alias-border-l1);background:var(--dsw-alias-markdown-code-block);border-radius:12px;flex-direction:column;max-height:260px;margin:4px 0 4px 4px;display:flex;overflow:hidden}.NHJAaW_instructionsHeader{border-bottom:.5px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-markdown-code-block-banner);color:var(--dsw-alias-label-caption);text-transform:uppercase;letter-spacing:.04em;flex:none;padding:8px 12px;font-size:11px;font-weight:500;line-height:16px}.NHJAaW_instructions{white-space:pre-wrap;overflow-wrap:anywhere;min-height:0;font:var(--dsw-font-markdown-code-block-small);color:var(--dsw-alias-label-secondary);margin:0;padding:10px 12px 12px;overflow:auto}.NHJAaW_instructions[data-error]{color:var(--dsw-alias-state-error-primary)}.NHJAaW_instructions::-webkit-scrollbar-thumb{background-clip:padding-box;border:2px solid #0000;border-radius:6px}.NHJAaW_instructions::-webkit-scrollbar-track{margin:6px 0}.NHJAaW_inspectButton{border:.5px solid var(--dsw-alias-border-l4);corner-shape:round;background:var(--dsw-alias-bg-base);color:var(--dsw-alias-label-secondary);cursor:pointer;opacity:0;border-radius:999px;align-self:flex-start;align-items:center;gap:4px;margin:4px 0 2px 4px;padding:2px 8px;font-size:11px;line-height:16px;transition:opacity .1s;display:inline-flex}.NHJAaW_card:hover .NHJAaW_inspectButton,.NHJAaW_inspectButton:focus-visible{opacity:1}.NHJAaW_inspectButton:hover{background:var(--dsw-alias-interactive-bg-hover-solid);color:var(--dsw-alias-label-primary)}.NHJAaW_visuallyHidden{clip:rect(0 0 0 0);white-space:nowrap;width:1px;height:1px;position:absolute;overflow:hidden}@media (prefers-reduced-motion:reduce){.NHJAaW_card[data-state=running] .NHJAaW_row:after{animation:none;display:none}.NHJAaW_iconIdle,.NHJAaW_chevronHover,.NHJAaW_inspectButton{transition:none}}";
|
|
12
12
|
const tagId = "@prettier-ai/dsh-client-ui-skill/SkillRow.module.css";
|
|
@@ -285,7 +285,7 @@ window.__ModuleLoader__.load({
|
|
|
285
285
|
async candidates(session, { query, signal }) {
|
|
286
286
|
const skills = await fetchCatalog(session.sessionId);
|
|
287
287
|
if (signal.aborted) return [];
|
|
288
|
-
return
|
|
288
|
+
return (0, _prettier_ai_dsh_client_ui_primitives.rankByName)(skills, query).map((skill) => ({
|
|
289
289
|
name: skill.name,
|
|
290
290
|
description: skill.modelInvocable ? skill.description : `${t("menu.userOnly")} · ${skill.description}`
|
|
291
291
|
}));
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prettier-ai/dsh-client-ui-skill",
|
|
3
3
|
"description": "Web skill references and the dedicated skill tool row",
|
|
4
|
-
"version": "0.1.
|
|
4
|
+
"version": "0.1.3-alpha.1",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
@@ -47,18 +47,18 @@
|
|
|
47
47
|
"@types/react": "~18.3.1",
|
|
48
48
|
"react": "^18.2.0",
|
|
49
49
|
"react-dom": "^18.2.0",
|
|
50
|
-
"@prettier-ai/dsh-api-remotes": "^0.1.
|
|
51
|
-
"@prettier-ai/dsh-
|
|
52
|
-
"@prettier-ai/dsh-client-
|
|
53
|
-
"@prettier-ai/dsh-
|
|
54
|
-
"@prettier-ai/dsh-client-
|
|
55
|
-
"@prettier-ai/dsh-client-ui-primitives": "^0.1.
|
|
56
|
-
"@prettier-ai/dsh-client-ui-input-trigger": "^0.1.
|
|
57
|
-
"@prettier-ai/dsh-client-ui-
|
|
58
|
-
"@prettier-ai/dsh-
|
|
59
|
-
"@prettier-ai/dsh-client-ui-
|
|
60
|
-
"@prettier-ai/
|
|
61
|
-
"@prettier-ai/
|
|
50
|
+
"@prettier-ai/dsh-api-remotes": "^0.1.3-alpha.1",
|
|
51
|
+
"@prettier-ai/dsh-api-session-controller": "^0.1.3-alpha.1",
|
|
52
|
+
"@prettier-ai/dsh-client-locale": "^0.1.3-alpha.1",
|
|
53
|
+
"@prettier-ai/dsh-client-test-runtime": "^0.1.3-alpha.1",
|
|
54
|
+
"@prettier-ai/dsh-client-connection": "^0.1.3-alpha.1",
|
|
55
|
+
"@prettier-ai/dsh-client-ui-primitives": "^0.1.3-alpha.1",
|
|
56
|
+
"@prettier-ai/dsh-client-ui-input-trigger": "^0.1.3-alpha.1",
|
|
57
|
+
"@prettier-ai/dsh-client-ui-renderer": "^0.1.3-alpha.1",
|
|
58
|
+
"@prettier-ai/dsh-client-ui-slots": "^0.1.3-alpha.1",
|
|
59
|
+
"@prettier-ai/dsh-client-ui-tool": "^0.1.3-alpha.1",
|
|
60
|
+
"@prettier-ai/cordis": "^4.0.2",
|
|
61
|
+
"@prettier-ai/dsh-session": "^0.1.3-alpha.1"
|
|
62
62
|
},
|
|
63
63
|
"files": [
|
|
64
64
|
"lib/index.js",
|