dsh-completion-reminder 1.0.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 +173 -0
- package/cordis.patch.yml +7 -0
- package/dist/dsh-completion-reminder.js +590 -0
- package/install.md +97 -0
- package/lib/client.d.ts +34 -0
- package/lib/client.d.ts.map +1 -0
- package/lib/client.js +779 -0
- package/lib/client.js.map +1 -0
- package/lib/index.d.ts +15 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +15 -0
- package/lib/index.js.map +1 -0
- package/lib/types.d.ts +208 -0
- package/lib/types.d.ts.map +1 -0
- package/lib/types.js +72 -0
- package/lib/types.js.map +1 -0
- package/package.json +68 -0
package/lib/client.d.ts
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* DSH Completion Reminder — client half.
|
|
3
|
+
*
|
|
4
|
+
* A DOM-based DSH client plugin that fires a notification when the agent
|
|
5
|
+
* stops generating. The plugin watches the input toolbar (send vs stop
|
|
6
|
+
* button) and the conversation stream to detect three terminal states:
|
|
7
|
+
* success, user-stopped, and error.
|
|
8
|
+
*
|
|
9
|
+
* Delivery channels:
|
|
10
|
+
* - browser : window.Notification (default; user-gated permission)
|
|
11
|
+
* - telegram : Telegram Bot API
|
|
12
|
+
* - bark : Apple Push (Bark) HTTP API
|
|
13
|
+
* - pushover : Pushover REST API
|
|
14
|
+
* - serverchan: Server酱 (sct.ftqq.com) — popular in CN
|
|
15
|
+
* - discord : Discord incoming webhook
|
|
16
|
+
* - slack : Slack incoming webhook
|
|
17
|
+
* - webhook : generic JSON POST webhook
|
|
18
|
+
* - custom : user-supplied function
|
|
19
|
+
*
|
|
20
|
+
* The plugin is packaged as a DSH client plugin (`dsh.client` in
|
|
21
|
+
* package.json) and loaded through `window.__ModuleLoader__`.
|
|
22
|
+
*/
|
|
23
|
+
import type { CompletionReminderOptions } from './types.js';
|
|
24
|
+
import { DEFAULT_OPTIONS } from './types.js';
|
|
25
|
+
declare function configure(opts?: CompletionReminderOptions): void;
|
|
26
|
+
declare function activate(): void;
|
|
27
|
+
declare function deactivate(): void;
|
|
28
|
+
declare function requestBrowserPermission(): Promise<NotificationPermission | 'unsupported'>;
|
|
29
|
+
/**
|
|
30
|
+
* DSH client plugin entry — called by the Cordis Loader.
|
|
31
|
+
*/
|
|
32
|
+
declare function apply(ctx: unknown, opts?: CompletionReminderOptions): void;
|
|
33
|
+
export { configure, activate, deactivate, apply, requestBrowserPermission, DEFAULT_OPTIONS };
|
|
34
|
+
//# sourceMappingURL=client.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,KAAK,EAEV,yBAAyB,EAK1B,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,eAAe,EAGhB,MAAM,YAAY,CAAC;AA8EpB,iBAAS,SAAS,CAAC,IAAI,CAAC,EAAE,yBAAyB,GAAG,IAAI,CAUzD;AAED,iBAAS,QAAQ,IAAI,IAAI,CAcxB;AAED,iBAAS,UAAU,IAAI,IAAI,CAQ1B;AAWD,iBAAe,wBAAwB,IAAI,OAAO,CAAC,sBAAsB,GAAG,aAAa,CAAC,CAczF;AA2jBD;;GAEG;AACH,iBAAS,KAAK,CAAC,GAAG,EAAE,OAAO,EAAE,IAAI,CAAC,EAAE,yBAAyB,GAAG,IAAI,CAGnE;AAED,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,UAAU,EAAE,KAAK,EAAE,wBAAwB,EAAE,eAAe,EAAE,CAAA"}
|