@remit/web-client 0.0.283 → 0.0.284
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@remit/web-client",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.284",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Remit web client, published as composable primitives — the app shell, auth shells, and runtime config. A distributor imports what it composes and bundles it.",
|
|
6
6
|
"exports": {
|
|
@@ -17,7 +17,7 @@ import { QuarantinePanelView } from "./QuarantinePanel";
|
|
|
17
17
|
const render = (props: {
|
|
18
18
|
entries: readonly QuarantineEntry[];
|
|
19
19
|
isPending: boolean;
|
|
20
|
-
error:
|
|
20
|
+
error: unknown;
|
|
21
21
|
}): string =>
|
|
22
22
|
renderToString(createElement(QuarantinePanelView, props) as never);
|
|
23
23
|
|
|
@@ -44,7 +44,7 @@ function issueUrlFor(entry: QuarantineEntry): string {
|
|
|
44
44
|
);
|
|
45
45
|
}
|
|
46
46
|
|
|
47
|
-
function QuarantineReadFailure({ error }: { error:
|
|
47
|
+
function QuarantineReadFailure({ error }: { error: unknown }) {
|
|
48
48
|
return (
|
|
49
49
|
<section role="alert" className="space-y-3">
|
|
50
50
|
<h2 className="text-sm font-semibold text-fg">Messages set aside</h2>
|
|
@@ -77,7 +77,7 @@ function QuarantineReadFailure({ error }: { error: Error }) {
|
|
|
77
77
|
export interface QuarantinePanelViewProps {
|
|
78
78
|
entries: readonly QuarantineEntry[];
|
|
79
79
|
isPending: boolean;
|
|
80
|
-
error:
|
|
80
|
+
error: unknown;
|
|
81
81
|
}
|
|
82
82
|
|
|
83
83
|
export function QuarantinePanelView({
|
|
@@ -25,13 +25,17 @@ type MailboxItems = RemitImapMailboxResponse[];
|
|
|
25
25
|
interface MailboxListsState {
|
|
26
26
|
items: MailboxItems[];
|
|
27
27
|
isPending: boolean;
|
|
28
|
-
|
|
28
|
+
// Typed as the generated wire body by TanStack now that the operation
|
|
29
|
+
// declares its failures, but always an `ApiError` or a `NetworkError` by the
|
|
30
|
+
// time it arrives — `client.ts` re-wraps every HTTP failure.
|
|
31
|
+
// `formatErrorMessage` reads a message off any of them.
|
|
32
|
+
error: unknown;
|
|
29
33
|
}
|
|
30
34
|
|
|
31
35
|
export interface ResultFolderIndexState {
|
|
32
36
|
index: ResultFolderIndex;
|
|
33
37
|
isPending: boolean;
|
|
34
|
-
error:
|
|
38
|
+
error: unknown;
|
|
35
39
|
}
|
|
36
40
|
|
|
37
41
|
/**
|
|
@@ -44,7 +48,7 @@ const combineMailboxLists = (
|
|
|
44
48
|
results: {
|
|
45
49
|
data?: { items: MailboxItems };
|
|
46
50
|
isPending: boolean;
|
|
47
|
-
error:
|
|
51
|
+
error: unknown;
|
|
48
52
|
}[],
|
|
49
53
|
): MailboxListsState => ({
|
|
50
54
|
items: results.map((result) => result.data?.items ?? []),
|
|
@@ -9,7 +9,13 @@ interface UseTriggerSyncResult {
|
|
|
9
9
|
trigger: () => void;
|
|
10
10
|
triggerAsync: () => Promise<unknown>;
|
|
11
11
|
isPending: boolean;
|
|
12
|
-
|
|
12
|
+
// TanStack types this as the generated wire body now that the operation
|
|
13
|
+
// declares its failures; by the time it arrives, `client.ts`'s error
|
|
14
|
+
// interceptor has re-wrapped it as an `ApiError` and `taggedFetch` a
|
|
15
|
+
// transport failure as a `NetworkError`. `unknown` is what the declared type
|
|
16
|
+
// and the real one agree on, and every reader goes through
|
|
17
|
+
// `formatErrorMessage`.
|
|
18
|
+
error: unknown;
|
|
13
19
|
reset: () => void;
|
|
14
20
|
}
|
|
15
21
|
|