@hiver/connector-agent 4.18.1 → 4.18.2
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/app/hig-slack/HigSlackSection.d.ts.map +1 -1
- package/features/slack/api/__tests__/linked-conv.test.d.ts +2 -0
- package/features/slack/api/__tests__/linked-conv.test.d.ts.map +1 -0
- package/features/slack/api/linked-conv.d.ts +38 -6
- package/features/slack/api/linked-conv.d.ts.map +1 -1
- package/features/slack/components/HeroIllustration.d.ts +1 -0
- package/features/slack/components/HeroIllustration.d.ts.map +1 -1
- package/features/slack/components/LinkedConversationPanel/ThreadDetailView.d.ts.map +1 -1
- package/features/slack/components/SlackConversationTab.d.ts.map +1 -1
- package/index.es.js +3363 -3333
- package/index.umd.js +327 -327
- package/main-dev.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HigSlackSection.d.ts","sourceRoot":"","sources":["../../../src/app/hig-slack/HigSlackSection.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAkC,MAAM,OAAO,CAAC;AAQ3D,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAiCjE,MAAM,MAAM,oBAAoB,GAAG,gBAAgB,GAAG;IACpD;yEACqE;IACrE,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;CACxB,CAAC;
|
|
1
|
+
{"version":3,"file":"HigSlackSection.d.ts","sourceRoot":"","sources":["../../../src/app/hig-slack/HigSlackSection.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAkC,MAAM,OAAO,CAAC;AAQ3D,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAiCjE,MAAM,MAAM,oBAAoB,GAAG,gBAAgB,GAAG;IACpD;yEACqE;IACrE,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;CACxB,CAAC;AAoPF;;;;;GAKG;AACH,eAAO,MAAM,eAAe,EAAE,EAAE,CAAC,oBAAoB,CAIpD,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"linked-conv.test.d.ts","sourceRoot":"","sources":["../../../../../src/features/slack/api/__tests__/linked-conv.test.ts"],"names":[],"mappings":""}
|
|
@@ -10,6 +10,29 @@ import { ExternalConversation, SlackThreadGroup } from '../types/wire';
|
|
|
10
10
|
* the timer.
|
|
11
11
|
*/
|
|
12
12
|
export declare const LINKED_CONV_POLL_INTERVAL_MS = 2000;
|
|
13
|
+
/**
|
|
14
|
+
* Slower cadence for the HIG details-panel section (M-HIG). Unlike the tab
|
|
15
|
+
* — which mounts only when the agent opens it — the section lives in the
|
|
16
|
+
* mail-view details column and is near-permanently mounted, so it polls at a
|
|
17
|
+
* lighter rate to keep the always-on background load down. The tab keeps the
|
|
18
|
+
* snappier LINKED_CONV_POLL_INTERVAL_MS.
|
|
19
|
+
*/
|
|
20
|
+
export declare const SECTION_POLL_INTERVAL_MS = 5000;
|
|
21
|
+
/**
|
|
22
|
+
* Backoff ceiling for a failing poll. While the endpoint keeps erroring the
|
|
23
|
+
* interval doubles per consecutive failure and is clamped here, so a dead
|
|
24
|
+
* backend is hit at most once a minute instead of every 2s. The first
|
|
25
|
+
* successful fetch resets react-query's failure count, snapping the cadence
|
|
26
|
+
* straight back to the base interval.
|
|
27
|
+
*/
|
|
28
|
+
export declare const MAX_POLL_BACKOFF_MS = 60000;
|
|
29
|
+
/**
|
|
30
|
+
* Base interval → actual interval given the number of consecutive fetch
|
|
31
|
+
* failures. Exponential backoff (base·2^failures) capped at
|
|
32
|
+
* MAX_POLL_BACKOFF_MS; a healthy / just-recovered query (failureCount 0)
|
|
33
|
+
* polls at the base cadence.
|
|
34
|
+
*/
|
|
35
|
+
export declare function backedOffInterval(baseMs: number, failureCount: number): number;
|
|
13
36
|
/**
|
|
14
37
|
* Reads the linked Slack thread for a Hiver conversation, if any.
|
|
15
38
|
* Returns `null` on 404 (no link yet) and surfaces other errors
|
|
@@ -17,17 +40,26 @@ export declare const LINKED_CONV_POLL_INTERVAL_MS = 2000;
|
|
|
17
40
|
*
|
|
18
41
|
* Used by SlackEmptyState (UI-1) to branch between the "Start" CTAs
|
|
19
42
|
* and the LinkedConversationPanel (UI-5). Polls every
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
43
|
+
* `refetchIntervalMs` while the surface is active so inbound Slack
|
|
44
|
+
* messages surface without a websocket — react-query pauses the timer
|
|
45
|
+
* when the browser tab is hidden, and hosts that keep the surface
|
|
46
|
+
* mounted-but-hidden pass a 0 interval (via `isActive`) to pause it too.
|
|
47
|
+
*
|
|
48
|
+
* Two load-shedding behaviours layer on the base cadence:
|
|
49
|
+
* - Pass a falsy interval (0 / undefined) to disable polling entirely
|
|
50
|
+
* (the surface is inactive / hidden behind another tab).
|
|
51
|
+
* - While the endpoint is failing, the effective interval backs off
|
|
52
|
+
* exponentially up to MAX_POLL_BACKOFF_MS and snaps back to base on
|
|
53
|
+
* the first success (see `backedOffInterval`).
|
|
24
54
|
*/
|
|
25
55
|
export declare function useLinkedConversation(hiverConvId: string, enabled?: boolean, refetchIntervalMs?: number): import('@tanstack/react-query').UseQueryResult<ExternalConversation | null, Error>;
|
|
26
56
|
/**
|
|
27
57
|
* Channel mode (B4): lazily fetch a single thread's messages (root +
|
|
28
58
|
* replies) when the user drills into it from the channel list. Enabled
|
|
29
59
|
* only while a thread is open, so the channel list view never pays for
|
|
30
|
-
* replies. Polls on the same cadence so live replies surface
|
|
60
|
+
* replies. Polls on the same cadence so live replies surface — and, like
|
|
61
|
+
* `useLinkedConversation`, pauses when the surface is inactive (`isActive`
|
|
62
|
+
* false) and backs off while the endpoint is failing.
|
|
31
63
|
*/
|
|
32
|
-
export declare function useThread(hiverConvId: string, threadTs: string | null): import('@tanstack/react-query').UseQueryResult<SlackThreadGroup, Error>;
|
|
64
|
+
export declare function useThread(hiverConvId: string, threadTs: string | null, isActive?: boolean): import('@tanstack/react-query').UseQueryResult<SlackThreadGroup, Error>;
|
|
33
65
|
//# sourceMappingURL=linked-conv.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"linked-conv.d.ts","sourceRoot":"","sources":["../../../../src/features/slack/api/linked-conv.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,oBAAoB,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAE1F;;;;;;;;;GASG;AACH,eAAO,MAAM,4BAA4B,OAAO,CAAC;AAEjD
|
|
1
|
+
{"version":3,"file":"linked-conv.d.ts","sourceRoot":"","sources":["../../../../src/features/slack/api/linked-conv.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,oBAAoB,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAE1F;;;;;;;;;GASG;AACH,eAAO,MAAM,4BAA4B,OAAO,CAAC;AAEjD;;;;;;GAMG;AACH,eAAO,MAAM,wBAAwB,OAAO,CAAC;AAE7C;;;;;;GAMG;AACH,eAAO,MAAM,mBAAmB,QAAQ,CAAC;AAEzC;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,GAAG,MAAM,CAG9E;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,qBAAqB,CACnC,WAAW,EAAE,MAAM,EACnB,OAAO,UAAO,EACd,iBAAiB,GAAE,MAAqC,sFA+BzD;AAED;;;;;;;GAOG;AACH,wBAAgB,SAAS,CAAC,WAAW,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI,EAAE,QAAQ,UAAO,2EAWtF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HeroIllustration.d.ts","sourceRoot":"","sources":["../../../../src/features/slack/components/HeroIllustration.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAM3B;;;;;;;;GAQG;AACH,eAAO,MAAM,gBAAgB,EAAE,EAAE,CAAC;IAAE,KAAK,CAAC,EAAE,MAAM,CAAA;CAAE,
|
|
1
|
+
{"version":3,"file":"HeroIllustration.d.ts","sourceRoot":"","sources":["../../../../src/features/slack/components/HeroIllustration.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAM3B;;;;;;;;GAQG;AACH,eAAO,MAAM,gBAAgB,EAAE,EAAE,CAAC;IAAE,KAAK,CAAC,EAAE,MAAM,CAAC;IAAC,KAAK,CAAC,EAAE,OAAO,CAAA;CAAE,CAQpE,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ThreadDetailView.d.ts","sourceRoot":"","sources":["../../../../../src/features/slack/components/LinkedConversationPanel/ThreadDetailView.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,SAAS,EAAyC,MAAM,OAAO,CAAC;AA0F7E,UAAU,qBAAqB;IAC7B,0CAA0C;IAC1C,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAClC;0EACsE;IACtE,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,cAAc,EAAE,OAAO,CAAC;IACxB,KAAK,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC,CAAC,CAAC,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;IAChD,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB;;qEAEiE;IACjE,WAAW,CAAC,EAAE,SAAS,CAAC;CACzB;AAED;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB,EAAE,EAAE,CAAC,qBAAqB,
|
|
1
|
+
{"version":3,"file":"ThreadDetailView.d.ts","sourceRoot":"","sources":["../../../../../src/features/slack/components/LinkedConversationPanel/ThreadDetailView.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,SAAS,EAAyC,MAAM,OAAO,CAAC;AA0F7E,UAAU,qBAAqB;IAC7B,0CAA0C;IAC1C,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAClC;0EACsE;IACtE,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,cAAc,EAAE,OAAO,CAAC;IACxB,KAAK,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC,CAAC,CAAC,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;IAChD,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB;;qEAEiE;IACjE,WAAW,CAAC,EAAE,SAAS,CAAC;CACzB;AAED;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB,EAAE,EAAE,CAAC,qBAAqB,CA0KtD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SlackConversationTab.d.ts","sourceRoot":"","sources":["../../../../src/features/slack/components/SlackConversationTab.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAoC,MAAM,OAAO,CAAC;AAwB7D,UAAU,yBAAyB;IACjC;;oDAEgD;IAChD,oBAAoB,CAAC,EAAE,MAAM,IAAI,CAAC;CACnC;AAuCD,eAAO,MAAM,oBAAoB,EAAE,EAAE,CAAC,yBAAyB,
|
|
1
|
+
{"version":3,"file":"SlackConversationTab.d.ts","sourceRoot":"","sources":["../../../../src/features/slack/components/SlackConversationTab.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAoC,MAAM,OAAO,CAAC;AAwB7D,UAAU,yBAAyB;IACjC;;oDAEgD;IAChD,oBAAoB,CAAC,EAAE,MAAM,IAAI,CAAC;CACnC;AAuCD,eAAO,MAAM,oBAAoB,EAAE,EAAE,CAAC,yBAAyB,CAmN9D,CAAC;AAEF,eAAe,oBAAoB,CAAC"}
|