@remit/web-client 0.0.346 → 0.0.347
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/dist/src/components/mail/{FlaggedList.d.ts → CollectionList.d.ts} +7 -3
- package/dist/src/components/mail/{FlaggedList.js → CollectionList.js} +25 -22
- package/dist/src/components/mail/CollectionPane.d.ts +32 -0
- package/dist/src/components/mail/{FlaggedPane.js → CollectionPane.js} +32 -30
- package/dist/src/components/mail/MailSidebarAdapter.js +29 -7
- package/dist/src/hooks/{useStarredThreads.d.ts → useCollectionThreads.d.ts} +10 -8
- package/dist/src/hooks/{useStarredThreads.js → useCollectionThreads.js} +16 -14
- package/dist/src/hooks/useCurrentMailboxName.d.ts +1 -0
- package/dist/src/hooks/useCurrentMailboxName.js +6 -1
- package/dist/src/hooks/useLabels.d.ts +10 -9
- package/dist/src/hooks/useLabels.js +25 -6
- package/dist/src/lib/{flagged-criteria.d.ts → collection-criteria.d.ts} +18 -6
- package/dist/src/lib/{flagged-criteria.js → collection-criteria.js} +4 -3
- package/dist/src/lib/label-folders.d.ts +6 -0
- package/dist/src/lib/label-folders.js +10 -0
- package/dist/src/lib/mail-route.d.ts +10 -5
- package/dist/src/lib/mail-route.js +9 -1
- package/dist/src/lib/mail-search.d.ts +11 -0
- package/dist/src/lib/mail-search.js +4 -0
- package/dist/src/lib/search-scope.d.ts +2 -2
- package/dist/src/lib/search-scope.js +4 -4
- package/dist/src/lib/search-tokens.d.ts +1 -1
- package/dist/src/lib/search-tokens.js +2 -2
- package/dist/src/routeTree.gen.d.ts +288 -3
- package/dist/src/routeTree.gen.js +65 -0
- package/dist/src/routes/mail/flagged/$threadId/$messageId.js +2 -2
- package/dist/src/routes/mail/flagged/$threadId/index.js +2 -2
- package/dist/src/routes/mail/flagged/index.js +2 -2
- package/dist/src/routes/mail/flagged.js +3 -2
- package/dist/src/routes/mail/label/$labelId/$threadId/$messageId/$mode.{-$outboxMessageId}.d.ts +18 -0
- package/dist/src/routes/mail/label/$labelId/$threadId/$messageId/$mode.{-$outboxMessageId}.js +8 -0
- package/dist/src/routes/mail/label/$labelId/$threadId/$messageId.d.ts +15 -0
- package/dist/src/routes/mail/label/$labelId/$threadId/$messageId.js +14 -0
- package/dist/src/routes/mail/label/$labelId/$threadId/index.d.ts +15 -0
- package/dist/src/routes/mail/label/$labelId/$threadId/index.js +9 -0
- package/dist/src/routes/mail/label/$labelId/$threadId.d.ts +15 -0
- package/dist/src/routes/mail/label/$labelId/$threadId.js +8 -0
- package/dist/src/routes/mail/label/$labelId/compose.{-$outboxMessageId}.d.ts +15 -0
- package/dist/src/routes/mail/label/$labelId/compose.{-$outboxMessageId}.js +10 -0
- package/dist/src/routes/mail/label/$labelId/index.d.ts +15 -0
- package/dist/src/routes/mail/label/$labelId/index.js +9 -0
- package/dist/src/routes/mail/label/$labelId.d.ts +15 -0
- package/dist/src/routes/mail/label/$labelId.js +30 -0
- package/dist/src/routes/mail/label/index.d.ts +29 -0
- package/dist/src/routes/mail/label/index.js +18 -0
- package/dist/src/routing/browsed-list.d.ts +1 -1
- package/dist/src/routing/browsed-list.js +15 -4
- package/dist/src/routing/compose.js +10 -6
- package/dist/src/routing/index.d.ts +1 -1
- package/dist/src/routing/index.js +1 -1
- package/dist/src/routing/nav-selection.d.ts +5 -0
- package/dist/src/routing/nav-selection.js +15 -0
- package/dist/src/routing/open-thread.js +23 -3
- package/dist/src/routing/reply.js +28 -11
- package/dist/src/routing/search-mirror.d.ts +5 -0
- package/dist/src/routing/search-mirror.js +20 -2
- package/package.json +2 -2
- package/dist/src/components/mail/FlaggedPane.d.ts +0 -29
|
@@ -39,6 +39,8 @@ import { Route as MailBriefIndexRouteImport } from './routes/mail/brief/index';
|
|
|
39
39
|
import { Route as MailBriefThreadIdRouteImport } from './routes/mail/brief/$threadId';
|
|
40
40
|
import { Route as MailFlaggedIndexRouteImport } from './routes/mail/flagged/index';
|
|
41
41
|
import { Route as MailFlaggedThreadIdRouteImport } from './routes/mail/flagged/$threadId';
|
|
42
|
+
import { Route as MailLabelIndexRouteImport } from './routes/mail/label/index';
|
|
43
|
+
import { Route as MailLabelLabelIdRouteImport } from './routes/mail/label/$labelId';
|
|
42
44
|
import { Route as MailOutboxIndexRouteImport } from './routes/mail/outbox/index';
|
|
43
45
|
import { Route as CalendarViewDateIndexRouteImport } from './routes/calendar/$view.$date/index';
|
|
44
46
|
import { Route as CalendarViewDateCalendarObjectIdRouteImport } from './routes/calendar/$view.$date/$calendarObjectId';
|
|
@@ -52,6 +54,8 @@ import { Route as MailBriefComposeChar123OutboxMessageIdChar125RouteImport } fro
|
|
|
52
54
|
import { Route as MailFlaggedThreadIdIndexRouteImport } from './routes/mail/flagged/$threadId/index';
|
|
53
55
|
import { Route as MailFlaggedThreadIdMessageIdRouteImport } from './routes/mail/flagged/$threadId/$messageId';
|
|
54
56
|
import { Route as MailFlaggedComposeChar123OutboxMessageIdChar125RouteImport } from './routes/mail/flagged/compose.{-$outboxMessageId}';
|
|
57
|
+
import { Route as MailLabelLabelIdIndexRouteImport } from './routes/mail/label/$labelId/index';
|
|
58
|
+
import { Route as MailLabelLabelIdThreadIdRouteImport } from './routes/mail/label/$labelId/$threadId';
|
|
55
59
|
import { Route as MailOutboxComposeChar123OutboxMessageIdChar125RouteImport } from './routes/mail/outbox/compose.{-$outboxMessageId}';
|
|
56
60
|
import { Route as MailOutboxDraftOutboxMessageIdRouteImport } from './routes/mail/outbox/draft/$outboxMessageId';
|
|
57
61
|
import { Route as CalendarViewDateCalendarObjectIdIndexRouteImport } from './routes/calendar/$view.$date/$calendarObjectId/index';
|
|
@@ -59,11 +63,15 @@ import { Route as CalendarViewDateCalendarObjectIdRecurrenceIdRouteImport } from
|
|
|
59
63
|
import { Route as CalendarViewDateCalendarObjectIdEditRouteImport } from './routes/calendar/$view.$date/$calendarObjectId/edit';
|
|
60
64
|
import { Route as CalendarViewDateSuggestionSuggestionIdRouteImport } from './routes/calendar/$view.$date/suggestion.$suggestionId';
|
|
61
65
|
import { Route as CalendarViewDateTaskCalendarTaskIdRouteImport } from './routes/calendar/$view.$date/task.$calendarTaskId';
|
|
66
|
+
import { Route as MailLabelLabelIdThreadIdIndexRouteImport } from './routes/mail/label/$labelId/$threadId/index';
|
|
67
|
+
import { Route as MailLabelLabelIdThreadIdMessageIdRouteImport } from './routes/mail/label/$labelId/$threadId/$messageId';
|
|
68
|
+
import { Route as MailLabelLabelIdComposeChar123OutboxMessageIdChar125RouteImport } from './routes/mail/label/$labelId/compose.{-$outboxMessageId}';
|
|
62
69
|
import { Route as CalendarViewDateCalendarObjectIdRecurrenceIdIndexRouteImport } from './routes/calendar/$view.$date/$calendarObjectId/$recurrenceId/index';
|
|
63
70
|
import { Route as CalendarViewDateCalendarObjectIdRecurrenceIdEditRouteImport } from './routes/calendar/$view.$date/$calendarObjectId/$recurrenceId/edit';
|
|
64
71
|
import { Route as MailMailboxIdThreadIdMessageIdModeChar123OutboxMessageIdChar125RouteImport } from './routes/mail/$mailboxId/$threadId/$messageId/$mode.{-$outboxMessageId}';
|
|
65
72
|
import { Route as MailBriefThreadIdMessageIdModeChar123OutboxMessageIdChar125RouteImport } from './routes/mail/brief/$threadId/$messageId/$mode.{-$outboxMessageId}';
|
|
66
73
|
import { Route as MailFlaggedThreadIdMessageIdModeChar123OutboxMessageIdChar125RouteImport } from './routes/mail/flagged/$threadId/$messageId/$mode.{-$outboxMessageId}';
|
|
74
|
+
import { Route as MailLabelLabelIdThreadIdMessageIdModeChar123OutboxMessageIdChar125RouteImport } from './routes/mail/label/$labelId/$threadId/$messageId/$mode.{-$outboxMessageId}';
|
|
67
75
|
const IndexRoute = IndexRouteImport.update({
|
|
68
76
|
id: '/',
|
|
69
77
|
path: '/',
|
|
@@ -234,6 +242,16 @@ const MailFlaggedThreadIdRoute = MailFlaggedThreadIdRouteImport.update({
|
|
|
234
242
|
path: '/$threadId',
|
|
235
243
|
getParentRoute: () => MailFlaggedRoute,
|
|
236
244
|
});
|
|
245
|
+
const MailLabelIndexRoute = MailLabelIndexRouteImport.update({
|
|
246
|
+
id: '/label/',
|
|
247
|
+
path: '/label/',
|
|
248
|
+
getParentRoute: () => MailRoute,
|
|
249
|
+
});
|
|
250
|
+
const MailLabelLabelIdRoute = MailLabelLabelIdRouteImport.update({
|
|
251
|
+
id: '/label/$labelId',
|
|
252
|
+
path: '/label/$labelId',
|
|
253
|
+
getParentRoute: () => MailRoute,
|
|
254
|
+
});
|
|
237
255
|
const MailOutboxIndexRoute = MailOutboxIndexRouteImport.update({
|
|
238
256
|
id: '/',
|
|
239
257
|
path: '/',
|
|
@@ -299,6 +317,16 @@ const MailFlaggedComposeChar123OutboxMessageIdChar125Route = MailFlaggedComposeC
|
|
|
299
317
|
path: '/compose/{-$outboxMessageId}',
|
|
300
318
|
getParentRoute: () => MailFlaggedRoute,
|
|
301
319
|
});
|
|
320
|
+
const MailLabelLabelIdIndexRoute = MailLabelLabelIdIndexRouteImport.update({
|
|
321
|
+
id: '/',
|
|
322
|
+
path: '/',
|
|
323
|
+
getParentRoute: () => MailLabelLabelIdRoute,
|
|
324
|
+
});
|
|
325
|
+
const MailLabelLabelIdThreadIdRoute = MailLabelLabelIdThreadIdRouteImport.update({
|
|
326
|
+
id: '/$threadId',
|
|
327
|
+
path: '/$threadId',
|
|
328
|
+
getParentRoute: () => MailLabelLabelIdRoute,
|
|
329
|
+
});
|
|
302
330
|
const MailOutboxComposeChar123OutboxMessageIdChar125Route = MailOutboxComposeChar123OutboxMessageIdChar125RouteImport.update({
|
|
303
331
|
id: '/compose/{-$outboxMessageId}',
|
|
304
332
|
path: '/compose/{-$outboxMessageId}',
|
|
@@ -334,6 +362,21 @@ const CalendarViewDateTaskCalendarTaskIdRoute = CalendarViewDateTaskCalendarTask
|
|
|
334
362
|
path: '/task/$calendarTaskId',
|
|
335
363
|
getParentRoute: () => CalendarViewDateRoute,
|
|
336
364
|
});
|
|
365
|
+
const MailLabelLabelIdThreadIdIndexRoute = MailLabelLabelIdThreadIdIndexRouteImport.update({
|
|
366
|
+
id: '/',
|
|
367
|
+
path: '/',
|
|
368
|
+
getParentRoute: () => MailLabelLabelIdThreadIdRoute,
|
|
369
|
+
});
|
|
370
|
+
const MailLabelLabelIdThreadIdMessageIdRoute = MailLabelLabelIdThreadIdMessageIdRouteImport.update({
|
|
371
|
+
id: '/$messageId',
|
|
372
|
+
path: '/$messageId',
|
|
373
|
+
getParentRoute: () => MailLabelLabelIdThreadIdRoute,
|
|
374
|
+
});
|
|
375
|
+
const MailLabelLabelIdComposeChar123OutboxMessageIdChar125Route = MailLabelLabelIdComposeChar123OutboxMessageIdChar125RouteImport.update({
|
|
376
|
+
id: '/compose/{-$outboxMessageId}',
|
|
377
|
+
path: '/compose/{-$outboxMessageId}',
|
|
378
|
+
getParentRoute: () => MailLabelLabelIdRoute,
|
|
379
|
+
});
|
|
337
380
|
const CalendarViewDateCalendarObjectIdRecurrenceIdIndexRoute = CalendarViewDateCalendarObjectIdRecurrenceIdIndexRouteImport.update({
|
|
338
381
|
id: '/',
|
|
339
382
|
path: '/',
|
|
@@ -359,6 +402,11 @@ const MailFlaggedThreadIdMessageIdModeChar123OutboxMessageIdChar125Route = MailF
|
|
|
359
402
|
path: '/$mode/{-$outboxMessageId}',
|
|
360
403
|
getParentRoute: () => MailFlaggedThreadIdMessageIdRoute,
|
|
361
404
|
});
|
|
405
|
+
const MailLabelLabelIdThreadIdMessageIdModeChar123OutboxMessageIdChar125Route = MailLabelLabelIdThreadIdMessageIdModeChar123OutboxMessageIdChar125RouteImport.update({
|
|
406
|
+
id: '/$mode/{-$outboxMessageId}',
|
|
407
|
+
path: '/$mode/{-$outboxMessageId}',
|
|
408
|
+
getParentRoute: () => MailLabelLabelIdThreadIdMessageIdRoute,
|
|
409
|
+
});
|
|
362
410
|
const CalendarViewDateCalendarObjectIdRecurrenceIdRouteChildren = {
|
|
363
411
|
CalendarViewDateCalendarObjectIdRecurrenceIdEditRoute: CalendarViewDateCalendarObjectIdRecurrenceIdEditRoute,
|
|
364
412
|
CalendarViewDateCalendarObjectIdRecurrenceIdIndexRoute: CalendarViewDateCalendarObjectIdRecurrenceIdIndexRoute,
|
|
@@ -434,12 +482,29 @@ const MailOutboxRouteChildren = {
|
|
|
434
482
|
MailOutboxDraftOutboxMessageIdRoute: MailOutboxDraftOutboxMessageIdRoute,
|
|
435
483
|
};
|
|
436
484
|
const MailOutboxRouteWithChildren = MailOutboxRoute._addFileChildren(MailOutboxRouteChildren);
|
|
485
|
+
const MailLabelLabelIdThreadIdMessageIdRouteChildren = {
|
|
486
|
+
MailLabelLabelIdThreadIdMessageIdModeChar123OutboxMessageIdChar125Route: MailLabelLabelIdThreadIdMessageIdModeChar123OutboxMessageIdChar125Route,
|
|
487
|
+
};
|
|
488
|
+
const MailLabelLabelIdThreadIdMessageIdRouteWithChildren = MailLabelLabelIdThreadIdMessageIdRoute._addFileChildren(MailLabelLabelIdThreadIdMessageIdRouteChildren);
|
|
489
|
+
const MailLabelLabelIdThreadIdRouteChildren = {
|
|
490
|
+
MailLabelLabelIdThreadIdMessageIdRoute: MailLabelLabelIdThreadIdMessageIdRouteWithChildren,
|
|
491
|
+
MailLabelLabelIdThreadIdIndexRoute: MailLabelLabelIdThreadIdIndexRoute,
|
|
492
|
+
};
|
|
493
|
+
const MailLabelLabelIdThreadIdRouteWithChildren = MailLabelLabelIdThreadIdRoute._addFileChildren(MailLabelLabelIdThreadIdRouteChildren);
|
|
494
|
+
const MailLabelLabelIdRouteChildren = {
|
|
495
|
+
MailLabelLabelIdThreadIdRoute: MailLabelLabelIdThreadIdRouteWithChildren,
|
|
496
|
+
MailLabelLabelIdIndexRoute: MailLabelLabelIdIndexRoute,
|
|
497
|
+
MailLabelLabelIdComposeChar123OutboxMessageIdChar125Route: MailLabelLabelIdComposeChar123OutboxMessageIdChar125Route,
|
|
498
|
+
};
|
|
499
|
+
const MailLabelLabelIdRouteWithChildren = MailLabelLabelIdRoute._addFileChildren(MailLabelLabelIdRouteChildren);
|
|
437
500
|
const MailRouteChildren = {
|
|
438
501
|
MailMailboxIdRoute: MailMailboxIdRouteWithChildren,
|
|
439
502
|
MailBriefRoute: MailBriefRouteWithChildren,
|
|
440
503
|
MailFlaggedRoute: MailFlaggedRouteWithChildren,
|
|
441
504
|
MailOutboxRoute: MailOutboxRouteWithChildren,
|
|
442
505
|
MailIndexRoute: MailIndexRoute,
|
|
506
|
+
MailLabelLabelIdRoute: MailLabelLabelIdRouteWithChildren,
|
|
507
|
+
MailLabelIndexRoute: MailLabelIndexRoute,
|
|
443
508
|
};
|
|
444
509
|
const MailRouteWithChildren = MailRoute._addFileChildren(MailRouteChildren);
|
|
445
510
|
const SettingsRouteChildren = {
|
|
@@ -13,9 +13,9 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
13
13
|
* would collapse and scroll to the top the moment someone pressed Reply.
|
|
14
14
|
*/
|
|
15
15
|
import { createFileRoute } from "@tanstack/react-router";
|
|
16
|
-
import {
|
|
16
|
+
import { CollectionPane } from "../../../../components/mail/CollectionPane";
|
|
17
17
|
function FlaggedMessagePane() {
|
|
18
|
-
return _jsx(
|
|
18
|
+
return _jsx(CollectionPane.Reading, {});
|
|
19
19
|
}
|
|
20
20
|
export const Route = createFileRoute("/mail/flagged/$threadId/$messageId")({
|
|
21
21
|
component: FlaggedMessagePane,
|
|
@@ -4,9 +4,9 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
4
4
|
* same as for a thread whose row the reader never pointed at.
|
|
5
5
|
*/
|
|
6
6
|
import { createFileRoute } from "@tanstack/react-router";
|
|
7
|
-
import {
|
|
7
|
+
import { CollectionPane } from "../../../../components/mail/CollectionPane";
|
|
8
8
|
function FlaggedThreadPane() {
|
|
9
|
-
return _jsx(
|
|
9
|
+
return _jsx(CollectionPane.Reading, {});
|
|
10
10
|
}
|
|
11
11
|
export const Route = createFileRoute("/mail/flagged/$threadId/")({
|
|
12
12
|
component: FlaggedThreadPane,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { createFileRoute } from "@tanstack/react-router";
|
|
3
|
-
import {
|
|
3
|
+
import { CollectionPane } from "../../../components/mail/CollectionPane";
|
|
4
4
|
function FlaggedReadingPane() {
|
|
5
|
-
return _jsx(
|
|
5
|
+
return _jsx(CollectionPane.Reading, {});
|
|
6
6
|
}
|
|
7
7
|
export const Route = createFileRoute("/mail/flagged/")({
|
|
8
8
|
component: FlaggedReadingPane,
|
|
@@ -10,14 +10,15 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
10
10
|
import { ErrorState } from "@remit/ui";
|
|
11
11
|
import { createFileRoute, Outlet, } from "@tanstack/react-router";
|
|
12
12
|
import { MailShell } from "../../components/layout/MailShell";
|
|
13
|
-
import {
|
|
13
|
+
import { CollectionPane } from "../../components/mail/CollectionPane";
|
|
14
|
+
import { STARRED } from "../../lib/collection-criteria";
|
|
14
15
|
import { flaggedSearchSchema } from "../../lib/mail-search";
|
|
15
16
|
import { useOpenThreadPath, useSearchMirror } from "../../routing";
|
|
16
17
|
const FlaggedError = ({ error, reset }) => (_jsx("div", { className: "flex h-full items-center justify-center bg-canvas p-4", children: _jsx(ErrorState, { title: "Couldn't load your starred mail", error: error, onRetry: reset }) }));
|
|
17
18
|
function FlaggedLayout() {
|
|
18
19
|
const thread = useOpenThreadPath();
|
|
19
20
|
useSearchMirror({ to: "/mail/flagged" });
|
|
20
|
-
return (_jsx(
|
|
21
|
+
return (_jsx(CollectionPane, { collection: STARRED, title: "Starred", thread: thread, children: _jsx(MailShell, { phone: _jsx(CollectionPane.Phone, {}), list: _jsx(CollectionPane.List, {}), reading: _jsx(Outlet, {}), intelligence: _jsx(CollectionPane.Intelligence, {}), hasThread: Boolean(thread) }) }));
|
|
21
22
|
}
|
|
22
23
|
export const Route = createFileRoute("/mail/flagged")({
|
|
23
24
|
component: FlaggedLayout,
|
package/dist/src/routes/mail/label/$labelId/$threadId/$messageId/$mode.{-$outboxMessageId}.d.ts
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export declare const Route: import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", "/mail", "/mail", "/mail", import("zod").ZodObject<{
|
|
2
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
3
|
+
wizard: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
4
|
+
name: "name";
|
|
5
|
+
match: "match";
|
|
6
|
+
run: "run";
|
|
7
|
+
folder: "folder";
|
|
8
|
+
rule: "rule";
|
|
9
|
+
review: "review";
|
|
10
|
+
properties: "properties";
|
|
11
|
+
}>>>;
|
|
12
|
+
wizardFrom: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodLiteral<"search">>>;
|
|
13
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/mail">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, ({ context: { queryClient } }: import("@tanstack/router-core").LoaderFnContext<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", import("@tanstack/router-core").ResolveParams<"/mail">, {}, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, unknown, undefined>) => void, unknown, unknown, unknown, unknown, undefined>, "/label/$labelId", "/mail/label/$labelId", "/mail/label/$labelId", "/mail/label/$labelId", import("zod").ZodObject<{
|
|
14
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
15
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/label/$labelId">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/$threadId", "/mail/label/$labelId/$threadId", "/mail/label/$labelId/$threadId", "/mail/label/$labelId/$threadId", undefined, import("@tanstack/router-core").ResolveParams<"/$threadId">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/$messageId", "/mail/label/$labelId/$threadId/$messageId", "/mail/label/$labelId/$threadId/$messageId", "/mail/label/$labelId/$threadId/$messageId", undefined, import("@tanstack/router-core").ResolveParams<"/$messageId">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/$mode/{-$outboxMessageId}", "/mail/label/$labelId/$threadId/$messageId/$mode/{-$outboxMessageId}", "/mail/label/$labelId/$threadId/$messageId/$mode/{-$outboxMessageId}", "/mail/label/$labelId/$threadId/$messageId/$mode/{-$outboxMessageId}", import("zod").ZodObject<{
|
|
16
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
17
|
+
body: import("zod").ZodOptional<import("zod").ZodString>;
|
|
18
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/$mode/{-$outboxMessageId}">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
// biome-ignore lint/style/useFilenamingConvention: TanStack Router convention
|
|
2
|
+
/**
|
|
3
|
+
* The reply, reply-all or forward under a conversation opened from a label.
|
|
4
|
+
* The conversation reads it off the address and opens it at its head.
|
|
5
|
+
*/
|
|
6
|
+
import { createFileRoute } from "@tanstack/react-router";
|
|
7
|
+
import { replySearchSchemas } from "../../../../../../lib/mail-search";
|
|
8
|
+
export const Route = createFileRoute("/mail/label/$labelId/$threadId/$messageId/$mode/{-$outboxMessageId}")({ validateSearch: replySearchSchemas.label });
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare const Route: import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", "/mail", "/mail", "/mail", import("zod").ZodObject<{
|
|
2
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
3
|
+
wizard: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
4
|
+
name: "name";
|
|
5
|
+
match: "match";
|
|
6
|
+
run: "run";
|
|
7
|
+
folder: "folder";
|
|
8
|
+
rule: "rule";
|
|
9
|
+
review: "review";
|
|
10
|
+
properties: "properties";
|
|
11
|
+
}>>>;
|
|
12
|
+
wizardFrom: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodLiteral<"search">>>;
|
|
13
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/mail">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, ({ context: { queryClient } }: import("@tanstack/router-core").LoaderFnContext<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", import("@tanstack/router-core").ResolveParams<"/mail">, {}, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, unknown, undefined>) => void, unknown, unknown, unknown, unknown, undefined>, "/label/$labelId", "/mail/label/$labelId", "/mail/label/$labelId", "/mail/label/$labelId", import("zod").ZodObject<{
|
|
14
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
15
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/label/$labelId">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/$threadId", "/mail/label/$labelId/$threadId", "/mail/label/$labelId/$threadId", "/mail/label/$labelId/$threadId", undefined, import("@tanstack/router-core").ResolveParams<"/$threadId">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/$messageId", "/mail/label/$labelId/$threadId/$messageId", "/mail/label/$labelId/$threadId/$messageId", "/mail/label/$labelId/$threadId/$messageId", undefined, import("@tanstack/router-core").ResolveParams<"/$messageId">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
/**
|
|
3
|
+
* /mail/label/$labelId/$threadId/$messageId — the same conversation, with one
|
|
4
|
+
* of its messages expanded and scrolled to. It mounts the pane rather than
|
|
5
|
+
* delegating to an index route, because the reply is a segment under it.
|
|
6
|
+
*/
|
|
7
|
+
import { createFileRoute } from "@tanstack/react-router";
|
|
8
|
+
import { CollectionPane } from "../../../../../components/mail/CollectionPane";
|
|
9
|
+
function LabelMessagePane() {
|
|
10
|
+
return _jsx(CollectionPane.Reading, {});
|
|
11
|
+
}
|
|
12
|
+
export const Route = createFileRoute("/mail/label/$labelId/$threadId/$messageId")({
|
|
13
|
+
component: LabelMessagePane,
|
|
14
|
+
});
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare const Route: import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", "/mail", "/mail", "/mail", import("zod").ZodObject<{
|
|
2
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
3
|
+
wizard: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
4
|
+
name: "name";
|
|
5
|
+
match: "match";
|
|
6
|
+
run: "run";
|
|
7
|
+
folder: "folder";
|
|
8
|
+
rule: "rule";
|
|
9
|
+
review: "review";
|
|
10
|
+
properties: "properties";
|
|
11
|
+
}>>>;
|
|
12
|
+
wizardFrom: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodLiteral<"search">>>;
|
|
13
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/mail">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, ({ context: { queryClient } }: import("@tanstack/router-core").LoaderFnContext<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", import("@tanstack/router-core").ResolveParams<"/mail">, {}, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, unknown, undefined>) => void, unknown, unknown, unknown, unknown, undefined>, "/label/$labelId", "/mail/label/$labelId", "/mail/label/$labelId", "/mail/label/$labelId", import("zod").ZodObject<{
|
|
14
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
15
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/label/$labelId">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/$threadId", "/mail/label/$labelId/$threadId", "/mail/label/$labelId/$threadId", "/mail/label/$labelId/$threadId", undefined, import("@tanstack/router-core").ResolveParams<"/$threadId">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/mail/label/$labelId/$threadId/", "/mail/label/$labelId/$threadId/", "/mail/label/$labelId/$threadId/", undefined, import("@tanstack/router-core").ResolveParams<"/">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { createFileRoute } from "@tanstack/react-router";
|
|
3
|
+
import { CollectionPane } from "../../../../../components/mail/CollectionPane";
|
|
4
|
+
function LabelThreadPane() {
|
|
5
|
+
return _jsx(CollectionPane.Reading, {});
|
|
6
|
+
}
|
|
7
|
+
export const Route = createFileRoute("/mail/label/$labelId/$threadId/")({
|
|
8
|
+
component: LabelThreadPane,
|
|
9
|
+
});
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare const Route: import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", "/mail", "/mail", "/mail", import("zod").ZodObject<{
|
|
2
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
3
|
+
wizard: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
4
|
+
name: "name";
|
|
5
|
+
match: "match";
|
|
6
|
+
run: "run";
|
|
7
|
+
folder: "folder";
|
|
8
|
+
rule: "rule";
|
|
9
|
+
review: "review";
|
|
10
|
+
properties: "properties";
|
|
11
|
+
}>>>;
|
|
12
|
+
wizardFrom: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodLiteral<"search">>>;
|
|
13
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/mail">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, ({ context: { queryClient } }: import("@tanstack/router-core").LoaderFnContext<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", import("@tanstack/router-core").ResolveParams<"/mail">, {}, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, unknown, undefined>) => void, unknown, unknown, unknown, unknown, undefined>, "/label/$labelId", "/mail/label/$labelId", "/mail/label/$labelId", "/mail/label/$labelId", import("zod").ZodObject<{
|
|
14
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
15
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/label/$labelId">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/$threadId", "/mail/label/$labelId/$threadId", "/mail/label/$labelId/$threadId", "/mail/label/$labelId/$threadId", undefined, import("@tanstack/router-core").ResolveParams<"/$threadId">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* /mail/label/$labelId/$threadId — a conversation open in the label list's
|
|
3
|
+
* reading pane. A layout, because the message segment nests under it.
|
|
4
|
+
*/
|
|
5
|
+
import { createFileRoute, Outlet } from "@tanstack/react-router";
|
|
6
|
+
export const Route = createFileRoute("/mail/label/$labelId/$threadId")({
|
|
7
|
+
component: Outlet,
|
|
8
|
+
});
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare const Route: import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", "/mail", "/mail", "/mail", import("zod").ZodObject<{
|
|
2
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
3
|
+
wizard: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
4
|
+
name: "name";
|
|
5
|
+
match: "match";
|
|
6
|
+
run: "run";
|
|
7
|
+
folder: "folder";
|
|
8
|
+
rule: "rule";
|
|
9
|
+
review: "review";
|
|
10
|
+
properties: "properties";
|
|
11
|
+
}>>>;
|
|
12
|
+
wizardFrom: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodLiteral<"search">>>;
|
|
13
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/mail">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, ({ context: { queryClient } }: import("@tanstack/router-core").LoaderFnContext<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", import("@tanstack/router-core").ResolveParams<"/mail">, {}, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, unknown, undefined>) => void, unknown, unknown, unknown, unknown, undefined>, "/label/$labelId", "/mail/label/$labelId", "/mail/label/$labelId", "/mail/label/$labelId", import("zod").ZodObject<{
|
|
14
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
15
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/label/$labelId">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/compose/{-$outboxMessageId}", "/mail/label/$labelId/compose/{-$outboxMessageId}", "/mail/label/$labelId/compose/{-$outboxMessageId}", "/mail/label/$labelId/compose/{-$outboxMessageId}", undefined, import("@tanstack/router-core").ResolveParams<"/compose/{-$outboxMessageId}">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
// biome-ignore lint/style/useFilenamingConvention: TanStack Router convention
|
|
2
|
+
/**
|
|
3
|
+
* /mail/label/$labelId/compose — the compose surface, open over a label, and
|
|
4
|
+
* /mail/label/$labelId/compose/<outboxMessageId> once it has a draft.
|
|
5
|
+
*/
|
|
6
|
+
import { createFileRoute } from "@tanstack/react-router";
|
|
7
|
+
import { FullCompose } from "../../../../components/compose/FullCompose";
|
|
8
|
+
export const Route = createFileRoute("/mail/label/$labelId/compose/{-$outboxMessageId}")({
|
|
9
|
+
component: FullCompose,
|
|
10
|
+
});
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare const Route: import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", "/mail", "/mail", "/mail", import("zod").ZodObject<{
|
|
2
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
3
|
+
wizard: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
4
|
+
name: "name";
|
|
5
|
+
match: "match";
|
|
6
|
+
run: "run";
|
|
7
|
+
folder: "folder";
|
|
8
|
+
rule: "rule";
|
|
9
|
+
review: "review";
|
|
10
|
+
properties: "properties";
|
|
11
|
+
}>>>;
|
|
12
|
+
wizardFrom: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodLiteral<"search">>>;
|
|
13
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/mail">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, ({ context: { queryClient } }: import("@tanstack/router-core").LoaderFnContext<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", import("@tanstack/router-core").ResolveParams<"/mail">, {}, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, unknown, undefined>) => void, unknown, unknown, unknown, unknown, undefined>, "/label/$labelId", "/mail/label/$labelId", "/mail/label/$labelId", "/mail/label/$labelId", import("zod").ZodObject<{
|
|
14
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
15
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/label/$labelId">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/mail/label/$labelId/", "/mail/label/$labelId/", "/mail/label/$labelId/", undefined, import("@tanstack/router-core").ResolveParams<"/">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { createFileRoute } from "@tanstack/react-router";
|
|
3
|
+
import { CollectionPane } from "../../../../components/mail/CollectionPane";
|
|
4
|
+
function LabelReadingPane() {
|
|
5
|
+
return _jsx(CollectionPane.Reading, {});
|
|
6
|
+
}
|
|
7
|
+
export const Route = createFileRoute("/mail/label/$labelId/")({
|
|
8
|
+
component: LabelReadingPane,
|
|
9
|
+
});
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare const Route: import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", "/mail", "/mail", "/mail", import("zod").ZodObject<{
|
|
2
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
3
|
+
wizard: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
4
|
+
name: "name";
|
|
5
|
+
match: "match";
|
|
6
|
+
run: "run";
|
|
7
|
+
folder: "folder";
|
|
8
|
+
rule: "rule";
|
|
9
|
+
review: "review";
|
|
10
|
+
properties: "properties";
|
|
11
|
+
}>>>;
|
|
12
|
+
wizardFrom: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodLiteral<"search">>>;
|
|
13
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/mail">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, ({ context: { queryClient } }: import("@tanstack/router-core").LoaderFnContext<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", import("@tanstack/router-core").ResolveParams<"/mail">, {}, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, unknown, undefined>) => void, unknown, unknown, unknown, unknown, undefined>, "/label/$labelId", "/mail/label/$labelId", "/mail/label/$labelId", "/mail/label/$labelId", import("zod").ZodObject<{
|
|
14
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
15
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/label/$labelId">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
/**
|
|
3
|
+
* /mail/label/$labelId — one label across every account, a flat list of the
|
|
4
|
+
* label's folder in each of them.
|
|
5
|
+
*
|
|
6
|
+
* The same layout as Starred: list, reading pane and intelligence rail, with
|
|
7
|
+
* the open thread and the message inside it as the segments below.
|
|
8
|
+
*/
|
|
9
|
+
import { createFileRoute, Outlet } from "@tanstack/react-router";
|
|
10
|
+
import { useMemo } from "react";
|
|
11
|
+
import { MailShell } from "../../../components/layout/MailShell";
|
|
12
|
+
import { CollectionPane } from "../../../components/mail/CollectionPane";
|
|
13
|
+
import { useLabelList } from "../../../hooks/useLabels";
|
|
14
|
+
import { useMailContext } from "../../../lib/mail-context";
|
|
15
|
+
import { labelSearchSchema } from "../../../lib/mail-search";
|
|
16
|
+
import { useOpenThreadPath, useSearchMirror } from "../../../routing";
|
|
17
|
+
function LabelLayout() {
|
|
18
|
+
const { labelId } = Route.useParams();
|
|
19
|
+
const { accounts } = useMailContext();
|
|
20
|
+
const thread = useOpenThreadPath();
|
|
21
|
+
const { labels } = useLabelList(accounts[0]?.accountId);
|
|
22
|
+
const name = labels.find((label) => label.labelId === labelId)?.name ?? "";
|
|
23
|
+
useSearchMirror({ to: "/mail/label/$labelId", params: { labelId } });
|
|
24
|
+
const collection = useMemo(() => ({ labelId }), [labelId]);
|
|
25
|
+
return (_jsx(CollectionPane, { collection: collection, title: name, thread: thread, children: _jsx(MailShell, { phone: _jsx(CollectionPane.Phone, {}), list: _jsx(CollectionPane.List, {}), reading: _jsx(Outlet, {}), intelligence: _jsx(CollectionPane.Intelligence, {}), hasThread: Boolean(thread) }) }));
|
|
26
|
+
}
|
|
27
|
+
export const Route = createFileRoute("/mail/label/$labelId")({
|
|
28
|
+
component: LabelLayout,
|
|
29
|
+
validateSearch: labelSearchSchema,
|
|
30
|
+
});
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
export declare const Route: import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", "/mail", "/mail", "/mail", import("zod").ZodObject<{
|
|
2
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
3
|
+
wizard: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
4
|
+
name: "name";
|
|
5
|
+
match: "match";
|
|
6
|
+
run: "run";
|
|
7
|
+
folder: "folder";
|
|
8
|
+
rule: "rule";
|
|
9
|
+
review: "review";
|
|
10
|
+
properties: "properties";
|
|
11
|
+
}>>>;
|
|
12
|
+
wizardFrom: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodLiteral<"search">>>;
|
|
13
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/mail">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, ({ context: { queryClient } }: import("@tanstack/router-core").LoaderFnContext<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", import("@tanstack/router-core").ResolveParams<"/mail">, {}, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, unknown, undefined>) => void, unknown, unknown, unknown, unknown, undefined>, "/label", "/mail/label/", "/mail/label/", "/mail/label/", import("zod").ZodObject<{
|
|
14
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
15
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/label">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, ({ search, location }: import("@tanstack/router-core").BeforeLoadContextOptions<import("@tanstack/react-router").Register, import("@tanstack/router-core").Route<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", "/mail", "/mail", "/mail", import("zod").ZodObject<{
|
|
16
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
17
|
+
wizard: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
18
|
+
name: "name";
|
|
19
|
+
match: "match";
|
|
20
|
+
run: "run";
|
|
21
|
+
folder: "folder";
|
|
22
|
+
rule: "rule";
|
|
23
|
+
review: "review";
|
|
24
|
+
properties: "properties";
|
|
25
|
+
}>>>;
|
|
26
|
+
wizardFrom: import("zod").ZodCatch<import("zod").ZodOptional<import("zod").ZodLiteral<"search">>>;
|
|
27
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/mail">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, ({ context: { queryClient } }: import("@tanstack/router-core").LoaderFnContext<import("@tanstack/react-router").Register, import("@tanstack/react-router").RootRoute<import("@tanstack/react-router").Register, undefined, import("../../../router").RouterContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/mail", import("@tanstack/router-core").ResolveParams<"/mail">, {}, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, unknown, undefined>) => void, unknown, unknown, unknown, unknown, undefined>, import("zod").ZodObject<{
|
|
28
|
+
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
29
|
+
}, import("zod/v4/core").$strip>, import("@tanstack/router-core").ResolveParams<"/label">, import("@tanstack/router-core").AnyContext, import("@tanstack/router-core").AnyContext, "/mail/label/", unknown, undefined>) => never, {}, undefined, unknown, unknown, unknown, unknown, undefined>;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `/mail/label` names no label, so it is no list. Without this route the
|
|
3
|
+
* segment would be read as a mailbox id; it goes on to the brief the way `/mail`
|
|
4
|
+
* does.
|
|
5
|
+
*/
|
|
6
|
+
import { createFileRoute, redirect } from "@tanstack/react-router";
|
|
7
|
+
import { mailIndexSearchSchema } from "../../../lib/mail-search";
|
|
8
|
+
export const Route = createFileRoute("/mail/label/")({
|
|
9
|
+
validateSearch: mailIndexSearchSchema,
|
|
10
|
+
beforeLoad: ({ search, location }) => {
|
|
11
|
+
throw redirect({
|
|
12
|
+
to: "/mail/brief",
|
|
13
|
+
search,
|
|
14
|
+
hash: location.hash,
|
|
15
|
+
replace: true,
|
|
16
|
+
});
|
|
17
|
+
},
|
|
18
|
+
});
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type BrowsedList } from "../lib/mail-route";
|
|
2
2
|
export type { BrowsedList };
|
|
3
3
|
/**
|
|
4
|
-
* The list the address is browsing, as the
|
|
4
|
+
* The list the address is browsing, as the values a navigation to it needs.
|
|
5
5
|
*
|
|
6
6
|
* Every surface a list can open — compose, a reply, a conversation — reads the
|
|
7
7
|
* same answer, so the four lists cannot disagree about which one is underneath.
|
|
@@ -3,7 +3,7 @@ import { useCallback, useMemo } from "react";
|
|
|
3
3
|
import { locationOpensDetail, mailListRoute, } from "../lib/mail-route";
|
|
4
4
|
import { useRetainOpenPanels } from "./fragment";
|
|
5
5
|
/**
|
|
6
|
-
* The list the address is browsing, as the
|
|
6
|
+
* The list the address is browsing, as the values a navigation to it needs.
|
|
7
7
|
*
|
|
8
8
|
* Every surface a list can open — compose, a reply, a conversation — reads the
|
|
9
9
|
* same answer, so the four lists cannot disagree about which one is underneath.
|
|
@@ -16,7 +16,9 @@ export function useBrowsedList() {
|
|
|
16
16
|
});
|
|
17
17
|
const mailbox = useParams({ from: "/mail/$mailboxId", shouldThrow: false });
|
|
18
18
|
const mailboxId = mailbox?.mailboxId;
|
|
19
|
-
|
|
19
|
+
const label = useParams({ from: "/mail/label/$labelId", shouldThrow: false });
|
|
20
|
+
const labelId = label?.labelId;
|
|
21
|
+
return useMemo(() => ({ list, mailboxId, labelId }), [list, mailboxId, labelId]);
|
|
20
22
|
}
|
|
21
23
|
/**
|
|
22
24
|
* Whether the address names something the list has open below it — a
|
|
@@ -40,7 +42,7 @@ export function useOpensDetail() {
|
|
|
40
42
|
export function useNavigateToBrowsedList() {
|
|
41
43
|
const navigate = useNavigate();
|
|
42
44
|
const retainPanels = useRetainOpenPanels();
|
|
43
|
-
const { list, mailboxId } = useBrowsedList();
|
|
45
|
+
const { list, mailboxId, labelId } = useBrowsedList();
|
|
44
46
|
return useCallback(() => {
|
|
45
47
|
const search = (prev) => prev;
|
|
46
48
|
const hash = retainPanels;
|
|
@@ -56,6 +58,15 @@ export function useNavigateToBrowsedList() {
|
|
|
56
58
|
navigate({ to: "/mail/$mailboxId", params: { mailboxId }, search, hash });
|
|
57
59
|
return;
|
|
58
60
|
}
|
|
61
|
+
if (list === "label" && labelId) {
|
|
62
|
+
navigate({
|
|
63
|
+
to: "/mail/label/$labelId",
|
|
64
|
+
params: { labelId },
|
|
65
|
+
search,
|
|
66
|
+
hash,
|
|
67
|
+
});
|
|
68
|
+
return;
|
|
69
|
+
}
|
|
59
70
|
navigate({ to: "/mail/brief", search, hash });
|
|
60
|
-
}, [navigate, retainPanels, list, mailboxId]);
|
|
71
|
+
}, [navigate, retainPanels, list, mailboxId, labelId]);
|
|
61
72
|
}
|