iskills 0.2.45 → 0.2.47
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/LICENSE +21 -0
- package/README.md +9 -7
- package/README.zh-CN.md +8 -6
- package/bin/iskills.js +10 -2
- package/dist/src/cli.js +22 -7
- package/dist/src/cli.js.map +1 -1
- package/dist/src/commands/browser-actions.d.ts +2 -0
- package/dist/src/commands/browser-actions.js +154 -49
- package/dist/src/commands/browser-actions.js.map +1 -1
- package/dist/src/commands/config.d.ts +5 -0
- package/dist/src/commands/config.js +23 -0
- package/dist/src/commands/config.js.map +1 -0
- package/dist/src/commands/create.js +12 -8
- package/dist/src/commands/create.js.map +1 -1
- package/dist/src/commands/index.d.ts +1 -0
- package/dist/src/commands/index.js +19 -77
- package/dist/src/commands/index.js.map +1 -1
- package/dist/src/commands/library.d.ts +46 -12
- package/dist/src/commands/library.js +384 -230
- package/dist/src/commands/library.js.map +1 -1
- package/dist/src/commands/search.js +17 -39
- package/dist/src/commands/search.js.map +1 -1
- package/dist/src/domain/collection-write.d.ts +53 -2
- package/dist/src/domain/collection-write.js +293 -61
- package/dist/src/domain/collection-write.js.map +1 -1
- package/dist/src/domain/core.d.ts +46 -5
- package/dist/src/domain/core.js +164 -58
- package/dist/src/domain/core.js.map +1 -1
- package/dist/src/domain/cross-agent-install.d.ts +32 -0
- package/dist/src/domain/cross-agent-install.js +147 -0
- package/dist/src/domain/cross-agent-install.js.map +1 -0
- package/dist/src/domain/errors.d.ts +20 -0
- package/dist/src/domain/errors.js +31 -0
- package/dist/src/domain/errors.js.map +1 -0
- package/dist/src/domain/git.js +15 -14
- package/dist/src/domain/git.js.map +1 -1
- package/dist/src/domain/user-config.d.ts +12 -0
- package/dist/src/domain/user-config.js +55 -0
- package/dist/src/domain/user-config.js.map +1 -0
- package/dist/src/i18n/en.d.ts +5 -0
- package/dist/src/i18n/en.js +423 -0
- package/dist/src/i18n/en.js.map +1 -0
- package/dist/src/i18n/index.d.ts +54 -0
- package/dist/src/i18n/index.js +164 -0
- package/dist/src/i18n/index.js.map +1 -0
- package/dist/src/i18n/zh.d.ts +409 -0
- package/dist/src/i18n/zh.js +423 -0
- package/dist/src/i18n/zh.js.map +1 -0
- package/dist/src/ui/browser/browse-capabilities.d.ts +26 -0
- package/dist/src/ui/browser/browse-capabilities.js +130 -0
- package/dist/src/ui/browser/browse-capabilities.js.map +1 -0
- package/dist/src/ui/browser/browser.js +205 -62
- package/dist/src/ui/browser/browser.js.map +1 -1
- package/dist/src/ui/browser/detail.js +1 -1
- package/dist/src/ui/browser/detail.js.map +1 -1
- package/dist/src/ui/browser/footer.js +26 -88
- package/dist/src/ui/browser/footer.js.map +1 -1
- package/dist/src/ui/browser/format.d.ts +13 -20
- package/dist/src/ui/browser/format.js +81 -144
- package/dist/src/ui/browser/format.js.map +1 -1
- package/dist/src/ui/browser/index.js +35 -3
- package/dist/src/ui/browser/index.js.map +1 -1
- package/dist/src/ui/browser/shortcut-help.js +3 -4
- package/dist/src/ui/browser/shortcut-help.js.map +1 -1
- package/dist/src/ui/browser/store.d.ts +4 -0
- package/dist/src/ui/browser/store.js +2 -0
- package/dist/src/ui/browser/store.js.map +1 -1
- package/dist/src/ui/browser/types.d.ts +19 -4
- package/dist/src/ui/collection-match.d.ts +1 -1
- package/dist/src/ui/collection-match.js +8 -5
- package/dist/src/ui/collection-match.js.map +1 -1
- package/dist/src/ui/components/framed-panel.d.ts +6 -1
- package/dist/src/ui/components/framed-panel.js +7 -4
- package/dist/src/ui/components/framed-panel.js.map +1 -1
- package/dist/src/ui/components/modal-panel.d.ts +4 -1
- package/dist/src/ui/components/modal-panel.js +8 -2
- package/dist/src/ui/components/modal-panel.js.map +1 -1
- package/dist/src/ui/components/mouse/index.d.ts +1 -1
- package/dist/src/ui/components/mouse/index.js +1 -1
- package/dist/src/ui/components/mouse/index.js.map +1 -1
- package/dist/src/ui/components/mouse/parse.d.ts +0 -7
- package/dist/src/ui/components/mouse/parse.js +0 -41
- package/dist/src/ui/components/mouse/parse.js.map +1 -1
- package/dist/src/ui/components/multi-select.js +3 -10
- package/dist/src/ui/components/multi-select.js.map +1 -1
- package/dist/src/ui/components/options.d.ts +2 -0
- package/dist/src/ui/components/options.js +9 -0
- package/dist/src/ui/components/options.js.map +1 -1
- package/dist/src/ui/components/select.js +1 -1
- package/dist/src/ui/components/select.js.map +1 -1
- package/dist/src/ui/components/tag-editor.d.ts +1 -2
- package/dist/src/ui/components/tag-editor.js +6 -4
- package/dist/src/ui/components/tag-editor.js.map +1 -1
- package/dist/src/ui/components/termcn.d.ts +1 -5
- package/dist/src/ui/components/termcn.js +1 -4
- package/dist/src/ui/components/termcn.js.map +1 -1
- package/dist/src/ui/config/index.d.ts +11 -0
- package/dist/src/ui/config/index.js +22 -0
- package/dist/src/ui/config/index.js.map +1 -0
- package/dist/src/ui/config/settings.d.ts +17 -0
- package/dist/src/ui/config/settings.js +126 -0
- package/dist/src/ui/config/settings.js.map +1 -0
- package/dist/src/ui/footer/resolve-footer.js +54 -36
- package/dist/src/ui/footer/resolve-footer.js.map +1 -1
- package/dist/src/ui/footer/types.d.ts +12 -2
- package/dist/src/ui/import/review.js +5 -8
- package/dist/src/ui/import/review.js.map +1 -1
- package/dist/src/ui/import/skill-select.js +15 -33
- package/dist/src/ui/import/skill-select.js.map +1 -1
- package/dist/src/ui/install/review.js +18 -19
- package/dist/src/ui/install/review.js.map +1 -1
- package/dist/src/ui/overlay/bridge.d.ts +1 -1
- package/dist/src/ui/prompts/present.d.ts +4 -2
- package/dist/src/ui/prompts/present.js +70 -5
- package/dist/src/ui/prompts/present.js.map +1 -1
- package/dist/src/ui/search/index.js +9 -7
- package/dist/src/ui/search/index.js.map +1 -1
- package/dist/src/ui/shell/app-shell.d.ts +1 -1
- package/dist/src/ui/shell/app-shell.js +1 -1
- package/dist/src/ui/shell/run.d.ts +0 -11
- package/dist/src/ui/shell/run.js +0 -43
- package/dist/src/ui/shell/run.js.map +1 -1
- package/dist/src/ui/shell/terminal.d.ts +0 -1
- package/dist/src/ui/shell/terminal.js +2 -1
- package/dist/src/ui/shell/terminal.js.map +1 -1
- package/dist/src/ui/skill-labels.d.ts +10 -9
- package/dist/src/ui/skill-labels.js +14 -10
- package/dist/src/ui/skill-labels.js.map +1 -1
- package/dist/src/ui/tui/hooks.d.ts +1 -13
- package/dist/src/ui/tui/hooks.js +1 -11
- package/dist/src/ui/tui/hooks.js.map +1 -1
- package/dist/src/ui/tui/index.d.ts +1 -1
- package/dist/src/ui/tui/index.js +1 -1
- package/dist/src/ui/tui/index.js.map +1 -1
- package/package.json +10 -11
- package/bin/patch-react-reconciler.mjs +0 -71
- package/dist/src/ui/components/confirm.d.ts +0 -6
- package/dist/src/ui/components/confirm.js +0 -22
- package/dist/src/ui/components/confirm.js.map +0 -1
- package/dist/src/ui/components/link.d.ts +0 -7
- package/dist/src/ui/components/link.js +0 -17
- package/dist/src/ui/components/link.js.map +0 -1
- package/dist/src/ui/components/modal.d.ts +0 -16
- package/dist/src/ui/components/modal.js +0 -58
- package/dist/src/ui/components/modal.js.map +0 -1
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025-2026 eightHundreds and contributors
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -26,18 +26,17 @@ Data integrity comes first: writes are transactional where it matters; conflicts
|
|
|
26
26
|
## Requirements
|
|
27
27
|
|
|
28
28
|
- **Node.js** 24+
|
|
29
|
+
- **Bun** recommended for the full-screen TUI (OpenTUI native FFI). `iskills` re-execs under Bun when the current Node lacks `node:ffi`. Pure CLI paths (help, non-TTY flags) work on Node alone.
|
|
29
30
|
- **macOS** or **Linux**
|
|
30
31
|
- A TTY for the interactive UI (`stdin` and `stdout`)
|
|
31
32
|
- **Git** optional — enable only if you want collection versioning / remote sync
|
|
32
33
|
|
|
33
|
-
> **UI language:**
|
|
34
|
+
> **UI language:** Defaults to the system locale — Chinese (`zh*`) for Chinese UI, English otherwise. Override with `iskills config` (Chinese / English / follow system).
|
|
34
35
|
|
|
35
36
|
## Install
|
|
36
37
|
|
|
37
38
|
```bash
|
|
38
|
-
|
|
39
|
-
# or
|
|
40
|
-
pnpm add -g iskills
|
|
39
|
+
bun install -g iskills
|
|
41
40
|
```
|
|
42
41
|
|
|
43
42
|
Verify:
|
|
@@ -77,6 +76,9 @@ iskills add my-skill --copy
|
|
|
77
76
|
# Optional: turn the collection into a Git repo (and set origin)
|
|
78
77
|
iskills init
|
|
79
78
|
iskills init --remote git@github.com:you/my-skills.git
|
|
79
|
+
|
|
80
|
+
# Configure UI language (follow system / Chinese / English)
|
|
81
|
+
iskills config
|
|
80
82
|
```
|
|
81
83
|
|
|
82
84
|
In the main TUI, day-to-day work (browse, delete, update, notes, tags, sync) lives on the keyboard-driven browser. With a remote configured, press **`s`** on the Collection tab to sync.
|
|
@@ -91,6 +93,7 @@ In the main TUI, day-to-day work (browse, delete, update, notes, tags, sync) liv
|
|
|
91
93
|
| `iskills import [source]` | Import a local path or Git URL |
|
|
92
94
|
| `iskills add [skill…]` | Install from the collection into a project or global agent dir |
|
|
93
95
|
| `iskills init` | Initialize Git for the collection (optional remote) |
|
|
96
|
+
| `iskills config` | Configure UI preferences (language) |
|
|
94
97
|
|
|
95
98
|
Common flags (see `iskills help <command>` for the full set):
|
|
96
99
|
|
|
@@ -120,7 +123,6 @@ pnpm install --frozen-lockfile
|
|
|
120
123
|
pnpm run build
|
|
121
124
|
pnpm start -- --help
|
|
122
125
|
pnpm run type-check
|
|
123
|
-
pnpm test
|
|
124
126
|
pnpm pack --dry-run
|
|
125
127
|
```
|
|
126
128
|
|
|
@@ -135,8 +137,8 @@ Stack: TypeScript (strict), OpenTUI, React. The published package ships compiled
|
|
|
135
137
|
|
|
136
138
|
## Contributing
|
|
137
139
|
|
|
138
|
-
|
|
140
|
+
Tests and internal documentation live outside this public tree. **Issues are welcome** — bugs, ideas, and questions.
|
|
139
141
|
|
|
140
142
|
## License
|
|
141
143
|
|
|
142
|
-
|
|
144
|
+
[MIT](./LICENSE)
|
package/README.zh-CN.md
CHANGED
|
@@ -26,18 +26,17 @@
|
|
|
26
26
|
## 环境要求
|
|
27
27
|
|
|
28
28
|
- **Node.js** 24+
|
|
29
|
+
- **Bun** 推荐用于完整全屏 TUI(OpenTUI 原生 FFI)。当前 Node 缺少 `node:ffi` 时,`iskills` 会 re-exec 到 Bun。纯 CLI 路径(帮助、非 TTY 参数)可仅用 Node。
|
|
29
30
|
- **macOS** 或 **Linux**
|
|
30
31
|
- 交互界面需要 TTY(`stdin` 与 `stdout`)
|
|
31
32
|
- **Git** 可选 — 仅在需要收藏夹版本管理 / 远端同步时启用
|
|
32
33
|
|
|
33
|
-
> **界面语言:**
|
|
34
|
+
> **界面语言:** 默认跟随系统 locale — 中文族(`zh*`)为中文,其余为英文。可用 `iskills config` 持久覆盖为中文 / English,或恢复跟随系统。
|
|
34
35
|
|
|
35
36
|
## 安装
|
|
36
37
|
|
|
37
38
|
```bash
|
|
38
|
-
|
|
39
|
-
# 或
|
|
40
|
-
pnpm add -g iskills
|
|
39
|
+
bun install -g iskills
|
|
41
40
|
```
|
|
42
41
|
|
|
43
42
|
验证:
|
|
@@ -77,6 +76,9 @@ iskills add my-skill --copy
|
|
|
77
76
|
# 可选:将收藏夹初始化为 Git 仓库(并配置 origin)
|
|
78
77
|
iskills init
|
|
79
78
|
iskills init --remote git@github.com:you/my-skills.git
|
|
79
|
+
|
|
80
|
+
# 配置 UI 语言(跟随系统 / 中文 / English)
|
|
81
|
+
iskills config
|
|
80
82
|
```
|
|
81
83
|
|
|
82
84
|
日常操作(浏览、删除、更新、备注、标签、同步)在主 TUI 的键盘浏览中完成。配置远程后,在收藏夹 Tab 按 **`s`** 同步。
|
|
@@ -91,6 +93,7 @@ iskills init --remote git@github.com:you/my-skills.git
|
|
|
91
93
|
| `iskills import [来源]` | 导入本地路径或 Git URL |
|
|
92
94
|
| `iskills add [技能…]` | 从收藏夹安装到项目或 Agent 全局目录 |
|
|
93
95
|
| `iskills init` | 初始化收藏夹 Git(可选远程) |
|
|
96
|
+
| `iskills config` | 配置界面偏好(UI 语言) |
|
|
94
97
|
|
|
95
98
|
常用参数(完整列表见 `iskills help <命令>`):
|
|
96
99
|
|
|
@@ -120,7 +123,6 @@ pnpm install --frozen-lockfile
|
|
|
120
123
|
pnpm run build
|
|
121
124
|
pnpm start -- --help
|
|
122
125
|
pnpm run type-check
|
|
123
|
-
pnpm test
|
|
124
126
|
pnpm pack --dry-run
|
|
125
127
|
```
|
|
126
128
|
|
|
@@ -135,7 +137,7 @@ pnpm pack --dry-run
|
|
|
135
137
|
|
|
136
138
|
## 贡献
|
|
137
139
|
|
|
138
|
-
|
|
140
|
+
测试与内部文档不在本公开仓库中。**欢迎提 Issue**(缺陷、想法、问题均可)。
|
|
139
141
|
|
|
140
142
|
## 许可
|
|
141
143
|
|
package/bin/iskills.js
CHANGED
|
@@ -64,7 +64,12 @@ if (shouldReexecToBun()) {
|
|
|
64
64
|
},
|
|
65
65
|
});
|
|
66
66
|
if (result.error) {
|
|
67
|
-
|
|
67
|
+
const { t } = await import('../dist/src/i18n/index.js');
|
|
68
|
+
console.error(
|
|
69
|
+
t('cli.errorPrefix', {
|
|
70
|
+
message: t('cli.bunStartFailed', { message: result.error.message }),
|
|
71
|
+
})
|
|
72
|
+
);
|
|
68
73
|
process.exitCode = 1;
|
|
69
74
|
} else {
|
|
70
75
|
process.exit(result.status ?? 1);
|
|
@@ -77,6 +82,7 @@ if (shouldReexecToBun()) {
|
|
|
77
82
|
await import('./opentui-register.mjs');
|
|
78
83
|
|
|
79
84
|
const { main } = await import('../dist/src/cli.js');
|
|
85
|
+
const { formatAppError, t } = await import('../dist/src/i18n/index.js');
|
|
80
86
|
const { InterruptError } = await import('../dist/src/ui/shell/terminal.js');
|
|
81
87
|
|
|
82
88
|
main().catch((error) => {
|
|
@@ -87,6 +93,8 @@ main().catch((error) => {
|
|
|
87
93
|
process.exitCode = 130;
|
|
88
94
|
return;
|
|
89
95
|
}
|
|
90
|
-
|
|
96
|
+
// Single presentation path: DomainError codes → catalog; plain Error → message.
|
|
97
|
+
const message = formatAppError(error);
|
|
98
|
+
console.error(t('cli.errorPrefix', { message }));
|
|
91
99
|
process.exitCode = 1;
|
|
92
100
|
});
|
package/dist/src/cli.js
CHANGED
|
@@ -1,11 +1,21 @@
|
|
|
1
1
|
import { createRequire } from 'node:module';
|
|
2
|
-
import { commandAdd, commandCreate, commandImport, commandInit, commandSearch, printHelp, } from './commands/index.js';
|
|
2
|
+
import { commandAdd, commandConfig, commandCreate, commandImport, commandInit, commandSearch, printHelp, } from './commands/index.js';
|
|
3
3
|
import { commitCollection, ensureCollection, readState } from './domain/core.js';
|
|
4
4
|
import { finalizeResolvedConflicts } from './domain/git.js';
|
|
5
|
+
import { DomainError } from './domain/errors.js';
|
|
6
|
+
import { applyUserConfigLocale, installDomainNotify, t } from './i18n/index.js';
|
|
5
7
|
import { InterruptError } from './ui/shell/terminal.js';
|
|
6
8
|
const packageVersion = createRequire(import.meta.url)('../../package.json').version;
|
|
7
|
-
const PUBLIC_COMMANDS = new Set([
|
|
9
|
+
const PUBLIC_COMMANDS = new Set([
|
|
10
|
+
'search',
|
|
11
|
+
'add',
|
|
12
|
+
'create',
|
|
13
|
+
'import',
|
|
14
|
+
'init',
|
|
15
|
+
'config',
|
|
16
|
+
]);
|
|
8
17
|
async function run(argv) {
|
|
18
|
+
await applyUserConfigLocale();
|
|
9
19
|
const [command, ...rest] = argv;
|
|
10
20
|
if (command === 'help' || command === '--help' || command === '-h') {
|
|
11
21
|
return printHelp(rest[0]);
|
|
@@ -16,12 +26,15 @@ async function run(argv) {
|
|
|
16
26
|
console.log(packageVersion);
|
|
17
27
|
return;
|
|
18
28
|
}
|
|
19
|
-
if (command && !PUBLIC_COMMANDS.has(command))
|
|
20
|
-
throw new
|
|
29
|
+
if (command && !PUBLIC_COMMANDS.has(command)) {
|
|
30
|
+
throw new DomainError('cli.unknownCommand', { command });
|
|
31
|
+
}
|
|
21
32
|
if (command === 'search')
|
|
22
33
|
return commandSearch(rest);
|
|
34
|
+
if (command === 'config')
|
|
35
|
+
return commandConfig(rest);
|
|
23
36
|
if (!command && (!process.stdin.isTTY || !process.stdout.isTTY)) {
|
|
24
|
-
throw new
|
|
37
|
+
throw new DomainError('cli.mainTtyRequired');
|
|
25
38
|
}
|
|
26
39
|
await ensureCollection();
|
|
27
40
|
if (command === 'init')
|
|
@@ -30,7 +43,7 @@ async function run(argv) {
|
|
|
30
43
|
await commitCollection('capture external skill edits');
|
|
31
44
|
const pending = (await readState()).conflicts;
|
|
32
45
|
if (pending.length)
|
|
33
|
-
console.error(
|
|
46
|
+
console.error(t('cli.pendingConflicts', { count: pending.length }));
|
|
34
47
|
if (!command) {
|
|
35
48
|
const { runBrowserApp } = await import('./ui/browser/index.js');
|
|
36
49
|
return runBrowserApp('', 'collection');
|
|
@@ -41,9 +54,10 @@ async function run(argv) {
|
|
|
41
54
|
return commandCreate(rest);
|
|
42
55
|
if (command === 'import')
|
|
43
56
|
return commandImport(rest);
|
|
44
|
-
throw new
|
|
57
|
+
throw new DomainError('cli.unknownCommand', { command });
|
|
45
58
|
}
|
|
46
59
|
export async function main(argv = process.argv.slice(2)) {
|
|
60
|
+
installDomainNotify();
|
|
47
61
|
try {
|
|
48
62
|
await run(argv);
|
|
49
63
|
}
|
|
@@ -53,6 +67,7 @@ export async function main(argv = process.argv.slice(2)) {
|
|
|
53
67
|
process.exitCode = 130;
|
|
54
68
|
return;
|
|
55
69
|
}
|
|
70
|
+
// Keep DomainError (stable code); bin formats via formatAppError.
|
|
56
71
|
throw error;
|
|
57
72
|
}
|
|
58
73
|
finally {
|
package/dist/src/cli.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli.js","sourceRoot":"","sources":["../../src/cli.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EACL,UAAU,EACV,aAAa,EACb,aAAa,EACb,WAAW,EACX,aAAa,EACb,SAAS,GACV,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AACjF,OAAO,EAAE,yBAAyB,EAAE,MAAM,iBAAiB,CAAC;AAC5D,OAAO,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAC;AAExD,MAAM,cAAc,GAClB,aAAa,CAAC,OAAO,IAAI,CAAC,GAAG,CAAC,CAAC,oBAAoB,CACpD,CAAC,OAAO,CAAC;AAEV,MAAM,eAAe,GAAG,IAAI,GAAG,CAAC,
|
|
1
|
+
{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QAAE,OAAO,UAAU,CAAC,IAAI,CAAC,CAAC;IAC/C,IAAI,OAAO,KAAK,QAAQ;QAAE,OAAO,aAAa,CAAC,IAAI,CAAC,CAAC;IACrD,IAAI,OAAO,KAAK,QAAQ;QAAE,OAAO,aAAa,CAAC,IAAI,CAAC,CAAC;IACrD,MAAM,IAAI,WAAW,CAAC,oBAAoB,EAAE,EAAE,OAAO,EAAE,CAAC,CAAC;AAC3D,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,IAAI,CAAC,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;IACrD,mBAAmB,EAAE,CAAC;IACtB,IAAI,CAAC;QACH,MAAM,GAAG,CAAC,IAAI,CAAC,CAAC;IAClB,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,IACE,KAAK,YAAY,cAAc;YAC/B,CAAC,KAAK,YAAY,KAAK,IAAI,KAAK,CAAC,IAAI,KAAK,gBAAgB,CAAC,EAC3D,CAAC;YACD,OAAO,CAAC,QAAQ,GAAG,GAAG,CAAC;YACvB,OAAO;QACT,CAAC;QACD,kEAAkE;QAClE,MAAM,KAAK,CAAC;IACd,CAAC;YAAS,CAAC;QACT,kEAAkE;QAClE,MAAM,EAAE,QAAQ,EAAE,GAAG,MAAM,MAAM,CAAC,yBAAyB,CAAC,CAAC;QAC7D,QAAQ,EAAE,CAAC;IACb,CAAC;AACH,CAAC"}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import type { BrowserActionHost, BrowserDataSnapshot, BrowserResult, DetailEditorContext, DetailViewContext } from '../ui/browser/types.js';
|
|
2
2
|
export declare function loadBrowserData(): Promise<BrowserDataSnapshot>;
|
|
3
|
+
/** One-shot adopt for skills that landed under skills/ without metadata. */
|
|
4
|
+
export declare function adoptMissingCollectionMetadata(names?: string[]): Promise<string[]>;
|
|
3
5
|
export declare function loadDetailContext(skill: import('../domain/types.js').Skill, collection: boolean, frameHeight: number, frameWidth: number): Promise<DetailViewContext>;
|
|
4
6
|
export declare function handleBrowserResult(host: BrowserActionHost, result: BrowserResult): Promise<'quit' | 'continue'>;
|
|
5
7
|
export declare function handleDetailAction(host: BrowserActionHost, context: DetailEditorContext, action: 'note' | 'tags' | 'source'): Promise<void>;
|