@linxin666/dsh-client-ui-task-board 0.3.0 → 0.3.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/lib/client.js +25 -15
- package/lib/client.js.map +1 -1
- package/package.json +1 -1
- package/src/client/index.ts +21 -11
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@linxin666/dsh-client-ui-task-board",
|
|
3
3
|
"description": "Host-authoritative task board for the DSH Web GUI with real session execution, Host cron scheduling, and optional cross-platform idle-sleep protection; mounted without DSH source changes.",
|
|
4
|
-
"version": "0.3.
|
|
4
|
+
"version": "0.3.1",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "lib/index.js",
|
|
7
7
|
"types": "lib/types/index.d.ts",
|
package/src/client/index.ts
CHANGED
|
@@ -84,7 +84,13 @@ export function apply(ctx: ClientContext): void {
|
|
|
84
84
|
// page instead of being silently dropped.
|
|
85
85
|
ctx.effect(() => releaseTaskboardApply, 'task-board: apply claim')
|
|
86
86
|
|
|
87
|
-
ctx.effect(() =>
|
|
87
|
+
ctx.effect(() => {
|
|
88
|
+
try {
|
|
89
|
+
return ctx.locale.register(NS, { zh, en })
|
|
90
|
+
} catch {
|
|
91
|
+
return () => {}
|
|
92
|
+
}
|
|
93
|
+
}, 'task-board: dictionaries')
|
|
88
94
|
|
|
89
95
|
// Plugin configuration card: one staged form over the `task-board` settings
|
|
90
96
|
// namespace, contributed to the Web UI plugin group.
|
|
@@ -92,16 +98,20 @@ export function apply(ctx: ClientContext): void {
|
|
|
92
98
|
const settingsScope = binder.bind<TaskBoardSettings>({ namespace: TASK_BOARD_NS })
|
|
93
99
|
const settingsCard = new TaskBoardSettingsCardController(settingsScope)
|
|
94
100
|
ctx.slots.inject('web-ui.plugin.item', () => {
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
101
|
+
try {
|
|
102
|
+
const unregister = ctx.slots.register({
|
|
103
|
+
name: 'web-ui.plugin.item',
|
|
104
|
+
id: 'task-board',
|
|
105
|
+
order: 110,
|
|
106
|
+
locale: NS,
|
|
107
|
+
inject: () => settingsCard.inject(),
|
|
108
|
+
}, TaskBoardSettingsCard)
|
|
109
|
+
return () => {
|
|
110
|
+
settingsCard.dispose()
|
|
111
|
+
unregister()
|
|
112
|
+
}
|
|
113
|
+
} catch {
|
|
114
|
+
return () => {}
|
|
105
115
|
}
|
|
106
116
|
})
|
|
107
117
|
|