dshget 0.0.0-stage → 0.1.0
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.md +12 -2
- package/client.js +39 -0
- package/cordis.patch.yml +3 -0
- package/index.js +5 -0
- package/package.json +11 -4
package/README.md
CHANGED
|
@@ -1,3 +1,13 @@
|
|
|
1
|
-
#
|
|
1
|
+
# DSH Store — Hello 测试插件
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
这是用于 DeepSeek Harness 的第三方测试插件,在支持插件页扩展的版本中提供「DSH Store」标签,展示 `Hi there!`。
|
|
4
|
+
|
|
5
|
+
在 DSH 桌面版「添加插件」中输入 npm 包名:
|
|
6
|
+
|
|
7
|
+
```text
|
|
8
|
+
dshget
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
安装后重启 DSH,在插件页面查看「DSH 商店」。标签和页面接入 DSH 的语言服务,提供中文、英语、俄语、法语、西班牙语、阿拉伯语、日语和韩语翻译;可选择的语言由 DSH 本身及已安装语言包决定。测试版本没有商店功能。之前安装过 `dsh-store-hello` 或 `dshstore` 的用户应先卸载旧插件,避免同时出现两个标签。
|
|
12
|
+
|
|
13
|
+
这是独立社区项目,与 DeepSeek 官方无隶属关系。
|
package/client.js
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
window.__ModuleLoader__.load({
|
|
2
|
+
id: 'dshget',
|
|
3
|
+
factory(require) {
|
|
4
|
+
const { createElement } = require('react')
|
|
5
|
+
const ns = 'dsh-store-hello'
|
|
6
|
+
const dictionaries = {
|
|
7
|
+
zh: { tab: 'DSH 商店', greeting: '你好!👋', description: 'DSH Store 测试插件已加载。' },
|
|
8
|
+
en: { tab: 'DSH Store', greeting: 'Hi there! 👋', description: 'The DSH Store test plugin is loaded.' },
|
|
9
|
+
ru: { tab: 'Магазин DSH', greeting: 'Привет! 👋', description: 'Тестовый плагин DSH Store загружен.' },
|
|
10
|
+
fr: { tab: 'Boutique DSH', greeting: 'Bonjour ! 👋', description: 'Le plug-in de test DSH Store est chargé.' },
|
|
11
|
+
es: { tab: 'Tienda DSH', greeting: '¡Hola! 👋', description: 'El complemento de prueba de DSH Store está cargado.' },
|
|
12
|
+
ar: { tab: 'متجر DSH', greeting: 'مرحبًا! 👋', description: 'تم تحميل إضافة DSH Store التجريبية.' },
|
|
13
|
+
ja: { tab: 'DSH ストア', greeting: 'こんにちは!👋', description: 'DSH Store のテストプラグインが読み込まれました。' },
|
|
14
|
+
ko: { tab: 'DSH 스토어', greeting: '안녕하세요! 👋', description: 'DSH Store 테스트 플러그인이 로드되었습니다.' },
|
|
15
|
+
}
|
|
16
|
+
const render = ({ t }) => createElement('div', { style: { padding: '32px' } },
|
|
17
|
+
createElement('h1', null, t('greeting')),
|
|
18
|
+
createElement('p', null, t('description')))
|
|
19
|
+
|
|
20
|
+
return {
|
|
21
|
+
name: 'dshget',
|
|
22
|
+
inject: ['slots', 'locale'],
|
|
23
|
+
apply(ctx) {
|
|
24
|
+
ctx.effect(() => ctx.locale.register(ns, dictionaries), 'dsh-store: translations')
|
|
25
|
+
const t = ctx.locale.bind(ns)
|
|
26
|
+
for (const slot of ['plugins.tab', 'settings.plugins.tab']) {
|
|
27
|
+
ctx.slots.inject(slot, () => ctx.slots.register({
|
|
28
|
+
name: slot,
|
|
29
|
+
id: 'dshget',
|
|
30
|
+
order: -99,
|
|
31
|
+
locale: ns,
|
|
32
|
+
label: () => t('tab'),
|
|
33
|
+
inject: () => ({ t }),
|
|
34
|
+
}, render))
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
})
|
package/cordis.patch.yml
ADDED
package/index.js
ADDED
package/package.json
CHANGED
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dshget",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "A simple DSH Store test page for DeepSeek Harness",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "index.js",
|
|
7
|
+
"files": ["index.js", "client.js", "cordis.patch.yml"],
|
|
8
|
+
"exports": { ".": "./index.js", "./client": "./client.js", "./package.json": "./package.json" },
|
|
9
|
+
"dsh": {
|
|
10
|
+
"bundle": { "patch": "./cordis.patch.yml" },
|
|
11
|
+
"client": { "inject": ["@deepseek-ai/dsh-client-locale"], "platform": "web" }
|
|
12
|
+
}
|
|
13
|
+
}
|