@tolinax/ayoune-interfaces 2026.62.0 → 2026.63.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.
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* in the in-app notifications panel and (up to two primary actions) as native
|
|
4
4
|
* Web-Push action buttons on supporting platforms.
|
|
5
5
|
*
|
|
6
|
-
*
|
|
6
|
+
* Five dispatch modes:
|
|
7
7
|
* - `link` — internal router navigation (`href` relative to the app)
|
|
8
8
|
* - `api` — `fetch()` call to an absolute endpoint, optionally with
|
|
9
9
|
* a confirm prompt; the service-worker can execute this
|
|
@@ -12,10 +12,21 @@
|
|
|
12
12
|
* dialog in the PWA; the text is POSTed to `endpoint`.
|
|
13
13
|
* - `ai-copilot` — opens the Comm-Sidebar Copilot panel with
|
|
14
14
|
* `copilotContext` pre-populated as the first user message.
|
|
15
|
+
* - `sidebar` — opens a specific Comm-Sidebar panel with an optional
|
|
16
|
+
* `itemId` / `threadId` / `messageId` target so the
|
|
17
|
+
* PWA scrolls/loads directly to the target item.
|
|
18
|
+
* Consumed by `SidebarDeeplinkService` in the
|
|
19
|
+
* `@tolinax/ayoune-comm-sidebar` library.
|
|
15
20
|
*/
|
|
16
|
-
export type NotificationActionType = "link" | "api" | "reply" | "ai-copilot";
|
|
21
|
+
export type NotificationActionType = "link" | "api" | "reply" | "ai-copilot" | "sidebar";
|
|
17
22
|
/** Visual weight of the action button. */
|
|
18
23
|
export type NotificationActionStyle = "primary" | "secondary" | "danger";
|
|
24
|
+
/**
|
|
25
|
+
* Target panel for `type: "sidebar"` actions. Mirrors the `SidebarPanel`
|
|
26
|
+
* union in `@tolinax/ayoune-comm-sidebar` — duplicated here so the
|
|
27
|
+
* interfaces package stays free of Angular/runtime deps.
|
|
28
|
+
*/
|
|
29
|
+
export type NotificationSidebarPanel = "copilot" | "notifications" | "phone" | "video" | "chat" | "contacts" | "channels" | "support" | "inbox";
|
|
19
30
|
export interface INotificationAction {
|
|
20
31
|
/** Stable identifier per notification — used as the Web-Push `action` id. */
|
|
21
32
|
id: string;
|
|
@@ -40,6 +51,21 @@ export interface INotificationAction {
|
|
|
40
51
|
* that are rendered against the notification's `data` context before
|
|
41
52
|
* being inserted into the input. */
|
|
42
53
|
copilotContext?: string;
|
|
54
|
+
/** For `type: "sidebar"` — the target panel to open. */
|
|
55
|
+
panel?: NotificationSidebarPanel;
|
|
56
|
+
/** For `type: "sidebar"` — optional target item inside the panel
|
|
57
|
+
* (notification id, ticket id, external-inbox conversation id, etc.). */
|
|
58
|
+
itemId?: string;
|
|
59
|
+
/** For `type: "sidebar"` with `panel: "chat"` or `panel: "channels"` —
|
|
60
|
+
* the thread/channel id to load before scrolling. */
|
|
61
|
+
threadId?: string;
|
|
62
|
+
/** For `type: "sidebar"` with `panel: "chat"` or `panel: "channels"` —
|
|
63
|
+
* optional message id to scroll into view after the thread loads. */
|
|
64
|
+
messageId?: string;
|
|
65
|
+
/** For `type: "sidebar"` with `panel: "phone"` — dialer sub-action
|
|
66
|
+
* (`accept`, `reject`, `dial`). Auto-fires `CommBridgeService.voice.*`
|
|
67
|
+
* on arrival when set. */
|
|
68
|
+
panelAction?: "accept" | "reject" | "dial" | "join";
|
|
43
69
|
/** Should this action close/dismiss the notification after firing? */
|
|
44
70
|
dismissOnComplete?: boolean;
|
|
45
71
|
}
|